/* ==========================================================================
   Velosearch design system — "editorial engineering"
   Warm paper, deep ink, vermilion. Fraunces display, Instrument Sans body,
   Spline Sans Mono for data. Hand-rolled, dependency-free CSS.
   ========================================================================== */

:root {
  --paper: #f3efe5;
  --paper-2: #ece6d6;
  --surface: #fbf8f1;
  --line: #ddd5c2;
  --line-strong: #c2b69c;
  --line-ink: #2a261d;

  --ink: #1d1a14;
  --ink-2: #4a443a;
  --muted: #756d5c;
  --faint: #a39a86;

  --fire: #e0440a;
  --fire-deep: #bd3504;
  --fire-soft: #f9e2d2;
  --fire-ink: #1d1a14;

  --coal: #201c14;
  --coal-2: #17140d;
  --cream: #ede5d2;

  --ok: #3e7a3a;
  --ok-soft: #e3edd9;
  --warn: #9c6a10;
  --warn-soft: #f6ecd1;
  --danger: #b3261e;
  --danger-soft: #f6ddd8;

  --radius: 14px;
  --radius-sm: 10px;
  --radius-xs: 8px;

  --shadow-sm: 0 1px 2px rgba(29, 26, 20, 0.07);
  --shadow: 0 8px 28px -12px rgba(29, 26, 20, 0.25);
  --pop: 7px 7px 0 rgba(29, 26, 20, 0.12);
  --pop-hard: 9px 9px 0 var(--ink);

  --display: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --font: 'Instrument Sans', 'Avenir Next', 'Segoe UI', Helvetica, sans-serif;
  --mono: 'Spline Sans Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  --maxw: 1080px;
  --lp-maxw: 1140px;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 76px;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  background-image: radial-gradient(
    1100px 540px at 80% -12%,
    #faf6ea 0%,
    rgba(250, 246, 234, 0) 60%
  );
  background-repeat: no-repeat;
  line-height: 1.55;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2 {
  font-family: var(--display);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 0.4em;
}
h1 {
  font-size: 1.9rem;
}
h2 {
  font-size: 1.35rem;
}
h3 {
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.25;
  margin: 0 0 0.4em;
}
p {
  margin: 0 0 0.8em;
}
a {
  color: var(--fire-deep);
  text-decoration: none;
  font-weight: 550;
}
a:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}
small {
  color: var(--muted);
}
::selection {
  background: var(--fire-soft);
}

code {
  font-family: var(--mono);
  font-size: 0.85em;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 0.12em 0.4em;
  border-radius: 6px;
  color: var(--ink-2);
  word-break: break-all;
}

pre {
  font-family: var(--mono);
  font-size: 0.82rem;
  background: var(--coal-2);
  color: var(--cream);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  overflow: auto;
  line-height: 1.55;
  box-shadow: inset 0 0 0 1px rgba(237, 229, 210, 0.08);
}
pre code {
  background: none;
  border: 0;
  color: inherit;
  padding: 0;
}

/* ---- Brand mark --------------------------------------------------------- */
.logo-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--ink);
  display: grid;
  place-items: center;
  color: var(--paper);
  font-family: var(--display);
  font-style: italic;
  font-weight: 700;
  font-size: 16px;
  box-shadow: inset 0 0 0 1.5px rgba(243, 239, 229, 0.14);
}
.logo-mark--sm {
  width: 22px;
  height: 22px;
  font-size: 13px;
  border-radius: 6px;
}

/* ---- App top bar -------------------------------------------------------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 13px clamp(16px, 4vw, 40px);
  background: rgba(243, 239, 229, 0.88);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar__brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-size: 1.05rem;
}
.topbar__brand:hover {
  text-decoration: none;
}
.topbar__spacer {
  flex: 1;
}
.topbar__nav {
  display: flex;
  gap: 4px;
}
.topbar__nav a {
  color: var(--muted);
  font-weight: 550;
  padding: 6px 11px;
  border-radius: 8px;
  font-size: 0.9rem;
}
.topbar__nav a:hover {
  color: var(--ink);
  background: var(--paper-2);
  text-decoration: none;
}
.topbar__nav a.is-active {
  color: var(--fire-deep);
  background: var(--fire-soft);
}
.topbar__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--muted);
  font-size: 0.85rem;
}
.topbar__meta strong {
  color: var(--ink-2);
  font-weight: 600;
}
.topbar form {
  margin: 0;
}

/* ---- Layout shells ------------------------------------------------------ */
.page {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(20px, 4vw, 40px);
}
.page__head {
  margin-bottom: 22px;
}
.page__head p {
  color: var(--muted);
  margin: 0;
}

.auth-shell {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 32px 20px;
}
.auth-card {
  width: 100%;
  max-width: 408px;
  background: var(--surface);
  border: 1.5px solid var(--line-ink);
  border-radius: 18px;
  box-shadow: var(--pop);
  padding: 32px;
}
.auth-card__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  margin-bottom: 22px;
}
.auth-card h1 {
  font-size: 1.55rem;
}
.auth-card .sub {
  color: var(--muted);
  margin-top: -0.3em;
}
.auth-foot {
  margin: 18px 0 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
}
.auth-foot a {
  font-weight: 600;
}
.auth-links {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  font-size: 0.9rem;
}

/* ---- Cards / sections ---------------------------------------------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 22px 24px;
  margin-bottom: 18px;
}
.card > :last-child {
  margin-bottom: 0;
}
.card__head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 14px;
}
.card__head h2 {
  margin: 0;
}
.card__head .muted {
  margin: 0;
}

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

/* ---- Stat cards ---------------------------------------------------------- */
.stat-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, 1fr);
  margin-bottom: 18px;
}
@media (min-width: 760px) {
  .stat-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px;
}
.stat__label {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.stat__value {
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}
.stat__sub {
  color: var(--faint);
  font-size: 0.82rem;
  margin-top: 2px;
}

/* ---- Ranked list --------------------------------------------------------- */
.ranklist {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.rankrow {
  display: grid;
  grid-template-columns: 1.4rem 1fr auto;
  align-items: center;
  gap: 4px 12px;
}
.rankrow__n {
  color: var(--faint);
  font-size: 0.85rem;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.rankrow__q {
  font-weight: 550;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.rankrow__count {
  color: var(--muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}
.rankrow__bar {
  grid-column: 2 / 4;
  height: 6px;
  border-radius: 999px;
  background: var(--fire-soft);
  overflow: hidden;
}
.rankrow__bar > span {
  display: block;
  height: 100%;
  background: var(--fire);
  border-radius: 999px;
}

/* ---- Period selector ------------------------------------------------------ */
.period-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.period-bar__label {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.segmented {
  display: inline-flex;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 3px;
  box-shadow: var(--shadow-sm);
}
.segmented a {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 5px 13px;
  border-radius: 999px;
}
.segmented a:hover {
  color: var(--ink);
  text-decoration: none;
}
.segmented a.is-active {
  color: var(--paper);
  background: var(--ink);
}

/* ---- Store selector ------------------------------------------------------- */
.store-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.store-bar__label {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.store-bar__form select {
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 6px 14px;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

/* ---- Data tables ---------------------------------------------------------- */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.data-table th {
  text-align: left;
  color: var(--muted);
  font-family: var(--mono);
  font-weight: 600;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0 10px 10px;
  border-bottom: 1px solid var(--line-strong);
}
.data-table td {
  padding: 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.data-table tr:last-child td {
  border-bottom: 0;
}
.data-table .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.data-table tbody tr:hover {
  background: var(--paper);
}

.muted {
  color: var(--muted);
}
.stack > * + * {
  margin-top: 12px;
}

/* ---- Forms ----------------------------------------------------------------- */
form {
  margin: 0;
}
.field {
  display: block;
  margin-bottom: 14px;
}
.field > label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 6px;
}

input[type='text'],
input[type='email'],
input[type='password'],
input[type='url'],
input[type='number'],
input[type='search'],
textarea,
select {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-xs);
  padding: 10px 12px;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
  appearance: none;
}
input::placeholder,
textarea::placeholder {
  color: var(--faint);
}
input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--fire);
  box-shadow: 0 0 0 4px var(--fire-soft);
}

/* Buttons — covers form.submit (input[type=submit]) and button_to (button) */
button,
input[type='submit'],
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-xs);
  padding: 10px 16px;
  background: var(--ink);
  color: var(--paper);
  box-shadow: var(--shadow-sm);
  transition:
    transform 0.12s ease,
    box-shadow 0.12s ease,
    background 0.15s,
    color 0.15s;
  text-decoration: none;
}
button:hover,
input[type='submit']:hover,
.btn:hover {
  background: #322d23;
  text-decoration: none;
}
button:active,
input[type='submit']:active,
.btn:active {
  transform: translateY(1px);
}
input[type='submit'] {
  width: 100%;
}

.btn--block {
  width: 100%;
}
.btn--secondary,
button.btn--secondary {
  background: var(--surface);
  color: var(--ink-2);
  border-color: var(--line-strong);
}
.btn--secondary:hover {
  background: var(--paper-2);
  color: var(--ink);
}
.btn--danger,
button.btn--danger {
  background: var(--danger);
  border-color: var(--danger);
}
.btn--danger:hover {
  background: #9a1f18;
}
.btn--ghost,
button.btn--ghost {
  background: transparent;
  color: var(--fire-deep);
  box-shadow: none;
  border-color: transparent;
  padding-inline: 4px;
}

/* ---- Badges ------------------------------------------------------------------ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--muted);
  border: 1px solid var(--line);
}
.badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.badge--active {
  background: var(--ok-soft);
  color: var(--ok);
  border-color: transparent;
}
.badge--pending {
  background: var(--warn-soft);
  color: var(--warn);
  border-color: transparent;
}

/* ---- Flash --------------------------------------------------------------------- */
.flash-stack {
  max-width: var(--maxw);
  margin: 16px auto -4px;
  padding: 0 clamp(20px, 4vw, 40px);
}
.auth-shell .flash-stack {
  max-width: 408px;
  margin: 0 auto 14px;
  padding: 0;
}
.flash {
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-size: 0.9rem;
  font-weight: 500;
  border: 1px solid transparent;
  margin-bottom: 10px;
}
.flash--notice {
  background: var(--ok-soft);
  color: #2c5f29;
  border-color: #c4d8b4;
}
.flash--alert {
  background: var(--danger-soft);
  color: #8e1d16;
  border-color: #e7bcb4;
}

/* ---- Definition rows --------------------------------------------------------- */
.kv {
  display: grid;
  grid-template-columns: minmax(120px, max-content) 1fr;
  gap: 6px 16px;
  margin: 0;
}
.kv dt {
  color: var(--muted);
  font-size: 0.85rem;
}
.kv dd {
  margin: 0;
  color: var(--ink-2);
}

/* ---- Callout (one-time secrets) ----------------------------------------------- */
.callout {
  border: 1.5px solid var(--fire);
  background: linear-gradient(180deg, #fbeee2, var(--surface));
  border-radius: var(--radius);
  padding: 20px 22px;
  margin-bottom: 18px;
  box-shadow: var(--pop);
}
.callout h2 {
  color: var(--fire-deep);
}
.callout .kv dd code {
  width: 100%;
  display: inline-block;
}

/* ---- Integration list ----------------------------------------------------------- */
.conn {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  background: var(--paper);
}
.conn + .conn {
  margin-top: 10px;
}
.conn__id {
  font-weight: 650;
}
.conn__meta {
  color: var(--muted);
  font-size: 0.85rem;
}
.conn__spacer {
  flex: 1;
}

.empty {
  text-align: center;
  color: var(--muted);
  padding: 22px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm);
}

ul.clean {
  margin: 0;
  padding-left: 1.1em;
}
ul.clean li {
  margin-bottom: 4px;
}

.errors {
  background: var(--danger-soft);
  border: 1px solid #e7bcb4;
  color: #8e1d16;
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-bottom: 16px;
}
.errors p {
  font-weight: 600;
  margin: 0 0 6px;
}
.errors ul {
  margin: 0;
  padding-left: 1.1em;
}

.toolbar {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  flex-wrap: wrap;
}
.toolbar .field {
  margin-bottom: 0;
}
.field--grow {
  flex: 1;
  min-width: 220px;
}
.field--narrow {
  width: 140px;
}

/* ==========================================================================
   Landing / marketing pages
   ========================================================================== */

.landing {
  overflow-x: clip;
}
.landing main > section {
  max-width: var(--lp-maxw);
  margin: 0 auto clamp(72px, 10vh, 116px);
  padding: 0 clamp(20px, 4.5vw, 48px);
}

.eyebrow {
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fire-deep);
  margin: 0 0 14px;
}
.eyebrow::before {
  content: '— ';
  color: var(--faint);
}
.eyebrow--dark {
  color: #f0824d;
}
.eyebrow--dark::before {
  color: rgba(237, 229, 210, 0.4);
}

.soon {
  display: inline-block;
  margin-left: 10px;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--fire-soft);
  color: var(--fire-deep);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  vertical-align: middle;
}

.section-head {
  margin-bottom: clamp(26px, 4vw, 40px);
}
.section-head h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
  max-width: 18em;
  margin-bottom: 0;
}
.section-sub {
  color: var(--muted);
  font-size: 1.04rem;
  max-width: 42em;
  margin: 12px 0 0;
}

/* Landing nav — full-bleed sticky bar */
.lp-nav {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(243, 239, 229, 0.92);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.lp-nav__inner {
  display: flex;
  align-items: center;
  gap: 22px;
  max-width: var(--lp-maxw);
  margin: 0 auto;
  padding: 14px clamp(20px, 4.5vw, 48px);
}
.lp-nav__brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-size: 1.1rem;
}
.lp-nav__brand:hover {
  text-decoration: none;
}
.lp-nav__links {
  display: flex;
  gap: 4px;
}
.lp-nav__links a {
  color: var(--ink-2);
  font-weight: 550;
  font-size: 0.92rem;
  padding: 6px 11px;
  border-radius: 8px;
}
.lp-nav__links a:hover {
  color: var(--ink);
  background: var(--paper-2);
  text-decoration: none;
}
.lp-nav__spacer {
  flex: 1;
}
.lp-nav__signin {
  color: var(--ink);
  font-weight: 600;
  font-size: 0.92rem;
}
.lp-nav .btn {
  padding: 8px 15px;
  font-size: 0.92rem;
}
@media (max-width: 860px) {
  .lp-nav__links,
  .lp-nav__signin {
    display: none;
  }
}

/* Landing buttons */
.btn--ink {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.btn--fire {
  background: var(--fire);
  color: #fff;
  border-color: var(--ink);
}
.btn--fire:hover {
  background: var(--fire);
  transform: translate(-2px, -2px);
  box-shadow: 4px 4px 0 var(--ink);
}
.btn--fire:active {
  transform: none;
  box-shadow: var(--shadow-sm);
}
.btn--paper {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
  box-shadow: none;
}
.btn--paper:hover {
  background: var(--ink);
  color: var(--paper);
}
.btn--big {
  padding: 14px 24px;
  font-size: 1.02rem;
  border-radius: 12px;
}

/* Hero */
.landing .hero {
  display: grid;
  align-items: center;
  gap: clamp(36px, 5vw, 64px);
  padding-top: clamp(36px, 6vh, 72px);
  margin-bottom: clamp(44px, 7vh, 80px);
}
@media (min-width: 920px) {
  .landing .hero {
    grid-template-columns: 1.04fr 0.96fr;
  }
}

.hero__title {
  font-size: clamp(2.5rem, 5.6vw, 4.1rem);
  font-weight: 560;
  line-height: 1.04;
  letter-spacing: -0.022em;
  margin-bottom: 0.35em;
}
.hero__title em {
  font-style: italic;
  font-weight: 620;
  color: var(--fire-deep);
  font-variation-settings: 'SOFT' 30;
}
.hero__sub {
  color: var(--ink-2);
  font-size: 1.12rem;
  line-height: 1.6;
  max-width: 34em;
  margin-bottom: 1.6em;
}
.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}
.hero__note {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--muted);
  letter-spacing: 0.02em;
  margin: 0;
  max-width: 40em;
}

/* Entrance animation */
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.reveal {
  animation: rise 0.7s cubic-bezier(0.2, 0.7, 0.25, 1) both;
}
.hero__copy > .reveal:nth-child(1),
.page-hero > .reveal:nth-child(1) {
  animation-delay: 0.05s;
}
.hero__copy > .reveal:nth-child(2),
.page-hero > .reveal:nth-child(2) {
  animation-delay: 0.12s;
}
.hero__copy > .reveal:nth-child(3),
.page-hero > .reveal:nth-child(3) {
  animation-delay: 0.22s;
}
.hero__copy > .reveal:nth-child(4),
.page-hero > .reveal:nth-child(4) {
  animation-delay: 0.32s;
}
.hero__copy > .reveal:nth-child(5) {
  animation-delay: 0.42s;
}
.hero__demo.reveal {
  animation-delay: 0.3s;
}

/* Scroll-driven reveals where supported (progressive enhancement) */
@supports (animation-timeline: view()) {
  .feature,
  .plat,
  .splitrow,
  .panel,
  .faq__item {
    animation: rise 0.8s both;
    animation-timeline: view();
    animation-range: entry 0% entry 35%;
  }
}

/* Search demo card */
.demo {
  background: var(--surface);
  border: 1.5px solid var(--ink);
  border-radius: 16px;
  box-shadow: var(--pop-hard);
  transform: rotate(-1.2deg);
  transition: transform 0.35s cubic-bezier(0.2, 0.7, 0.25, 1);
  overflow: hidden;
}
.demo:hover {
  transform: rotate(0deg);
}

.demo__chrome {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.demo__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--line-strong);
}
.demo__dot:first-child {
  background: var(--fire);
}
.demo__url {
  margin-left: 8px;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--faint);
  letter-spacing: 0.03em;
}

.demo__input {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}
.demo__query {
  font-family: var(--mono);
  font-size: 1.06rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  display: inline-block;
  animation: demo-type 9s steps(12, end) infinite;
}
@keyframes demo-type {
  0%,
  5% {
    width: 0;
  }
  30% {
    width: 12ch;
  }
  100% {
    width: 12ch;
  }
}
.demo__caret {
  width: 2px;
  height: 1.15em;
  background: var(--fire);
  animation: demo-caret 1s steps(1) infinite;
}
@keyframes demo-caret {
  50% {
    opacity: 0;
  }
}

.demo__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 20px;
  animation: demo-pop-1 9s ease infinite;
}
.demo__count {
  font-family: var(--mono);
  font-size: 0.76rem;
  color: var(--muted);
}
.demo__fix {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--fire-deep);
  background: var(--fire-soft);
  border-radius: 999px;
  padding: 3px 10px;
}
.demo__results {
  padding: 2px 8px 10px;
  animation: demo-pop-2 9s ease infinite;
}
.demo__hit {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
}
.demo__hit:hover {
  background: var(--paper);
}
.demo__thumb {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  font-size: 19px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 9px;
}
.demo__hit-name {
  font-weight: 550;
  font-size: 0.94rem;
}
.demo__hit-name mark {
  background: var(--fire-soft);
  color: inherit;
  padding: 0 2px;
  border-radius: 3px;
  box-shadow: inset 0 -2px 0 var(--fire);
}
.demo__hit-price {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--ink-2);
}

@keyframes demo-pop-1 {
  0%,
  31% {
    opacity: 0;
    transform: translateY(6px);
  }
  37%,
  100% {
    opacity: 1;
    transform: none;
  }
}
@keyframes demo-pop-2 {
  0%,
  35% {
    opacity: 0;
    transform: translateY(8px);
  }
  43%,
  100% {
    opacity: 1;
    transform: none;
  }
}

/* Ticker — two identical groups, each with trailing gap, slide one group width */
.ticker {
  border-top: 1.5px solid var(--ink);
  border-bottom: 1.5px solid var(--ink);
  background: var(--paper-2);
  overflow: hidden;
  padding: 11px 0;
  margin: 0 0 clamp(72px, 10vh, 116px);
}
.ticker__track {
  display: flex;
  width: max-content;
  animation: ticker 36s linear infinite;
}
.ticker__group {
  display: flex;
  align-items: center;
  gap: 30px;
  padding-right: 30px;
  white-space: nowrap;
  font-family: var(--mono);
  font-size: 0.76rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-2);
}
.ticker__group span:nth-child(even) {
  color: var(--fire);
  font-size: 0.6rem;
}
@keyframes ticker {
  to {
    transform: translateX(-50%);
  }
}

/* Steps */
.steps__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: clamp(24px, 3.5vw, 40px);
}
@media (min-width: 760px) {
  .steps__list {
    grid-template-columns: repeat(3, 1fr);
  }
}
.steps__list li {
  border-top: 1.5px solid var(--ink);
  padding-top: 18px;
}
.steps__n {
  display: block;
  font-family: var(--display);
  font-style: italic;
  font-size: 2.6rem;
  line-height: 1;
  color: var(--fire);
  margin-bottom: 14px;
}
.steps__list h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.3rem;
  letter-spacing: -0.01em;
}
.steps__list p {
  color: var(--ink-2);
  margin: 0;
}

/* Features */
.features__grid {
  display: grid;
  gap: clamp(26px, 3.5vw, 44px) clamp(32px, 5vw, 72px);
}
@media (min-width: 760px) {
  .features__grid {
    grid-template-columns: 1fr 1fr;
  }
}
.feature {
  border-top: 1px solid var(--line-strong);
  padding-top: 16px;
}
.feature__n {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--fire-deep);
  letter-spacing: 0.1em;
}
.feature h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.28rem;
  letter-spacing: -0.01em;
  margin: 0 0 6px;
}
.feature p {
  color: var(--ink-2);
  margin: 0;
}
.feature em {
  font-style: italic;
  color: var(--ink);
}

.feature__demo {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 14px;
  margin: 12px 0 14px;
  background: var(--paper-2);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm);
  transition:
    border-color 0.25s,
    background 0.25s;
}
.feature:hover .feature__demo {
  border-color: var(--fire);
  background: var(--surface);
}

.fchip {
  font-family: var(--mono);
  font-size: 0.73rem;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  color: var(--ink-2);
  white-space: nowrap;
}
.fchip--strike {
  text-decoration: line-through;
  color: var(--faint);
}
.fchip--ok {
  background: var(--ok-soft);
  border-color: transparent;
  color: var(--ok);
  font-weight: 600;
}
.fchip--pin {
  background: var(--fire-soft);
  border-color: var(--fire);
  color: var(--fire-deep);
  font-weight: 600;
}
.fchip--dim {
  color: var(--faint);
}
.fchip-arrow {
  color: var(--fire);
  font-weight: 600;
}

.feature__demo--bars {
  align-items: flex-end;
  height: 88px;
  gap: 7px;
}
.feature__demo--bars > span {
  display: block;
  width: 20px;
  height: var(--h);
  background: var(--fire);
  border-radius: 4px 4px 0 0;
}
.feature__demo--bars > span:nth-child(2) {
  opacity: 0.7;
}
.feature__demo--bars > span:nth-child(3) {
  opacity: 0.45;
}
.feature__demo--bars > span:nth-child(4) {
  opacity: 0.25;
}
.feature__demo--bars em {
  font-family: var(--mono);
  font-style: normal;
  font-size: 0.68rem;
  color: var(--muted);
  margin-left: auto;
  align-self: center;
}

/* Panels (AI search, recommendations, developers) */
.panelwrap {
  padding: 0 clamp(20px, 4.5vw, 48px);
}
.panel {
  display: grid;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
  border: 1.5px solid var(--ink);
  border-radius: 22px;
  background: var(--surface);
  padding: clamp(28px, 4.5vw, 52px);
  box-shadow: var(--pop);
}
@media (min-width: 920px) {
  .panel {
    grid-template-columns: 1fr 1fr;
  }
  .panel--reverse .panel__copy {
    order: 2;
  }
}
.panel--tint {
  background: var(--paper-2);
}
.panel h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.4rem);
}
.panel__copy p {
  color: var(--ink-2);
  line-height: 1.65;
}
.panel__link {
  font-weight: 600;
}

/* Chat demo (AI search) */
.chat {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--surface);
  border: 1.5px solid var(--ink);
  border-radius: 16px;
  padding: 18px;
  box-shadow: var(--pop);
}
.chat__bubble {
  max-width: 92%;
  align-self: flex-start;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: 14px 14px 14px 4px;
  padding: 10px 14px;
  font-size: 0.92rem;
}
.chat__bubble--user {
  align-self: flex-end;
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
  border-radius: 14px 14px 4px 14px;
  font-family: var(--mono);
  font-size: 0.82rem;
}
.chat__parsed {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 2px 0;
}

/* Recommendations demo */
.reco {
  background: var(--paper);
  border: 1.5px solid var(--ink);
  border-radius: 16px;
  padding: 18px;
  box-shadow: var(--pop);
}
.reco__label {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--muted);
  margin: 0 0 12px;
}
.reco__row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.ptile {
  display: flex;
  flex-direction: column;
  gap: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 10px;
  background: var(--surface);
  transition:
    transform 0.2s,
    border-color 0.2s;
}
.ptile:hover {
  transform: translateY(-2px);
  border-color: var(--ink);
}
.ptile__img {
  font-size: 26px;
  height: 48px;
  display: grid;
  place-items: center;
  background: var(--paper-2);
  border-radius: 8px;
}
.ptile__name {
  font-weight: 600;
  font-size: 0.8rem;
  line-height: 1.2;
}
.ptile__price {
  font-family: var(--mono);
  font-size: 0.76rem;
  color: var(--muted);
}

/* Platforms */
.platforms__grid {
  display: grid;
  gap: 18px;
}
@media (min-width: 760px) {
  .platforms__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.plat {
  border: 1.5px solid var(--line-ink);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 22px;
  transition:
    transform 0.25s,
    box-shadow 0.25s;
}
.plat:hover {
  transform: translateY(-3px);
  box-shadow: var(--pop);
}
.plat__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.plat h3 {
  font-family: var(--display);
  font-size: 1.25rem;
  margin: 0;
}
.plat p {
  color: var(--ink-2);
}
.plat a {
  font-weight: 600;
}

/* Developer panel */
.devpanel {
  background: var(--coal);
  color: var(--cream);
  border-radius: 22px;
  padding: clamp(32px, 5vw, 60px);
  display: grid;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
  box-shadow: var(--pop-hard);
}
@media (min-width: 920px) {
  .devpanel {
    grid-template-columns: 0.9fr 1.1fr;
  }
}
.devpanel h2 {
  color: #faf6ec;
  font-size: clamp(1.8rem, 3.2vw, 2.5rem);
}
.devpanel__copy p {
  color: rgba(237, 229, 210, 0.78);
  line-height: 1.65;
  margin-bottom: 1.5em;
}
.devpanel__code {
  min-width: 0;
}
.devpanel__code pre {
  margin: 0;
  background: var(--coal-2);
  border-radius: 14px;
  padding: 20px 22px;
  font-size: 0.78rem;
  box-shadow: inset 0 0 0 1px rgba(237, 229, 210, 0.1);
}
.tok-c {
  color: #877c64;
}
.tok-s {
  color: #dfa45c;
}
.tok-k {
  color: #e8dfc8;
}
.tok-n {
  color: #f0824d;
}

/* Pricing */
.pricing__grid {
  display: grid;
  gap: 18px;
  align-items: start;
}
@media (min-width: 860px) {
  .pricing__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.price-card {
  position: relative;
  border: 1.5px solid var(--line-ink);
  border-radius: 18px;
  background: var(--surface);
  padding: 26px;
}
.price-card h3 {
  font-family: var(--display);
  font-size: 1.3rem;
  margin: 0 0 2px;
}
.price-card__price {
  font-family: var(--display);
  font-size: 2.6rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0;
  line-height: 1.1;
}
.price-card__price span {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 400;
  letter-spacing: 0;
}
.price-card__for {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 6px 0 18px;
}
.price-card ul {
  list-style: none;
  margin: 0 0 22px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.92rem;
  color: var(--ink-2);
}
.price-card li::before {
  content: '—  ';
  color: var(--fire);
}
.price-card--featured {
  border-color: var(--ink);
  background: var(--paper-2);
  box-shadow: var(--pop-hard);
}
@media (min-width: 860px) {
  .price-card--featured {
    transform: translateY(-10px);
  }
}
.price-card__flag {
  position: absolute;
  top: -13px;
  right: 20px;
  font-family: var(--mono);
  font-size: 0.64rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: var(--fire);
  color: #fff;
  border: 1.5px solid var(--ink);
  padding: 3px 10px;
  border-radius: 999px;
}

/* FAQ */
.landing .faq {
  max-width: 880px;
}
.faq__item {
  border-top: 1px solid var(--line-strong);
}
.faq__item:last-of-type {
  border-bottom: 1px solid var(--line-strong);
}
.faq__item summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  font-family: var(--display);
  font-size: 1.12rem;
  font-weight: 600;
}
.faq__item summary::-webkit-details-marker {
  display: none;
}
.faq__item summary::after {
  content: '+';
  font-family: var(--mono);
  color: var(--fire);
  font-size: 1.3rem;
  transition: transform 0.2s;
  flex-shrink: 0;
}
.faq__item[open] summary::after {
  transform: rotate(45deg);
}
.faq__item p {
  color: var(--ink-2);
  margin: 0 0 18px;
  max-width: 56em;
}

/* Subpage hero */
.landing .page-hero {
  max-width: 940px;
  padding-top: clamp(36px, 6vh, 72px);
  margin-bottom: clamp(52px, 8vh, 90px);
}
.page-hero__title {
  font-size: clamp(2.2rem, 4.6vw, 3.4rem);
  line-height: 1.06;
  letter-spacing: -0.02em;
  margin-bottom: 0.35em;
}
.page-hero__title em {
  font-style: italic;
  color: var(--fire-deep);
  font-variation-settings: 'SOFT' 30;
}
.page-hero__sub {
  color: var(--ink-2);
  font-size: 1.12rem;
  line-height: 1.6;
  max-width: 38em;
  margin-bottom: 1.6em;
}

/* Split rows (subpages) */
.splitrow {
  display: grid;
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}
@media (min-width: 920px) {
  .splitrow {
    grid-template-columns: 1fr 1fr;
  }
  .splitrow--reverse .splitrow__copy {
    order: 2;
  }
}
.splitrow h2 {
  font-size: clamp(1.7rem, 3vw, 2.3rem);
}
.splitrow__copy p {
  color: var(--ink-2);
  line-height: 1.65;
}

/* Prose section */
.prose__cols {
  display: grid;
  gap: 24px;
}
@media (min-width: 860px) {
  .prose__cols {
    grid-template-columns: 1fr 1fr;
    gap: clamp(32px, 5vw, 64px);
  }
}
.prose__cols p {
  color: var(--ink-2);
  font-size: 1.04rem;
  line-height: 1.7;
  margin: 0;
}

/* CTA band */
.cta-band {
  text-align: center;
}
.cta-band h2 {
  font-size: clamp(2.3rem, 5vw, 3.5rem);
  letter-spacing: -0.02em;
  margin-bottom: 0.3em;
}
.cta-band h2 em {
  font-style: italic;
  color: var(--fire-deep);
}
.cta-band p {
  color: var(--muted);
  font-size: 1.05rem;
  margin-bottom: 2em;
}
.cta-band__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
}

/* Landing footer */
.lp-foot {
  border-top: 1.5px solid var(--ink);
  background: var(--paper-2);
}
.lp-foot__inner {
  max-width: var(--lp-maxw);
  margin: 0 auto;
  padding: clamp(28px, 4vw, 48px) clamp(20px, 4.5vw, 48px);
  display: grid;
  gap: 28px;
}
@media (min-width: 760px) {
  .lp-foot__inner {
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
  }
}
.lp-foot__brand > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}
.lp-foot__fine {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 8px 0 0;
  max-width: 24em;
}
.lp-foot__col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.9rem;
}
.lp-foot__col h4 {
  margin: 0 0 4px;
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}
.lp-foot__col a {
  color: var(--ink-2);
  font-weight: 500;
}

/* Reduced motion: show everything, skip theatrics */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .reveal,
  .demo__query,
  .demo__caret,
  .demo__meta,
  .demo__results,
  .ticker__track,
  .feature,
  .plat,
  .splitrow,
  .panel,
  .faq__item {
    animation: none;
  }
  .demo {
    transform: none;
  }
}
