/* Sitebound landing: light by default, dark on request. Loaded after ../onboard/common.css, ../onboard/style.css and
   ../dashboard/style.css (the inline kit uses their components), so these tokens win everywhere on the page.
   Scale: spacing in steps of 8px (--s1..), radii --r-sm / --r-md / --r-lg, type --fs-*. */
:root {
  color-scheme: light;
  --bg: #fafaf7;
  --surface: #ffffff;
  --ink: #14171a;
  --muted: #565c66;
  --line: #e2e2da;
  --line-2: #cfcfc6;
  --accent: #0b7a5a;
  --accent-ink: #ffffff;
  --ring: rgba(11, 122, 90, 0.25);
  --err: #b42318;
  --warn: #8a5a00;
  --shadow: 0 1px 2px rgba(20, 23, 26, 0.05), 0 8px 24px rgba(20, 23, 26, 0.07);
  --font: Inter, "Inter var", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --pad: clamp(16px, 5vw, 48px);

  /* Theme-dependent pieces that are not one flat colour */
  --spot: 11, 122, 90;            /* rgb of the accent, for washes and the pointer light */
  --rl: 20, 23, 26;               /* rgb of the ink, for dots and rings */
  --dot-a: 0.16; --ring-a: 0.14;
  --hl: rgba(255, 255, 255, 1);   /* top edge highlight */
  --sh1: rgba(20, 23, 26, 0.06); --sh2: rgba(20, 23, 26, 0.08);
  --field: #ffffff;
  --sunk: #f4f4ef;
  --chip: linear-gradient(180deg, #ffffff, #f7f7f3);
  --chip-lit: linear-gradient(180deg, #ecf7f2, #e2f2ea);
  --conn: #8b929a;
  --num: #8b929a;
  --placeholder: #737a82;
  --hover-line: #aeb1a8;
  --wash: 0.05;

  --s1: 8px; --s2: 16px; --s3: 24px; --s4: 32px; --s5: 40px; --s6: 48px; --s8: 64px; --s12: 96px;
  --r-sm: 6px; --r-md: 10px; --r-lg: 16px;
  --fs-xs: 0.75rem; --fs-sm: 0.875rem; --fs-md: 1rem; --fs-lg: 1.125rem; --fs-xl: 1.5rem;
  --fs-h2: clamp(1.75rem, 1.1rem + 2.6vw, 2.5rem);
  --fs-hero: clamp(2rem, 1.2rem + 3.4vw, 3.5rem);
  --card: var(--surface);
  --edge: inset 0 1px 0 var(--hl);
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #07080a;
  --surface: #101215;
  --ink: #eef0ee;
  --muted: #9ba2aa;
  --line: #22262b;
  --line-2: #2f343a;
  --accent: #3fd69a;
  --accent-ink: #04150d;
  --ring: rgba(63, 214, 154, 0.3);
  --err: #ff9a90;
  --warn: #f1c56b;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 10px 32px rgba(0, 0, 0, 0.45);
  --spot: 63, 214, 154;
  --rl: 255, 255, 255;
  --dot-a: 0.075; --ring-a: 0.11;
  --hl: rgba(255, 255, 255, 0.05);
  --sh1: rgba(0, 0, 0, 0.5); --sh2: rgba(0, 0, 0, 0.4);
  --field: #0d0f12;
  --sunk: #0c0e10;
  --chip: linear-gradient(180deg, #1b1f23, #111316);
  --chip-lit: linear-gradient(180deg, #12261d, #0c1713);
  --conn: #66707a;
  --num: #5d656d;
  --placeholder: #7d858e;
  --hover-line: #4a525a;
  --wash: 0.04;
}

html { scroll-behavior: smooth; }
body {
  background:
    radial-gradient(1100px 640px at 50% 38%, rgba(var(--spot), var(--wash)), transparent 62%),
    var(--bg);
  background-repeat: no-repeat;
  overflow-x: hidden;
  font-feature-settings: "cv11", "ss03";
  font-variant-numeric: tabular-nums;
}
/* Keyboard focus: one ring everywhere, shaped like the thing it surrounds. */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.top a:focus-visible, .quiet:focus-visible, .skip:focus-visible { border-radius: 999px; }

/* Top bar */
.top {
  position: absolute; inset: 0 0 auto 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: var(--s2);
  padding: var(--s2) calc(var(--pad) - 6px);
}
.top-brand {
  display: inline-flex; align-items: center; gap: 10px; padding: 6px;
  font-weight: 650; letter-spacing: -0.03em; text-decoration: none; border-radius: 999px;
}
.top-brand .mark { width: 22px; height: 22px; }
.top nav { display: flex; align-items: center; gap: 4px; min-width: 0; }
.top nav a {
  padding: 8px 12px; border-radius: 999px; color: var(--muted);
  font-size: var(--fs-sm); text-decoration: none; white-space: nowrap; transition: color 0.2s, background-color 0.2s;
}
.top nav .nav-sec { display: none; }
@media (min-width: 1000px) { .top nav .nav-sec { display: inline-block; } }
.top nav a:hover { color: var(--ink); background: rgba(var(--rl), 0.06); }
@media (max-width: 560px) {
  .top-brand span { display: none; }
  .top nav a { padding: 8px; }
}

/* Hero background: a dot lattice (lit under the pointer by field.js, which draws on this canvas). It lives inside the
   hero only and fades out at its bottom edge. Not `.field`: that class is the form row in onboard/common.css. */
.hero-field {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none;
  background-image: radial-gradient(circle, rgba(var(--rl), var(--dot-a)) 1px, transparent 1.5px);
  background-size: 28px 28px;
  -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent);
  mask-image: linear-gradient(180deg, #000 55%, transparent);
}
main { position: relative; z-index: 1; }

/* Hero: the search bar, with website chips orbiting it (orbit.js). The orbit layer makes no stacking context, so its
   chips sit either behind the hero content (z 1, .is-back) or in front of it (z 3). */
.hero {
  position: relative; overflow: clip;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 72px var(--pad) clamp(40px, 8vh, 80px);
}
.hero-inner { position: relative; z-index: 2; width: 100%; max-width: 680px; text-align: center; pointer-events: none; }
.hero-inner > * { pointer-events: auto; }
.hero-h, .tagline { width: fit-content; max-width: 100%; margin-inline: auto; }

.hero-h {
  font-size: var(--fs-hero); font-weight: 700; letter-spacing: -0.04em; line-height: 1.05;
  text-wrap: balance;
}
.tagline {
  margin-top: var(--s2);
  font-size: clamp(1rem, 0.92rem + 0.4vw, 1.125rem); line-height: 1.55; color: var(--muted); text-wrap: balance;
}

/* Orbit rings: fade out toward the edges of the hero. Styled here, on the svg, never on .orbit itself (an opacity,
   filter or animation there would make a stacking context around every chip). Chips never overlap the text, so they
   all sit in front of the hero content (z 3); orbit.js fades a chip out before it reaches any text. */
.orbit { position: absolute; inset: 0; pointer-events: none; }
.orbit-rings {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; overflow: visible;
  -webkit-mask-image: linear-gradient(90deg, #000 24%, transparent 32%, transparent 68%, #000 76%);
  mask-image: linear-gradient(90deg, #000 24%, transparent 32%, transparent 68%, #000 76%);
}
.orbit-rings ellipse { fill: none; stroke: rgba(var(--rl), calc(var(--ring-a) * 1.7)); stroke-width: 1; stroke-dasharray: 2 6; }
.orbit-rings ellipse:nth-child(2) { stroke: rgba(var(--rl), calc(var(--ring-a) * 0.7)); }
.orb-chip {
  position: absolute; left: 0; top: 0; z-index: 3; display: block; padding: 0; border: 0; background: none;
  color: var(--ink); font: 500 0.75rem/1 var(--mono);
  pointer-events: auto; cursor: pointer; transform-origin: 50% 50%; will-change: transform, opacity;
}
.orb-chip:focus-visible { outline: none; }
.orb-face {
  display: inline-flex; align-items: center; gap: 8px; padding: 5px 14px 5px 5px; white-space: nowrap;
  border: 1px solid var(--line-2); border-radius: 999px;
  background: var(--field);
  box-shadow: 0 1px 2px var(--sh1);
  transition: border-color 0.2s, box-shadow 0.2s, background-color 0.2s;
}
.orb-chip.is-lit .orb-face, .orb-chip[aria-expanded="true"] .orb-face, .orb-chip:focus-visible .orb-face {
  border-color: color-mix(in srgb, var(--accent) 65%, transparent);
  background: var(--chip-lit);
  box-shadow: 0 0 0 3px var(--ring);
}
/* The logo: the site's own file from logos/ on a white tile. Until it loads, or if there is none, a letter mark. */
.orb-logo {
  position: relative; display: grid; place-items: center; width: 24px; height: 24px; flex: none; overflow: hidden; border-radius: 50%;
  font-size: 0.6875rem; font-weight: 700; color: #fff; background: hsl(var(--h) 36% 34%);
}
.orb-logo img { position: absolute; inset: 4px; width: 16px; height: 16px; object-fit: contain; opacity: 0; transition: opacity 0.2s; }
.orb-logo.has-img { background: #fff; box-shadow: inset 0 0 0 1px rgba(20, 23, 26, 0.1); color: transparent; }
.orb-logo.has-img img { opacity: 1; }
.orb-chip[data-kind="ours"] .orb-face, .orb-chip[data-kind="user"] .orb-face { border-color: color-mix(in srgb, var(--accent) 40%, var(--line-2)); }
@keyframes orb-in { from { transform: scale(0.9); opacity: 0; } }
.orb-face.is-new { animation: orb-in 0.3s var(--ease) both; }

/* The detail panel: docked at the bottom, never modal. */
.panel {
  position: fixed; z-index: 20; left: 50%; bottom: max(var(--s2), env(safe-area-inset-bottom));
  width: min(720px, calc(100% - 2 * var(--s2))); max-height: min(72svh, 520px); overflow: auto; overscroll-behavior: contain;
  display: grid; gap: var(--s2); padding: var(--s2) var(--s2) var(--s2) var(--s3);
  border: 1px solid var(--line-2); border-radius: var(--r-lg); background: var(--surface); box-shadow: var(--shadow);
  transform: translate(-50%, 0);
  transition: opacity 0.24s var(--ease), transform 0.24s var(--ease), visibility 0s;
}
.panel:not(.is-open) {
  opacity: 0; visibility: hidden; pointer-events: none; transform: translate(-50%, 8px);
  transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0s 0.2s;
}
.panel:focus { outline: 0; }
.panel-bar { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s2); }
.panel-who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.panel .orb-logo { width: 36px; height: 36px; font-size: var(--fs-md); }
.panel .orb-logo img { inset: 8px; width: 20px; height: 20px; }
.panel-name { min-width: 0; }
.panel-title { font-size: var(--fs-lg); font-weight: 650; letter-spacing: -0.02em; line-height: 1.25; overflow-wrap: anywhere; }
.panel-what { color: var(--muted); font-size: var(--fs-sm); line-height: 1.4; }
.panel-x {
  display: grid; place-items: center; width: 32px; height: 32px; flex: none; margin: -4px -8px 0 0; padding: 0;
  border: 0; border-radius: 999px; background: transparent; color: var(--muted); cursor: pointer; transition: color 0.2s, background-color 0.2s;
}
.panel-x:hover { color: var(--ink); background: rgba(var(--rl), 0.06); }
.panel-x svg { width: 16px; height: 16px; }
.panel-cols { display: grid; gap: var(--s2); }
.panel-col { display: grid; align-content: start; gap: var(--s1); padding: var(--s2); border-radius: var(--r-md); background: var(--sunk); }
.panel-col h3 { font-size: var(--fs-sm); font-weight: 600; letter-spacing: -0.005em; line-height: 1.4; }
.panel-col p, .panel-col li { color: var(--muted); font-size: var(--fs-sm); line-height: 1.5; }
.panel-col ul { display: grid; gap: 6px; }
.panel-col li { position: relative; padding-left: 14px; }
.panel-col li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 5px; height: 5px; border-radius: 50%; background: var(--line-2); }
.panel-link {
  justify-self: start; padding: 4px 0; border: 0; background: none; cursor: pointer; color: var(--ink);
  font: inherit; font-size: var(--fs-sm); font-weight: 500; text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 4px;
  transition: text-decoration-color 0.2s;
}
.panel-link:hover { text-decoration-color: currentColor; }
a.panel-link::after { content: "\2197"; margin-left: 4px; font-size: 0.85em; }
.panel-lede { max-width: 52ch; color: var(--muted); line-height: 1.5; }
.panel-cta { justify-self: start; }
@media (max-width: 619px) {
  .panel { padding: var(--s2); gap: 12px; }
  .panel-col { padding: 12px var(--s2); }
}
@media (min-width: 620px) {
  .panel-cols { grid-template-columns: 1fr 1fr; }
}

/* Search bar */
.search { margin-top: var(--s5); }
.search-row { position: relative; }
.pill {
  position: relative; display: flex; align-items: center; gap: 12px;
  height: 56px; padding: 0 var(--s3);
  background: var(--field); border: 1px solid var(--line-2); border-radius: 999px;
  box-shadow: inset 0 1px 0 var(--hl), inset 0 0 28px rgba(var(--spot), 0.04), 0 12px 32px var(--sh2);
  transition: box-shadow 0.25s var(--ease), border-color 0.25s;
}
.pill:hover { border-color: var(--hover-line); }
.pill:focus-within {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--line-2));
  box-shadow: inset 0 1px 0 var(--hl), inset 0 0 28px rgba(var(--spot), 0.07), 0 0 0 4px var(--ring), 0 12px 32px var(--sh2);
}
.pill:has([aria-invalid]) {
  border-color: var(--err);
  box-shadow: inset 0 1px 0 var(--hl), 0 0 0 4px color-mix(in srgb, var(--err) 20%, transparent), 0 12px 32px var(--sh2);
}
.pill-icon { width: 20px; height: 20px; flex: none; color: var(--muted); transition: color 0.25s; }
.search-row[data-state="valid"] .pill-icon, .pill:focus-within .pill-icon { color: var(--accent); }
.pill:has([aria-invalid]) .pill-icon { color: var(--err); }
.pill input {
  flex: 1; min-width: 0; height: 100%;
  border: 0; outline: 0; background: transparent; color: var(--ink);
  font: inherit; font-size: var(--fs-md); /* 16px minimum: no iOS zoom on focus */
}
.pill input::placeholder { color: var(--placeholder); opacity: 1; }

.search-go {
  width: 100%; margin-top: var(--s1); height: 48px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3);
}
.search-go:hover:not(:disabled) { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 4px 16px var(--ring); }
.go-arrow, .go-spin { width: 16px; height: 16px; }
.go-spin { display: none; }
.search-row[data-state="loading"] .search-go { pointer-events: none; }
.search-row[data-state="loading"] .go-arrow { display: none; }
.search-row[data-state="loading"] .go-spin { display: block; }
.search-go:hover .go-arrow { transform: translateX(2px); }
.go-arrow { transition: transform 0.25s var(--ease); }

/* Under the bar, one slot: the hint, or the validation message in its place. Same box, so nothing moves. */
.under { display: grid; margin-top: var(--s2); }
.under > * { grid-area: 1 / 1; }
.msg {
  display: flex; align-items: flex-start; justify-content: center; gap: var(--s1);
  color: var(--err); font-size: var(--fs-sm); line-height: 1.5; text-wrap: balance; visibility: hidden;
}
.msg:not(:empty) { visibility: visible; }
.msg:not(:empty)::before {
  content: "!"; display: grid; place-items: center; width: 16px; height: 16px; margin-top: 2px; flex: none;
  border: 1.5px solid currentColor; border-radius: 50%; font-size: 0.6875rem; font-weight: 700; line-height: 1;
}
.trust { max-width: 64ch; margin-inline: auto; color: var(--muted); font-size: var(--fs-sm); line-height: 1.5; text-wrap: balance; transition: opacity 0.2s; }
.search:has([aria-invalid]) .trust { opacity: 0; }

@media (min-width: 560px) {
  .pill { padding-right: 216px; }
  .search-go { position: absolute; right: 6px; top: 6px; bottom: 6px; width: auto; height: auto; margin: 0; padding: 0 var(--s3); }
}
.hero-links { margin-top: var(--s2); display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0 var(--s2); }

.quiet {
  display: inline-flex; align-items: center; padding: 12px 8px; border: 0; background: none; cursor: pointer;
  color: var(--muted); font: inherit; font-size: var(--fs-sm); text-decoration: none; border-radius: 999px; transition: color 0.2s;
}
.quiet:hover { color: var(--ink); }
.quiet.is-try { color: var(--ink); font-weight: 600; }
.quiet.is-try[aria-expanded="true"] { text-decoration: underline; text-underline-offset: 4px; }

/* The inline setup kit */
.kit { scroll-margin-top: 12px; padding: clamp(24px, 6vw, 56px) var(--pad) clamp(40px, 8vw, 88px); }
.kit-root {
  width: min(760px, 100%); margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0;
  padding: clamp(20px, 4vw, 36px); border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.kit-root .step-body, .kit-root .status, .kit-root .totals, .kit-root .table { background: var(--sunk); }
.kit-loading { margin: 0; }
.kit-status { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 8px; color: var(--muted); font-size: 0.92rem; }
.kit-status .spin { width: 14px; height: 14px; }
.kit-trust { overflow-wrap: anywhere; margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.875rem; }

.preview { display: grid; gap: 10px; padding: 16px; border: 1px dashed var(--line-2); border-radius: 16px; }
.test-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 16px; }
.test-amt { width: 150px; }
.test-go { display: flex; align-items: center; min-height: 48px; }

.mini-dash { display: grid; gap: 18px; margin-top: clamp(28px, 5vw, 44px); padding-top: clamp(24px, 4vw, 32px); border-top: 1px solid var(--line); }
.mini-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 16px; }
.mini-top .sect { margin-top: 2px; overflow-wrap: anywhere; }
.mini-dash .totals { margin-bottom: 0; }
.mini-dash .orders { margin-bottom: 0; }

/* Below the fold */
.band { max-width: 1040px; margin: 0 auto; padding: clamp(48px, 8vw, 80px) var(--pad); }
.section-title {
  max-width: 20ch; font-size: var(--fs-h2); line-height: 1.1; font-weight: 700; letter-spacing: -0.035em;
  text-wrap: balance;
}
.section-title span { color: var(--muted); }

.tag {
  font-size: var(--fs-xs); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted);
}
.tag { display: inline-flex; align-items: center; gap: var(--s1); margin-bottom: var(--s1); }

/* How a payment is routed: three icons joined by a line with a light that runs along it. */
.route-flow { margin-top: var(--s5); display: grid; gap: 0; }
.route-flow li { position: relative; padding: 0 0 var(--s4) 68px; }
.route-flow li:last-child { padding-bottom: 0; }
.ico {
  position: absolute; left: 0; top: 0; z-index: 1; display: grid; place-items: center; width: 48px; height: 48px;
  border: 1px solid var(--line-2); border-radius: 50%; background: var(--field); color: var(--ink);
}
.ico svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.route-flow li:last-child .ico { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, var(--line-2)); }
.route-flow li:not(:last-child)::after {
  content: ""; position: absolute; left: 23px; top: 52px; bottom: 4px; width: 2px; border-radius: 2px;
  background: linear-gradient(180deg, transparent, var(--accent), transparent) 0 -100% / 100% 40% no-repeat, var(--line);
}
.route-flow h3 { font-size: var(--fs-lg); font-weight: 600; letter-spacing: -0.02em; line-height: 1.3; padding-top: 2px; }
.route-flow p { margin-top: 4px; color: var(--muted); max-width: 36ch; }

/* Verify us */
.vcard .tag { margin: 0; }
.vcard a { text-underline-offset: 3px; }
.vhead { display: flex; align-items: center; justify-content: space-between; gap: var(--s1); }
.vfacts { display: grid; gap: var(--s2); }
.vfacts dt { font-size: var(--fs-xs); font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.vfacts dd { margin-top: 2px; font: 0.8125rem/1.5 var(--mono); overflow-wrap: anywhere; }
.vresult {
  display: flex; align-items: flex-start; gap: 10px; padding: 12px var(--s2); border-radius: var(--r-sm);
  border: 1px solid var(--line); color: var(--muted); font-weight: 600; font-size: var(--fs-sm); line-height: 1.5;
}
.vresult::before { content: ""; width: 8px; height: 8px; margin-top: 7px; flex: none; border-radius: 50%; background: currentColor; }
.vresult.ok { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 40%, var(--line)); background: color-mix(in srgb, var(--accent) 8%, transparent); }
.vresult.bad { color: var(--err); border-color: color-mix(in srgb, var(--err) 40%, var(--line)); background: color-mix(in srgb, var(--err) 8%, transparent); }
.vresult.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 38%, var(--line)); background: color-mix(in srgb, var(--warn) 6%, transparent); }

/* Status chip: green match, amber could not verify, red mismatch, grey while it works. */
.chip {
  --c: var(--muted);
  display: inline-flex; align-items: center; gap: 6px; flex: none; height: 24px; padding: 0 10px 0 8px;
  border: 1px solid color-mix(in srgb, var(--c) 35%, var(--line)); border-radius: 999px;
  background: color-mix(in srgb, var(--c) 10%, transparent); color: var(--c);
  font-size: var(--fs-xs); font-weight: 600; letter-spacing: 0.01em; white-space: nowrap;
}
.chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.chip.ok { --c: var(--accent); }
.chip.warn { --c: var(--warn); }
.chip.bad { --c: var(--err); }

.rows { margin-top: var(--s5); border-bottom: 1px solid var(--line); }
.rows li { padding: var(--s3) 0; border-top: 1px solid var(--line); color: var(--muted); }
.rows b { display: flex; align-items: baseline; gap: var(--s1); margin-bottom: 4px; color: var(--ink); font-weight: 600; letter-spacing: -0.01em; }
.rows.warn b::before { content: ""; width: 6px; height: 6px; flex: none; border-radius: 50%; background: var(--warn); transform: translateY(-1px); }
.rows a, .checks a, .vcard a { color: var(--ink); text-underline-offset: 3px; text-decoration-color: var(--line-2); }
.rows a[target="_blank"]::after { content: "\2197"; margin-left: 3px; font-size: 0.85em; }
.rows a:hover, .checks a:hover, .vcard a:hover { text-decoration-color: currentColor; }
code { font: 0.9em var(--mono); }
.foot-note { margin-top: var(--s3); max-width: 60ch; color: var(--muted); }
.foot-note.strong { color: var(--ink); font-weight: 600; }

@media (max-width: 400px) {
  .pill { padding: 0 var(--s2) 0 18px; }
  .pill-icon { display: none; }
}

@media (min-width: 760px) {
  .pill { height: 64px; padding-left: 28px; }
  .pill input { font-size: var(--fs-lg); }
  .search-go { font-size: var(--fs-md); }
  .route-flow { grid-template-columns: repeat(3, 1fr); gap: var(--s6); }
  .route-flow li, .route-flow li:last-child { padding: 68px 0 0; }
  .route-flow li:not(:last-child)::after {
    left: 60px; right: calc(-1 * var(--s6) + 12px); top: 23px; bottom: auto; width: auto; height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent) -100% 0 / 40% 100% no-repeat, var(--line);
  }
  .rows li { display: grid; grid-template-columns: 300px 1fr; gap: var(--s4); }
  .rows b { margin: 0; }
}

/* Motion: one calm entrance, staggered, 300 ms a step. orbit.js and field.js handle reduced motion themselves. */
@media (prefers-reduced-motion: no-preference) {
  @keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
  @keyframes fade { from { opacity: 0; } }
  @keyframes dim { 50% { opacity: 0.35; } }
  @keyframes run-y { to { background-position: 0 200%, 0 0; } }
  @keyframes run-x { to { background-position: 200% 0, 0 0; } }
  /* Scroll reveal: main.js sets .reveal-ready on <html> and adds .is-in as each [data-reveal] enters the view. */
  .reveal-ready [data-reveal] { opacity: 0; transform: translateY(12px); transition: opacity 0.28s var(--ease), transform 0.28s var(--ease); transition-delay: calc(var(--i, 0) * 60ms); }
  .reveal-ready [data-reveal].is-in { opacity: 1; transform: none; }
  .top, .hero-h, .tagline, .search, .under, .hero-links { animation: rise 0.3s var(--ease) both; }
  .top { animation-name: fade; }
  .hero-h { animation-delay: 0.04s; }
  .tagline { animation-delay: 0.08s; }
  .search { animation-delay: 0.12s; }
  .under { animation-delay: 0.16s; }
  .hero-links { animation-delay: 0.2s; }
  /* Not on .orbit itself: an animation there would make it a stacking context and pin every chip behind the text. */
  .orbit-rings { animation: fade 0.3s var(--ease) 0.2s both; }
  .orb-face.is-in { animation: fade 0.3s var(--ease) calc(0.3s + var(--k, 0) * 0.04s) both; }
  .search-row[data-state="loading"] .pill { animation: dim 1.2s ease-in-out infinite; }
  .chip:not(.ok):not(.warn):not(.bad)::before { animation: dim 1.2s ease-in-out infinite; }

  /* The route pulse starts when the strip scrolls into view (main.js adds .is-in). */
  .is-in .route-flow li:not(:last-child)::after { animation: run-y 1.6s ease-out calc(0.4s + var(--i, 0) * 0.4s) 1 both; }
  @media (min-width: 760px) {
    .is-in .route-flow li:not(:last-child)::after { animation-name: run-x; }
  }
}
/* Reduced motion, or no scroll reveal: the connectors are drawn at once and the route pulse rests on its links. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* Theme toggle: the icon shows where a click goes. */
.theme {
  display: grid; place-items: center; width: 36px; height: 36px; margin-left: 4px; padding: 0;
  border: 0; border-radius: 999px; background: transparent; color: var(--muted); cursor: pointer;
  transition: color 0.2s, background-color 0.2s;
}
.theme:hover { color: var(--ink); background: rgba(var(--rl), 0.06); }
.theme svg { width: 18px; height: 18px; }
.theme .i-sun { display: none; }
:root[data-theme="dark"] .theme .i-sun { display: block; }
:root[data-theme="dark"] .theme .i-moon { display: none; }

/* ---------------------------------------------------------------- setup wizard (kit.js)
   One panel: a progress rail, the current step's reason, and only the current step's action.
   Onboarding's own header, dots and the steps that are not current are hidden here. */
.wiz { display: grid; gap: var(--s3); min-width: 0; }
.wiz .head, .wiz .stepper > .step:not(.current) { display: none; }
.wiz .stepper { display: block; }
.wiz .step { display: block; padding: 0; }
.wiz .step::after, .wiz .step .dot, .wiz .step .step-title { display: none; }
.wiz .step-main { padding: 0; }
.wiz .step-body { margin: 0; padding: 0; gap: var(--s2); background: none; border: 0; box-shadow: none; border-radius: 0; animation: none; }
.wiz .step.current .row > .link-btn, .wiz .step.current .row > a.btn { display: none; } /* Shop's Stop checking and Open dashboard: the wizard has its own Pause and links */
.wiz .live > .hint { display: none; }              /* Shop's slow "checking again in" line; the wizard reports its own */
.wiz .status { margin-bottom: 0; background: var(--sunk); box-shadow: none; }
.wiz > .notice { margin: 0; }

.wiz-top { display: grid; gap: 2px; justify-items: start; }
.wiz-host { font-size: clamp(1.25rem, 4.5vw, 1.6rem); font-weight: 650; letter-spacing: -0.03em; line-height: 1.2; overflow-wrap: anywhere; }
.wiz-change { padding: 4px 0; font-size: var(--fs-sm); }

.rail { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.rail-i { display: grid; align-content: start; gap: 6px; min-width: 0; color: var(--muted); }
.rail-bar { height: 3px; border-radius: 2px; background: var(--line); }
.rail-i.done .rail-bar, .rail-i.current .rail-bar { background: var(--accent); }
.rail-l { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 5px; font-size: var(--fs-xs); font-weight: 600; line-height: 1.25; }
.rail-l .icon { width: 12px; height: 12px; stroke-width: 2.6; color: var(--accent); }
.rail-n { font-variant-numeric: tabular-nums; }
.rail-i.current { color: var(--ink); }
.rail-s { display: none; font: var(--fs-xs)/1.3 var(--mono); color: var(--muted); overflow-wrap: anywhere; }
@media (min-width: 640px) {
  .rail { gap: 10px; }
  .rail-l { font-size: var(--fs-sm); }
  .rail-s { display: block; }
}
@media (max-width: 480px) {
  .rail-i:not(.current) .rail-l { font-size: 0.6875rem; }
}

.wiz-now { display: grid; gap: 8px; padding-top: var(--s2); border-top: 1px solid var(--line); }
.wiz-count { font-size: var(--fs-xs); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.wiz-h { font-size: clamp(1.35rem, 1.1rem + 1.4vw, 1.75rem); font-weight: 700; letter-spacing: -0.03em; line-height: 1.15; text-wrap: balance; }
.wiz-h:focus { outline: 0; }
.wiz-why { max-width: 56ch; color: var(--muted); text-wrap: pretty; }
.wiz-why strong { color: var(--ink); font-weight: 600; overflow-wrap: anywhere; }
.wiz-status { display: flex; align-items: center; gap: 8px; min-height: 0; font-size: var(--fs-sm); color: var(--muted); }
.wiz-status:empty { display: none; }
.wiz-status .spin { width: 14px; height: 14px; }
.wiz-status .link-btn { padding: 4px 2px; }
.wiz-now.live .wiz-h::before { content: ""; display: inline-block; width: 8px; height: 8px; margin: 0 10px 3px 0; border-radius: 50%; background: var(--accent); }
.done-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.preview { scroll-margin-top: 24px; }
.preview:focus { outline: 0; }
.preview:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

@media (max-width: 400px) {
  .kit-root { padding: 18px 16px; }
  .done-links .btn { flex: 1 1 calc(50% - 8px); padding: 0 10px; }
}

/* Why we are building it: five short reasons, numbered. */
.reasons { counter-reset: r; }
.reasons li { counter-increment: r; }
.reasons b::before { content: counter(r, decimal-leading-zero); min-width: 22px; color: var(--muted); font: 500 var(--fs-xs) var(--mono); }
.reasons p { max-width: 52ch; }
.view {
  display: inline-block; margin-left: 4px; padding: 1px 8px; border: 1px solid var(--line-2); border-radius: 999px;
  color: var(--muted); font-size: var(--fs-xs); font-weight: 500; line-height: 1.5; white-space: nowrap;
}

/* Rules you can check: the one raised band. Trust, the chain and the source live here. */
.rules { display: grid; gap: var(--s3); padding: clamp(var(--s3), 5vw, var(--s6)); border: 1px solid var(--line-2); border-radius: var(--r-lg); background: var(--surface); box-shadow: var(--shadow); }
.rules-lead { font-size: var(--fs-xl); font-weight: 650; letter-spacing: -0.03em; line-height: 1.2; max-width: 28ch; text-wrap: balance; }
.checks { display: grid; gap: var(--s1); max-width: 62ch; color: var(--muted); }
.checks li { position: relative; padding-left: var(--s3); }
.checks li::before { content: ""; position: absolute; left: 4px; top: 0.7em; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.checks a[target="_blank"]::after { content: "\2197"; margin-left: 3px; font-size: 0.85em; }
.vcard { display: grid; gap: var(--s2); align-content: start; min-width: 0; margin-top: var(--s1); padding: var(--s3); border: 1px solid var(--line); border-radius: var(--r-md); background: var(--sunk); }
.hint { color: var(--muted); font-size: var(--fs-sm); line-height: 1.5; }

/* Try it on a real site */
.try-lead { margin-top: var(--s3); max-width: 40ch; font-size: var(--fs-xl); font-weight: 650; letter-spacing: -0.03em; line-height: 1.2; text-wrap: balance; }
.ticks { margin-top: var(--s3); display: grid; gap: var(--s1); color: var(--muted); }
.ticks li { position: relative; padding-left: var(--s3); }
.ticks li::before { content: ""; position: absolute; left: 4px; top: 0.7em; width: 6px; height: 6px; border-radius: 50%; background: var(--line-2); }
.try .hint { margin-top: var(--s3); }
.try-go { margin-top: var(--s2); display: inline-flex; width: auto; padding: 0 var(--s4); }

/* "Details" under a wizard notice: the raw reply sits below the toggle, not beside it. */
.wiz .more { display: block; margin-top: 6px; color: var(--muted); font-size: 0.875rem; text-align: left; }
.wiz .more summary { width: fit-content; cursor: pointer; }
.wiz .more p { margin-top: 4px; overflow-wrap: anywhere; }
