/* =========================================================
   Data Sync Pro · home
   ========================================================= */

:root {
  /* LIGHT / hi-tech palette */
  --paper: #FAFBFC;
  --paper-2: #F2F4F8;
  --paper-3: #EAEEF3;
  --paper-deep: #0B1019;       /* dark accent band — ribbon / functions / closing */
  --card: #FFFFFF;
  --card-2: #FAFBFC;
  --ink: #0E141C;
  --ink-head: #0B2227;        /* deep teal-navy — branded heading ink */
  --ink-2: #2D3340;
  --ink-3: #5E6878;
  --mute: #8A93A1;
  --rule: #E3E7EE;
  --rule-2: #C9D0DA;
  --brand: #07A6A8;            /* vivid teal — brighter, ServiceNow-style pop */
  --brand-ink: #0B5E60;        /* darker brand text */
  --brand-soft: #E0EFEF;       /* pale teal wash */
  --brand-pure: #7FB9BB;       /* logo elephant teal */
  --brand-bright: #0FD49E;     /* brand green — bright on dark accent bands */
  --signal: #C84A1A;
  --signal-soft: #FBE7DC;
  --good: #117D4F;
  --good-soft: #DCF0E5;
  --code-bg: #0B1019;
  --code-fg: #E8EDF3;
  --code-mute: #8A93A1;

  /* On-dark text — used inside .ribbon / .functions / .closing */
  --ink-on-dark: #E8EDF3;
  --ink-2-on-dark: #B6BDC8;
  --ink-3-on-dark: #7C8493;

  --r-xs: 2px;
  --r-sm: 4px;
  --r-md: 6px;
  --r-lg: 10px;
  --r-xl: 14px;

  --sh-1: 0 1px 0 rgba(11,16,25,.03), 0 1px 2px rgba(11,16,25,.05);
  --sh-2: 0 1px 0 rgba(11,16,25,.03), 0 8px 24px -10px rgba(11,16,25,.14);
  --sh-3: 0 1px 0 rgba(11,16,25,.04), 0 24px 60px -24px rgba(11,16,25,.22), 0 0 0 1px rgba(127,185,187,.08);

  --gutter: clamp(20px, 4vw, 56px);
  --max: min(95vw, 1880px);

  --f-sans: "Geist", "Söhne", -apple-system, "Segoe UI", sans-serif;
  --f-display: "Figtree", "Geist", -apple-system, "Segoe UI", sans-serif;
  --f-mono: "Geist Mono", "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --f-serif: "Instrument Serif", "Iowan Old Style", Georgia, serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body::before {
  content: '';
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(127,185,187,.14), transparent 60%),
    radial-gradient(ellipse 60% 40% at 100% 100%, rgba(127,185,187,.08), transparent 60%),
    radial-gradient(circle at 1px 1px, rgba(11,16,25,.10) 1px, transparent 1.5px) 0 0 / 22px 22px;
  mask-image: linear-gradient(180deg, black, transparent 70%);
  -webkit-mask-image: linear-gradient(180deg, black, transparent 70%);
}
body > * { position: relative; z-index: 1; }
html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; scroll-behavior: smooth; scroll-padding-top: 76px; overflow-x: clip; }
body {
  /* clip the ~scrollbar-width overhang from full-bleed 100vw backgrounds
     (e.g. .surfaces-sticky::before) so the page never scrolls horizontally.
     `clip` (not `hidden`) avoids creating a scroll container, so the sticky
     capability shelf keeps working. */
  overflow-x: clip;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-sans);
  font-feature-settings: "ss01", "ss02", "cv11";
  font-size: 17px;
  line-height: 1.5;
  letter-spacing: -0.005em;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

::selection { background: var(--ink); color: var(--paper); }

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- Type ---------- */
.eyebrow {
  font-family: var(--f-mono);
  font-size: 15px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
}
.eyebrow .dot {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 999px;
  background: var(--brand);
  margin-right: 10px;
  vertical-align: 2px;
}
h1, h2, h3, h4 { margin: 0; font-family: var(--f-display); font-weight: 800; letter-spacing: -0.03em; line-height: 1.02; color: var(--ink-head); }
h1 { font-size: clamp(36px, 3.4vw, 52px); font-weight: 800; letter-spacing: -0.035em; line-height: 0.98; }
.hero h1 .slogan {
  display: block;
}
.hero h1 { font-size: clamp(40px, 3.9vw, 60px); }
.hero h1 .slogan + .slogan {
  margin-top: 0.32em;
}

.hero-replaces {
  margin-top: 32px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
}
.hero-replaces .hr-items {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  align-items: baseline;
}
.hero-replaces .hr-tag {
  font-family: var(--f-mono);
  font-size: 21px;
  letter-spacing: -0.005em;
  color: var(--ink-3);
  background: none;
  border: none;
  padding: 0;
  white-space: nowrap;
  text-decoration: line-through;
  text-decoration-color: var(--signal);
  text-decoration-thickness: 2.5px;
  font-weight: 500;
}
.hero-replaces .hr-arrow {
  display: inline-flex;
  width: 32px;
  height: 32px;
  color: var(--brand);
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.hero-replaces .hr-arrow svg {
  width: 28px;
  height: 28px;
}
.hero-replaces .hr-target {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 34px;
  color: var(--brand-ink);
  letter-spacing: -0.01em;
  line-height: 1;
}
h2 { font-size: clamp(40px, 4.4vw, 60px); letter-spacing: -0.03em; }
h3 { font-size: clamp(21px, 1.9vw, 26px); letter-spacing: -0.02em; line-height: 1.15; }
h4 { font-size: 17px; letter-spacing: -0.01em; line-height: 1.2; }
.serif-italic {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
}
p { margin: 0; }
.lead {
  font-size: clamp(17px, 1.2vw, 20px);
  color: var(--ink-3);
  max-width: 56ch;
  line-height: 1.45;
}
.mono { font-family: var(--f-mono); }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  padding: 3px 8px 4px;
  border: 1px solid var(--rule);
  background: var(--paper);
  border-radius: 999px;
  color: var(--ink-2);
}
.tag.brand { background: var(--brand-soft); border-color: rgba(63,133,135,.22); color: var(--brand-ink); }
.tag.signal { background: var(--signal-soft); border-color: rgba(200,74,26,.22); color: var(--signal); }
.tag.good { background: var(--good-soft); border-color: rgba(14,110,71,.2); color: var(--good); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 999px;
  font-family: var(--f-sans);
  font-size: 15.5px;
  font-weight: 600;
  letter-spacing: 0.005em;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  white-space: nowrap;
  transition: transform .15s ease, background .15s ease, color .15s ease;
}
.btn:hover { transform: translateY(-1px); background: #1B2230; }
.btn.secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--rule-2);
}
.btn.secondary:hover { background: var(--paper-2); border-color: var(--ink); }
.btn .arrow {
  width: 14px; height: 14px;
  transition: transform .2s ease;
}
.btn:hover .arrow { transform: translateX(2px); }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in oklab, var(--paper) 80%, transparent);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  backdrop-filter: blur(12px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, background .2s ease;
}
.nav.scrolled { border-bottom-color: var(--rule); }
.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 14px var(--gutter);
  display: flex;
  align-items: center;
  gap: 32px;
}
.brand-mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 500;
  letter-spacing: -0.01em;
  white-space: nowrap;
  flex: 0 0 auto;
}
.brand-mark .logo {
  width: 28px; height: 28px;
  display: block;
  flex: 0 0 auto;
}
.nav .brand-mark span { color: var(--brand-ink); font-size: 14.5px; }
.nav .brand-mark .logo { width: 36px; height: 36px; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14.5px;
  color: var(--ink-2);
  margin-left: 8px;
}
.nav-links a {
  padding: 8px 12px;
  border-radius: 8px;
  white-space: nowrap;
  transition: background .12s ease, color .12s ease;
}
body.sn-hero .nav-links a { color: var(--ink); font-size: 15.5px; font-weight: 500; }
body.sn-hero .nav-links a.active { color: #FFFFFF; background: rgba(15,212,158,.12); }
body.sn-hero .nav-links a.active::after { background: var(--sn-btn, #0FD49E); }
body.sn-hero .nav-links a:hover { color: #fff; background: rgba(255,255,255,.06); }
body.sn-hero .nav-cta .btn:not(.secondary) { background: var(--sn-btn, #0FD49E); border-color: var(--sn-btn, #0FD49E); color: #06231C; }
body.sn-hero .nav-cta .btn:not(.secondary):hover { filter: brightness(1.08); }
.nav-links a:hover { background: var(--paper-2); color: var(--ink); }
.nav-links a.active {
  color: var(--brand-ink);
  background: var(--brand-soft);
}
.nav-links a.active::after {
  content: '';
  position: absolute;
  left: 12px; right: 12px;
  bottom: 2px;
  height: 2px;
  background: var(--brand);
  border-radius: 2px;
}
.nav-links a { position: relative; }
.nav-spacer { flex: 1; }
.nav-cta {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-cta .btn { padding: 8px 14px; font-size: 14px; }

/* ---------- Nav: Resources dropdown ---------- */
.nav-dd { position: relative; }
.nav-dd-trigger {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 12px;
  border: 0;
  background: transparent;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14.5px;
  letter-spacing: inherit;
  color: var(--ink-2);
  transition: background .12s ease, color .12s ease;
}
.nav-dd-trigger:hover,
.nav-dd:hover .nav-dd-trigger,
.nav-dd-trigger[aria-expanded="true"] { background: var(--paper-2); color: var(--ink); }
.nav-dd-trigger .dd-chev { width: 14px; height: 14px; transition: transform .15s ease; }
.nav-dd:hover .dd-chev,
.nav-dd-trigger[aria-expanded="true"] .dd-chev { transform: rotate(180deg); }
.nav-dd-menu {
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 8px;
  min-width: 212px;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-2);
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity .14s ease, transform .14s ease, visibility .14s;
  z-index: 60;
}
/* Invisible bridge across the 8px gap so hover doesn't drop. */
.nav-dd-menu::before {
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: -8px;
  height: 8px;
}
.nav-dd:hover .nav-dd-menu,
.nav-dd:focus-within .nav-dd-menu,
.nav-dd-menu.open { opacity: 1; visibility: visible; transform: none; }
.nav-dd-menu a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 6px;
  font-size: 14px;
  color: var(--ink-2);
  white-space: nowrap;
  transition: background .12s ease, color .12s ease;
}
.nav-dd-menu a:hover { background: var(--paper-2); color: var(--ink); }
.nav-dd-menu .dd-ext { width: 13px; height: 13px; color: var(--mute); flex: 0 0 auto; }
.nav-dd-divider { height: 1px; background: var(--rule); margin: 6px 8px; }
.nav-dd-label {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
  padding: 6px 12px 4px;
}

/* ---------- Nav: mobile toggle + panel ---------- */
.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--rule);
  border-radius: 9px;
  background: var(--card);
  color: var(--ink);
  flex: 0 0 auto;
}
.nav-toggle-bars { position: relative; width: 18px; height: 12px; }
.nav-toggle-bars span {
  position: absolute;
  left: 0; right: 0;
  height: 1.7px;
  border-radius: 2px;
  background: currentColor;
  transition: transform .2s ease, opacity .15s ease, top .2s ease;
}
.nav-toggle-bars span:nth-child(1) { top: 0; }
.nav-toggle-bars span:nth-child(2) { top: 5px; }
.nav-toggle-bars span:nth-child(3) { top: 10px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(1) { top: 5px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(3) { top: 5px; transform: rotate(-45deg); }

.nav-mobile {
  display: none;
  border-top: 1px solid var(--rule);
  background: color-mix(in oklab, var(--paper) 94%, transparent);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  backdrop-filter: blur(12px) saturate(140%);
  max-height: calc(100vh - 57px);
  overflow-y: auto;
}
.nav-mobile-inner {
  display: flex;
  flex-direction: column;
  padding: 8px var(--gutter) 24px;
}
.nav-mobile a:not(.btn) {
  padding: 13px 4px;
  font-size: 16px;
  color: var(--ink-2);
  border-bottom: 1px solid var(--rule);
  transition: color .12s ease;
}
.nav-mobile a:not(.btn):hover,
.nav-mobile a:not(.btn):active { color: var(--brand-ink); }
.nav-mobile-label {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
  padding: 18px 4px 4px;
}
.nav-mobile-cta {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}
.nav-mobile-cta .btn { width: 100%; justify-content: center; }

@media (max-width: 980px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav.menu-open .nav-mobile { display: block; }
}

/* =========================================================
   Hero
   ========================================================= */
.hero {
  padding: 0;
  position: relative;
  overflow: hidden;
  min-height: calc(100vh - var(--nav-h, 77px));
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero > .container { width: 100%; display: flex; align-items: center; }
.hero > .container.hero-main { flex: 1 1 auto; align-items: center; }
.hero > .container.hero-topbar { flex: 0 0 auto; display: block; padding-top: 30px; }
.hero-eyebrow { margin: 0 0 40px; }
.hero > .ribbon { flex: 0 0 auto; width: 100%; }
@media (max-width: 940px) {
  .hero { min-height: 0; display: block; padding-top: 28px; }
}
.hero-grid {
  display: grid;
  width: 100%;
  grid-template-columns: 1.02fr 0.98fr;
  gap: 48px;
  align-items: center;
}
@media (max-width: 940px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
}
.hero h1 .it {
  color: var(--ink);
}
.hero h1 .brand-word {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--brand-ink);
  padding-right: 0.04em;
  -webkit-text-stroke: 0.45px currentColor;
}
.hero h1 .mute-it {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--signal);
  padding-right: 0.04em;
  -webkit-text-stroke: 0.45px currentColor;
}
.hero h1 .good-it {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.015em;
  word-spacing: 0.16em;
  color: #397B53;
  padding-right: 0.04em;
  -webkit-text-stroke: 0.45px currentColor;
}
.hero h1 .ink-mute {
  color: var(--ink-3);
  font-weight: 500;
}
.hero .lead { margin-top: 24px; }


.results-block {
  margin-top: 48px;
  max-width: 58ch;
}
.results-block .results-head {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--brand);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}
.results-block .results-head::before {
  content: "";
  width: 28px; height: 1px;
  background: var(--brand);
}
.results {
  list-style: none;
  padding: 0; margin: 0;
  display: grid;
}
.results li {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 14px;
  padding: 8px 0;
  border-top: 1px solid var(--rule);
  align-items: baseline;
}
.results li .n {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  color: var(--brand);
  font-weight: 500;
}
.results li .r {
  font-size: 15px;
  color: var(--ink-2);
  line-height: 1.35;
  letter-spacing: -.005em;
}
.results li .r b {
  color: var(--ink);
  font-weight: 500;
}
.results-note {
  margin: 18px 0 0;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--ink-3);
  max-width: none;
  text-wrap: pretty;
}
.hero-cta {
  margin-top: 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.hero-trust {
  margin-top: 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  font-family: var(--f-sans);
  font-size: 15px;
  color: var(--ink-3);
  letter-spacing: .01em;
}
.hero-trust .pip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 999px;
  box-shadow: var(--sh-1);
}
.hero-trust .pip svg { width: 14px; height: 14px; }
.hero-trust .pip-strong {
  padding: 9px 16px;
  font-size: 15px;
  white-space: nowrap;
  color: var(--brand-ink);
  background: var(--brand-soft);
  border-color: color-mix(in oklab, var(--brand) 30%, transparent);
}
.hero-trust .pip-strong svg { width: 16px; height: 16px; color: var(--brand); }
.hero-trust .pip-strong b { font-weight: 700; color: var(--brand-ink); }

/* ----- Executable Card (hero visual) ----- */
.exec-card {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-3);
  overflow: hidden;
  position: relative;
}
.exec-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(60% 80% at 100% 0%, rgba(127,185,187,.16), transparent 60%);
}
.exec-head {
  padding: 18px 22px;
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid var(--rule);
  background: linear-gradient(180deg, var(--paper-3), transparent);
}
.exec-head .icn {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--brand-soft);
  color: var(--brand-ink);
}
.exec-head .icn svg { width: 18px; height: 18px; }
.exec-head .title-row {
  display: flex; flex-direction: column; gap: 2px;
}
.exec-head .obj {
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: .02em;
}
.exec-head .name {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.exec-head .spacer { flex: 1; }
.exec-head .pill {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--good-soft);
  color: var(--good);
  border: 1px solid rgba(14,110,71,.18);
}
.exec-rows {
  display: grid;
  grid-template-columns: 130px 1fr;
}
.exec-row {
  display: contents;
}
.exec-row > .k, .exec-row > .v {
  padding: 22px 22px;
  border-top: 1px solid var(--rule);
  font-size: 14.5px;
}
.exec-row > .k {
  font-family: var(--f-sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-3);
  background: var(--paper-3);
  display: flex;
  align-items: flex-start;
  padding-top: 22px;
}
.exec-row > .v {
  font-family: var(--f-mono);
  color: var(--ink);
  font-size: 13.5px;
  line-height: 1.55;
}
.exec-row .v .tok-fn { color: var(--brand-ink); }
.exec-row .v .tok-str { color: var(--good); }
.exec-row .v .tok-op { color: var(--ink-3); }
.exec-row .v .tok-field { color: var(--ink); }
.exec-row .v .row-line { display: block; }
.exec-row .v .row-line + .row-line { margin-top: 6px; }
.exec-row .v .arrow-asn { color: var(--brand); margin: 0 6px; }

.exec-card.hero-card { transform-origin: center; }
.exec-card.hero-card:hover { /* subtle */ }

/* =========================================================
   Batch Execution Widget (hero + capability viz)
   ========================================================= */
.batch-widget {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-3);
  overflow: hidden;
  position: relative;
}
.batch-widget::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(60% 80% at 100% 0%, rgba(127,185,187,.16), transparent 60%);
}
.bw-head {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid var(--rule);
  background: linear-gradient(180deg, var(--paper-3), transparent);
  position: relative;
}
.bw-head .icn {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: grid; place-items: center;
  background: var(--brand-soft);
  color: var(--brand-ink);
}
.bw-head .icn svg { width: 18px; height: 18px; }
.bw-head .titles {
  display: flex; flex-direction: column; gap: 2px;
  min-width: 0;
}
.bw-head .obj-tag {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: .04em;
}
.bw-head .obj-name {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bw-head .spacer { flex: 1; }
.bw-head .run-btn {
  padding: 7px 13px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 999px;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  border: 0;
  display: inline-flex; align-items: center; gap: 6px;
}
.bw-head .run-btn .pulse {
  width: 6px; height: 6px;
  border-radius: 999px;
  background: #6BE0A0;
  display: inline-block;
  animation: pulse 1.4s ease-in-out infinite;
}
.bw-head .run-btn.done .pulse {
  animation: none;
  opacity: 1;
  transform: none;
  background: var(--sn-btn, #28E07A);
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .4; transform: scale(1.4); }
}
.bw-progress-head {
  padding: 14px 20px;
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--rule);
}
.bw-progress-head .title { font-size: 15px; font-weight: 500; }
.bw-progress-head .x {
  width: 24px; height: 24px;
  border-radius: 6px;
  display: grid; place-items: center;
  color: var(--ink-3);
  background: transparent;
  border: 0; cursor: pointer;
}
.bw-progress-head .x:hover { background: var(--paper-2); color: var(--ink); }

.bw-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.bw-table colgroup col:nth-child(1) { width: 49%; }
.bw-table colgroup col:nth-child(2),
.bw-table colgroup col:nth-child(3),
.bw-table colgroup col:nth-child(4) { width: 17%; }
.bw-table th {
  text-align: left;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 12px 20px;
  font-weight: 500;
  background: var(--paper-3);
  border-bottom: 1px solid var(--rule);
}
.bw-table th.num { text-align: right; }
.bw-table td {
  padding: 11px 20px;
  border-bottom: 1px solid var(--rule);
  font-family: var(--f-mono);
  font-size: 12.5px;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.bw-table td.num { text-align: right; }
.bw-table th:last-child,
.bw-table td:last-child { padding-right: 26px; }
.bw-table td .row-name {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--ink);
}
.bw-table td .ck {
  width: 14px; height: 14px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--good);
  color: white;
  display: inline-grid; place-items: center;
}
.bw-table td .ck svg { width: 9px; height: 9px; }
.bw-table td .spin {
  width: 14px; height: 14px;
  flex: 0 0 auto;
  border-radius: 999px;
  border: 1.6px solid var(--brand-soft);
  border-top-color: var(--brand);
  animation: bwspin .9s linear infinite;
}
@keyframes bwspin { to { transform: rotate(360deg); } }
.bw-table td .row-link {
  color: var(--ink);
  border-bottom: 1px dashed rgba(11,13,16,.18);
}
.bw-table tr.total td {
  background: linear-gradient(180deg, var(--paper-3), var(--paper-2));
  font-weight: 500;
}
.bw-table tr.total td .row-name { color: var(--brand-ink); font-weight: 500; }
.bw-table tr.total td.num {
  color: var(--ink);
  font-weight: 500;
  font-size: 13.5px;
}
.bw-progress-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.bw-progress-foot .actions { display: flex; gap: 8px; }
.bw-progress-foot button {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 6px;
  padding: 6px 12px;
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink);
  cursor: pointer;
}
.bw-progress-foot button.stop {
  display: inline-flex; align-items: center; gap: 6px;
  background: #B45309;
  color: #fff;
  border-color: #B45309;
}
.bw-progress-foot button.stop::before {
  content: ""; width: 8px; height: 8px; background: currentColor; border-radius: 1px;
}
.bw-toast {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  background: var(--good);
  color: var(--paper);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -.005em;
  opacity: 0;
  transform: translateY(100%);
  transition: opacity .3s ease, transform .35s ease;
  pointer-events: none;
}
.bw-toast.on { opacity: 1; transform: translateY(0); pointer-events: auto; }
.bw-toast .ck-mini {
  width: 18px; height: 18px; border-radius: 999px;
  background: rgba(255,255,255,.2);
  display: grid; place-items: center;
}
.bw-toast .ck-mini svg { width: 10px; height: 10px; }

/* annotations around the batch widget */
.bw-annotate { position: relative; }
.bw-annotate .anno {
  position: absolute;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
  background: var(--paper);
  padding: 4px 8px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  white-space: nowrap;
  z-index: 2;
}
.bw-annotate .anno.tl { top: -10px; left: 24px; }
.bw-annotate .anno.tr { top: -10px; right: 24px; background: var(--brand-soft); color: var(--brand-ink); border-color: rgba(63,133,135,.26); }
.bw-annotate .anno.br { bottom: -10px; right: 24px; }
.bw-annotate .anno.free {
  background: oklch(0.74 0.16 145);
  color: #fff;
  border-color: transparent;
  font-weight: 500;
  letter-spacing: .1em;
}

/* =========================================================
   Capabilities section
   ========================================================= */
.capabilities { background: var(--paper); }

/* Pill-style tabs for capabilities */
.cap-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 5px;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 999px;
  margin-bottom: clamp(48px, 6vw, 72px);
  flex-wrap: wrap;
}
.cap-tab {
  background: transparent;
  border: 0;
  padding: 9px 16px 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink-3);
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}
.cap-tab:hover { background: var(--paper-2); color: var(--ink); }
.cap-tab .hash {
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--brand);
  letter-spacing: -.01em;
}
.cap-tab .label {
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -.005em;
  color: var(--ink-2);
  white-space: nowrap;
}
.cap-tab.active {
  background: linear-gradient(180deg, var(--brand-soft), var(--card));
}
.cap-tab.active .hash { color: var(--brand); }
.cap-tab.active .label { color: var(--ink); }

.cap-panels {}
.cap-panel { display: none; animation: panelFade .35s ease; }
.cap-panel.active { display: block; }

.cap {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
.cap.reverse { grid-template-columns: 1.15fr 0.85fr; }
.cap.reverse .cap-text { order: 2; }
@media (max-width: 940px) {
  .cap, .cap.reverse {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .cap.reverse .cap-text { order: 0; }
}
.cap-text .cap-tag {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brand-ink);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}
.cap-text .cap-tag::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 999px;
  background: var(--brand);
}
.cap-text h3 {
  font-size: clamp(26px, 2.7vw, 36px);
  letter-spacing: -0.025em;
  line-height: 1.05;
  margin-bottom: 18px;
}
.cap-text h3 .it { font-family: var(--f-serif); font-style: italic; font-weight: 400; color: var(--ink-3); }
.cap-text .cap-lead {
  font-size: 17px;
  color: var(--ink-3);
  line-height: 1.5;
  max-width: 48ch;
  margin-bottom: 20px;
}
.cap-text .cap-points {
  list-style: none;
  padding: 0; margin: 0 0 24px 0;
  display: grid;
  gap: 10px;
}
.cap-text .cap-points li {
  display: grid;
  grid-template-columns: 26px 1fr;
  column-gap: 16px;
  align-items: start;
  font-size: 14.5px;
  color: var(--ink-2);
  padding: 4px 0;
  border-top: 1px solid var(--rule);
  padding-top: 14px;
}
.cap-text .cap-points li:first-child { border-top: 0; padding-top: 4px; }
.cap-text .cap-points li::before {
  content: "";
  width: 24px; height: 24px;
  border-radius: 999px;
  background: var(--brand-soft);
  margin-top: 1px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'><path d='M4 8l3 3 5-6' stroke='%232A5E60' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-size: contain;
  background-repeat: no-repeat;
}
.cap-text .cap-points li .t {
  grid-column: 2;
  display: block;
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -.01em;
  color: var(--ink);
  line-height: 1.3;
}
.cap-text .cap-points li .d {
  grid-column: 2;
  display: block;
  margin-top: 6px;
  font-size: 16.5px;
  color: var(--ink-3);
  line-height: 1.45;
  letter-spacing: -.003em;
}
.cap-text .cap-points li.grp {
  border-top: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  column-gap: 0;
  padding: 12px 0 2px;
  margin-top: 2px;
}
.cap-text .cap-points li.grp:first-child { padding-top: 0; margin-top: 0; }
.cap-text .cap-points li.grp::before { display: none; }
.cap-text .cap-points li.grp .grp-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-ink);
  white-space: nowrap;
}
.cap-text .cap-points li.grp .grp-label::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 999px;
  background: var(--brand);
  opacity: .8;
  flex: none;
}
.cap-text .cap-points li.grp::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--rule), transparent);
}
/* first point under a group header ties to the label (no divider) */
.cap-text .cap-points li.grp + li { border-top: 0; padding-top: 6px; }

.cap-text .cap-meta {
  display: flex; gap: 16px;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.cap-text .cap-meta b { color: var(--ink); font-weight: 500; font-family: var(--f-sans); letter-spacing: -.005em; }
.cap-viz {
  position: relative;
}
/* Full-bleed capability visual (spans full panel width) */
.cap-fullbleed {
  margin: 32px 0 40px;
}

/* Decorative separators between stacked diagrams in #panel-ui & #panel-query (per GUIHUA) */
#panel-ui .cap-fullbleed,
#panel-ui .surface-viz,
#panel-query .cap-fullbleed,
#panel-query .surface-viz {
  position: relative;
  margin-top: 0;
}
#panel-ui .surface-panel > .cs-header,
#panel-ui > .cs-header,
#panel-query > .cs-header,
#panel-ui .cs-header,
#panel-query .cs-header { margin-top: 120px; }
#panel-ui .cap-fullbleed::before,
#panel-ui .surface-viz::before,
#panel-query .cap-fullbleed::before,
#panel-query .surface-viz::before {
  content: none;
}

/* Real in-flow divider between stacked diagrams — copies the cs-header rule that works on dark panels */
.cap-sep {
  height: 0;
  margin: 48px 0;
  border-top: 1px solid rgba(255,255,255,.15);
}
#panel-ui .cap-fullbleed::after,
#panel-ui .surface-viz::after,
#panel-query .cap-fullbleed::after,
#panel-query .surface-viz::after {
  content: none;
}
.cap-fullbleed .frame {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-3);
}
.cap-fullbleed .frame img {
  width: 100%;
  display: block;
}
.cap-fullbleed .frame-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--rule);
  background: var(--paper-3);
}
.cap-fullbleed .frame-head .fh-dot {
  width: 7px; height: 7px;
  border-radius: 999px;
  background: var(--brand);
  flex: none;
}
.cap-fullbleed .frame-head .fh-label {
  font-family: var(--f-sans);
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: -.005em;
  color: var(--ink);
}
.cap-fullbleed .frame-head .fh-tag {
  margin-left: auto;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brand-ink);
  background: var(--brand-soft);
  border: 1px solid color-mix(in oklch, var(--brand) 24%, transparent);
  padding: 3px 9px;
  border-radius: 999px;
}
.cap-fullbleed .frame-foot {
  padding: 12px 18px;
  border-top: 1px solid var(--rule);
  font-family: var(--f-sans);
  font-size: 13.5px;
  color: var(--ink-2);
  letter-spacing: -.005em;
  line-height: 1.45;
  background: var(--paper-3);
  display: flex; gap: 12px; align-items: flex-start;
}
.cap-fullbleed .frame-foot b {
  color: var(--ink);
  font-weight: 500;
}
.cap-fullbleed .frame-foot .dot {
  width: 6px; height: 6px; border-radius: 999px;
  background: var(--brand);
  flex: 0 0 auto;
  margin-top: 8px;
}

/* Full-bleed capability visual (spans full panel width) — END */
.cap-viz .frame {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-3);
}
.cap-viz .frame img {
  width: 100%;
  display: block;
}
.cap-viz .frame-foot {
  padding: 10px 16px;
  border-top: 1px solid var(--rule);
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: .06em;
  background: var(--paper-3);
  display: flex; gap: 16px; align-items: center;
}
.cap-viz .frame-foot .dot {
  width: 6px; height: 6px; border-radius: 999px;
  background: var(--brand);
}

/* =========================================================
   Pipeline Records (Shift "after" view)
   ========================================================= */
.pipeline-records {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-1);
  overflow: hidden;
  font-family: var(--f-sans);
}
.pr-head {
  padding: 14px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--rule);
  background: linear-gradient(180deg, var(--brand-soft), transparent);
}
.pr-head .titles { display: flex; flex-direction: column; gap: 2px; }
.pr-head .obj-tag {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-ink);
}
.pr-head .name {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -.01em;
  color: var(--ink);
}
.pr-head .count {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--good-soft);
  color: var(--good);
  border: 1px solid rgba(17,125,79,.2);
}
.pr-row {
  display: grid;
  grid-template-columns: 28px 1fr 18px;
  gap: 14px;
  padding: 10px 18px;
  border-top: 1px solid var(--rule);
  align-items: center;
}
.pr-row .num {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  color: var(--brand);
  font-weight: 500;
}
.pr-info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pr-info-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pr-info .nm {
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: -.005em;
  color: var(--ink);
  font-family: var(--f-mono);
}
.pr-info .ev {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .04em;
  color: var(--ink-3);
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--paper-3);
  border: 1px solid var(--rule);
}
.pr-info .formula {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pr-info .formula .fn { color: var(--brand-ink); }
.pr-status {
  width: 22px; height: 22px;
  border-radius: 999px;
  background: var(--good);
  display: grid; place-items: center;
  color: #fff;
}
.pr-status svg { width: 14px; height: 14px; }
.pr-row.more {
  padding: 14px 18px 16px;
  grid-template-columns: 28px 1fr 18px;
  align-items: center;
}
.pr-row.more .num,
.pr-row.more .pr-status { opacity: 0; }
.pr-row.more .stack {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.pr-row.more .stack .dots {
  display: inline-flex; gap: 5px;
}
.pr-row.more .stack .dots i {
  width: 4px; height: 4px;
  border-radius: 999px;
  background: var(--brand);
  opacity: .4;
  display: inline-block;
  animation: prDot 1.6s ease-in-out infinite;
}
.pr-row.more .stack .dots i:nth-child(2) { animation-delay: .15s; opacity: .6; }
.pr-row.more .stack .dots i:nth-child(3) { animation-delay: .3s; opacity: .8; }
@keyframes prDot {
  0%, 100% { transform: translateY(0); opacity: .4; }
  50% { transform: translateY(-2px); opacity: 1; }
}
.pr-row.more .stack-meta b { color: var(--brand-ink); font-weight: 500; font-family: var(--f-sans); letter-spacing: -.005em; }

.pr-foot {
  padding: 12px 18px;
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
  font-family: var(--f-mono);
  font-size: 13.5px;
  letter-spacing: .04em;
  color: var(--ink-3);
  display: flex; align-items: center; gap: 10px;
}
.pr-foot .dot {
  width: 6px; height: 6px;
  border-radius: 999px;
  background: var(--good);
  display: inline-block;
}
.pr-foot b { color: var(--ink); font-family: var(--f-sans); font-weight: 500; letter-spacing: -.005em; }

/* =========================================================
   Pipeline Execution Widget (capability viz)
   ========================================================= */
.pipeline-widget {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-3);
  overflow: hidden;
  position: relative;
}
.pipeline-widget::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 80% at 100% 0%, rgba(127,185,187,.10), transparent 60%);
}
.pipeline-widget .bw-head {
  padding: 14px 18px;
  display: flex; align-items: center; gap: 14px;
  border-bottom: 1px solid var(--rule);
  background: linear-gradient(180deg, var(--brand-soft), transparent);
}
.pipeline-widget .bw-head .icn {
  width: 32px; height: 32px; border-radius: 8px;
  display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand-ink);
  border: 1px solid rgba(22,138,140,.18);
}
.pipeline-widget .bw-head .icn svg { width: 18px; height: 18px; }
.pipeline-widget .titles { display: flex; flex-direction: column; gap: 2px; }
.pipeline-widget .obj-tag {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-ink);
}
.pipeline-widget .obj-name {
  font-size: 16px; font-weight: 500;
  letter-spacing: -.01em; color: var(--ink);
}
.pipeline-widget .spacer { flex: 1; }
.pipeline-widget .run-btn {
  padding: 6px 11px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 999px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  border: 0;
  display: inline-flex; align-items: center; gap: 6px;
}
.pipeline-widget .pulse {
  width: 6px; height: 6px;
  border-radius: 999px;
  background: #6BE0A0;
  display: inline-block;
  animation: pulse 1.4s ease-in-out infinite;
}

.pw-progress-head {
  padding: 12px 18px;
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--rule);
}
.pw-progress-head .title { font-size: 15px; font-weight: 500; }
.pw-progress-head .x {
  width: 24px; height: 24px;
  border-radius: 6px;
  display: grid; place-items: center;
  color: var(--ink-3);
  background: transparent;
  border: 0; cursor: pointer;
}

.pw-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.pw-table colgroup col:nth-child(1) { width: 38px; }
.pw-table colgroup col:nth-child(3) { width: 80px; }
.pw-table colgroup col:nth-child(4),
.pw-table colgroup col:nth-child(5),
.pw-table colgroup col:nth-child(6) { width: 80px; }
.pw-table th {
  text-align: left;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 12px 18px;
  font-weight: 500;
  background: var(--paper-3);
  border-bottom: 1px solid var(--rule);
}
.pw-table th:first-child { padding-right: 0; padding-left: 18px; }
.pw-table th.num { text-align: right; }
.pw-table td {
  padding: 11px 18px;
  border-bottom: 1px solid var(--rule);
  font-family: var(--f-mono);
  font-size: 12.5px;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.pw-table td:first-child { padding-right: 0; }
.pw-table td.num { text-align: right; }
.pw-table tr:last-child td { border-bottom: 0; }

.pw-status {
  width: 22px; height: 22px;
  border-radius: 999px;
  background: var(--paper-3);
  border: 1.5px solid var(--rule-2);
  display: inline-grid; place-items: center;
  transition: all .25s ease;
  position: relative;
}
.pw-status.running {
  background: var(--brand-soft);
  border-color: var(--brand);
}
.pw-status.running::after {
  content: "";
  position: absolute; inset: 3px;
  border-radius: 999px;
  border: 1.6px solid rgba(22,138,140,.22);
  border-top-color: var(--brand);
  animation: pwspin .85s linear infinite;
}
.pw-status.done {
  background: var(--good);
  border-color: var(--good);
}
.pw-status.done svg {
  width: 14px; height: 14px;
  color: white;
}
@keyframes pwspin { to { transform: rotate(360deg); } }

.pw-row .exec-name {
  color: var(--brand-ink);
  font-weight: 500;
  font-family: var(--f-sans);
  font-size: 13.5px;
  letter-spacing: -.005em;
  text-decoration: underline;
  text-decoration-color: rgba(22,138,140,.25);
  text-underline-offset: 3px;
}
.pw-row.pending td { color: var(--ink-3); }
.pw-row.pending .exec-name { color: var(--ink-3); text-decoration-color: transparent; }

.pw-foot {
  padding: 12px 18px;
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: .04em;
}
.pw-foot button {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 6px;
  padding: 6px 12px;
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--ink);
}
.pw-foot .actions { display: flex; gap: 8px; }
.pw-foot .stop {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.pw-foot .stop::before {
  content: ""; width: 7px; height: 7px;
  background: currentColor; border-radius: 1px;
}

.pw-toast {
  display: flex; align-items: center; gap: 12px;
  padding: 0 18px;
  max-height: 0;
  background: var(--good);
  color: var(--paper);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -.005em;
  opacity: 0;
  overflow: hidden;
  border-top: 0 solid rgba(0,0,0,.12);
  transition: max-height .34s ease, padding .34s ease, opacity .28s ease, border-top-width .34s ease;
}
.pw-toast.on { max-height: 120px; padding: 14px 18px; opacity: 1; border-top-width: 1px; }
.pw-toast .ck-mini {
  width: 22px; height: 22px; border-radius: 999px;
  background: rgba(255,255,255,.22);
  display: grid; place-items: center;
}
.pw-toast .ck-mini svg { width: 12px; height: 12px; }
.pw-toast .toast-body { display: flex; flex-direction: column; gap: 2px; }
.pw-toast .toast-body b { font-weight: 600; font-size: 14px; }
.pw-toast .toast-body span { opacity: .92; font-size: 12.5px; font-weight: 400; }

/* annotation pills for pipeline-widget */
.pw-annotate { position: relative; }
.pw-annotate .anno {
  position: absolute;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
  background: var(--paper);
  padding: 4px 8px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  white-space: nowrap;
  z-index: 2;
}
.pw-annotate .anno.tl { top: -10px; left: 24px; }
.pw-annotate .anno.tr { top: -10px; right: 24px; background: var(--brand-soft); color: var(--brand-ink); border-color: rgba(63,133,135,.26); }
.pw-annotate .anno.br { bottom: -10px; right: 24px; }

/* =========================================================
   Trigger Execution Trace (capability viz · NEW)
   ========================================================= */
.trigger-trace {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-3);
  overflow: hidden;
  position: relative;
  font-family: var(--f-sans);
}
.trigger-trace::before {
  content: "";
  position: absolute; inset: 0;
  pointer-events: none;
  background: radial-gradient(60% 80% at 100% 0%, rgba(127,185,187,.10), transparent 60%);
}
.tt-event {
  padding: 9px 20px;
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--rule);
  background: var(--paper-3);
}
.tt-event-label {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.tt-event-value {
  font-size: 13.5px;
  color: var(--ink);
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-mono);
}
.tt-event-value .ev-pill {
  background: var(--ink);
  color: var(--paper);
  padding: 3px 9px;
  border-radius: 4px;
  font-size: 11px;
  letter-spacing: .04em;
  font-weight: 500;
  font-family: var(--f-mono);
}
.tt-rules-head {
  padding: 11px 20px 7px;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  display: flex; align-items: center; gap: 12px;
}
.tt-rules-head::after {
  content: ""; flex: 1; height: 1px; background: var(--rule);
}
.tt-rules {
  padding: 0 20px 20px;
  display: grid;
  gap: 6px;
}
.tt-rule {
  display: grid;
  grid-template-columns: 22px 1fr 80px;
  gap: 14px;
  align-items: flex-start;
  padding: 6px 14px;
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  background: var(--paper);
  transition: background .25s ease, border-color .25s ease;
}
.tt-rule.running {
  background: var(--brand-soft);
  border-color: var(--brand);
}
.tt-rule.done {
  background: var(--card);
  border-color: rgba(17,125,79,.35);
}
.tt-status {
  width: 16px; height: 16px;
  margin-top: 0;
  border-radius: 999px;
  border: 1.5px solid var(--rule-2);
  background: var(--card);
  display: grid; place-items: center;
  flex: 0 0 auto;
  position: relative;
  transition: all .25s ease;
}
.tt-rule.running .tt-status {
  border-color: var(--brand);
  background: var(--brand-soft);
}
.tt-rule.running .tt-status::after {
  content: "";
  width: 8px; height: 8px;
  border-radius: 999px;
  background: var(--brand);
  animation: pulse 1.1s ease-in-out infinite;
}
.tt-rule.done .tt-status {
  background: var(--good);
  border-color: var(--good);
}
.tt-rule.done .tt-status::after {
  content: "";
  position: absolute; inset: 1px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'><path d='M4 8l2.5 2.5L12 5' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}
.tt-info {
  display: flex; flex-direction: column; gap: 3px;
  min-width: 0;
}
.tt-name {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -.005em;
  color: var(--ink);
}
.tt-formula {
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tt-formula .fn { color: var(--brand-ink); }
.tt-bar {
  margin-top: 1px;
  height: 3px;
  border-radius: 2px;
  background: var(--paper-3);
  overflow: hidden;
}
.tt-bar-fill {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--brand);
  border-radius: 2px;
}
.tt-rule.done .tt-bar-fill {
  background: var(--good);
}
.tt-time {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
  text-align: center;
  align-self: center;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--paper-3);
  border: 1px solid var(--rule);
  white-space: nowrap;
  opacity: 0;
  transition: opacity .25s ease;
}
.tt-rule.running .tt-time {
  opacity: 1;
  color: var(--brand-ink);
  background: var(--brand-soft);
  border-color: rgba(22,138,140,.22);
}
.tt-rule.done .tt-time {
  opacity: 1;
  color: var(--good);
  background: var(--good-soft);
  border-color: rgba(17,125,79,.22);
}
.tt-foot {
  padding: 12px 20px;
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  color: var(--ink-3);
  flex-wrap: wrap;
}
.tt-foot .dot {
  width: 6px; height: 6px; border-radius: 999px;
  background: var(--good);
  display: inline-block;
}
.tt-foot b {
  color: var(--ink);
  font-weight: 500;
  font-family: var(--f-sans);
  letter-spacing: -.005em;
}

/* =========================================================
   Trigger Pipeline (legacy)
   ========================================================= */
.trigger-pipeline {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-3);
  overflow: hidden;
  position: relative;
}
.trigger-pipeline::before {
  content: "";
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 80% at 100% 0%, rgba(127,185,187,.16), transparent 60%);
}
.tp-event {
  padding: 16px 22px 10px;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  display: flex; align-items: center; gap: 12px;
}
.tp-event::after {
  content: "";
  flex: 1; height: 1px;
  background: var(--rule);
}
.tp-event .pip {
  display: inline-block; width: 6px; height: 6px;
  border-radius: 999px; background: var(--brand);
}
.tp-rules {
  padding: 0 22px 16px;
  display: grid; gap: 6px;
}
.tp-rule {
  display: grid;
  grid-template-columns: 18px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
}
.tp-rule .check {
  width: 16px; height: 16px;
  border-radius: 999px;
  background: var(--good);
  color: white;
  display: grid; place-items: center;
}
.tp-rule .check svg { width: 10px; height: 10px; }
.tp-rule .info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.tp-rule .name { font-size: 14px; font-weight: 500; letter-spacing: -.005em; }
.tp-rule .formula {
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tp-rule .formula .fn { color: var(--brand-ink); }
.tp-rule .time {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .04em;
  color: var(--brand-ink);
  background: var(--brand-soft);
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
}
.tp-foot {
  padding: 12px 20px;
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
  display: flex; align-items: center; gap: 10px;
}
.tp-foot .dot { width: 6px; height: 6px; border-radius: 999px; background: var(--good); display: inline-block; }

/* =========================================================
   Data Loader Widget (capability viz)
   ========================================================= */
.dl-widget {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-3);
  overflow: hidden;
  position: relative;
}
.dl-widget::before {
  content: "";
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 80% at 100% 0%, rgba(127,185,187,.16), transparent 60%);
}
.dl-body {
  padding: 22px;
  display: grid;
  gap: 18px;
}
.dl-drop {
  border: 1.5px dashed var(--rule-2);
  border-radius: var(--r-md);
  padding: 22px 24px;
  background: repeating-linear-gradient(135deg, transparent 0 10px, rgba(63,133,135,.06) 10px 20px);
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 16px;
  align-items: center;
}
.dl-drop .arr-icon {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: var(--brand-soft);
  color: var(--brand-ink);
  display: grid; place-items: center;
}
.dl-drop .arr-icon svg { width: 18px; height: 18px; }
.dl-drop .info { display: flex; flex-direction: column; gap: 4px; }
.dl-drop .info .file {
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -.005em;
}
.dl-drop .info .meta {
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: .04em;
}
.dl-drop .ok {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--good);
  background: var(--good-soft);
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(14,110,71,.2);
  letter-spacing: .04em;
}

.dl-preview-title {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  display: flex; align-items: center; gap: 10px;
}
.dl-preview-title::before {
  content: ""; width: 6px; height: 6px;
  border-radius: 999px; background: var(--brand);
}
.dl-preview {
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  overflow: hidden;
}
.dl-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1.7fr;
  border-top: 1px solid var(--rule);
  padding: 11px 16px;
  font-family: var(--f-mono);
  font-size: 12.5px;
  align-items: center;
  gap: 12px;
}
.dl-row:first-child {
  border-top: 0;
  background: var(--paper-3);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--ink-3);
}
.dl-row .field { color: var(--ink); font-weight: 500; font-family: var(--f-sans); letter-spacing: -.005em; font-size: 13px; }
.dl-row .src { color: var(--ink-3); font-family: var(--f-mono); font-size: 12px; letter-spacing: 0; }
.dl-row .fn .ftok { color: var(--brand-ink); }
.dl-row .val {
  color: var(--good);
  background: var(--good-soft);
  padding: 3px 9px;
  border-radius: 6px;
  display: inline-block;
  border: 1px solid rgba(14,110,71,.16);
  font-size: 11.5px;
}
@media (max-width: 720px) {
  .dl-row { grid-template-columns: 1fr; gap: 4px; }
  .dl-row:first-child { display: none; }
}

.dl-mapfoot {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 12px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.dl-mapfoot span { display: inline-flex; gap: 6px; align-items: baseline; }
.dl-mapfoot b { color: var(--ink); font-weight: 600; }

.dl-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: .04em;
  flex-wrap: wrap;
}
.dl-foot .run {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 999px;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  border: 0;
}
.dl-foot .run svg { width: 11px; height: 11px; }
.dl-foot .audit { color: var(--ink); }
.dl-foot .audit b { color: var(--good); font-weight: 500; }

/* Workspace inset (within UI cap) */
.cap-inset {
  margin-top: 18px;
  padding: 18px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  display: grid;
  gap: 14px;
}
.cap-inset .inset-title {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
  display: flex; align-items: center; gap: 10px;
}
.cap-inset .inset-title::before {
  content: ""; width: 6px; height: 6px;
  border-radius: 999px; background: var(--brand);
}
.cap-inset .ws-mock {
  background: var(--card);
  border: 1px solid var(--rule);
  padding: 14px;
}

/* Rich Composed Workspace (Account record + multiple Data Lists) */
.ws-rich {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  font-family: var(--f-sans);
}
.ws-rich-head {
  padding: 14px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  background: linear-gradient(180deg, var(--brand-soft), transparent);
  border-bottom: 1px solid var(--rule);
  flex-wrap: wrap;
}
.ws-rich-head .titles {
  display: flex; flex-direction: column; gap: 2px;
}
.ws-rich-head .obj-label {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-ink);
}
.ws-rich-head .record-name {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -.01em;
  color: var(--ink);
}
.ws-acts {
  display: flex; gap: 6px; flex-wrap: wrap;
}
.ws-btn {
  font-family: var(--f-sans);
  font-size: 11px;
  letter-spacing: -.003em;
  padding: 4px 9px;
  border-radius: 4px;
  border: 1px solid var(--rule-2);
  background: var(--card);
  color: var(--ink-2);
  font-weight: 500;
  white-space: nowrap;
  cursor: default;
  display: inline-flex; align-items: center; gap: 6px;
  transition: background .12s ease;
  line-height: 1.3;
}
.ws-btn:hover { background: var(--paper-2); }
.ws-btn.primary { background: var(--brand); color: #fff; border-color: var(--brand); }
.ws-btn.primary:hover { background: var(--brand-ink); border-color: var(--brand-ink); }
.ws-btn.good { background: var(--good); color: #fff; border-color: var(--good); }
.ws-btn.good:hover { filter: brightness(.92); }
.ws-btn.signal { background: var(--signal); color: #fff; border-color: var(--signal); }
.ws-btn.signal:hover { filter: brightness(.92); }
.ws-btn.ink { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.ws-btn.ink:hover { background: #1B2230; }

.ws-dl { border-top: 1px solid var(--rule); }
.ws-dl-tabs-row {
  display: flex;
  align-items: flex-end;
  gap: 0;
  padding: 6px 12px 0;
  background: var(--paper-2);
  border-bottom: 1px solid var(--rule);
}
.ws-dl-tabs { display: flex; gap: 2px; }
.ws-dl-tab {
  font-size: 13px;
  font-weight: 500;
  padding: 6px 12px 8px;
  border-radius: 4px 4px 0 0;
  color: var(--ink-3);
  background: transparent;
  border: 1px solid transparent;
  border-bottom: 0;
  position: relative;
  margin-bottom: -1px;
}
.ws-dl-tab.active {
  color: var(--ink);
  background: var(--card);
  border-color: var(--rule);
}
.ws-dl-tab.active::before {
  content: "";
  position: absolute;
  top: -1px; left: 10px; right: 10px;
  height: 2px;
  background: var(--brand);
  border-radius: 2px;
}
.ws-dl-actions-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 10px;
  padding: 8px 14px;
  background: var(--card);
  border-bottom: 1px solid var(--rule);
}
/* column filter (left) */
.ws-dl-filter { display: flex; align-items: center; gap: 6px; min-width: 0; }
.ws-dl-col, .ws-dl-search {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--f-sans); font-size: 11px; font-weight: 500; line-height: 1.3;
  padding: 4px 9px; border: 1px solid var(--rule-2); border-radius: 4px;
  background: var(--card); color: var(--ink-2); white-space: nowrap;
}
.ws-dl-col { cursor: default; }
.ws-dl-col .caret { width: 12px; height: 12px; color: var(--ink-3); margin-left: 1px; }
.ws-dl-search { background: var(--paper); color: var(--ink-3); min-width: 0; }
.ws-dl-search .mag { width: 13px; height: 13px; color: var(--ink-3); flex: 0 0 auto; }
.ws-dl-search .q { width: 150px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* action buttons + function tools (right) */
.ws-dl-acts { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 3px; }
.ws-dl-sep { width: 1px; height: 18px; background: var(--rule); margin: 0 4px; flex: 0 0 auto; }
.ws-ic {
  width: 27px; height: 27px; flex: 0 0 auto; display: inline-grid; place-items: center;
  border: 1px solid var(--rule); border-radius: var(--r-sm); background: var(--card);
  color: var(--ink-3); cursor: default; transition: background .12s ease, color .12s ease;
}
.ws-ic:hover { background: var(--paper-2); color: var(--ink-2); }
.ws-ic svg { width: 14px; height: 14px; }

.ws-dl-table { font-size: 12.5px; }
.ws-dl-row {
  display: grid;
  grid-template-columns: 20px 1.4fr 0.9fr 0.9fr 0.6fr;
  padding: 9px 18px;
  border-top: 1px solid var(--rule);
  align-items: center;
  gap: 12px;
}
.ws-dl-row.head {
  border-top: 0;
  background: var(--paper-3);
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.ws-check {
  width: 14px; height: 14px;
  border: 1.4px solid var(--rule-2);
  border-radius: 3px;
  background: var(--card);
  display: inline-block;
  position: relative;
  flex: 0 0 auto;
}
.ws-check.on {
  background: var(--brand);
  border-color: var(--brand);
}
.ws-check.on::after {
  content: "";
  position: absolute;
  inset: 1px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none'><path d='M2.5 6.5l2.2 2.2L9.5 3.5' stroke='%23ffffff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}
.ws-check.indet {
  background: var(--brand-soft);
  border-color: var(--brand);
}
.ws-check.indet::after {
  content: "";
  position: absolute;
  left: 2px; right: 2px; top: 50%;
  height: 1.6px; margin-top: -1px;
  background: var(--brand);
  border-radius: 1px;
}
.ws-dl-row .nm {
  color: var(--brand-ink);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ws-dl-row .num {
  font-variant-numeric: tabular-nums;
  font-family: var(--f-mono);
  font-size: 12.5px;
  color: var(--ink);
}
.ws-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  background: var(--paper-3);
  color: var(--ink-2);
  width: max-content;
}
.ws-pill.high { background: var(--signal-soft); color: var(--signal); }
.ws-pill.med { background: #FFF1D6; color: #8B5A1A; }
.ws-pill.low { background: var(--good-soft); color: var(--good); }
.ws-pill.warn { background: var(--signal-soft); color: var(--signal); }
.ws-pill.ok { background: var(--good-soft); color: var(--good); }

@media (max-width: 760px) {
  .ws-dl-row { grid-template-columns: 20px 1.4fr 1fr; gap: 8px; }
  .ws-dl-row > *:nth-child(n+4) { display: none; }
}

/* annotations around the card */
.exec-annotate {
  position: relative;
}
.exec-annotate .anno {
  position: absolute;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
  background: var(--paper);
  padding: 4px 8px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  white-space: nowrap;
}
.exec-annotate .anno.tl { top: -10px; left: 24px; }
.exec-annotate .anno.tr { top: -10px; right: 24px; background: var(--brand-soft); color: var(--brand-ink); border-color: rgba(63,133,135,.26); }
.exec-annotate .anno.br { bottom: -10px; right: 32px; }

/* =========================================================
   Section base
   ========================================================= */
section.section {
  padding: clamp(72px, 9vw, 120px) 0;
  position: relative;
}
.section-head {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-bottom: clamp(40px, 5vw, 64px);
  max-width: 1120px;
}
.section-head .lead { max-width: 80ch; }

.rule {
  height: 1px;
  background: var(--rule);
  margin: 0;
}

/* =========================================================
   Problem ribbon
   ========================================================= */
.ribbon {
  background: var(--paper-deep);
  color: var(--ink-2-on-dark);
  padding: 20px 0;
  overflow: hidden;
  border-top: 1px solid var(--paper-deep);
  border-bottom: 1px solid var(--paper-deep);
}
.ribbon-track {
  display: flex;
  gap: 72px;
  align-items: center;
  white-space: nowrap;
  animation: marquee 38s linear infinite;
  width: max-content;
}
.ribbon-track .item {
  font-family: var(--f-mono);
  font-size: 19px;
  letter-spacing: .04em;
  color: var(--ink-on-dark);
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.ribbon-track .item .x {
  color: var(--signal);
  font-size: 14px;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@keyframes marquee-rev {
  from { transform: translateX(-50%); }
  to { transform: translateX(0); }
}
.ribbon-track--rev { animation-name: marquee-rev; }
.ribbon-track .item .ok {
  color: var(--sn-btn, #28E07A);
  font-size: 18px;
}

/* =========================================================
   The Shift (before / after)
   ========================================================= */
.shift {
  background: var(--paper-2);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

/* "sprawl" word emphasis in shift headline */
.sprawl-word {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--signal);
  position: relative;
  display: inline-block;
  letter-spacing: -.01em;
  padding: 0 .05em;
}
.sprawl-word::after {
  content: "";
  position: absolute;
  left: 2%;
  right: 2%;
  bottom: 0.12em;
  height: .14em;
  background:
    radial-gradient(circle at 10% 50%, var(--signal) 0 1px, transparent 2px) 0 0 / 7px 100%,
    radial-gradient(circle at 90% 50%, var(--signal) 0 1px, transparent 2px) 0 0 / 7px 100%;
  background-repeat: repeat-x;
  background-position: 0 50%, 3.5px 50%;
  opacity: .35;
  pointer-events: none;
}
/* "rule records" headline emphasis → brand green */
.rule-green { color: var(--sn-btn, #0FD49E); }

.shift-grid {
  display: grid;
  /* minmax(0,1fr), not 1fr: plain 1fr resolves to minmax(auto,1fr), whose auto floor
     lets the right card's long monospace strings inflate that column past 50%. The 0
     floor forces both sides to split the row exactly in half. */
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 32px;
  align-items: stretch;
}
@media (max-width: 980px) {
  .shift-grid { grid-template-columns: 1fr; }
  .shift-grid .arrow-col { display: none; }
}
.shift-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.shift-side .label {
  display: flex; align-items: center; gap: 11px;
  font-family: var(--f-mono);
  font-size: 14px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(255,255,255,.72);
}
.shift-side .label .badge {
  position: relative;
  flex: 0 0 auto;
  width: 24px; height: 24px;
  min-width: 24px;
  aspect-ratio: 1;
  border-radius: 50%;
  font-size: 0;
  color: transparent;
}
/* BEFORE: coral disc with a drawn × (matches the capability rows) */
.shift-side.before .label .badge {
  background: rgba(240,130,75,.16);
  box-shadow: inset 0 0 0 1px rgba(240,130,75,.30);
}
.shift-side.before .label .badge::before,
.shift-side.before .label .badge::after {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 11px; height: 2px;
  border-radius: 1px;
  background: var(--signal);
}
.shift-side.before .label .badge::before { transform: translate(-50%,-50%) rotate(45deg); }
.shift-side.before .label .badge::after  { transform: translate(-50%,-50%) rotate(-45deg); }
/* AFTER: green disc with a drawn ✓ */
.shift-side.after .label .badge {
  background: rgba(40,224,122,.16);
  box-shadow: inset 0 0 0 1px rgba(40,224,122,.34);
}
.shift-side.after .label .badge::before {
  content: "";
  position: absolute;
  top: 44%; left: 50%;
  width: 6px; height: 10px;
  border: solid var(--sn-btn, #28E07A);
  border-width: 0 2.6px 2.6px 0;
  border-radius: 1px;
  transform: translate(-50%,-50%) rotate(45deg);
}
.shift-side h3 { color: var(--ink); }
.shift-side h3 .mute { color: var(--ink-3); }

/* BEFORE: sprawl visualization */
.sprawl {
  flex: 1;
  background: var(--card);
  background-image: radial-gradient(circle, rgba(215,209,192,.7) 1px, transparent 1.5px);
  background-size: 14px 14px;
  background-position: 1px 1px;
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: 22px;
  position: relative;
  min-height: 480px;
  box-shadow: var(--sh-1);
  /* Center the fixed-size canvas inside the (taller) sprawl container so
     the nodes sit visually in the middle, not pinned to the top. */
  display: flex;
  align-items: center;
  justify-content: center;
}
.sprawl-canvas {
  position: relative;
  width: 600px;
  height: 430px;
  margin: 0 auto;
  flex: 0 0 auto;
  transform-origin: center center;
}
.sprawl-node {
  position: absolute;
  font-family: var(--f-mono);
  font-size: 11.5px;
  padding: 5px 10px;
  border-radius: 6px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  color: var(--ink-2);
  white-space: nowrap;
  box-sizing: border-box;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sprawl-node.apex {
  background: #FBE7DC;
  border-color: rgba(200,74,26,.25);
  color: var(--signal);
  width: 150px;
}
.sprawl-node.flow {
  background: #FFF1D6;
  border-color: rgba(180,120,20,.25);
  color: #8B5A1A;
  width: 150px;
}
.sprawl-node.sub {
  background: #E6EDEC;
  border-color: rgba(40,70,72,.28);
  color: #2B4A4A;
  width: 180px;
}
.sprawl svg.wires {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}
.sprawl .footnote {
  position: absolute;
  bottom: 14px; left: 22px;
  font-family: var(--f-mono);
  font-size: 13px;
  color: #FFFFFF;
  letter-spacing: .02em;
}

.arrow-col {
  display: grid;
  place-items: center;
  width: 96px;
}
.arrow-col .arrow-big {
  width: 72px; height: 72px;
  border-radius: 999px;
  background: var(--card);
  border: 2px solid var(--brand);
  display: grid; place-items: center;
  box-shadow: 0 0 0 2px var(--brand), 0 0 40px -10px rgba(22,138,140,.5);
  color: var(--brand);
  position: relative;
}
.arrow-col .arrow-big::after {
  content: "DSP";
  position: absolute;
  bottom: -22px;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  color: var(--ink-3);
}
body.sn-hero .arrow-col .arrow-big {
  border-color: var(--sn-btn, #0FD49E);
  box-shadow: 0 0 0 2px var(--sn-btn, #0FD49E), 0 0 40px -10px rgba(15,212,158,.5);
  color: var(--sn-btn, #0FD49E);
}
.arrow-col .arrow-big svg { width: 28px; height: 28px; }

/* =========================================================
   Executable anatomy (interactive)
   ========================================================= */
.anatomy {
  background: var(--paper-2);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.anatomy .section-head h2 { font-size: clamp(40px, 4.4vw, 60px); }
.anatomy h2 .stages-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.32em;
  margin-top: 0.42em;
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 0.78em;
  letter-spacing: -0.015em;
  color: var(--sn-btn, #0FD49E);
  line-height: 1.05;
}
.anatomy h2 .stages-line .stage-word {
  display: inline-block;
  position: relative;
}
.anatomy h2 .stages-line .stage-word::before {
  content: "";
  position: absolute;
  left: 0; right: 0;
  bottom: 0.08em;
  height: 0.18em;
  background: var(--brand-soft);
  border-radius: 1px;
  z-index: -1;
}
.anatomy h2 .stages-line .sep {
  color: var(--mute);
  font-family: var(--f-sans);
  font-style: normal;
  font-size: 0.7em;
  transform: translateY(-0.1em);
  display: inline-block;
}
.anatomy h2 .stages-line .stage-end {
  color: var(--ink);
  font-family: var(--f-sans);
  font-style: normal;
  font-size: 1em;
  transform: none;
  margin-left: -0.18em;
}
.anatomy-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: stretch;
}
.anatomy-grid > .reveal { display: flex; flex-direction: column; min-height: 0; }
.anatomy-grid > .reveal > .stage-rail { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: space-between; }
.anatomy-grid > .reveal > .stage-rail > .stage-btn { flex: 0 0 auto; padding-top: 24px; padding-bottom: 24px; }
@media (max-width: 980px) {
  .anatomy-grid { grid-template-columns: 1fr; gap: 36px; }
}
.stage-rail {
  display: grid;
  gap: 10px;
  margin-top: 32px;
}
.stage-btn {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--r-md);
  background: var(--card);
  border: 1px solid var(--rule);
  text-align: left;
  color: var(--ink-2);
  transition: border-color .15s ease, background .15s ease;
}
.stage-btn:hover { border-color: var(--rule-2); }
.stage-btn.active {
  border-color: var(--brand);
  background: linear-gradient(180deg, var(--brand-soft), var(--card));
  color: var(--ink);
  box-shadow: 0 0 0 1px var(--brand), 0 0 32px -10px var(--brand);
}
.stage-btn .num {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: .08em;
  width: 28px; height: 28px;
  border-radius: 999px;
  display: grid; place-items: center;
  background: var(--paper-2);
  color: var(--ink-3);
}
.stage-btn.active .num { background: var(--brand); color: #FFFFFF; }
.stage-btn .stage-name {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.stage-btn .stage-sub {
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: .02em;
  margin-top: 2px;
  display: block;
}
.stage-btn.active .stage-sub { color: var(--ink-3); }
.stage-btn .chev { opacity: .35; }
.stage-btn.active .chev { opacity: 1; }

.stage-preview {
  position: relative;
}
.stage-preview .exec-card {
  margin-top: 32px;
}
.stage-preview .exec-row.dim > .k,
.stage-preview .exec-row.dim > .v { opacity: .35; transition: opacity .25s ease; }
.stage-preview .exec-row.lit > .k {
  background: var(--brand-soft);
  color: var(--brand);
}
.stage-preview .exec-row.lit > .v {
  background: linear-gradient(180deg, var(--brand-soft), transparent);
}

.stage-card-foot {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 14px 22px;
  border-top: 1px solid var(--rule);
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: .04em;
  background: var(--paper-3);
}
.stage-card-foot .dot { width: 6px; height: 6px; border-radius: 999px; background: var(--good); display: inline-block; margin-right: 8px;}

/* =========================================================
   Four surfaces — tabbed
   ========================================================= */
.surfaces {
  background: var(--paper);
  padding-top: clamp(108px, 13.5vw, 180px);
  padding-bottom: clamp(108px, 13.5vw, 180px);
}
/* breathing room above the surfaces nav line (per comment) */
.surfaces .section-head {
  margin-bottom: clamp(40px, 5vw, 64px);
}
.surfaces .section-head .lead { font-size: clamp(20px, 1.5vw, 25px); max-width: 64ch; }
.surface-tabs {
  margin-top: 8px;
  display: grid;
  position: relative;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  overflow: hidden;
}
@media (max-width: 1180px) {
  .surface-tabs { grid-template-columns: repeat(3, 1fr); }
  .surface-tab { border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
  .surface-tab:nth-child(3n) { border-right: 0; }
  .surface-tab:nth-last-child(-n+2):nth-child(n+4) { border-bottom: 0; }
  .surface-tab:last-child { border-right: 0; border-bottom: 0; }
}
@media (max-width: 880px) {
  .surface-tabs { grid-template-columns: 1fr 1fr; }
  .surface-tab { border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
  .surface-tab:nth-child(2n) { border-right: 0; }
  .surface-tab:last-child { border-bottom: 0; }
}
.surface-tab {
  background: transparent;
  border: 0;
  border-right: 1px solid var(--rule);
  text-align: left;
  padding: 22px 24px 20px;
  color: var(--ink-2);
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  transition: background .15s ease, color .15s ease;
  cursor: pointer;
}
.surface-tab::after {
  content: "";
  position: absolute;
  top: 22px;
  right: 16px;
  width: 12px;
  height: 12px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'><path d='M6 4l4 4-4 4' stroke='%23168A8C' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: .55;
  transition: opacity .2s ease, transform .2s ease;
}
.surface-tab:hover::after { opacity: 1; transform: translateX(2px); }
.surface-tab.active::after { opacity: 0; }
.surface-tab:last-child { border-right: 0; }
/* --- FREE tier badges (Query tab) --- */
.surface-tab .free-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 1px 6px 0;
  height: 16px;
  background: oklch(0.74 0.16 145);
  color: #fff;
  font-family: var(--f-mono);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.1em;
  border-radius: 3px;
  vertical-align: 1px;
  transform: translateY(-1px);
}
.surface-tab.is-free.active .free-badge { background: oklch(0.58 0.16 145); }
.panel-head .hash-big .free-tag {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 1px 6px 0;
  height: 16px;
  background: oklch(0.74 0.16 145);
  color: #fff;
  border: 0;
  font-family: var(--f-mono);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.1em;
  border-radius: 3px;
  vertical-align: 1px;
  transform: translateY(-1px);
}
.panel-head .hash-big .free-tag::before {
  content: none;
}

/* --- Query Manager widget --- */
.qm-widget {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 8px 30px -16px rgba(14,20,28,.18);
}
.qm-widget .bw-head { border-bottom: 1px solid var(--rule); }
.qm-media {
  background: #eef2f8;
  border-bottom: 1px solid var(--rule);
  display: block;
  line-height: 0;
}
.qm-media img {
  width: 100%;
  height: auto;
  display: block;
}
.qm-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 16px;
  background: var(--paper-3);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.qm-foot .qm-foot-r { color: var(--brand-ink); }

#panel-query .cap-points li b,
.cap-points li b {
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -.005em;
}
.cs-grid .cell.solution p b {
  color: var(--ink);
  font-weight: 600;
}

/* --- Query Manager: 5 tools strip --- */
.qm-tools {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 12px;
  overflow: hidden;
}
@media (max-width: 980px) {
  .qm-tools { grid-template-columns: repeat(2, 1fr); }
}
.qm-tool {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 20px;
  border-right: 1px solid var(--rule);
  position: relative;
}
.qm-tool:last-child { border-right: 0; }
.qm-tool .num {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  color: var(--ink-3);
  text-transform: uppercase;
}
.qm-tool .name {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.qm-tool .desc {
  font-size: 13.5px;
  color: var(--ink-3);
  line-height: 1.45;
  letter-spacing: -.005em;
}
.qm-tool.action { background: linear-gradient(180deg, var(--brand-soft), var(--card)); }
.qm-tool.action .name { color: var(--brand-ink); }
@media (max-width: 980px) {
  .qm-tool { border-bottom: 1px solid var(--rule); }
  .qm-tool:nth-child(odd) { border-right: 1px solid var(--rule); }
  .qm-tool:nth-child(even) { border-right: 0; }
  .qm-tool:last-child { border-bottom: 0; grid-column: 1 / -1; }
}
.surface-tab:hover {
  background: var(--paper-2);
  color: var(--ink);
  box-shadow: inset 4px 0 0 var(--brand-pure);
  z-index: 1;
}
.surface-tab:hover .label { color: var(--ink); font-weight: 600; }
.surface-tab:hover .hash { color: var(--brand); }
.surface-tab:hover .sub { color: var(--ink-2); }
.surface-tab:hover::after { opacity: 1; transform: translateX(2px); }
.surface-tab .hash {
  font-family: var(--f-sans);
  font-size: 14px;
  font-weight: 700;
  color: var(--brand);
  letter-spacing: 0;
}
.surface-tab .label {
  font-size: 23px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1.1;
}
.surface-tab .sub {
  font-family: var(--f-mono);
  font-size: 13px;
  letter-spacing: .01em;
  color: var(--ink-3);
  margin-top: 4px;
}
.surface-tab .sub { min-width: 0; }
.surface-tab.active {
  background: linear-gradient(180deg, rgba(22,138,140,.10), var(--card));
  color: var(--ink);
  box-shadow:
    inset 0 3px 0 var(--brand),
    inset 0 -1px 0 var(--brand),
    0 6px 18px -10px rgba(22,138,140,.4);
  z-index: 1;
}
.surface-tab.active .label { color: var(--ink); font-weight: 600; }
.surface-tab.active .hash { color: var(--brand-ink); }
.surface-tab.active .sub { color: var(--ink-2); }
.surface-tab.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 2px;
  background: var(--brand);
  box-shadow: 0 0 14px rgba(22,138,140,.4);
}

/* Panels */
.surface-panels {
  margin-top: 32px;
}
.surface-panel {
  display: none;
  animation: panelFade .35s ease;
}
.surface-panel.active { display: block; }
@keyframes panelFade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

.panel-head {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 48px;
  align-items: end;
  margin-bottom: 64px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--rule);
}
@media (max-width: 880px) {
  .panel-head { grid-template-columns: 1fr; gap: 24px; }
}
.panel-head .hash-big {
  font-family: var(--f-mono);
  font-size: 18px;
  color: var(--brand);
  letter-spacing: -.01em;
  margin-bottom: 10px;
  display: inline-block;
}
.panel-head h3 {
  font-size: clamp(32px, 3.6vw, 44px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 0.98;
  margin-bottom: 16px;
}
.panel-head h3 .it {
  display: inline-block;
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--sn-btn, #0FD49E);
  font-size: 0.92em;
}
.panel-head .panel-lead {
  font-size: 17px;
  color: var(--ink-3);
  line-height: 1.5;
  max-width: 52ch;
}
.panel-head .panel-recipe {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 18px;
  font-family: var(--f-mono);
  font-size: 18px;
  letter-spacing: .04em;
  color: var(--brand-ink);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: gap .15s ease, border-color .15s ease;
}
.panel-head .panel-recipe svg { width: 18px; height: 18px; }
.panel-head .panel-recipe:hover { gap: 11px; border-color: currentColor; }
.panel-head .panel-aside {
  font-family: var(--f-mono);
  font-size: 14.5px;
  color: var(--ink-3);
  letter-spacing: .02em;
  line-height: 1.6;
  border-left: 1px solid var(--rule);
  padding-left: 24px;
}
.panel-head .panel-aside b {
  display: block;
  color: var(--ink);
  font-weight: 500;
  font-family: var(--f-sans);
  letter-spacing: -.005em;
  font-size: 17px;
  margin-bottom: 8px;
}

/* Surface key viz strip */
.surface-viz {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: 28px;
  margin-top: 64px;
  margin-bottom: 64px;
  box-shadow: var(--sh-1);
  overflow: hidden;
}
.surface-viz .v-title {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 18px;
  display: flex; align-items: center; gap: 10px;
}
.surface-viz .v-title::before {
  content: ""; width: 6px; height: 6px; border-radius: 999px;
  background: var(--brand);
}

/* Batch 6-stage engine viz */
.engine-strip {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  align-items: stretch;
}
.engine-strip.cols-4 { grid-template-columns: repeat(4, 1fr); }
.engine-strip.cols-5 { grid-template-columns: repeat(5, 1fr); }
@media (max-width: 720px) {
  .engine-strip,
  .engine-strip.cols-4,
  .engine-strip.cols-5 { grid-template-columns: repeat(2, 1fr); }
}
.engine-step {
  position: relative;
  padding: 18px 16px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  min-height: 110px;
  display: flex; flex-direction: column; gap: 6px;
}
.engine-step .num {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .14em;
  color: var(--ink-3);
}
.engine-step .name {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.015em;
}
.engine-step .desc {
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  line-height: 1.45;
  margin-top: 10px;
}
.engine-step.action {
  background: linear-gradient(180deg, var(--brand-soft), var(--card));
  color: var(--ink);
  border-color: var(--brand);
  box-shadow: 0 0 0 1px var(--brand), 0 0 24px -10px rgba(22,138,140,.4);
}
.engine-step.action .num { color: var(--brand-ink); }
.engine-step.action .name { color: var(--brand-ink); }
.engine-step.action .desc { color: var(--ink-2); }

/* Data Loader viz */
.loader-flow {
  display: grid;
  grid-template-columns: 220px 1fr 180px;
  gap: 18px;
  align-items: stretch;
}
@media (max-width: 880px) { .loader-flow { grid-template-columns: 1fr; } }
.loader-flow .drop-zone {
  border: 1.5px dashed var(--rule-2);
  border-radius: var(--r-md);
  padding: 18px;
  background: repeating-linear-gradient(135deg, transparent 0 10px, rgba(63,133,135,.06) 10px 20px);
  display: flex; flex-direction: column; gap: 8px;
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--ink-3);
}
.loader-flow .drop-zone b {
  font-family: var(--f-sans);
  font-weight: 500;
  letter-spacing: -.005em;
  color: var(--ink);
  font-size: 14.5px;
}
.loader-flow .drop-zone .meta {
  margin-top: auto;
  letter-spacing: .04em;
}
.loader-flow .stages-mini {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}
.loader-flow .stages-mini .s {
  border: 1px solid var(--rule);
  background: var(--paper);
  border-radius: var(--r-sm);
  padding: 10px 8px;
  display: flex; flex-direction: column; gap: 4px;
  text-align: center;
  font-size: 11.5px;
}
.loader-flow .stages-mini .s .n {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: .14em;
  color: var(--ink-3);
}
.loader-flow .stages-mini .s .nm {
  font-weight: 500;
  letter-spacing: -.005em;
  font-size: 13px;
}
.loader-flow .stages-mini .s.brand {
  background: var(--brand-soft);
  border-color: rgba(63,133,135,.22);
  color: var(--brand-ink);
}
.loader-flow .log-out {
  background: var(--ink);
  color: var(--paper);
  border-radius: var(--r-md);
  padding: 14px 16px;
  display: flex; flex-direction: column; gap: 6px;
  font-family: var(--f-mono);
  font-size: 11.5px;
}
.loader-flow .log-out b {
  font-family: var(--f-sans);
  font-weight: 500;
  font-size: 13px;
  color: var(--paper);
}
.loader-flow .log-out .lr {
  color: rgba(232,237,243,.7);
  letter-spacing: .04em;
}
.loader-flow .log-out .ok { color: #6BE0A0; }

/* Trigger viz */
.trigger-flow {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 18px;
}
@media (max-width: 720px) { .trigger-flow { grid-template-columns: 1fr; } }
.trigger-flow .dml-events {
  display: grid; gap: 8px;
  align-content: start;
}
.trigger-flow .dml {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-sm);
  padding: 10px 14px;
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--ink-3);
  display: flex; align-items: center; gap: 8px;
}
.trigger-flow .dml.active {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.trigger-flow .dml .dot { width: 6px; height: 6px; border-radius: 999px; background: var(--brand); }
.trigger-flow .exec-list { display: grid; gap: 8px; }
.trigger-flow .exec-mini {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  padding: 12px 16px;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 14px;
  align-items: center;
  font-size: 13.5px;
}
.trigger-flow .exec-mini .nm { font-weight: 500; letter-spacing: -.005em; }
.trigger-flow .exec-mini .obj { font-family: var(--f-mono); font-size: 11.5px; color: var(--ink-3); }
.trigger-flow .exec-mini .pill {
  font-family: var(--f-mono); font-size: 10.5px;
  padding: 3px 8px; border-radius: 999px;
  background: var(--good-soft); color: var(--good);
  letter-spacing: .04em;
}

/* UI workspace viz */
.ws-mock {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  padding: 18px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
}
@media (max-width: 880px) { .ws-mock { grid-template-columns: 1fr; } }
.ws-panel {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  padding: 14px;
  display: flex; flex-direction: column; gap: 10px;
  min-height: 180px;
}
.ws-panel .ph {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--f-mono); font-size: 11.5px; color: var(--ink-3);
  letter-spacing: .04em;
}
.ws-panel .pn {
  font-family: var(--f-sans);
  font-weight: 500;
  font-size: 14px;
  color: var(--ink);
  letter-spacing: -.005em;
}
.ws-panel .row {
  height: 8px; border-radius: 4px; background: var(--paper-2);
}
.ws-panel .row.b { background: var(--brand-soft); }
.ws-panel .acts { display: flex; gap: 6px; margin-top: auto; }
.ws-panel .acts span {
  flex: 1;
  font-family: var(--f-mono); font-size: 10.5px;
  text-align: center;
  background: var(--ink); color: var(--paper);
  padding: 5px 0; border-radius: 4px;
  letter-spacing: .02em;
}
.ws-panel .acts span.alt {
  background: transparent; color: var(--ink); border: 1px solid var(--rule);
}

/* Challenges → Solutions paired grid */
.cs-grid {
  display: flex;
  flex-direction: column;
}
.cs-header {
  display: grid;
  grid-template-columns: 1fr 96px 1fr;
  gap: 0;
  margin-bottom: 4px;
  border-top: 1px solid var(--rule);
  padding-top: 56px;
  margin-top: 88px;
}
body.sn-hero .surface-panel > .cs-header { border-top-color: rgba(255,255,255,.15); }
@media (max-width: 880px) {
  .cs-header { grid-template-columns: 1fr; }
  .cs-header .cs-divider { display: none; }
}
.cs-header > div {
  font-family: var(--f-mono);
  font-size: 19px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 14px 0 22px;
}
.cs-header .signal { color: var(--signal); }
.cs-header .good { color: var(--good); }

.cs-row {
  display: grid;
  grid-template-columns: 1fr 96px 1fr;
  transition: background .2s ease;
}
@media (max-width: 880px) {
  .cs-row { grid-template-columns: 1fr; }
  .cs-row > .cs-divider { display: none; }
}
.cs-row > .cell {
  border-top: 1px solid var(--rule);
  padding: 26px 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.cs-row > .cs-divider { border-top: 0; }
.cs-row > .cell.problem { padding-right: 28px; margin-right: 32px; position: relative; }
.cs-row > .cell.problem::after {
  content: "";
  position: absolute;
  top: 32px;
  right: 2px;
  width: 9px;
  height: 9px;
  border-right: 1.6px solid var(--ink-3);
  border-bottom: 1.6px solid var(--ink-3);
  transform: rotate(45deg);
  opacity: .7;
  transition: transform .3s ease, opacity .2s ease, border-color .2s ease;
}
.cs-row.open > .cell.problem::after {
  transform: rotate(-135deg) translate(-1px,-1px);
  opacity: 1;
}

.cs-row > .cell.solution { padding-right: 28px; margin-left: 32px; position: relative; }
.cs-row > .cell.solution::after {
  content: "";
  position: absolute;
  top: 32px;
  right: 2px;
  width: 9px;
  height: 9px;
  border-right: 1.6px solid var(--ink-3);
  border-bottom: 1.6px solid var(--ink-3);
  transform: rotate(45deg);
  opacity: .7;
  transition: transform .3s ease, opacity .2s ease, border-color .2s ease;
}
.cs-row.open > .cell.solution::after {
  transform: rotate(-135deg) translate(-1px,-1px);
  opacity: 1;
}
body.sn-hero .cs-row.open > .cell.solution::after,
body.sn-hero .cs-row.open > .cell.problem::after { border-color: var(--sn-btn, #28E07A); }

.cs-header > .signal { margin-right: 32px; }
.cs-header > .good { margin-left: 32px; }
.cs-row > .cell h4 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -.01em;
  line-height: 1.3;
}
.cs-row > .cell p {
  font-size: 15px;
  color: var(--ink-3);
  line-height: 1.55;
  max-width: 48ch;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  margin-top: 0;
  transition: max-height .32s ease, opacity .25s ease, margin-top .32s ease;
}
/* Reveal a row's descriptions on hover; keep the first row open as an affordance */
.cs-row.open > .cell p {
  max-height: 220px;
  opacity: 1;
  margin-top: 9px;
  transition-delay: 0s;
}
.cs-row { cursor: pointer; }
.cs-row.open > .cell h4 { color: var(--ink); }
body.sn-hero .cs-row.open > .cell h4 { color: #FFFFFF; }

.cs-row > .cell h4 .x,
.cs-row > .cell h4 .v {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  min-width: 24px;
  aspect-ratio: 1;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  font-family: var(--f-mono);
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  margin: 0;
}
.cs-row > .cell.problem h4 .x {
  position: relative;
  color: transparent;
  font-size: 0;
  background: rgba(240,130,75,.16);
  box-shadow: inset 0 0 0 1px rgba(240,130,75,.30);
}
/* Draw the × as two centered bars so it's pixel-identical and dead-centered everywhere */
.cs-row > .cell.problem h4 .x::before,
.cs-row > .cell.problem h4 .x::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 13px;
  height: 2px;
  border-radius: 1px;
  background: var(--signal);
}
.cs-row > .cell.problem h4 .x::before { transform: translate(-50%,-50%) rotate(45deg); }
.cs-row > .cell.problem h4 .x::after  { transform: translate(-50%,-50%) rotate(-45deg); }
.cs-row > .cell.solution h4 .v {
  position: relative;
  color: transparent;
  font-size: 0;
  background: rgba(40,224,122,.16);
  box-shadow: inset 0 0 0 1px rgba(40,224,122,.34);
}
/* Draw the ✓ as a 2px stroke so it matches the × exactly */
.cs-row > .cell.solution h4 .v::before {
  content: "";
  position: absolute;
  top: 44%;
  left: 50%;
  width: 6px;
  height: 10px;
  border: solid var(--sn-btn, #28E07A);
  border-width: 0 2.6px 2.6px 0;
  border-radius: 1px;
  transform: translate(-50%,-50%) rotate(45deg);
}
.cs-divider {
  position: relative;
}
.cs-divider .arrow-mini { display: none; }
.cs-divider .arrow-mini--hidden-unused {
  position: absolute;
  top: 30px;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 36px; height: 36px;
  border-radius: 999px;
  background: var(--paper);
  border: 1px solid var(--rule);
  display: grid; place-items: center;
  color: var(--ink-3);
}
body.sn-hero .cs-divider .arrow-mini {
  background: rgba(40,224,122,.14);
  border-color: rgba(40,224,122,.4);
  color: var(--sn-btn, #28E07A);
}
.cs-divider .arrow-mini svg { width: 14px; height: 14px; }
.cs-row:last-child > .cell { border-bottom: 1px solid var(--rule); }

/* Surface metrics row at bottom */
.surface-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: 72px;
  border-top: 1px solid var(--rule);
}
@media (max-width: 720px) { .surface-metrics { grid-template-columns: 1fr 1fr; } }
.surface-metrics .m {
  padding: 32px 24px 8px;
  border-right: 1px solid var(--rule);
  display: flex; flex-direction: column; gap: 4px;
  position: relative;
}
.surface-metrics .m:last-child { border-right: 0; }
@media (max-width: 720px) {
  .surface-metrics .m { border-right: 0; border-bottom: 1px solid var(--rule); }
  .surface-metrics .m:nth-child(odd) { border-right: 1px solid var(--rule); }
  .surface-metrics .m:nth-last-child(-n+2) { border-bottom: 0; }
}
.surface-metrics .m .big {
  font-size: clamp(28px, 2.7vw, 36px);
  font-weight: 500;
  color: var(--sn-btn, #0FD49E);
  letter-spacing: -0.03em;
  line-height: 1;
}
.surface-metrics .m .big .it {
  font-family: var(--f-serif); font-style: italic; font-weight: 400; color: #FFFFFF;
}
.surface-metrics .m .lbl {
  font-family: var(--f-mono); font-size: 13px;
  letter-spacing: .12em; text-transform: uppercase; color: #FFFFFF;
  margin-top: 6px;
}
.surface-metrics .m .pre {
  position: absolute;
  top: 10px;
  left: 24px;
  font-family: var(--f-mono);
  font-size: 9.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--mute);
}



/* =========================================================
   Function library
   ========================================================= */
.functions {
  background: var(--paper-deep);
  color: var(--ink-on-dark);
  border-top: 1px solid var(--paper-deep);
  border-bottom: 1px solid var(--paper-deep);
}
.functions .eyebrow { color: var(--ink-3-on-dark); }
.functions .section-head h2 { font-size: clamp(40px, 4.4vw, 60px); }
.functions h2 { color: var(--ink-on-dark); }
.functions .lead { color: var(--ink-2-on-dark); }
.functions h2 .it {
  color: var(--sn-btn, #0FD49E);
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.015em;
  font-size: clamp(40px, 4.4vw, 58px);
  -webkit-text-stroke: 0.4px currentColor;
}
.functions .eyebrow .dot { background: var(--brand-bright); }
.fn-grid {
  margin-top: 56px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 8px;
}
.fn-grid .chip {
  font-family: var(--f-mono);
  font-size: 12px;
  padding: 11px 14px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
  color: var(--ink-2-on-dark);
  min-width: 0;
  overflow: hidden;
  transition: background .15s ease, transform .15s ease, color .15s ease;
  cursor: default;
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px;
}
.fn-grid .chip:hover {
  background: rgba(255,255,255,.06);
  color: var(--ink-on-dark);
  border-color: rgba(255,255,255,.18);
  transform: translateY(-1px);
}
.fn-grid .chip.more {
  border-style: dashed;
  border-color: rgba(255,255,255,.18);
  color: var(--brand-bright);
  background: rgba(15,212,158,.06);
  text-decoration: none;
  justify-content: center;
}
.fn-grid .chip.more:hover {
  background: rgba(15,212,158,.12);
  color: var(--brand-bright);
  border-color: var(--brand-bright);
}
.fn-grid .chip > span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}
.fn-grid .chip .cat {
  display: none;
}
.fn-grid .chip.brand { background: rgba(15,212,158,.10); color: var(--brand-bright); border-color: var(--brand-bright); box-shadow: 0 0 0 1px var(--brand-bright), 0 0 24px -8px var(--brand-bright); }
.fn-grid.view-all .chip.brand[data-no-all-brand="1"] {
  background: rgba(255,255,255,.03);
  color: var(--ink-2-on-dark);
  border-color: rgba(255,255,255,.08);
  box-shadow: none;
}
.fn-grid .chip.brand .cat { color: var(--brand-bright); opacity: .7; }

.fn-cats {
  display: flex; gap: 8px;
  margin-top: 32px;
  flex-wrap: wrap;
}
.fn-cats .fc {
  font-family: var(--f-sans);
  font-weight: 500;
  font-size: 13px;
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.28);
  color: #FFFFFF;
  background: rgba(255,255,255,.06);
  transition: all .15s ease;
}
.fn-cats .fc:hover { color: var(--ink-on-dark); border-color: rgba(255,255,255,.4); }
.fn-cats .fc.on { background: var(--brand-bright); color: var(--paper-deep); border-color: var(--brand-bright); box-shadow: 0 0 28px -10px var(--brand-bright); }

/* Embeddable formula-engine band (within Functions) */
.fx-embed {
  margin-top: 80px;
  padding-top: 56px;
  border-top: 1px solid rgba(255,255,255,.10);
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
@media (max-width: 860px) { .fx-embed { grid-template-columns: 1fr; gap: 36px; } }
/* Align the code card's middle to the text block (heading→list), not the full
   column — the eyebrow adds height up top that otherwise pulls the card high. */
@media (min-width: 861px) { .fx-embed .fx-code { transform: translateY(21px); } }
.fx-embed-text .eyebrow { color: var(--ink-3-on-dark); }
.fx-embed-text .eyebrow .dot { background: var(--brand-bright); }
.fx-embed-text h3 {
  margin: 16px 0 0;
  font-size: clamp(24px, 2.4vw, 30px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ink-on-dark);
  font-weight: 500;
}
.fx-embed-text p {
  margin: 18px 0 0;
  max-width: 46ch;
  color: var(--ink-2-on-dark);
  font-size: 16px;
  line-height: 1.6;
}
.fx-points {
  list-style: none;
  margin: 30px 0 0;
  padding: 0;
  display: grid;
}
.fx-points li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: start;
  padding: 16px 0;
  border-top: 1px solid rgba(255,255,255,.10);
}
.fx-points li:last-child { border-bottom: 1px solid rgba(255,255,255,.10); }
.fx-check {
  width: 24px; height: 24px;
  flex: 0 0 auto;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(40,224,122,.14);
  color: var(--sn-btn, #28E07A);
  margin-top: 1px;
}
.fx-check svg { width: 14px; height: 14px; }
.fx-pt { display: grid; gap: 3px; }
.fx-pt-t {
  font-size: 16.5px;
  font-weight: 600;
  letter-spacing: -.01em;
  color: var(--ink-on-dark);
}
.fx-pt-d {
  font-size: 14px;
  line-height: 1.45;
  color: var(--ink-3-on-dark);
}
.fx-code {
  border: 1px solid rgba(255,255,255,.14);
  border-radius: var(--r-lg);
  background: rgba(255,255,255,.03);
  overflow: hidden;
  box-shadow: 0 30px 80px -40px rgba(0,0,0,.85);
}
.fx-code-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  border-bottom: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.02);
}
.fx-traffic { display: inline-flex; gap: 6px; flex: 0 0 auto; }
.fx-traffic i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.18); }
.fx-traffic i:first-child { background: var(--brand-bright); box-shadow: 0 0 10px var(--brand-bright); }
.fx-code-title {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3-on-dark);
}
.fx-code-tag {
  margin-left: auto;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: .08em;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid var(--brand-bright);
  color: var(--brand-bright);
  background: rgba(15,212,158,.08);
}
.fx-code-body {
  margin: 0;
  padding: 16px 0;
  font-family: var(--f-mono);
  font-size: 13px;
  line-height: 1.75;
  color: var(--ink-on-dark);
  overflow-x: auto;
  tab-size: 2;
  counter-reset: ln;
}
.fx-code-body code { display: block; white-space: normal; }
.fx-code-body .cl {
  display: block;
  white-space: pre;
  counter-increment: ln;
  position: relative;
  padding: 0 22px 0 58px;
  min-height: 1.75em;
}
.fx-code-body .cl::before {
  content: counter(ln);
  position: absolute;
  left: 0;
  width: 38px;
  text-align: right;
  color: rgba(255,255,255,.26);
  font-variant-numeric: tabular-nums;
  -webkit-user-select: none; user-select: none;
}
.fx-code-body .cl:hover { background: rgba(255,255,255,.03); }
.fx-code-body .t-c { color: var(--ink-3-on-dark); font-style: italic; }
.fx-code-body .t-k { color: #9DB4D0; }
.fx-code-body .t-s { color: #E0B080; }
.fx-code-body .t-f { color: var(--brand-bright); }
.fx-code-body .t-t { color: #C8A6E0; }
.fx-code-foot {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 20px;
  border-top: 1px solid rgba(255,255,255,.10);
  background: rgba(40,224,122,.06);
  font-family: var(--f-mono);
  font-size: 12.5px;
  color: var(--ink-2-on-dark);
}
.fx-out-dot {
  width: 8px; height: 8px; border-radius: 50%;
  flex: 0 0 auto;
  background: var(--sn-btn, #28E07A);
  box-shadow: 0 0 10px var(--sn-btn, #28E07A);
}
.fx-out-text { letter-spacing: .01em; }

/* =========================================================
   By the numbers
   ========================================================= */
.numbers {
  background: var(--paper);
}
.num-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
@media (max-width: 880px) { .num-grid { grid-template-columns: 1fr 1fr; } }
.num-cell {
  padding: 36px 28px;
  border-right: 1px solid var(--rule);
  display: flex; flex-direction: column; gap: 10px;
}
.num-cell:last-child { border-right: none; }
@media (max-width: 880px) {
  .num-cell { border-right: none; border-bottom: 1px solid var(--rule); }
  .num-cell:nth-child(odd) { border-right: 1px solid var(--rule); }
  .num-cell:nth-last-child(-n+2) { border-bottom: none; }
}
.num-cell .big {
  font-size: clamp(48px, 5.4vw, 74px);
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 0.9;
  color: var(--sn-btn, #0FD49E);
}
.num-cell .big .it {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  color: #FFFFFF;
}
.num-cell .label {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.num-cell .desc {
  font-size: 14.5px;
  color: var(--ink-3);
  max-width: 32ch;
}

/* =========================================================
   Security
   ========================================================= */
.security {
  background: var(--paper-2);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.sec-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 56px;
  align-items: center;
}
@media (max-width: 940px) { .sec-grid { grid-template-columns: 1fr; } }
.sec-pillars {
  display: grid;
  gap: 14px;
}
.sec-pillar {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  padding: 18px 20px;
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 14px;
  align-items: flex-start;
}
.sec-pillar .icn {
  width: 28px; height: 28px;
  border-radius: 8px;
  background: var(--brand-soft);
  color: var(--brand-ink);
  display: grid; place-items: center;
}
.sec-pillar .icn svg { width: 16px; height: 16px; }
.sec-pillar h4 {
  font-family: var(--f-sans);
  font-size: 18px;
  margin-bottom: 6px;
  letter-spacing: -.01em;
}
.sec-pillar p {
  font-family: var(--f-sans);
  color: var(--ink-2-on-dark);
  font-size: 16px;
  line-height: 1.55;
}
.sec-badges {
  display: flex;
  gap: 16px;
  margin-top: 28px;
  flex-wrap: wrap;
}
.sec-badge {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
}
.sec-badge .mark {
  width: 32px; height: 32px;
  border-radius: 999px;
  display: grid; place-items: center;
  background: var(--brand);
  color: var(--paper);
}
.sec-badge .mark svg { width: 18px; height: 18px; }
.sec-badge .txt { font-family: var(--f-sans); font-size: 14px; }
.sec-badge .txt b { display: block; font-size: 16px; font-weight: 600; color: var(--ink); letter-spacing: -.01em; }
.sec-badge .txt span { font-size: 13.5px; color: var(--ink-2-on-dark); letter-spacing: 0; }

/* =========================================================
   Closing CTA
   ========================================================= */
.closing {
  background: var(--paper-deep);
  color: var(--ink-on-dark);
  padding: clamp(80px, 10vw, 140px) 0;
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--paper-deep);
}
.closing::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(70% 60% at 50% 100%, rgba(15,212,158,.18), transparent 60%),
    radial-gradient(40% 50% at 10% 20%, rgba(127,185,187,.06), transparent 60%);
  pointer-events: none;
}
.closing-inner {
  position: relative;
  text-align: center;
  max-width: 880px;
  margin: 0 auto;
}
.closing h2 {
  color: var(--ink-on-dark);
  font-size: clamp(36px, 4.6vw, 62px);
  letter-spacing: -0.035em;
}
.closing h2 .it { font-family: var(--f-serif); font-style: italic; font-weight: 400; color: var(--sn-btn, #0FD49E); }
.closing .lead { color: var(--ink-2-on-dark); margin: 28px auto 0; }
.closing .btn { background: var(--brand-bright); color: var(--paper-deep); border-color: var(--brand-bright); box-shadow: 0 0 0 1px var(--brand-bright), 0 0 40px -8px var(--brand-bright); }
.closing .btn:hover { background: #3FE3B5; border-color: #3FE3B5; transform: translateY(-1px); }
.closing .btn.secondary { background: transparent; color: var(--ink-on-dark); border-color: rgba(255,255,255,.18); box-shadow: none; }
.closing .btn.secondary:hover { background: rgba(255,255,255,.05); border-color: var(--ink-on-dark); }
.closing .cta-row {
  margin-top: 40px;
  display: inline-flex;
  gap: 12px;
}

/* =========================================================
   Lead form (Web-to-Lead) — sits inside .closing on dark bg
   ========================================================= */
.lead-plan-pill {
  margin: 28px auto 0;
  max-width: 720px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: rgba(15,212,158,.08);
  border: 1px solid rgba(15,212,158,.35);
  border-radius: 999px;
  padding: 8px 8px 8px 18px;
  text-align: left;
}
.lpp-eyebrow {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3-on-dark, #8893a3);
  font-weight: 500;
}
.lpp-name {
  font-family: var(--f-sans);
  font-size: 14px;
  font-weight: 500;
  color: var(--brand-bright);
  letter-spacing: -0.005em;
}
.lpp-clear {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(255,255,255,.06);
  color: var(--ink-2-on-dark);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 999px;
  padding: 5px 10px;
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.lpp-clear:hover {
  background: rgba(255,255,255,.10);
  border-color: rgba(255,255,255,.22);
  color: var(--ink-on-dark);
}

.lead-form {
  margin: 44px auto 0;
  max-width: 720px;
  text-align: left;
  background: linear-gradient(180deg, rgba(255,255,255,.04) 0%, rgba(255,255,255,.02) 100%);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  padding: 28px clamp(24px, 4vw, 36px) 24px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.lf-honeypot {
  position: absolute !important;
  left: -9999px !important;
  width: 1px; height: 1px; overflow: hidden;
}
.lf-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 18px;
}
.lf-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.lf-span-2 { grid-column: span 2; }
.lf-field label {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2-on-dark);
  font-weight: 500;
}
.lf-field .lf-opt {
  text-transform: none;
  letter-spacing: 0;
  font-size: 11px;
  color: var(--ink-3-on-dark, #8893a3);
  margin-left: 6px;
}
.lf-field input,
.lf-field select,
.lf-field textarea {
  font-family: var(--f-sans);
  font-size: 15px;
  line-height: 1.4;
  color: var(--ink-on-dark);
  background-color: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 8px;
  padding: 11px 14px;
  width: 100%;
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
  appearance: none;
  -webkit-appearance: none;
}
.lf-field textarea {
  resize: vertical;
  min-height: 78px;
  font-family: var(--f-sans);
}
.lf-field select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'><path d='M3 4.5L6 7.5L9 4.5' stroke='%23B6BDC8' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}
.lf-field select option {
  background: var(--paper-deep);
  color: var(--ink-on-dark);
}
.lf-field input::placeholder,
.lf-field textarea::placeholder {
  color: rgba(182,189,200,.55);
}
.lf-field input:hover,
.lf-field select:hover,
.lf-field textarea:hover {
  border-color: rgba(255,255,255,.28);
}
.lf-field input:focus,
.lf-field select:focus,
.lf-field textarea:focus {
  outline: none;
  border-color: var(--brand-bright);
  background-color: rgba(15,212,158,.06);
  box-shadow: 0 0 0 3px rgba(15,212,158,.18);
}
.lf-field [aria-invalid="true"] {
  border-color: rgba(231, 113, 84, 0.65);
  background-color: rgba(231, 113, 84, 0.05);
}
.lf-submit-row {
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.lf-submit {
  /* inherits .btn + .closing .btn styling already (brand-bright) */
}
.lf-meta {
  margin: 0;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: 0.02em;
  color: var(--ink-3-on-dark, #8893a3);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  line-height: 1.4;
}
.lf-meta .lf-dot {
  width: 6px; height: 6px; border-radius: 999px;
  background: var(--brand-bright);
  box-shadow: 0 0 12px var(--brand-bright);
  flex: 0 0 auto;
}

.lf-alt {
  margin: 18px auto 0;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--ink-3-on-dark, #8893a3);
  text-align: center;
}
.lf-alt a {
  color: var(--brand-bright);
  text-decoration: none;
  border-bottom: 1px solid rgba(15,212,158,.4);
}
.lf-alt a:hover { border-bottom-color: var(--brand-bright); }

/* Success state */
.lead-success {
  margin: 44px auto 0;
  max-width: 560px;
  text-align: center;
  background: rgba(15,212,158,.06);
  border: 1px solid rgba(15,212,158,.28);
  border-radius: 16px;
  padding: 36px 32px;
}
.lf-check {
  width: 52px; height: 52px;
  margin: 0 auto 16px;
  border-radius: 999px;
  display: grid; place-items: center;
  background: var(--brand-bright);
  color: var(--paper-deep);
  box-shadow: 0 0 40px -10px var(--brand-bright);
}
.lf-check svg { width: 28px; height: 28px; }
.lead-success h3 {
  font-size: 22px;
  margin: 0 0 10px;
  color: var(--ink-on-dark);
  letter-spacing: -0.01em;
  font-weight: 500;
}
.lead-success p {
  color: var(--ink-2-on-dark);
  margin: 0;
}
.lead-success .lf-success-alt {
  margin-top: 14px;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--ink-3-on-dark, #8893a3);
}
.lead-success .lf-success-alt a {
  color: var(--brand-bright);
  text-decoration: none;
  border-bottom: 1px solid rgba(15,212,158,.4);
}

@media (max-width: 640px) {
  .lf-grid { grid-template-columns: 1fr; }
  .lf-span-2 { grid-column: span 1; }
  .lead-form { padding: 22px 18px 20px; }
  .lf-submit-row { flex-direction: column; align-items: stretch; }
  .lf-meta { justify-content: center; }
}

/* =========================================================
   PLAN CONFIG MODAL
   Opened by pricing-card CTAs. Light card on dark backdrop.
   ========================================================= */
.pcm {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: grid;
  place-items: center;
  padding: 32px 20px;
  overflow-y: auto;
}
.pcm[hidden] { display: none; }
.pcm-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(11, 16, 25, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: pcmFade .22s ease-out;
}
@keyframes pcmFade {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes pcmRise {
  from { opacity: 0; transform: translateY(12px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.pcm-card {
  position: relative;
  width: 100%;
  max-width: 880px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 18px;
  box-shadow: 0 32px 80px -20px rgba(11,16,25,.55), 0 2px 8px rgba(11,16,25,.12);
  padding: 36px clamp(24px, 4vw, 44px) 28px;
  animation: pcmRise .28s cubic-bezier(.2,.7,.2,1.05);
  max-height: calc(100vh - 64px);
  overflow-y: auto;
  /* Keep the rounded right edge intact even when content scrolls — a flush
     native scrollbar visually flattens the top/bottom-right corners. */
  scrollbar-width: thin;
  scrollbar-color: rgba(11,16,25,.22) transparent;
}
.pcm-card::-webkit-scrollbar { width: 10px; }
.pcm-card::-webkit-scrollbar-track {
  background: transparent;
  margin: 14px 0; /* keep the thumb away from the rounded corners */
}
.pcm-card::-webkit-scrollbar-thumb {
  background-color: rgba(11,16,25,.22);
  border-radius: 999px;
  border: 3px solid transparent;
  background-clip: padding-box;
}
.pcm-card::-webkit-scrollbar-thumb:hover {
  background-color: rgba(11,16,25,.36);
}
/* Wrapper around the card so the close button can sit outside the card's
   border-radius without being clipped by its overflow:auto. */
.pcm-card-wrap {
  position: relative;
  width: 100%;
  max-width: 880px;
}

.pcm-close {
  position: absolute;
  top: 0;
  /* Sits just outside the card's right edge, so the visual chrome reads
     "card + dismiss" as a single unit. */
  left: calc(100% + 12px);
  z-index: 9001;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  background: rgba(255,255,255,.08);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  cursor: pointer;
  color: var(--ink-on-dark);
  transition: background .15s, color .15s, border-color .15s, transform .15s;
}
.pcm-close:hover {
  background: rgba(255,255,255,.16);
  border-color: rgba(255,255,255,.32);
  color: #fff;
  transform: rotate(90deg);
}
.pcm-close svg { width: 16px; height: 16px; }

/* On narrow viewports there's no room outside the card — fall back to
   in-corner placement on a translucent pill so it still reads cleanly. */
@media (max-width: 999px) {
  .pcm-close {
    left: auto;
    right: 12px;
    top: 12px;
  }
}

/* Head */
.pcm-head { margin-bottom: 24px; }
.pcm-head h2 {
  font-family: var(--f-sans);
  font-size: clamp(22px, 2.6vw, 28px);
  letter-spacing: -0.015em;
  font-weight: 500;
  line-height: 1.18;
  margin: 12px 0 8px;
  color: var(--ink);
}
.pcm-head .pcm-plan-name {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--brand-ink);
}
.pcm-sub {
  font-size: 14.5px;
  color: var(--ink-3);
  margin: 0;
  max-width: 56ch;
}

/* Rule */
.pcm-rule { height: 1px; background: var(--rule); margin: 20px 0; }

/* Plan switcher row */
.pcm-row {
  display: flex; align-items: center; gap: 16px;
  flex-wrap: wrap;
}
.pcm-row-label {
  font-family: var(--f-mono);
  font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ink-3); font-weight: 500;
}
.pcm-seg {
  display: inline-flex;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
}
.pcm-seg-btn {
  font-family: var(--f-sans);
  font-size: 13px; font-weight: 500;
  letter-spacing: -0.005em;
  background: transparent;
  border: 0;
  color: var(--ink-2);
  padding: 7px 16px;
  border-radius: 999px;
  cursor: pointer;
  transition: background .15s, color .15s, box-shadow .15s;
}
.pcm-seg-btn:hover { color: var(--ink); }
.pcm-seg-btn.is-active {
  background: var(--card);
  color: var(--brand-ink);
  box-shadow: 0 1px 2px rgba(11,16,25,.08), 0 0 0 1px var(--rule);
}

/* Section */
.pcm-section { }
.pcm-section-title {
  display: flex; align-items: baseline; gap: 14px;
  font-family: var(--f-sans);
  font-size: 15.5px; font-weight: 500;
  margin: 0 0 14px;
  color: var(--ink);
  letter-spacing: -0.005em;
}
.pcm-num {
  font-family: var(--f-mono);
  font-size: 11px; letter-spacing: 0.12em;
  color: var(--brand);
  font-weight: 500;
}
.pcm-org-count {
  margin-left: auto;
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: 0.02em;
  font-weight: 400;
}
.pcm-hint {
  font-size: 13px;
  color: var(--ink-3);
  margin: -4px 0 14px;
  max-width: 60ch;
}

/* Light-context form-field overrides (page form is on dark; modal is on light) */
.pcm-form .lf-field label { color: var(--ink-2); }
.pcm-form .lf-field input,
.pcm-form .lf-field select,
.pcm-form .lf-field textarea {
  background-color: var(--card);
  border: 1px solid var(--rule);
  color: var(--ink);
}
.pcm-form .lf-field input::placeholder { color: var(--mute); }
.pcm-form .lf-field input:hover,
.pcm-form .lf-field select:hover,
.pcm-form .lf-field textarea:hover { border-color: var(--rule-2); }
.pcm-form .lf-field input:focus,
.pcm-form .lf-field select:focus,
.pcm-form .lf-field textarea:focus {
  outline: none;
  border-color: var(--brand);
  background-color: var(--brand-soft);
  box-shadow: 0 0 0 3px rgba(22,138,140,.15);
}
.pcm-form .lf-field select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'><path d='M3 4.5L6 7.5L9 4.5' stroke='%235E6878' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/></svg>");
}
.pcm-form .lf-field select option {
  background: var(--card);
  color: var(--ink);
}
.pcm-form .lf-field [aria-invalid="true"] {
  border-color: var(--signal);
  background-color: var(--signal-soft);
}

/* Inline field-level error message (e.g. "use a work email") */
.lf-field .lf-error {
  display: block;
  margin-top: 6px;
  font-family: var(--f-sans);
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--signal);
}
.lf-field .lf-error[hidden] { display: none; }

/* Rate-limit banner shown near the submit button when the user has hit
   the daily submission cap (3 / 24h). Calmer than a field error — this
   isn't user error, it's a soft block we want them to understand. */
.pcm-rate-limit {
  margin: 0 0 12px;
  padding: 12px 14px;
  background: var(--signal-soft);
  border: 1px solid color-mix(in oklab, var(--signal) 25%, transparent);
  border-radius: 10px;
  font-family: var(--f-sans);
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink-2);
}
.pcm-rate-limit b { color: var(--signal); font-weight: 600; }
.pcm-rate-limit[hidden] { display: none; }

/* Google reCAPTCHA widget container — sits above the submit button.
   The widget itself is a fixed 304x78 iframe; we just give it breathing
   room and a left-alignment so it doesn't look floated. */
.pcm-captcha {
  margin: 0 0 14px;
  min-height: 78px;
}
.pcm-captcha .g-recaptcha {
  transform-origin: left center;
}
@media (max-width: 360px) {
  /* On very narrow screens the 304px widget overflows; shrink slightly. */
  .pcm-captcha .g-recaptcha { transform: scale(0.85); }
}

.pcm-contact { grid-template-columns: 1fr 1fr; }

/* Org rows */
.pcm-orgs { display: flex; flex-direction: column; gap: 12px; }
.pcm-org {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 12px;
  padding: 14px 16px 16px;
  position: relative;
  animation: pcmRise .22s ease-out;
}
.pcm-org-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 10px;
}
.pcm-org-label {
  font-family: var(--f-mono);
  font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ink-3); font-weight: 500;
}
.pcm-org-label .pcm-org-n { color: var(--brand); }
.pcm-org-remove {
  background: transparent;
  border: 0;
  width: 26px; height: 26px;
  border-radius: 999px;
  color: var(--ink-3);
  cursor: pointer;
  display: grid; place-items: center;
  transition: background .15s, color .15s;
}
.pcm-org-remove:hover { background: var(--signal-soft); color: var(--signal); }
.pcm-org-remove svg { width: 12px; height: 12px; }
.pcm-org.is-only .pcm-org-remove { visibility: hidden; }

.pcm-org-grid {
  display: grid;
  grid-template-columns: 1.6fr 0.7fr 0.7fr 1fr;
  gap: 10px 12px;
}
.pcm-org-grid .pcm-org-name { grid-column: span 1; }

/* Add row + totals */
.pcm-orgs-foot {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 14px;
  flex-wrap: wrap; gap: 12px;
}
.pcm-add-org {
  display: inline-flex; align-items: center; gap: 8px;
  background: transparent;
  border: 1px dashed var(--rule-2);
  border-radius: 999px;
  padding: 8px 14px;
  font-family: var(--f-sans);
  font-size: 13px; font-weight: 500;
  color: var(--brand-ink);
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.pcm-add-org:hover { background: var(--brand-soft); border-color: var(--brand); border-style: solid; }
.pcm-add-org svg { width: 14px; height: 14px; }
.pcm-totals {
  font-family: var(--f-mono);
  font-size: 11.5px; letter-spacing: 0.04em;
  color: var(--ink-3);
}
.pcm-totals b { color: var(--ink); font-weight: 600; }
.pcm-totals .pcm-dot { margin: 0 6px; color: var(--mute); }

/* Submit row */
.pcm-submit-row {
  margin-top: 24px;
  display: flex; align-items: center; gap: 18px;
  flex-wrap: wrap;
}
.pcm-submit {
  /* inherits .btn primary styling from the page */
  font-size: 14.5px;
  padding: 12px 22px;
}
.pcm-submit:disabled,
.pcm-submit[disabled] {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
  transform: none;
}
.pcm-meta {
  margin: 0;
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  letter-spacing: 0.02em;
  display: inline-flex; align-items: center; gap: 8px;
  line-height: 1.4;
}
.pcm-meta-dot {
  width: 6px; height: 6px; border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 0 10px rgba(22,138,140,.5);
}

/* Success state */
.pcm-success {
  text-align: center;
  padding: 32px 24px 12px;
}
.pcm-success .lf-check {
  background: var(--brand);
  color: var(--card);
  box-shadow: 0 0 36px -8px var(--brand);
}
.pcm-success h3 {
  font-size: 22px; font-weight: 500; margin: 0 0 10px;
  letter-spacing: -0.015em; color: var(--ink);
}
.pcm-success p { color: var(--ink-2); margin: 0 auto; max-width: 50ch; }

@media (max-width: 640px) {
  .pcm { padding: 16px 12px; }
  .pcm-card { padding: 28px 18px 22px; max-height: calc(100vh - 32px); }
  .pcm-contact { grid-template-columns: 1fr; }
  .pcm-org-grid { grid-template-columns: 1fr 1fr; }
  .pcm-org-grid .pcm-org-name { grid-column: span 2; }
  .pcm-submit-row { flex-direction: column; align-items: stretch; }
  .pcm-meta { justify-content: center; }
}

/* =========================================================
   Footer
   ========================================================= */
footer {
  background: var(--paper);
  padding: 48px 0 32px;
  border-top: 1px solid var(--rule);
}
.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
}
@media (max-width: 760px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
.foot-col h5 {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 14px;
  font-weight: 500;
}
.foot-col ul {
  list-style: none;
  padding: 0; margin: 0;
  display: grid;
  gap: 10px;
}
.foot-col a {
  color: var(--ink-2);
  font-size: 14.5px;
  transition: color .12s ease;
}
.foot-col a:hover { color: var(--ink); }
.foot-bottom {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 8px;
  text-align: center;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: .02em;
}
.foot-privacy {
  max-width: 64ch;
  line-height: 1.5;
  color: var(--ink-3);
}
.foot-bottom .right { display: flex; gap: 18px; }

/* =========================================================
   Reveal animations
   ========================================================= */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .7s cubic-bezier(.2,.6,.2,1), transform .7s cubic-bezier(.2,.6,.2,1);
}
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .06s; }
.reveal[data-d="2"] { transition-delay: .12s; }
.reveal[data-d="3"] { transition-delay: .18s; }
.reveal[data-d="4"] { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .ribbon-track { animation: none; }
}


/* ========== Surface tabs — affordance enhancements ========== */
.surfaces-sticky-region {
  position: relative;
  /* JS sets height + negative margin-bottom for partial-sticky behavior */
  pointer-events: none;
}
.surfaces-sticky-region > * { pointer-events: auto; }
.surfaces-sticky {
  position: static;
  z-index: 20;
  background: var(--paper);
  padding-top: 8px;
  padding-bottom: 12px;
  transition: box-shadow .2s ease;
}
.surfaces-sticky::before {
  /* full-bleed paper background under the sticky shelf */
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 0; bottom: 0;
  width: 100vw;
  background: var(--paper);
  z-index: -1;
}
.surfaces-sticky.is-stuck {
  box-shadow: 0 8px 24px -16px rgba(14,20,28,.18);
}
.surfaces-sticky.is-stuck::before {
  border-bottom: 1px solid var(--rule);
}

/* ===== Slim sticky sub-bar: takes over once the full cards scroll away ===== */
.subbar-sentinel { height: 1px; pointer-events: none; }
.surface-subbar {
  position: sticky;
  top: 64px; /* JS overrides to match the live nav height */
  z-index: 21;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  /* Float wider than the page content — break out symmetrically past the container gutter */
  width: min(96vw, 1920px);
  margin-inline: calc((100% - min(96vw, 1920px)) / 2);
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: 0 10px 26px -18px rgba(14,20,28,.22);
  margin-top: -64px; /* JS sets to -(bar height) so it has no resting footprint */
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity .22s ease, transform .22s ease;
}
.surface-subbar.is-visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
@media (max-width: 760px) {
  .surface-subbar {
    grid-template-columns: none;
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .surface-subbar::-webkit-scrollbar { display: none; }
  .subbar-tab { flex: 0 0 auto; min-width: 150px; }
}
.subbar-tab {
  appearance: none;
  background: var(--paper);
  border: 0;
  border-right: 1px solid var(--rule);
  text-align: left;
  padding: 15px 20px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  cursor: pointer;
  transition: background .15s ease;
  min-width: 0;
}
.subbar-tab:last-child { border-right: 0; }
.subbar-tab:not(.active):hover {
  background: linear-gradient(180deg, rgba(22,138,140,.06), rgba(22,138,140,0)), var(--paper);
}
.subbar-tab .sb-hash {
  font-family: var(--f-sans);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0;
  color: #FFFFFF;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.subbar-tab .sb-label {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -.01em;
  line-height: 1.15;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.subbar-tab.active {
  background: linear-gradient(180deg, rgba(22,138,140,.10), var(--card));
}
.subbar-tab.active .sb-hash { color: var(--sn-btn, #0FD49E); }
.subbar-tab.active .sb-label { color: #FFFFFF; font-weight: 600; }
.subbar-tab.is-free .sb-hash::after {
  content: "FREE";
  margin-left: 6px;
  font-size: 8px;
  letter-spacing: .1em;
  color: #fff;
  background: oklch(0.74 0.16 145);
  padding: 1px 4px;
  border-radius: 3px;
  vertical-align: 1px;
}
.subbar-tab.is-free.active .sb-hash::after { background: oklch(0.58 0.16 145); }

.surfaces-nav {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 4px 10px;
  border-bottom: 0;
}
.surfaces-nav .sn-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--ink-3);
  text-transform: uppercase;
  flex: 1;
  min-width: 0;
}
.surfaces-nav .sn-dot {
  width: 6px; height: 6px;
  background: var(--brand);
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(22,138,140,.55);
  flex-shrink: 0;
  animation: snPulse 2.2s ease-in-out infinite;
}
@keyframes snPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: .55; transform: scale(1.35); }
}
.surfaces-nav .sn-counter {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-2);
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  padding-right: 4px;
}
.surfaces-nav .sn-counter #snCount {
  color: var(--ink);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  min-width: 1.5em;
  display: inline-block;
  text-align: right;
}
.surfaces-nav .sn-slash { color: var(--mute); }
.surfaces-nav .sn-total { color: var(--mute); }
.surfaces-nav .sn-arrows {
  display: inline-flex;
  gap: 6px;
}
.surfaces-nav .sn-arrow {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 50%;
  color: var(--ink-2);
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s, transform .15s;
}
.surfaces-nav .sn-arrow:hover {
  background: var(--paper-2);
  color: var(--brand-ink);
  border-color: var(--brand);
  transform: translateY(-1px);
}
.surfaces-nav .sn-arrow svg { width: 14px; height: 14px; }
@media (max-width: 720px) {
  .surfaces-nav .sn-arrows { display: none; }
}

/* Number prefix on each tab */
.surface-tab[data-num]::before {
  content: none;
  position: absolute;
  top: 14px;
  left: 24px;
  font-family: var(--f-mono);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  color: var(--mute);
  opacity: .8;
  transition: color .2s, opacity .2s;
}
.surface-tab.active[data-num]::before {
  color: var(--brand-ink);
  opacity: 1;
}
.surface-tab { padding-top: 22px; }
.surface-tab:hover[data-num]::before { color: var(--ink-2); opacity: 1; }

/* Stronger hover: tab lift + tint */
.surface-tab {
  transition: background .18s ease, color .18s ease, transform .18s ease;
}
.surface-tab:not(.active) {
  background: var(--paper);
}
.surface-tab:not(.active):hover {
  background: linear-gradient(180deg, rgba(22,138,140,.06), rgba(22,138,140,0)), var(--paper);
  transform: translateY(-2px);
}
.surface-tab:not(.active):hover .label { color: var(--ink); }

/* Beefier chevron on hover */
.surface-tab::after {
  width: 14px;
  height: 14px;
  top: 16px;
  right: 16px;
}
.surface-tab:not(.active):hover::after {
  opacity: 1;
  transform: translateX(3px);
}

/* Fin: downward triangle pointing from active tab into the panel */
.surface-fin-wrap {
  position: relative;
  height: 0;
  pointer-events: none;
  z-index: 2;
}
.surface-fin {
  position: absolute;
  top: 0;
  left: 0;
  width: 20%;        /* 1/5 default, JS overrides */
  height: 14px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  transition: left .35s cubic-bezier(.4,.0,.2,1), top .25s cubic-bezier(.4,.0,.2,1), width .25s ease;
}
.surface-fin::before {
  content: "";
  width: 18px;
  height: 9px;
  background: var(--sn-btn, #0FD49E);
  clip-path: polygon(50% 100%, 0 0, 100% 0);
  filter: drop-shadow(0 4px 8px rgba(15,212,158,.45));
}

/* First-visit auto-cycle highlight */
.surface-tab.is-cycling {
  background: linear-gradient(180deg, rgba(22,138,140,.18), rgba(22,138,140,0));
  animation: cyclePulse .42s ease-out;
}
@keyframes cyclePulse {
  0%   { background: linear-gradient(180deg, rgba(22,138,140,.30), rgba(22,138,140,0)); }
  100% { background: linear-gradient(180deg, rgba(22,138,140,0), rgba(22,138,140,0)); }
}

@media (max-width: 1180px) {
  .surface-fin { display: none; }
}
@media (max-width: 880px) {
  .surfaces-nav { gap: 10px; }
  .surfaces-nav .sn-eyebrow { font-size: 10px; letter-spacing: 0.12em; }
}


/* =========================================================
   Pricing section
   ========================================================= */
.pricing {
  background: var(--paper);
}
.pricing .section-head { margin-bottom: 56px; }
.pricing .section-head h2 .it {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--sn-btn, #0FD49E);
  letter-spacing: -0.01em;
}

.price-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  align-items: stretch;
  padding-top: 14px;
}
@media (max-width: 1180px) {
  .price-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .price-grid { grid-template-columns: 1fr; }
}

.price-card {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.price-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--sh-3);
}
.price-card.featured {
  border-color: var(--brand);
  box-shadow:
    0 0 0 1px var(--brand),
    0 24px 60px -24px rgba(22,138,140,.28);
}
.price-card.featured:hover { transform: translateY(-2px); }

.pc-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--brand);
  color: #fff;
  font-family: var(--f-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 4px;
  white-space: nowrap;
}

.pc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.pc-name {
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.pc-tag {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: oklch(0.62 0.17 145);
  background: oklch(0.96 0.04 145);
  padding: 3px 7px;
  border-radius: 3px;
}

.pc-price {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
  margin-top: 4px;
}
.pc-amount {
  font-size: 40px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1;
}
.pc-period {
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.pc-price-custom { flex-wrap: nowrap; align-items: center; gap: 9px; min-height: 40px; }
.pc-price-custom .pc-amount { font-size: 32px; }
.pc-price-custom .pc-period { white-space: nowrap; font-size: 11px; max-width: none; }
.pc-from {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  align-self: center;
  margin-right: 2px;
}

.pc-tagline {
  font-size: 14.5px;
  color: var(--ink-3);
  line-height: 1.5;
  margin: 0;
  min-height: 3em;
}

.pc-features {
  list-style: none;
  margin: 8px 0 0;
  padding: 16px 0 0;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.pc-features li {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.45;
  position: relative;
  padding-left: 24px;
}
.pc-features li .v {
  color: var(--brand);
  font-weight: 600;
  position: absolute;
  left: 0;
  top: 0;
  width: 14px;
  display: inline-block;
}
.pc-features li .mute {
  color: var(--mute);
  position: absolute;
  left: 0;
  top: 0;
  width: 14px;
  display: inline-block;
}
.pc-features li b {
  color: var(--ink);
  font-weight: 500;
}

.pc-cta {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1.2;
  min-height: 42px;
  padding: 0 18px;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 500;
  text-decoration: none;
  transition: background .15s, color .15s, border-color .15s, transform .15s;
}
.pc-cta.primary {
  background: var(--brand);
  color: #fff;
  border: 1px solid var(--brand);
}
.pc-cta.primary:hover {
  background: oklch(0.50 0.10 195);
  border-color: oklch(0.50 0.10 195);
  transform: translateY(-1px);
}
.pc-cta.secondary {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--rule-2);
}
.pc-cta.secondary:hover {
  background: var(--paper-2);
  border-color: var(--ink-3);
  transform: translateY(-1px);
}

/* Add-ons */
.price-addons {
  margin-top: 72px;
  padding-top: 56px;
  border-top: 1px solid var(--rule);
}
.pa-head { margin-bottom: 32px; }
.pa-head h3 {
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin: 12px 0 0;
}
.pa-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 980px) {
  .pa-grid { grid-template-columns: 1fr; }
}
.pa-item {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pa-label {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.pa-price {
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--ink);
  line-height: 1;
}
.pa-unit {
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 400;
  color: var(--ink-3);
  letter-spacing: 0.04em;
}
.pa-desc {
  font-size: 14px;
  color: var(--ink-3);
  line-height: 1.5;
}
.pa-desc b { color: var(--ink-2); font-weight: 500; }

/* Support table */
.price-support {
  margin-top: 72px;
  padding-top: 56px;
  border-top: 1px solid var(--rule);
}
.ps-head { margin-bottom: 32px; }
.ps-head h3 {
  font-size: 40px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin: 12px 0 0;
}
.ps-head .ps-note {
  margin: 14px 0 0;
  font-size: 18.5px;
  color: var(--ink-3);
  max-width: 760px;
  line-height: 1.6;
}
.ps-foot {
  margin: 16px 0 0;
  font-size: 13px;
  color: var(--ink-3);
  line-height: 1.5;
}
.ps-table {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.ps-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 0;
  padding: 16px 24px;
  border-bottom: 1px solid var(--rule);
  font-size: 16px;
  color: var(--ink-2);
  align-items: center;
}
.ps-row:last-child { border-bottom: 0; }
.ps-row > span {
  padding-right: 16px;
  line-height: 1.4;
}
.ps-row [role="rowheader"] {
  font-weight: 500;
  color: var(--ink);
}
.ps-row .mute { color: var(--mute); }
.ps-ext {
  display: block;
  margin-top: 4px;
  font-family: var(--f-mono);
  font-size: 12.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--brand-ink);
}

/* Enterprise (future) column treatment */
.ps-future-head {
  position: relative;
}
.ps-future-head b {
  color: var(--ink-3);
}
.ps-soon {
  display: block;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand-ink);
  background: var(--brand-soft);
  border: 1px dashed rgba(22,138,140,.4);
  border-radius: 3px;
  padding: 2px 8px;
  margin-top: 6px;
  font-weight: 500;
  width: fit-content;
}
.ps-future {
  color: var(--ink-3);
  font-style: italic;
}
.ps-foot {
  margin-top: 18px;
  font-size: 13px;
  color: var(--ink-3);
  font-family: var(--f-mono);
  letter-spacing: 0.01em;
}
.ps-foot a {
  color: var(--brand-ink);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
.ps-foot a:hover { color: var(--brand); }
.ps-header {
  background: var(--paper-2);
  padding-top: 18px;
  padding-bottom: 18px;
}
.ps-header b {
  display: block;
  font-size: 17px;
  color: var(--ink);
  font-weight: 600;
}
.ps-header .ps-incl {
  display: block;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-top: 4px;
}
@media (max-width: 880px) {
  .ps-table { font-size: 13px; }
  .ps-row {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 16px 18px;
  }
  .ps-row [role="rowheader"] { font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-3); font-weight: 500; }
}

.price-foot {
  margin-top: 56px;
  font-size: 13px;
  color: var(--ink-3);
  line-height: 1.6;
  text-align: center;
}
.price-foot a { color: var(--brand-ink); }
.price-foot b { color: var(--ink-2); font-weight: 500; }

/* =========================================================
   Phone polish (<= 640px)
   Fixes flagged by the mobile QA pass — wrap dense widget
   tables, allow long formulas to wrap, collapse stat grids
   to one column, and rein in oversized headlines.
   ========================================================= */
@media (max-width: 640px) {
  /* Trigger trace — formulas would otherwise force horizontal
     scroll because .tt-formula is nowrap + ellipsis by default. */
  .tt-formula {
    white-space: normal;
    text-overflow: clip;
    overflow: visible;
    font-size: 10.5px;
    line-height: 1.45;
    word-break: break-word;
  }
  .tt-rule { gap: 8px; }
  .tt-time { font-size: 9.5px; }

  /* Pipeline widget — 6-col table is too wide for 375px; let it scroll
     horizontally inside the card instead of forcing an overflow. */
  .pipeline-widget { overflow: hidden; }
  .pw-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
    font-size: 12px;
  }
  .pw-table thead, .pw-table tbody, .pw-table tr { display: table; width: 100%; table-layout: fixed; }
  .pw-table colgroup col:nth-child(4),
  .pw-table colgroup col:nth-child(5),
  .pw-table colgroup col:nth-child(6) { width: 64px; }

  /* Stat grids — 2-col still feels cramped on 375px; go full single column. */
  .num-grid { grid-template-columns: 1fr; }
  .num-cell {
    border-right: none !important;
    border-bottom: 1px solid var(--rule);
  }
  .num-cell:last-child { border-bottom: none; }
  .surface-metrics { grid-template-columns: 1fr; }
  .surface-metrics .m {
    border-right: 0 !important;
    border-bottom: 1px solid var(--rule);
  }
  .surface-metrics .m:last-child { border-bottom: none; }

  /* Headlines — keep them confident but stop them blowing out of the viewport.
     clamp floors at 42/40 push past the line; cap below 640. */
  h1 { font-size: clamp(32px, 9vw, 42px); }
  .closing h2 { font-size: clamp(30px, 8.5vw, 40px); }

  /* Engine flow strip — already 1-col on phones, but the cells get tall and
     awkward. Slightly tighter padding keeps them readable. */
  .engine-step { padding: 14px 16px; }

  /* Code blocks in compare sections — let them scroll horizontally instead
     of forcing the whole page to scroll. */
  pre, code { max-width: 100%; }
  pre { overflow-x: auto; -webkit-overflow-scrolling: touch; }

  /* Pricing-detail rows — already stack 1-col at 880px, but cells are tight. */
  .ps-table { font-size: 12.5px; }
  .ps-row { padding: 14px 16px; }
}


/* =========================================================
   Hero capability rotator — cycles #Batch → #UI → #Trigger → #Query
   ========================================================= */
.hero-rotator { position: relative; }
@media (min-width: 941px) {
  /* Float the surface dots below the card so the card (not card+dots) is what
     the left text column vertically centers against. */
  .hero-grid .hero-rotator > .hero-dots { position: absolute; top: 100%; left: 0; right: 0; }
}
.hero-stage { position: relative; transform: scale(0.92); transform-origin: center; }
.hero-scene { transition: opacity .55s ease; }
.hero-scene[data-surface="trigger"] { position: relative; }       /* tallest scene defines stage height */
.hero-scene:not([data-surface="trigger"]) { position: absolute; inset: 0; display: grid; place-items: center; }
.hero-scene { opacity: 0; pointer-events: none; }
.hero-scene.is-active { opacity: 1; pointer-events: auto; }
.hero-scene .bw-annotate { width: 100%; }

/* shared mini-card */
.hs-card {
  width: 100%;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-2);
  overflow: hidden;
  font-family: var(--f-sans);
}
.hero-scene.is-active .hs-card { animation: hsIn .5s ease both; }
@keyframes hsIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.hs-head { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--rule); }
.hs-ico { flex: 0 0 auto; width: 30px; height: 30px; border-radius: var(--r-md); background: var(--brand-soft); color: var(--brand-ink); display: grid; place-items: center; }
.hs-ico svg { width: 17px; height: 17px; }
.hs-head .titles { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.hs-tag { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .12em; color: var(--ink-3); text-transform: uppercase; }
.hs-name { font-size: 14px; font-weight: 500; letter-spacing: -.01em; color: var(--ink); }
.hs-head .spacer { flex: 1; }
.hs-btn { font-family: var(--f-mono); font-size: 11px; letter-spacing: .02em; padding: 6px 12px; border-radius: var(--r-sm); border: 1px solid var(--rule-2); background: var(--paper-2); color: var(--ink); cursor: default; }
.hs-btn.run { background: var(--brand-ink); color: #fff; border-color: var(--brand-ink); }
.hs-chip.ok { font-family: var(--f-mono); font-size: 11px; padding: 4px 10px; border-radius: 999px; background: var(--good-soft); color: var(--good); }

/* list (UI + Query) */
.hs-listhead { padding: 9px 20px; background: var(--paper-2); border-bottom: 1px solid var(--rule); font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); display: grid; gap: 10px; }
.hs-rows { display: flex; flex-direction: column; }
.hs-row { padding: 11px 20px; border-bottom: 1px solid var(--rule); font-size: 13px; color: var(--ink-2); display: grid; gap: 10px; align-items: center; }
.hs-row:last-child { border-bottom: none; }
.hs-row .nm { color: var(--ink); font-weight: 500; }
.hs-row .num, .hs-listhead .num { text-align: right; font-family: var(--f-mono); font-size: 12.5px; color: var(--ink); }
.hs-listhead .num { font-size: 10px; }
.hs-ui .hs-listhead, .hs-ui .hs-row { grid-template-columns: 1.3fr 1fr .7fr auto; }
.hs-query .hs-listhead, .hs-query .hs-row { grid-template-columns: 1.4fr 1fr .8fr; }
.hs-row .act { justify-self: end; font-family: var(--f-mono); font-size: 10.5px; padding: 3px 9px; border-radius: var(--r-sm); border: 1px solid var(--brand-pure); color: var(--brand-ink); background: var(--brand-soft); }
.hs-row.editing .cell-edit { display: inline-flex; align-items: center; padding: 3px 8px; border: 1.5px solid var(--brand); border-radius: var(--r-sm); background: #fff; color: var(--ink); }
.hs-row.editing .cell-edit::after { content: ''; width: 1px; height: 13px; margin-left: 5px; background: var(--brand-ink); animation: hsCaret 1.05s steps(1) infinite; }
@keyframes hsCaret { 50% { opacity: 0; } }

/* chips (Query) */
.hs-chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 20px; border-bottom: 1px solid var(--rule); }
.hs-fchip { font-family: var(--f-mono); font-size: 11.5px; padding: 5px 11px; border-radius: 999px; background: var(--paper-2); border: 1px solid var(--rule); color: var(--ink-2); }
.hs-fchip.add { color: var(--brand-ink); border-style: dashed; border-color: var(--brand-pure); background: transparent; }

/* steps (Trigger) */
.hs-event { padding: 9px 20px 4px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; color: var(--ink-3); }
.hs-steps { list-style: none; margin: 0; padding: 1px 0; }
.hs-steps li { display: flex; align-items: center; gap: 12px; padding: 7px 20px; font-size: 13px; color: var(--ink-2); border-bottom: 1px solid var(--rule); }
.hs-steps li:last-child { border-bottom: none; }
.hs-steps .ck { flex: 0 0 auto; width: 16px; height: 16px; border-radius: 999px; background: var(--good); color: #fff; display: grid; place-items: center; }
.hs-steps .ck svg { width: 10px; height: 10px; }
.hs-steps .hs-out { margin-left: auto; font-family: var(--f-mono); font-size: 12px; color: var(--ink); }
.hs-steps .hs-out.ok { color: var(--good); }

.hs-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 20px; border-top: 1px solid var(--rule); background: var(--paper-3); font-family: var(--f-mono); font-size: 11px; letter-spacing: .04em; color: var(--ink-3); }
.hs-count { color: var(--ink); font-weight: 500; }

/* surface selector */
.hero-dots { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 26px; }
.hero-dot { font-family: var(--f-mono); font-weight: 600; font-size: 14px; letter-spacing: .03em; padding: 9px 18px; border-radius: 999px; border: 1px solid var(--rule); background: var(--card); color: var(--ink-3); cursor: pointer; transition: color .18s ease, border-color .18s ease, background .18s ease; }
.hero-dot:hover { color: var(--ink); border-color: var(--rule-2); }
.hero-dot.on { background: var(--brand-soft); border-color: var(--brand-pure); color: var(--brand-ink); }

/* === #UI · actionable data list (faithful recreation) === */
.al-card { position: relative; width: 100%; background: var(--card); border: 1px solid var(--rule); border-radius: var(--r-lg); box-shadow: var(--sh-2); overflow: hidden; font-family: var(--f-sans); color: var(--ink-2); }
.hero-scene.is-active .al-card { animation: hsIn .5s ease both; }

/* title · record count · selection · custom actions */
.al-titlebar { display: flex; align-items: center; gap: 11px; padding: 12px 16px; border-bottom: 1px solid var(--rule); }
.al-ico { flex: 0 0 auto; width: 30px; height: 30px; border-radius: var(--r-md); background: var(--brand-soft); color: var(--brand-ink); display: grid; place-items: center; }
.al-ico svg { width: 17px; height: 17px; }
.al-titles { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.al-title { font-size: 13.5px; font-weight: 600; letter-spacing: -.01em; color: var(--ink); white-space: nowrap; }
.al-rc { color: var(--ink-3); font-weight: 500; }
.al-selnote { font-family: var(--f-mono); font-size: 10px; letter-spacing: .02em; color: var(--ink-3); white-space: nowrap; transition: color .2s ease; }
.al-selnote.sel { color: var(--brand-ink); font-weight: 500; }
.al-spacer { flex: 1; }
.al-cacts { display: flex; gap: 7px; flex: 0 0 auto; }
.al-cbtn { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 12px; border-radius: var(--r-sm); border: 1px solid var(--brand-ink); background: var(--brand-ink); color: #fff; font-size: 12px; font-weight: 500; cursor: default; opacity: .42; transition: opacity .25s ease, box-shadow .2s ease, transform .12s ease; }
.al-cbtn svg { width: 14px; height: 14px; }
.al-cbtn.ghost { background: var(--card); color: var(--brand-ink); border-color: var(--brand-pure); }
.al-cacts.on .al-cbtn { opacity: 1; }
.al-cacts.on .al-cbtn.flash { box-shadow: 0 0 0 3px var(--brand-soft); }
.al-cbtn.press { transform: translateY(1px); }

/* toolbar: column filter · search · built-in actions */
.al-toolbar { display: flex; align-items: center; gap: 8px; padding: 9px 16px; border-bottom: 1px solid var(--rule); background: var(--paper); }
.al-fieldsel { display: inline-flex; align-items: center; gap: 6px; flex: 0 0 auto; height: 28px; padding: 0 10px; border-radius: var(--r-sm); border: 1px solid var(--rule-2); background: var(--card); color: var(--ink-2); font-size: 12px; cursor: default; }
.al-fieldsel .cv { width: 11px; height: 11px; color: var(--ink-3); }
.al-filter { position: relative; flex: 0 1 196px; min-width: 100px; }
.al-filter.open .al-search { border-color: var(--brand-pure); box-shadow: 0 0 0 2px var(--brand-soft); }
.al-fmenu { position: absolute; top: calc(100% + 5px); left: 0; width: 152px; background: var(--card); border: 1px solid var(--rule-2); border-radius: var(--r-md); box-shadow: 0 16px 38px -12px rgba(11,16,25,.32); padding: 6px; opacity: 0; transform: translateY(-5px); pointer-events: none; transition: opacity .16s ease, transform .16s ease; z-index: 9; }
.al-filter.open .al-fmenu { opacity: 1; transform: none; pointer-events: auto; }
.al-fopt { display: flex; align-items: center; gap: 8px; padding: 6px 7px; border-radius: var(--r-sm); font-size: 12px; color: var(--ink-2); }
.al-fchk { width: 15px; height: 15px; flex: 0 0 auto; border: 1.5px solid var(--rule-2); border-radius: 3px; display: inline-grid; place-items: center; color: #fff; background: var(--card); transition: background .15s ease, border-color .15s ease; }
.al-fchk svg { width: 10px; height: 10px; opacity: 0; transform: scale(.5); transition: opacity .15s ease, transform .15s ease; }
.al-fchk.on { background: var(--brand); border-color: var(--brand); }
.al-fchk.on svg { opacity: 1; transform: none; }
.al-ffoot { display: flex; justify-content: flex-end; padding: 5px 3px 1px; }
.al-confirm { height: 26px; padding: 0 13px; border-radius: var(--r-sm); border: 1px solid var(--brand-ink); background: var(--brand-ink); color: #fff; font-size: 11.5px; cursor: default; }
.al-search { width: 100%; display: flex; align-items: center; gap: 7px; height: 28px; padding: 0 10px; border-radius: var(--r-sm); border: 1px solid var(--rule-2); background: var(--card); color: var(--ink-3); font-size: 12px; transition: border-color .2s ease, box-shadow .2s ease; }
.al-search svg { width: 13px; height: 13px; flex: 0 0 auto; }
.al-search span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.al-search.has { color: var(--ink); }
.al-search.has svg { color: var(--brand-ink); }
.al-bicons { display: flex; gap: 3px; flex: 0 0 auto; margin-left: auto; }
.al-bicons button { width: 27px; height: 27px; display: grid; place-items: center; border: 1px solid var(--rule); border-radius: var(--r-sm); background: var(--card); color: var(--ink-3); cursor: default; }
.al-bicons svg { width: 14px; height: 14px; }

/* column header + rows */
.al-head, .al-row { display: grid; grid-template-columns: 18px 72px minmax(0,1.6fr) minmax(76px,1.05fr) minmax(60px,0.78fr) minmax(80px,1fr) 14px; gap: 9px; align-items: center; }
.al-head { padding: 8px 16px; background: var(--paper-2); border-bottom: 1px solid var(--rule); font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); }
.al-hcell { display: inline-flex; align-items: center; gap: 4px; min-width: 0; }
.al-hcell .cv { width: 9px; height: 9px; color: var(--mute); flex: 0 0 auto; }
.al-hcell.sorted { color: var(--brand-ink); }
.al-hcell .st { width: 10px; height: 10px; color: var(--brand-ink); flex: 0 0 auto; }
.al-rows { display: flex; flex-direction: column; }
.al-row { padding: 6px 16px; max-height: 46px; border-bottom: 1px solid var(--rule); font-size: 12px; color: var(--ink-2); transition: background .25s ease, opacity .3s ease, max-height .35s ease, padding .35s ease; }
.al-row:last-child { border-bottom: none; }
.al-row.sel { background: color-mix(in srgb, var(--brand-soft) 42%, #fff); }
.al-cnum { font-family: var(--f-mono); font-size: 11.5px; color: var(--brand-ink); white-space: nowrap; }
.al-subj { color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.al-pri { display: inline-block; padding: 3px 8px; margin: -3px -8px; border-radius: var(--r-sm); white-space: nowrap; }
.al-stat { display: inline-block; padding: 3px 8px; margin: -3px -8px; border-radius: var(--r-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: calc(100% + 16px); }
.al-pri.editing, .al-stat.editing { box-shadow: inset 0 0 0 1.5px var(--brand); background: #fff; }
.al-pri.lit, .al-stat.lit { animation: alCellFlash 1.1s ease both; }
@keyframes alCellFlash { 0% { background: var(--good-soft); } 100% { background: transparent; } }
.al-ctype { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; color: var(--ink-2); }
.al-rcaret { display: grid; place-items: center; color: var(--mute); }
.al-rcaret svg { width: 11px; height: 11px; }

/* checkboxes */
.al-ck { width: 15px; height: 15px; border: 1.5px solid var(--rule-2); border-radius: 3px; display: inline-grid; place-items: center; color: #fff; background: var(--card); transition: background .16s ease, border-color .16s ease; }
.al-ck svg { width: 10px; height: 10px; opacity: 0; transform: scale(.5); transition: opacity .15s ease, transform .15s ease; }
.al-ck.on { background: var(--brand); border-color: var(--brand); }
.al-ck.on svg { opacity: 1; transform: none; }
.al-ckall.some { background: var(--brand); border-color: var(--brand); }
.al-ckall.some svg { opacity: 1; transform: none; }

/* filter row collapse / incoming */
.al-row.gone { opacity: 0; max-height: 0; padding-top: 0; padding-bottom: 0; border-bottom: none; overflow: hidden; }
.al-row.incoming { animation: alRowIn .4s ease both; }
@keyframes alRowIn { 0% { opacity: 0; transform: translateY(-5px); } 100% { opacity: 1; transform: none; } }

/* pagination */
.al-pager { display: flex; align-items: center; justify-content: center; gap: 4px; padding: 9px 16px; border-top: 1px solid var(--rule); background: var(--paper-3); }
.al-psize { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 9px; border-radius: var(--r-sm); border: 1px solid var(--rule-2); background: var(--card); font-family: var(--f-mono); font-size: 11.5px; color: var(--ink-2); }
.al-psize .cv { width: 10px; height: 10px; color: var(--ink-3); }
.al-pgap { display: none; }
.al-psize { margin-right: 8px; }
.al-pbtn { height: 26px; min-width: 26px; padding: 0 9px; border-radius: var(--r-sm); border: 1px solid var(--rule); background: var(--card); color: var(--ink-2); font-family: var(--f-mono); font-size: 11.5px; cursor: default; transition: background .2s ease, color .2s ease, border-color .2s ease; }
.al-pbtn[disabled] { color: var(--mute); }
.al-pg { padding: 0; }
.al-pbtn.on { background: var(--brand-ink); border-color: var(--brand-ink); color: #fff; }
.al-pdots { color: var(--mute); padding: 0 2px; font-family: var(--f-mono); }

/* inline-edit popover (positioned over the Priority cell by JS) */
.al-edit { position: absolute; width: 206px; background: var(--card); border: 1px solid var(--rule-2); border-radius: var(--r-md); box-shadow: 0 20px 44px -14px rgba(11,16,25,.34); padding: 13px 14px; opacity: 0; transform: translateY(-6px) scale(.985); transform-origin: top left; pointer-events: none; transition: opacity .18s ease, transform .18s ease; z-index: 10; }
.al-edit.on { opacity: 1; transform: none; pointer-events: auto; }
.al-edit-label { display: block; font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 6px; }
.al-edit-field { display: flex; align-items: center; justify-content: space-between; gap: 8px; border: 1.5px solid var(--brand); border-radius: var(--r-sm); padding: 6px 9px; font-size: 12.5px; color: var(--ink); }
.al-edit-field .cv { width: 11px; height: 11px; color: var(--ink-3); flex: 0 0 auto; }
.al-edit-check { display: flex; align-items: center; gap: 8px; margin-top: 11px; font-size: 11.5px; color: var(--ink-2); }
.al-edit-check b { color: var(--ink); font-weight: 600; }
.al-edit-foot { display: flex; justify-content: flex-end; gap: 7px; margin-top: 12px; }
.al-ghostbtn, .al-applybtn { height: 28px; padding: 0 13px; border-radius: var(--r-sm); font-size: 11.5px; cursor: default; transition: transform .12s ease; }
.al-ghostbtn { background: var(--card); border: 1px solid var(--rule-2); color: var(--ink-2); }
.al-applybtn { background: var(--brand-ink); border: 1px solid var(--brand-ink); color: #fff; }
.al-applybtn.press { transform: translateY(1px); }

/* toast */
.al-toast { position: absolute; left: 50%; bottom: 52px; transform: translateX(-50%) translateY(8px); background: var(--good); color: #fff; font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .02em; padding: 8px 15px; border-radius: 999px; opacity: 0; pointer-events: none; transition: opacity .3s ease, transform .3s ease; z-index: 11; white-space: nowrap; box-shadow: 0 8px 22px -8px rgba(17,125,79,.55); }
.al-toast b { font-weight: 600; }
.al-toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .hero-scene { transition: none; }
  .hero-scene.is-active .hs-card,
  .hero-scene.is-active .al-card { animation: none; }
  .hs-row.editing .cell-edit::after { animation: none; }
  .al-pri.lit { animation: none; }
  .al-row.incoming { animation: none; }
  .al-edit, .al-toast { transition: none; }
  .hl-mrow, .hl-bar, .hl-toast { transition: none; }
  .qh-chip, .qh-row, .qh-toast { transition: none; }
  .qh-row .rate.lit { animation: none; }
  .qh-row .rate.editing::after { animation: none; }
}

/* === #Data Loader · hero demo (CSV upload → rule transforms → run upsert) === */
.hl-card { position: relative; }
.hl-status { font-family: var(--f-mono); font-size: 11px; letter-spacing: .02em; padding: 5px 11px; border-radius: 999px; border: 1px solid var(--rule-2); background: var(--paper-2); color: var(--ink-3); cursor: default; display: inline-flex; align-items: center; gap: 6px; transition: color .25s ease, background .25s ease, border-color .25s ease; }
.hl-status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--mute); transition: background .25s ease; }
.hl-status.running { color: var(--brand-ink); background: var(--brand-soft); border-color: var(--brand-pure); }
.hl-status.running::before { background: var(--brand); animation: pulse 1.1s ease-in-out infinite; }
.hl-status.done { color: var(--good); background: var(--good-soft); border-color: color-mix(in srgb, var(--good) 40%, transparent); }
.hl-status.done::before { background: var(--good); animation: none; }

/* dropzone */
.hl-drop { display: flex; align-items: center; gap: 12px; margin: 14px 18px 0; padding: 12px 14px; border: 1.5px dashed var(--rule-2); border-radius: var(--r-md); background: var(--paper); transition: border-color .3s ease, background .3s ease; }
.hl-drop.parsed { border-style: solid; border-color: var(--brand-pure); background: color-mix(in srgb, var(--brand-soft) 40%, #fff); }
.hl-fileicon { flex: 0 0 auto; width: 30px; height: 30px; display: grid; place-items: center; border-radius: var(--r-sm); background: var(--card); border: 1px solid var(--rule); color: var(--brand-ink); }
.hl-fileicon svg { width: 16px; height: 16px; }
.hl-fileinfo { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.hl-filename { font-size: 13px; font-weight: 500; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hl-filemeta { font-family: var(--f-mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.hl-parsed { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 5px; font-family: var(--f-mono); font-size: 11px; color: var(--good); opacity: 0; transform: translateX(-4px); transition: opacity .3s ease, transform .3s ease; }
.hl-parsed svg { width: 12px; height: 12px; }
.hl-drop.parsed .hl-parsed { opacity: 1; transform: none; }

/* field mapping */
.hl-maptitle { padding: 14px 18px 8px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.hl-map { padding: 0 18px 14px; display: flex; flex-direction: column; gap: 6px; }
.hl-mrow { display: grid; grid-template-columns: 70px 12px 72px minmax(0,1fr); gap: 8px; align-items: center; padding: 7px 11px; border: 1px solid var(--rule); border-radius: var(--r-sm); background: var(--paper); font-size: 11.5px; opacity: 0; transform: translateY(-5px); transition: opacity .3s ease, transform .3s ease, border-color .3s ease, background .3s ease; }
.hl-mrow.in { opacity: 1; transform: none; }
.hl-mrow.applied { border-color: var(--brand-pure); background: color-mix(in srgb, var(--brand-soft) 28%, #fff); }
.hl-mrow .src { font-family: var(--f-mono); color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hl-mrow .arr { color: var(--mute); text-align: center; }
.hl-mrow .field { font-weight: 500; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hl-mrow .fn { font-family: var(--f-mono); font-size: 11px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hl-mrow .fn b { color: var(--brand-ink); font-weight: 500; }

/* foot: audit + run */
.hl-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px 16px; }
.hl-audit { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .01em; color: var(--ink-3); min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .25s ease; }
.hl-audit b { color: var(--ink-2); font-weight: 600; }
.hl-audit.done { color: var(--good); }
.hl-audit.done b { color: var(--good); }
.hl-run { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 14px; border-radius: var(--r-sm); border: 1px solid var(--brand-ink); background: var(--brand-ink); color: #fff; font-size: 12px; font-weight: 500; cursor: default; transition: transform .12s ease, filter .2s ease; }
.hl-run svg { width: 13px; height: 13px; }
.hl-run.press { transform: translateY(1px); }
.hl-run.running { filter: saturate(.5) opacity(.7); }

/* progress bar (pinned to card bottom) */
.hl-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--paper-3); overflow: hidden; opacity: 0; transition: opacity .2s ease; }
.hl-progress.on { opacity: 1; }
.hl-bar { display: block; height: 100%; width: 0%; background: var(--brand); transition: width .25s linear; }
.hl-bar.done { background: var(--good); }

/* success toast */
.hl-toast { position: absolute; left: 50%; bottom: 60px; transform: translateX(-50%) translateY(8px); background: var(--good); color: #fff; font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .02em; padding: 8px 15px; border-radius: 999px; opacity: 0; pointer-events: none; transition: opacity .3s ease, transform .3s ease; z-index: 6; white-space: nowrap; box-shadow: 0 8px 22px -8px rgba(17,125,79,.55); }
.hl-toast b { font-weight: 600; }
.hl-toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }

/* === #Query · hero demo (visual builder · dynamic filters · saved queries · editable results) === */
.qh-card { position: relative; }
.qh-saved { position: relative; flex: 0 0 auto; }
.qh-savedbtn { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 11px; border-radius: var(--r-sm); border: 1px solid var(--rule-2); background: var(--card); color: var(--ink-2); font-size: 12px; cursor: default; transition: border-color .2s ease, box-shadow .2s ease; }
.qh-savedbtn svg { width: 11px; height: 11px; color: var(--ink-3); }
.qh-saved.open .qh-savedbtn { border-color: var(--brand-pure); box-shadow: 0 0 0 2px var(--brand-soft); }
.qh-savedmenu { position: absolute; top: calc(100% + 5px); right: 0; width: 178px; background: var(--card); border: 1px solid var(--rule-2); border-radius: var(--r-md); box-shadow: 0 16px 38px -12px rgba(11,16,25,.32); padding: 5px; opacity: 0; transform: translateY(-5px); pointer-events: none; transition: opacity .16s ease, transform .16s ease; z-index: 9; }
.qh-saved.open .qh-savedmenu { opacity: 1; transform: none; pointer-events: auto; }
.qh-sq { display: flex; align-items: center; gap: 7px; padding: 7px 9px; border-radius: var(--r-sm); font-size: 12px; color: var(--ink-2); white-space: nowrap; transition: background .15s ease, color .15s ease; }
.qh-sq::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--mute); flex: 0 0 auto; }
.qh-sq.pick { background: var(--brand-soft); color: var(--brand-ink); }
.qh-sq.pick::before { background: var(--brand); }
.qh-run { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 13px; border-radius: var(--r-sm); border: 1px solid var(--brand-ink); background: var(--brand-ink); color: #fff; font-size: 12px; font-weight: 500; cursor: default; transition: transform .12s ease; }
.qh-run svg { width: 12px; height: 12px; }
.qh-run.press { transform: translateY(1px); }

/* builder */
.qh-builder { display: flex; flex-wrap: wrap; gap: 8px; padding: 13px 18px 0; }
.qh-tok { display: inline-flex; align-items: center; gap: 7px; padding: 5px 10px; border-radius: var(--r-sm); border: 1px solid var(--rule); background: var(--paper); font-size: 12px; color: var(--ink); }
.qh-tok i { font-style: normal; font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .08em; color: var(--ink-3); }
.qh-tok.obj { background: var(--paper-2); }

/* filters (point-and-click, incl. dynamic) */
.qh-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 18px 14px; }
.qh-flabel { font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .1em; color: var(--ink-3); }
.qh-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; border: 1px solid var(--brand-pure); background: var(--brand-soft); font-size: 11.5px; color: var(--ink-2); opacity: 0; transform: scale(.92); transition: opacity .22s ease, transform .22s ease; }
.qh-chip.in { opacity: 1; transform: none; }
.qh-chip b { color: var(--brand-ink); font-weight: 600; }
.qh-chip.dyn { border-style: dashed; }
.qh-chip .dynb { font-style: normal; font-family: var(--f-mono); font-size: 8.5px; letter-spacing: .04em; text-transform: uppercase; color: #fff; background: var(--brand); border-radius: 3px; padding: 2px 4px; }
.qh-addf { display: inline-flex; align-items: center; padding: 5px 10px; border-radius: 999px; border: 1px dashed var(--rule-2); background: transparent; font-size: 11.5px; color: var(--ink-3); transition: border-color .2s ease, color .2s ease; }
.qh-addf.armed { border-color: var(--brand-pure); color: var(--brand-ink); }

/* results — editable data list */
.qh-listhead, .qh-row { display: grid; grid-template-columns: 1.5fr 1.1fr .85fr .85fr .85fr; gap: 10px; align-items: center; }
.qh-listhead { padding: 8px 18px; background: var(--paper-2); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.qh-listhead .num { text-align: left; }
.qh-rows { display: flex; flex-direction: column; }
.qh-row { padding: 9px 18px; border-bottom: 1px solid var(--rule); font-size: 12.5px; color: var(--ink-2); opacity: 0; transform: translateY(-5px); transition: opacity .26s ease, transform .26s ease; }
.qh-row.in { opacity: 1; transform: none; }
.qh-row:last-child { border-bottom: none; }
.qh-row .nm { color: var(--ink); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qh-row .num { text-align: left; font-family: var(--f-mono); font-size: 12px; color: var(--ink-2); }
.qh-row .rate { display: inline-block; padding: 2px 8px; margin: -2px -8px; border-radius: var(--r-sm); white-space: nowrap; }
.qh-row .rate.editing { box-shadow: inset 0 0 0 1.5px var(--brand); background: #fff; }
.qh-row .rate.editing::after { content: ""; display: inline-block; width: 1px; height: 12px; background: var(--brand-ink); margin-left: 2px; vertical-align: middle; animation: hsCaret 1.05s steps(1) infinite; }
.qh-row .rate.lit { animation: alCellFlash 1.1s ease both; }

.qh-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 18px; border-top: 1px solid var(--rule); background: var(--paper-3); font-family: var(--f-mono); font-size: 11px; letter-spacing: .04em; color: var(--ink-3); }
.qh-foot b { color: var(--ink); font-weight: 600; }

/* toast */
.qh-toast { position: absolute; left: 50%; bottom: 60px; transform: translateX(-50%) translateY(8px); background: var(--good); color: #fff; font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .02em; padding: 8px 15px; border-radius: 999px; opacity: 0; pointer-events: none; transition: opacity .3s ease, transform .3s ease; z-index: 6; white-space: nowrap; box-shadow: 0 8px 22px -8px rgba(17,125,79,.55); }
.qh-toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }


/* =========================================================
   ServiceNow-style modes (toggleable via Tweaks) — revertible.
   body.sn-hero  : dark hero band, bright-teal headline
   body.sn-heads : bright-teal headlines on the dark sections
   ========================================================= */
body.sn-hero .hero {
  background:
    radial-gradient(75% 60% at 50% -12%, rgba(43,227,229,.10), transparent 62%),
    radial-gradient(45% 55% at 96% -5%, rgba(15,212,158,.07), transparent 65%),
    var(--sn-hero-bg, #395B58);
  position: relative;
}
body.sn-hero .hero::before {
  content: '';
  position: absolute; inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(circle at 1px 1px, rgba(255,255,255,.07) 1px, transparent 1.5px) 0 0 / 24px 24px;
  mask-image: radial-gradient(ellipse 105% 95% at 38% 24%, black, transparent 82%);
  -webkit-mask-image: radial-gradient(ellipse 105% 95% at 38% 24%, black, transparent 82%);
}
body.sn-hero .hero > .container { position: relative; z-index: 1; }
body.sn-hero .hero h1 .slogan { color: var(--ink-on-dark); }
body.sn-hero .hero .eyebrow { color: var(--ink-3-on-dark); }
body.sn-hero .hero h1 .brand-word { color: #6DBE89; }
body.sn-hero .hero h1 .it { color: var(--ink-on-dark); }
body.sn-hero .hero h1 .mute-it { color: #F0824B; }
body.sn-hero .hero h1 .good-it { color: #6DBE89; }
body.sn-hero .hero h1 .ink-mute { color: var(--ink-3-on-dark); }
body.sn-hero .hero-replaces { color: var(--ink-2-on-dark); }
body.sn-hero .hero-replaces .hr-tag { color: var(--ink-2-on-dark); }
body.sn-hero .hero-replaces .hr-arrow { color: var(--ink-3-on-dark); }
body.sn-hero .hero-replaces .hr-target { color: var(--brand-bright); }
body.sn-hero .results-block .results-head { color: var(--brand-bright); }
body.sn-hero .results li .n { color: var(--brand-bright); }
body.sn-hero .results li .r { color: rgba(255,255,255,.58); }
body.sn-hero .results li .r b { color: #fff; }
body.sn-hero .results-note { color: var(--ink-3-on-dark); }
body.sn-hero .hero-trust { color: var(--ink-2-on-dark); }
body.sn-hero .hero-sub {
  margin-top: 44px;
  max-width: 48ch;
  font-size: 19.5px;
  line-height: 1.55;
  color: var(--ink-2-on-dark);
}
body.sn-hero .hero-sub b { color: var(--ink-on-dark); font-weight: 600; }
/* Decongest the hero left column */
body.sn-hero .hero-replaces { margin-top: 38px; }
body.sn-hero .results-block { margin-top: 56px; }
body.sn-hero .results li { padding: 12px 0; }
body.sn-hero .hero-cta { margin-top: 64px; }
body.sn-hero .hero-trust { margin-top: 24px; }

/* Transformational Results — bento grid */
.results-bento {
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.results-bento .rb-cell {
  border-radius: 16px;
  padding: 30px 30px 32px;
  min-height: 200px;
  display: flex;
  flex-direction: column;
}
.results-bento .rb-head { padding: 14px 8px 8px 0; justify-content: center; }
.results-bento .rb-head h2 {
  font-size: clamp(30px, 2.8vw, 40px);
  line-height: 1.0;
  margin-top: 14px;
}
.results-bento .rb-head .rb-head-note {
  margin-top: 18px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink-2-on-dark);
  max-width: 30ch;
}
.results-bento .rb-result {
  background: rgba(255,255,255,.045);
  border: 1px solid rgba(255,255,255,.10);
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.results-bento .rb-result:hover {
  transform: translateY(-3px);
  border-color: rgba(40,224,122,.45);
  background: rgba(255,255,255,.06);
}
.results-bento .rb-n {
  font-family: var(--f-mono);
  font-size: 13px;
  letter-spacing: .12em;
  color: var(--sn-btn, #28E07A);
}
.results-bento .rb-lead {
  margin-top: auto;
  padding-top: 28px;
  font-family: var(--f-display);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: #FFFFFF;
}
.results-bento .rb-lead .rb-hl { color: var(--sn-btn, #28E07A); }
.results-bento .rb-detail {
  margin-top: 12px;
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--ink-2-on-dark);
}
.results-section .results-note { max-width: 72ch; margin-top: 26px; }
@media (max-width: 980px) {
  .results-bento { grid-template-columns: repeat(2, 1fr); }
  .results-bento .rb-head { grid-column: 1 / -1; padding-bottom: 4px; }
}
@media (max-width: 640px) {
  .results-bento { grid-template-columns: 1fr; }
  .results-bento .rb-cell { min-height: 0; }
}
body.sn-hero .hero-trust .pip { background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.14); color: var(--ink-2-on-dark); }
body.sn-hero .hero-trust .pip-strong b { color: #FFFFFF; }
body.sn-hero .hero-trust .pip-strong svg { color: var(--sn-btn, #0FD49E); }
body.sn-hero .cap-text .cap-points li::before {
  background-color: var(--good);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'><path d='M4 8l3 3 5-6' stroke='%23FFFFFF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-size: 70%;
  background-position: center;
}
body.sn-hero h2 .hl-accent { color: var(--sn-btn, #0FD49E); }
body.sn-hero .hero .btn { background: var(--sn-btn, #0FD49E); border-color: var(--sn-btn, #0FD49E); color: #06231C; }
body.sn-hero .hero .btn:hover { filter: brightness(1.08); }
body.sn-hero .hero .btn.secondary { background: transparent; color: var(--ink-on-dark); border-color: rgba(255,255,255,.2); }
body.sn-hero .hero .btn.secondary:hover { background: rgba(255,255,255,.06); border-color: var(--ink-on-dark); }

body.sn-heads .functions h2 { color: var(--brand-bright); }
body.sn-heads .closing h2 { color: var(--brand-bright); }

/* =========================================================
   Page harmony — carry the hero's softer dark tone + accents
   into every dark band so the whole page reads as one piece.
   ========================================================= */
body.sn-hero .ribbon,
body.sn-hero .functions,
body.sn-hero .closing { background-color: #234A50; }
body.sn-hero .ribbon { border-top-color: rgba(255,255,255,.07); border-bottom-color: rgba(255,255,255,.07); }
body.sn-hero .functions { border-top-color: rgba(255,255,255,.07); border-bottom-color: rgba(255,255,255,.07); }
body.sn-hero .closing { border-top-color: rgba(255,255,255,.07); }

body.sn-hero .functions { position: relative; }
body.sn-hero .functions::before {
  content: '';
  position: absolute; inset: 0;
  pointer-events: none; z-index: 0;
  background: radial-gradient(circle at 1px 1px, rgba(255,255,255,.06) 1px, transparent 1.5px) 0 0 / 22px 22px;
  mask-image: radial-gradient(ellipse 90% 60% at 25% 0%, black, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 90% 60% at 25% 0%, black, transparent 70%);
}
body.sn-hero .functions > .container { position: relative; z-index: 1; }

body.sn-hero .closing .btn { background: var(--sn-btn, #0FD49E); border-color: var(--sn-btn, #0FD49E); color: #06231C; box-shadow: 0 0 0 1px var(--sn-btn, #0FD49E), 0 0 44px -8px var(--sn-btn, #0FD49E); }
body.sn-hero .closing .btn:hover { filter: brightness(1.08); transform: translateY(-1px); }
body.sn-hero .closing .btn.secondary { background: transparent; color: var(--ink-on-dark); border-color: rgba(255,255,255,.2); box-shadow: none; filter: none; }
body.sn-hero .closing .btn.secondary:hover { background: rgba(255,255,255,.06); border-color: var(--ink-on-dark); filter: none; }
body.sn-hero .pc-cta.primary { background: var(--sn-btn, #0FD49E); border-color: var(--sn-btn, #0FD49E); color: #06231C; }
body.sn-hero .pc-cta.primary:hover { filter: brightness(1.08); background: var(--sn-btn, #0FD49E); border-color: var(--sn-btn, #0FD49E); }
body.sn-hero .price-card.featured { border-color: var(--sn-btn, #0FD49E); box-shadow: 0 0 0 1px var(--sn-btn, #0FD49E), 0 24px 60px -24px rgba(15,212,158,.30); }
body.sn-hero .pc-badge { background: var(--sn-btn, #0FD49E); color: #06231C; }
body.sn-hero .pc-features li .v { color: var(--sn-btn, #0FD49E); }
body.sn-hero .engine-step.action { border-color: var(--sn-btn, #0FD49E); box-shadow: 0 0 0 1px var(--sn-btn, #0FD49E), 0 0 24px -10px rgba(15,212,158,.45); }
body.sn-hero .engine-step.action .num,
body.sn-hero .engine-step.action .name { color: var(--sn-btn, #0FD49E); }
body.sn-hero .stage-btn.active {
  border-color: var(--sn-btn, #0FD49E);
  background: #FFFFFF;
  box-shadow: 0 0 0 1px var(--sn-btn, #0FD49E), 0 0 32px -12px rgba(15,212,158,.5);
}
body.sn-hero .stage-btn.active .num { background: var(--sn-btn, #0FD49E); color: #06231C; }
body.sn-hero .stage-btn.active .stage-name { color: #14302E; }
body.sn-hero .stage-btn {
  background: #F1F5F4;
  border-color: rgba(0,0,0,.05);
  color: #2B4A4A;
}
body.sn-hero .stage-btn:hover { background: #FFFFFF; border-color: rgba(0,0,0,.14); }
body.sn-hero .stage-btn .stage-name { color: #14302E; }
body.sn-hero .stage-btn .stage-sub { color: #5E7672; }
body.sn-hero .stage-btn .num { background: #DCE6E4; color: #3C5853; }
body.sn-hero .stage-btn .chev { color: #6E867F; opacity: 1; }
body.sn-hero .stage-preview .exec-row.lit > .k {
  background: rgba(15,212,158,.2);
  color: #0A6A45;
  font-weight: 600;
  box-shadow: inset 3px 0 0 var(--sn-btn, #0FD49E);
}
body.sn-hero .stage-preview .exec-row.lit > .v {
  background: rgba(15,212,158,.16);
}

/* Light Live Preview card (matches light walkthrough boxes) */
body.sn-hero .stage-preview .exec-card {
  background: #FFFFFF;
  border-color: rgba(0,0,0,.08);
  box-shadow: 0 22px 54px -26px rgba(0,0,0,.55);
}
body.sn-hero .stage-preview .exec-card::before { display: none; }
body.sn-hero .stage-preview .exec-head {
  background: linear-gradient(180deg, #EEF3F2, #FFFFFF);
  border-bottom: 1px solid rgba(0,0,0,.06);
}
body.sn-hero .stage-preview .exec-head .icn {
  background: #E1ECE9; color: #1F4E48; border-color: rgba(0,0,0,.06);
}
body.sn-hero .stage-preview .exec-head .obj { color: #5E7672; }
body.sn-hero .stage-preview .exec-head .name { color: #14302E; }
body.sn-hero .stage-preview .exec-head .pill {
  background: rgba(15,212,158,.16); color: #0B6E47; border: 1px solid rgba(15,212,158,.34);
}
body.sn-hero .stage-preview .exec-row > .k,
body.sn-hero .stage-preview .exec-row > .v { border-top-color: rgba(0,0,0,.07); }
body.sn-hero .stage-preview .exec-row > .k { color: #5E7672; background: #E7EFEC; border-right: 1px solid rgba(0,0,0,.09); }
body.sn-hero .stage-preview .exec-row > .v { background: #F4F8F7; }
body.sn-hero .stage-preview .exec-row.dim > .k,
body.sn-hero .stage-preview .exec-row.dim > .v { opacity: 1; }
body.sn-hero .stage-preview .exec-row > .v { color: #14302E; }
body.sn-hero .stage-preview .exec-row .v .tok-field { color: #14302E; }
body.sn-hero .stage-preview .exec-row .v .tok-fn { color: #0B6E47; }
body.sn-hero .stage-preview .exec-row .v .tok-str { color: #0B6E47; }
body.sn-hero .stage-preview .exec-row .v .tok-op { color: #8A9B97; }
body.sn-hero .stage-preview .exec-row .v .arrow-asn { color: #0FA877; }
body.sn-hero .stage-preview .stage-card-foot {
  background: #EEF3F2;
  border-top: 1px solid rgba(0,0,0,.06);
  color: #5E7672;
}
/* Let the footer note grow to fill the card so its bottom aligns with the
   left rail, while the table rows keep their natural height. */
body.sn-hero .anatomy-grid > .reveal:last-child > .stage-preview { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
body.sn-hero .stage-preview .exec-card { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
body.sn-hero .stage-preview .exec-rows { flex: 0 0 auto; }
body.sn-hero .stage-preview .stage-card-foot { flex: 1 1 auto; }
body.sn-hero .stage-btn.active .stage-sub { color: #5E7672; }
body.sn-hero .stage-btn.active .chev { color: var(--sn-btn, #0FD49E); }
body.sn-hero .pr-foot { color: #FFFFFF; }
body.sn-hero .pr-foot b { color: #FFFFFF; font-weight: 600; }
body.sn-hero .stage-btn.active .chev { color: var(--sn-btn, #0FD49E); }
body.sn-hero .surface-tab.active {
  background: linear-gradient(180deg, rgba(15,212,158,.16), rgba(15,212,158,.05));
  position: relative;
  z-index: 1;
  box-shadow:
    inset 0 0 0 2px var(--sn-btn, #0FD49E),
    0 6px 18px -10px rgba(15,212,158,.45);
}
body.sn-hero .surface-tab.active .hash,
body.sn-hero .surface-tab.active[data-num]::before { color: var(--sn-btn, #0FD49E); }
body.sn-hero .surface-tab.active::after { background: var(--sn-btn, #0FD49E); box-shadow: 0 0 14px rgba(15,212,158,.45); }
/* Round the active highlight's outer corners so the green ring follows the container's rounded corners */
body.sn-hero .surface-tab.active:first-child { border-radius: calc(var(--r-lg) - 1px) 0 0 calc(var(--r-lg) - 1px); }
body.sn-hero .surface-tab.active:last-child { border-radius: 0 calc(var(--r-lg) - 1px) calc(var(--r-lg) - 1px) 0; }
/* Hover (non-active): show the brand green — outline, tint and hash */
body.sn-hero .surface-tab:not(.active):hover {
  background: linear-gradient(180deg, rgba(15,212,158,.10), rgba(15,212,158,0)), var(--paper);
  box-shadow: inset 0 0 0 2px rgba(15,212,158,.55);
}
body.sn-hero .surface-tab:not(.active):hover .hash { color: var(--sn-btn, #0FD49E); }
body.sn-hero .sec-badge .mark { background: var(--sn-btn, #0FD49E); color: #06231C; }
body.sn-hero .sec-pillar .icn { background: rgba(15,212,158,.16); color: var(--sn-btn, #0FD49E); }


/* =========================================================
   FULL-PAGE DARK THEME (gated to body.sn-hero)
   The whole page becomes the hero's teal-slate canvas by
   re-toning the design tokens. Product mockups stay LIGHT
   via island resets below, so they read like real app
   screenshots floating on the dark surface.
   ========================================================= */
body.sn-hero {
  --paper: #234A50;
  --paper-2: #284E54;
  --paper-3: #2C535A;
  --card: #305A61;
  --card-2: #2B545B;
  --ink: #EAF1F2;
  --ink-head: #FFFFFF;
  --ink-2: #B9C8CA;
  --ink-3: #8BA1A3;
  --mute: #6E8587;
  --rule: rgba(255,255,255,.10);
  --rule-2: rgba(255,255,255,.20);
  --brand-ink: #4FD2D4;
  --brand-soft: rgba(43,227,229,.12);
  --signal: #F0824B;
  --signal-soft: rgba(240,130,75,.16);
  --good: #3FD58E;
  --good-soft: rgba(63,213,142,.16);
  --sh-1: 0 1px 0 rgba(0,0,0,.20), 0 1px 2px rgba(0,0,0,.30);
  --sh-2: 0 1px 0 rgba(0,0,0,.20), 0 8px 24px -10px rgba(0,0,0,.45);
  --sh-3: 0 1px 0 rgba(0,0,0,.25), 0 24px 60px -24px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.06);
}

/* Light islands — product mockups keep the original light palette */
body.sn-hero .hero-rotator,
body.sn-hero .cap-viz,
body.sn-hero .surface-viz,
body.sn-hero .cap-fullbleed {
  color: var(--ink);
  --paper: #FAFBFC;
  --paper-2: #F2F4F8;
  --paper-3: #EAEEF3;
  --card: #FFFFFF;
  --card-2: #FAFBFC;
  --ink: #0E141C;
  --ink-head: #0B2227;
  --ink-2: #2D3340;
  --ink-3: #5E6878;
  --mute: #8A93A1;
  --rule: #E3E7EE;
  --rule-2: #C9D0DA;
  --brand-ink: #0B5E60;
  --brand-soft: #E0EFEF;
  --signal: #C84A1A;
  --signal-soft: #FBE7DC;
  --good: #117D4F;
  --good-soft: #DCF0E5;
  --sh-1: 0 1px 0 rgba(11,16,25,.03), 0 1px 2px rgba(11,16,25,.05);
  --sh-2: 0 1px 0 rgba(11,16,25,.03), 0 8px 24px -10px rgba(11,16,25,.14);
  --sh-3: 0 1px 0 rgba(11,16,25,.04), 0 24px 60px -24px rgba(11,16,25,.22), 0 0 0 1px rgba(127,185,187,.08);
}

/* Make the stage-engine panels obvious across all capabilities (per comment) */
body.sn-hero .surface-viz:has(.engine-strip) {
  border: 1px solid rgba(40,224,122,.45);
  box-shadow:
    0 0 0 1px rgba(40,224,122,.25),
    0 0 60px -16px rgba(40,224,122,.45),
    0 30px 70px -30px rgba(0,0,0,.6);
  background:
    radial-gradient(120% 80% at 50% -10%, rgba(40,224,122,.07), transparent 60%),
    #FFFFFF;
}
body.sn-hero .surface-viz:has(.engine-strip) .v-title {
  font-size: 13px;
  color: #0B5E45;
  font-weight: 600;
}
body.sn-hero .surface-viz:has(.engine-strip) .v-title::before {
  width: 9px; height: 9px;
  background: var(--sn-btn, #28E07A);
  box-shadow: 0 0 0 4px rgba(40,224,122,.2), 0 0 12px rgba(40,224,122,.8);
}
body.sn-hero .engine-step { min-height: 128px; padding: 22px 20px; }
body.sn-hero .engine-step .num { font-size: 13px; }
body.sn-hero .engine-step .name { font-size: 21px; }
body.sn-hero .engine-step .desc { font-size: 13.5px; line-height: 1.5; }
body.sn-hero .engine-step.action {
  background: linear-gradient(180deg, rgba(40,224,122,.1), #FFFFFF);
  border-color: var(--sn-btn, #28E07A);
  box-shadow: 0 0 0 1px var(--sn-btn, #28E07A), 0 0 28px -10px rgba(40,224,122,.5);
}
body.sn-hero .engine-step.action .num { color: #0B5E45; }
body.sn-hero .engine-step.action .name { color: #0B7A4D; }
body.sn-hero .engine-step.action .desc { color: var(--ink-2); }


/* hero-dot redesign — refined dark chips (they live in the light hero island,
   so colors are set explicitly to override the island's light tokens) */
body.sn-hero .hero-dots { gap: 10px; margin-top: 10px; }
body.sn-hero .hero-dot {
  font-family: var(--f-sans);
  font-size: 14px;
  font-weight: 600;
  padding: 9px 18px;
  background: rgba(255,255,255,.045);
  border: 1px solid rgba(255,255,255,.14);
  color: #FFFFFF;
  letter-spacing: 0;
  text-transform: none;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
body.sn-hero .hero-dot:hover {
  background: rgba(255,255,255,.09);
  border-color: rgba(255,255,255,.28);
  color: #FFFFFF;
}
body.sn-hero .hero-dot.on {
  background: var(--sn-btn, #0FD49E) !important;
  border-color: transparent !important;
  color: #06231C !important;
  box-shadow: 0 0 24px -8px var(--sn-btn, #0FD49E);
}

body.sn-hero .nav .brand-mark span { color: #FFFFFF; }

/* Header sizing (dark theme) */
body.sn-hero .nav-inner { padding-top: 18px; padding-bottom: 18px; }
body.sn-hero .nav .brand-mark span { font-size: 18px; line-height: 1; }
body.sn-hero .nav .brand-mark { align-items: center; }
body.sn-hero .nav .brand-mark .logo { width: 36px; height: 36px; }
body.sn-hero .nav-links { font-size: 18px; gap: 8px; }
body.sn-hero .nav-links a { font-size: 18px; padding: 9px 14px; }
body.sn-hero .nav-cta .btn { font-size: 15px; padding: 11px 20px; }

body.sn-hero .nav-dd-trigger { font-size: 18px; color: var(--ink); font-weight: 500; padding: 9px 14px; }

/* Larger footer (dark theme) */
body.sn-hero .foot-col h5 {
  font-family: var(--f-sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #93AEA9;
}
body.sn-hero .foot-col a { font-size: 15px; color: #FFFFFF; }
body.sn-hero .foot-col ul { gap: 12px; }

/* Ambient page depth — keeps the dark canvas from reading as a flat slab */
body.sn-hero {
  background-color: var(--paper);
  background-image:
    radial-gradient(90% 50% at 50% 0%, rgba(43,227,229,.045), transparent 58%),
    radial-gradient(55% 40% at 100% 22%, rgba(15,212,158,.035), transparent 62%),
    radial-gradient(50% 40% at 0% 72%, rgba(15,212,158,.03), transparent 62%),
    radial-gradient(circle at 1px 1px, rgba(255,255,255,.02) 1px, transparent 1.6px);
  background-size: auto, auto, auto, 26px 26px;
  background-attachment: fixed;
  background-repeat: no-repeat, no-repeat, no-repeat, repeat;
}

/* Enriched header background matching the hero */
body.sn-hero .nav {
  background-color: var(--sn-hero-bg, #395B58);
  background-image:
    radial-gradient(60% 200% at 6% 0%, rgba(43,227,229,.08), transparent 64%),
    radial-gradient(50% 200% at 97% 0%, rgba(15,212,158,.06), transparent 64%);
  background-repeat: no-repeat, no-repeat;
  -webkit-backdrop-filter: none; backdrop-filter: none;
  border-bottom: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 1px 0 rgba(0,0,0,.18), 0 8px 20px -14px rgba(0,0,0,.55);
}
body.sn-hero .nav.scrolled, body.sn-hero .nav.is-stuck { border-bottom-color: rgba(255,255,255,.14); }

/* BEFORE sprawl panel — "legacy canvas" background: a fine graph-paper line
   grid (the Flow/code canvas it describes), a depth vignette, and a faint warm
   glow behind the orange file-chip cluster to signal the legacy sprawl. */
body.sn-hero .sprawl {
  background-color: #3A656C;
  background-image:
    radial-gradient(55% 48% at 24% 40%, rgba(214,119,87,.10), transparent 72%),
    radial-gradient(130% 125% at 50% -10%, transparent 70%, rgba(0,0,0,.10)),
    radial-gradient(circle, rgba(120,224,200,.16) 1.5px, transparent 2px),
    radial-gradient(circle, rgba(255,255,255,.07) 1px, transparent 1.5px);
  background-size: 100% 100%, 100% 100%, 48px 48px, 16px 16px;
  background-position: center, center, 8px 8px, 0 0;
  border-color: rgba(255,255,255,.10);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
}

/* ============================================================
   THE SHIFT — only the two panels are light "islands"; the
   section keeps the dark sn-hero background and the headline /
   labels stay light. Scoped to .sprawl + .pipeline-records.
   ============================================================ */
body.sn-hero #shift .sprawl,
body.sn-hero #shift .pipeline-records {
  --paper: #FFFFFF;
  --paper-2: #FFFFFF;
  --paper-3: #F2F5F7;
  --card: #FFFFFF;
  --card-2: #FAFBFC;
  --ink: #14222B;
  --ink-head: #0B2227;
  --ink-2: #3A4750;
  --ink-3: #65757C;
  --mute: #93A0A6;
  --rule: #E6EAEE;
  --rule-2: #CDD5DB;
  --brand-ink: #0B6E60;
  --brand-soft: #E2F1EF;
  --signal: #D2551F;
  --signal-soft: #FBE7DC;
  --good: #11935C;
  --good-soft: #DCF0E5;
  --sh-1: 0 1px 0 rgba(16,32,40,.03), 0 1px 2px rgba(16,32,40,.06);
  --sh-2: 0 1px 0 rgba(16,32,40,.03), 0 12px 30px -14px rgba(16,32,40,.18);
  color: var(--ink);
}

/* BEFORE: light canvas with faint dot grid + the colored file chips */
body.sn-hero #shift .sprawl {
  background-color: #F4F7F9;
  background-image:
    radial-gradient(60% 55% at 26% 38%, rgba(210,85,31,.04), transparent 74%),
    radial-gradient(circle, rgba(36,64,74,.07) 1px, transparent 1.5px);
  background-size: 100% 100%, 30px 30px;
  background-position: center, 0 0;
  border-color: #E4E8EC;
  box-shadow: var(--sh-2);
}
body.sn-hero #shift .sprawl .footnote { color: #65757C; }
body.sn-hero #shift .sprawl-node { box-shadow: 0 1px 2px rgba(16,32,40,.10); }

/* AFTER: white record card */
body.sn-hero #shift .pipeline-records { box-shadow: var(--sh-2); }
body.sn-hero #shift .pipeline-records .pr-foot,
body.sn-hero #shift .pipeline-records .pr-foot b { color: var(--ink); }

/* Make the #UI and #Query hero cards as tall as the other rotator scenes.
   min-height stays under the trigger scene (504px) so they never overflow into
   the dots; the rows area grows so each card's footer anchors to the bottom. */
@media (min-width: 941px) {
  .hero-scene[data-surface="ui"] .al-card,
  .hero-scene[data-surface="query"] .hs-card {
    display: flex;
    flex-direction: column;
    min-height: 488px;
  }
  .hero-scene[data-surface="ui"] .al-rows,
  .hero-scene[data-surface="query"] .qh-rows {
    flex: 1 1 auto;
  }
  /* spread the stretch evenly across the UI rows so the last row sits flush
     at the bottom instead of leaving a single trailing gap */
  .hero-scene[data-surface="ui"] .al-rows {
    display: flex;
    flex-direction: column;
  }
  .hero-scene[data-surface="ui"] .al-rows > * {
    flex: 1 1 auto;
  }
}

/* All hero-scene card footers share one height. nowrap stops the Batch
   footer wrapping to two lines; min-height levels the rest. */
.hero-scene .bw-progress-foot,
.hero-scene .hl-foot,
.hero-scene .qh-foot,
.hero-scene .al-pager {
  min-height: 48px;
  box-sizing: border-box;
  white-space: nowrap;
}
.hero-scene .hl-foot { padding-top: 9px; padding-bottom: 9px; }
.hero-scene .bw-progress-foot { padding-top: 7px; padding-bottom: 7px; }
.hero-scene .bw-progress-foot .actions button { padding-top: 5px; padding-bottom: 5px; }

/* Give the Data Loader footer the same top-rule + tinted background the other
   hero footers have, so it reads as a footer strip rather than blending in. */
.hero-scene .hl-foot {
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
}

/* Remove the bottom-right corner pill across all hero scene cards. */
.hero-scene .bw-annotate .anno.br {
  display: none;
}


/* #Data Loader capability panel reuses the animated hero loader card —
   give its footer the same strip treatment the hero scene applies. */
#loaderCap .hl-foot {
  min-height: 48px;
  box-sizing: border-box;
  white-space: nowrap;
  padding-top: 9px;
  padding-bottom: 9px;
  border-top: 1px solid var(--rule);
  background: var(--paper-3);
}
