/* Selltix landing - shared by every page of selltix.io. */
:root {
  --bg: #171717;
  --surface: #1f1f1f;
  --surface-2: #262626;
  --border: #2f2f2f;
  --border-strong: #404040;
  --text: #f5f5f5;
  --muted: #a3a3a3;
  --faint: #737373;
  --accent: #3b82f6;
  --accent-soft: rgba(59, 130, 246, 0.12);
  --green: #22c55e;
  --pink: #f472b6;
  --violet: #a78bfa;
  --radius: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* ---- Header ---- */

header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(23, 23, 23, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.bar { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }

.mark {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--green));
}

.wordmark { font-size: 18px; font-weight: 700; letter-spacing: -0.01em; }
.wordmark span { color: var(--accent); }

nav { display: flex; align-items: center; gap: 24px; font-size: 14px; }
nav a { color: var(--muted); text-decoration: none; }
nav a:hover { color: var(--text); }

.lang { display: flex; padding: 2px; gap: 2px; border: 1px solid var(--border-strong); border-radius: 8px; }
.lang button {
  min-width: 34px;
  height: 28px;
  padding: 0 6px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
}
.lang button:hover { color: var(--text); }
.lang button[aria-checked="true"] { background: var(--surface-2); color: var(--text); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 20px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #2563eb; }
.btn-ghost { border-color: var(--border-strong); color: var(--text); background: var(--surface); }
.btn-ghost:hover { border-color: #595959; }
.btn-sm { height: 36px; padding: 0 14px; font-size: 14px; }

/* ---- Hero ---- */

.hero { padding: 88px 0 72px; position: relative; overflow: hidden; }

.hero::before {
  content: '';
  position: absolute;
  inset: -40% -10% auto;
  height: 620px;
  background:
    radial-gradient(closest-side at 30% 50%, rgba(59, 130, 246, 0.18), transparent),
    radial-gradient(closest-side at 75% 40%, rgba(34, 197, 94, 0.10), transparent);
  pointer-events: none;
}

.hero-grid { position: relative; display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items: center; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(96, 165, 250, 0.35);
  background: var(--accent-soft);
  color: #93c5fd;
  font-size: 13px;
  font-weight: 600;
}

.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2); }

h1 {
  margin: 20px 0 16px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 800;
}

h1 em {
  font-style: normal;
  background: linear-gradient(90deg, #60a5fa, #34d399);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead { margin: 0 0 28px; font-size: 18px; color: var(--muted); max-width: 540px; }

.cta { display: flex; gap: 12px; flex-wrap: wrap; }

.facts { display: flex; gap: 28px; margin-top: 36px; flex-wrap: wrap; }
.fact b { display: block; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.fact span { font-size: 13px; color: var(--faint); }

/* A card that looks like one signal in the app. */
.signal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}

.signal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.coin { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; }
.coin-icon { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(135deg, #f59e0b, #ef4444); }
.badge { font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 6px; color: #86efac; background: rgba(34, 197, 94, 0.14); letter-spacing: 0.04em; }

.legs { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; font-size: 12px; font-weight: 700; }
.leg { padding: 5px 10px; border-radius: 8px; border: 1px solid; }
.leg-buy { color: #93c5fd; border-color: rgba(96, 165, 250, 0.5); }
.leg-sell { color: #fcd34d; border-color: rgba(245, 158, 11, 0.5); }
.leg-arrow { color: var(--faint); }

.chart { width: 100%; height: 150px; display: block; }

.legend { display: flex; gap: 16px; margin-top: 10px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 16px; }
.stat { background: var(--surface-2); border-radius: 10px; padding: 10px 12px; }
.stat span { display: block; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.05em; }
.stat b { font-size: 16px; font-variant-numeric: tabular-nums; }

/* ---- Sections ---- */

section { padding: 72px 0; border-top: 1px solid var(--border); }

.section-title { margin: 0 0 12px; font-size: clamp(26px, 3.2vw, 36px); letter-spacing: -0.02em; line-height: 1.15; }
.section-lead { margin: 0 0 40px; color: var(--muted); font-size: 17px; max-width: 640px; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.card h3 { margin: 14px 0 8px; font-size: 18px; letter-spacing: -0.01em; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }

.icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: #93c5fd;
}

.icon svg { width: 22px; height: 22px; }

/* ---- How it works: steps on the left, a pinned illustration on the right that follows the step in view ---- */

.how { margin-bottom: 16px; }
.how-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.how-step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.how-num {
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  font-weight: 700;
  color: #93c5fd;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--accent-soft);
}
.how-text h3 { margin: 14px 0 8px; font-size: 24px; letter-spacing: -0.02em; }
.how-text p { margin: 0; color: var(--muted); font-size: 16px; }
.how-points { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 6px; font-size: 14px; color: #d4d4d4; }
.how-points li { display: flex; gap: 10px; align-items: baseline; }
.how-points li::before { content: '✓'; color: var(--green); font-weight: 700; }
.how-visual { margin-top: 20px; }
.how-stage { display: none; }

/* Desktop with JS: the steps scroll by, the illustration stays pinned and switches. */
@media (min-width: 901px) {
  .js .how { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 56px; align-items: start; }
  .js .how-steps { gap: 0; }
  .js .how-step {
    min-height: 56vh;
    display: flex;
    align-items: center;
    background: none;
    border: none;
    border-radius: 0;
    padding: 0 0 0 28px;
    position: relative;
    opacity: 0.38;
    transition: opacity 0.35s;
    cursor: default;
  }
  .js .how-step::before {
    content: '';
    position: absolute;
    left: 0;
    top: 12%;
    bottom: 12%;
    width: 2px;
    border-radius: 2px;
    background: var(--border-strong);
    transition: background 0.35s;
  }
  .js .how-step.is-active { opacity: 1; }
  .js .how-step.is-active::before { background: linear-gradient(180deg, var(--accent), var(--green)); }
  .js .how-step .how-visual { display: none; }
  .js .how-stage {
    display: block;
    position: sticky;
    top: calc(50vh - 250px);
    height: 500px;
  }
  .how-progress { display: flex; gap: 6px; margin-bottom: 14px; }
  .how-progress i { flex: 1; height: 3px; border-radius: 3px; background: var(--border-strong); transition: background 0.35s; }
  .how-progress i.on { background: linear-gradient(90deg, var(--accent), var(--green)); }
  .how-stage .how-visual {
    position: absolute;
    inset: 17px 0 auto 0;
    margin: 0;
    opacity: 0;
    transform: translateY(14px) scale(0.985);
    transition: opacity 0.4s, transform 0.4s;
    pointer-events: none;
  }
  .how-stage .how-visual.is-shown { opacity: 1; transform: none; }
}

/* The illustrations - the same look as a signal card in the app. */
.viz {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}
.viz-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.viz-chart { width: 100%; height: 170px; display: block; overflow: visible; }
.viz-axis { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 8px; font-size: 12px; }
.viz-foot { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); font-size: 13px; color: var(--muted); }
.violet { color: var(--violet); }
.pink { color: var(--pink); }
.green { color: #4ade80; }
.red { color: #f87171; }
.badge-pulse { animation: badge 1.6s ease-in-out infinite; }
.badge-done { color: #93c5fd; background: var(--accent-soft); }
@keyframes badge { 50% { box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.15); } }

.quotes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.quote {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--surface-2);
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}
.quote b { color: var(--text); font-variant-numeric: tabular-nums; }
.quote small { margin-left: auto; color: var(--faint); }
.q-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); flex-shrink: 0; }

.orders { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.order { background: var(--surface-2); border-radius: 12px; padding: 14px; }
.order-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.side { font-size: 11px; font-weight: 800; letter-spacing: 0.06em; padding: 3px 8px; border-radius: 6px; }
.side.long { color: #86efac; background: rgba(34, 197, 94, 0.14); }
.side.short { color: #fca5a5; background: rgba(239, 68, 68, 0.14); }
.ex { font-size: 12px; font-weight: 700; color: var(--muted); }
.order-row { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; color: var(--muted); padding: 3px 0; }
.order-row b { color: var(--text); font-variant-numeric: tabular-nums; }
.order-status { display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 12px; font-weight: 600; color: #86efac; }
.tick { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; color: #fff; background: var(--green); }

.hedge { margin-top: 14px; display: grid; gap: 8px; }
.hedge-row, .hedge-legend { display: grid; grid-template-columns: 92px 1fr 1fr; gap: 10px; align-items: center; font-size: 12px; color: var(--muted); }
.hedge-legend { color: var(--faint); font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; }
.hbar { height: 8px; border-radius: 8px; background: var(--surface-2); overflow: hidden; }
.hbar i { display: block; height: 100%; width: 70%; border-radius: 8px; }
.hbar i.plus { background: #22c55e; }
.hbar i.minus { background: #ef4444; }

/* Animations play each time an illustration is shown (.is-shown). */
.draw { stroke-dasharray: 1; stroke-dashoffset: 0; }
.is-shown .draw { animation: draw 1.3s ease-out both; }
.is-shown .draw-late { animation-delay: 0.25s; }
.pop, .ring { transform-box: fill-box; transform-origin: center; }
.is-shown .pop { animation: pop 0.35s 1.05s ease-out both; }
.is-shown .ring { animation: ring 1.8s 1.2s ease-out infinite both; }
.is-shown .fade { animation: fade 0.5s 1.05s both; }
.is-shown .order { animation: rise 0.45s ease-out both; }
.is-shown .order + .order { animation-delay: 0.08s; }
.is-shown .tick { animation: pop 0.3s 0.55s ease-out both; }
.is-shown .hbar i { animation: grow 0.8s 0.5s ease-out both; }
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes pop { from { transform: scale(0); } 70% { transform: scale(1.3); } to { transform: scale(1); } }
@keyframes ring { from { transform: scale(1); opacity: 0.9; } to { transform: scale(3); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@keyframes grow { from { width: 0; } }
@media (prefers-reduced-motion: reduce) {
  .is-shown .draw, .is-shown .pop, .is-shown .ring, .is-shown .fade, .is-shown .order, .is-shown .tick, .is-shown .hbar i, .badge-pulse { animation: none; }
  .how-stage .how-visual { transition: none; }
}

.lines { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.line-card h3 { display: flex; align-items: center; gap: 10px; margin-top: 0; }
.line-card h3 i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.formula {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--surface-2);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  color: #d4d4d4;
  overflow-x: auto;
}

.exchanges { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 8px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 14px;
  font-weight: 600;
  color: #d4d4d4;
}
.chip small { color: var(--faint); font-weight: 500; margin-left: -4px; }
.chip img, .chip .letter { width: 22px; height: 22px; border-radius: 6px; flex-shrink: 0; }
.chip .letter { display: grid; place-items: center; font-size: 12px; font-weight: 800; color: #fff; background: var(--border-strong); }

.final {
  text-align: center;
  background:
    radial-gradient(closest-side at 50% 0%, rgba(59, 130, 246, 0.16), transparent),
    var(--bg);
}
.final .section-lead { margin-left: auto; margin-right: auto; }
.final .cta { justify-content: center; }

footer { border-top: 1px solid var(--border); padding: 32px 0 48px; color: var(--faint); font-size: 13px; }
.foot { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.disclaimer { max-width: 720px; margin: 0; }

/* ---- Tablet / phone ---- */

@media (max-width: 900px) {
  .hero { padding: 56px 0 48px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .grid-3 { grid-template-columns: 1fr; }
  .lines { grid-template-columns: 1fr; }
}

/* A narrow phone: brand + RU|EN only - the hero right below has the same "open the app" button. */
@media (max-width: 440px) {
  nav .btn { display: none; }
}

@media (max-width: 600px) {
  .wrap { padding: 0 16px; }
  nav .link { display: none; }
  nav { gap: 10px; }
  .lead { font-size: 16px; }
  .cta .btn { flex: 1 1 100%; }
  .facts { gap: 20px; }
  .fact b { font-size: 22px; }
  section { padding: 56px 0; }
  .card { padding: 20px; }
  .how-step { padding: 20px; }
  .how-text h3 { font-size: 21px; }
  .viz { padding: 14px; }
  .quotes, .orders { grid-template-columns: 1fr; }
  .hedge-row, .hedge-legend { grid-template-columns: 78px 1fr 1fr; }
  .stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .stat { padding: 8px; }
  .stat b { font-size: 14px; }
}

/* ---- Footer with the site map (every page) ---- */

.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
  gap: 28px;
  margin-bottom: 24px;
}
.foot-col h4 { margin: 0 0 10px; font-size: 13px; color: var(--text); letter-spacing: 0.02em; }
.foot-col a { display: block; color: var(--faint); text-decoration: none; font-size: 13px; padding: 3px 0; }
.foot-col a:hover { color: var(--text); }
.foot-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 18px; border-top: 1px solid var(--border); }

@media (max-width: 900px) {
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-grid .foot-about { grid-column: 1 / -1; }
}

/* ---- Text pages: documents, the article, the partner program ---- */

.page-head { padding-top: 56px; padding-bottom: 24px; }
.page-head h1 { margin: 0 0 12px; font-size: clamp(28px, 4vw, 40px); letter-spacing: -0.02em; line-height: 1.15; }
.page-head .lead { margin: 0; }
.doc-meta { color: var(--faint); font-size: 13px; margin-top: 10px; }

.doc { max-width: 820px; padding-bottom: 72px; }
.doc h2 { margin: 36px 0 12px; font-size: 22px; letter-spacing: -0.01em; }
.doc h3 { margin: 24px 0 8px; font-size: 17px; }
.doc p, .doc li { color: #d4d4d4; font-size: 15px; line-height: 1.7; }
.doc ul, .doc ol { padding-left: 22px; }
.doc li { margin: 4px 0; }
.doc a { color: #93c5fd; }
.doc table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 14px; }
/* A wide table scrolls by itself on a phone instead of widening the page. */
@media (max-width: 760px) { .doc table { display: block; overflow-x: auto; } }
.doc th, .doc td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.doc th { color: var(--muted); font-weight: 600; }
.doc .note {
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--accent-soft);
  border: 1px solid rgba(96, 165, 250, 0.3);
  color: #bfdbfe;
  font-size: 14px;
}

/* Details the owner still has to fill in (requisites). */
.fill { background: rgba(245, 158, 11, 0.16); color: #fcd34d; padding: 0 4px; border-radius: 4px; }

.toc { margin: 8px 0 8px; padding: 14px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.toc a { color: var(--muted); text-decoration: none; }
.toc a:hover { color: var(--text); }

.steps-list { counter-reset: s; list-style: none; padding: 0 !important; }
.steps-list li { position: relative; padding-left: 40px; margin: 12px 0; }
.steps-list li::before {
  counter-increment: s;
  content: counter(s);
  position: absolute;
  left: 0;
  top: 2px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--green));
}

.tier-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 16px 0; }
.tier { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; }
.tier b { display: block; font-size: 30px; letter-spacing: -0.02em; margin: 4px 0; }
.tier span { color: var(--muted); font-size: 13px; }
.tier-top { border-color: rgba(52, 211, 153, 0.5); }

@media (max-width: 760px) {
  .tier-grid { grid-template-columns: 1fr; }
  .page-head { padding-top: 36px; padding-bottom: 16px; }
}

/* Exchange pages (/exchanges/, /exchanges/<name>/): numbers filled in by /exchanges/exchanges.js. */
a.chip { text-decoration: none; transition: border-color 0.15s, color 0.15s; }
a.chip:hover { border-color: var(--border-strong); color: var(--text); }

.crumbs { margin: 0 0 14px; font-size: 14px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); }
.ex-title { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; flex-wrap: wrap; }
.ex-title h1 { margin: 0; }
/* Favicons are often dark on transparent: a light tile keeps every logo visible on the dark page. */
.ex-logo { width: 40px; height: 40px; padding: 5px; border-radius: 10px; flex-shrink: 0; background: #f5f5f5; box-sizing: border-box; }
.ex-title .badge { color: #93c5fd; background: var(--accent-soft); }

.ex-live { padding: 0; border-top: 0; }
.ex-live h2 { margin: 16px 0 14px; font-size: 22px; letter-spacing: -0.01em; }
.ex-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stat-box { display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 14px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.stat-box span { color: var(--muted); font-size: 13px; }
.stat-box b { font-size: 20px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.stat-box small { color: var(--faint); font-size: 12px; }
.ex-note { color: var(--faint); font-size: 13px; margin: 12px 0 0; max-width: 820px; }
.ex-end { padding-bottom: 72px; }

.ex-facts { display: grid; grid-template-columns: 170px 1fr; gap: 10px 20px; margin: 12px 0; }
.ex-facts dt { color: var(--muted); font-size: 14px; padding-top: 2px; }
.ex-facts dd { margin: 0; color: #d4d4d4; font-size: 15px; line-height: 1.6; }

.ex-table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.ex-table { width: 100%; min-width: 760px; border-collapse: collapse; font-size: 14px; }
.ex-table th, .ex-table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.ex-table th { color: var(--muted); font-weight: 600; font-size: 13px; }
.ex-table tbody tr:last-child td { border-bottom: 0; }
.ex-table tbody tr:hover { background: var(--surface-2); }
.ex-table td { color: #d4d4d4; font-variant-numeric: tabular-nums; }
.ex-cell { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; text-decoration: none; }
.ex-cell:hover span { text-decoration: underline; }
.ex-logo-sm { width: 22px; height: 22px; padding: 2px; border-radius: 6px; background: #f5f5f5; box-sizing: border-box; }

@media (max-width: 900px) {
  .ex-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .ex-facts { grid-template-columns: 1fr; gap: 2px; }
  .ex-facts dd { margin-bottom: 10px; }
  .stat-box b { font-size: 17px; }
}

/* Main page: leverage and margin (#risk). */
.risk-figs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 16px; }
.risk-fig { display: flex; flex-direction: column; gap: 6px; padding: 20px 22px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.risk-fig b { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.1; letter-spacing: -0.02em; color: #86efac; font-variant-numeric: tabular-nums; }
.risk-fig > span { color: var(--muted); font-size: 14px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 760px) {
  .risk-figs, .grid-2 { grid-template-columns: 1fr; }
}
/* The long "What is an arbitrage scanner" link wraps on a phone instead of widening the page. */
#why .btn { white-space: normal; max-width: 100%; text-align: left; }

/* ================= Main page: life and detail (body.home) ================= */

/* How far the page is read. */
.scroll-progress {
  position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; transform: scaleX(0); transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--accent), var(--green), var(--violet));
}

/* Blocks rise into view (the class is added by the script, so without it everything is simply visible). */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease-out, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }

/* Cards: a light that follows the pointer, a lift on hover. */
.card, .risk-fig {
  background:
    radial-gradient(260px circle at var(--mx, -400px) var(--my, -400px), rgba(96, 165, 250, 0.10), transparent 70%),
    var(--surface);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
@media (hover: hover) {
  .card:hover, .risk-fig:hover { border-color: var(--border-strong); transform: translateY(-3px); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35); }
}

/* A small label above a section's title. */
.kicker {
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 12px; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase; color: #93c5fd;
}
.kicker b { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--faint); letter-spacing: 0; }
.kicker::after { content: ''; width: 36px; height: 1px; background: linear-gradient(90deg, #60a5fa, transparent); }

/* Each section has its own faint glow in a corner. */
.home section { position: relative; overflow: hidden; scroll-margin-top: 64px; }
.home section > .wrap { position: relative; }
.home section::before {
  content: ''; position: absolute; width: 620px; height: 620px; top: -320px; right: -180px; border-radius: 50%;
  background: radial-gradient(closest-side, var(--glow, rgba(59, 130, 246, 0.10)), transparent); pointer-events: none;
}
.home section:nth-of-type(even)::before { right: auto; left: -180px; }
.home #types { --glow: rgba(167, 139, 250, 0.10); }
.home #how { --glow: rgba(34, 197, 94, 0.08); overflow: visible; }
.home #how::before { display: none; } /* the pinned illustration needs the section unclipped */
.home #risk { --glow: rgba(34, 197, 94, 0.10); }
.home #backtest { --glow: rgba(244, 114, 182, 0.08); }

/* Hero: a faint grid behind, the example card floats, the status dot breathes. */
.hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 50% 20%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 80% at 50% 20%, #000 20%, transparent 75%);
}
.hero-grid { z-index: 1; }
.home .signal { animation: float 7s ease-in-out infinite; border-color: #353535; }
.home .dot { animation: breathe 2s ease-in-out infinite; }
.fact b { font-variant-numeric: tabular-nums; }
@keyframes float { 50% { transform: translateY(-8px); } }
@keyframes breathe { 50% { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); } }

/* What Selltix does: every icon in its own colour. */
#features .card:nth-child(2) .icon { color: #86efac; background: rgba(34, 197, 94, 0.12); }
#features .card:nth-child(3) .icon { color: #c4b5fd; background: rgba(167, 139, 250, 0.14); }
#features .card:nth-child(4) .icon { color: #fcd34d; background: rgba(245, 158, 11, 0.13); }
#features .card:nth-child(5) .icon { color: #f9a8d4; background: rgba(244, 114, 182, 0.13); }
#features .card:nth-child(6) .icon { color: #67e8f9; background: rgba(34, 211, 238, 0.12); }
#features .icon { transition: transform 0.25s; }
#features .card:hover .icon { transform: scale(1.1) rotate(-4deg); }

/* Three kinds of arbitrage: a moving picture of how each one earns. */
.type-card { --c: #34d399; display: flex; flex-direction: column; padding-top: 0; overflow: hidden; }
.type-b { --c: #60a5fa; }
.type-c { --c: #a78bfa; }
.type-card::before { content: ''; display: block; height: 3px; margin: 0 -24px; background: linear-gradient(90deg, var(--c), transparent 85%); }
.type-viz { margin: 18px 0 2px; padding: 12px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border); }
.type-viz svg { display: block; width: 100%; height: 96px; overflow: visible; }
.type-card h3 { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; }
.type-card p { flex: 1; }
.badge-beta { color: #c4b5fd; background: rgba(167, 139, 250, 0.16); }
.type-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; }
.type-facts div { padding: 9px 11px; border-radius: 10px; background: var(--surface-2); }
.type-facts div > span { display: block; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.05em; }
.type-facts div > b { font-size: 14px; color: var(--c); }
.type-link { margin-top: 14px; font-size: 14px; font-weight: 600; color: #c4b5fd; text-decoration: none; }
.type-link:hover { text-decoration: underline; }
/* The pictures loop: lines draw, markers and payments appear in turn, then it starts over. */
.type-viz .loop { stroke-dasharray: 1; animation: loop-draw 6s ease-in-out infinite; }
.type-viz .blip, .type-viz .gap { animation: loop-mark 6s ease-out infinite; transform-box: fill-box; transform-origin: center; }
.type-viz .blip.late { animation-name: loop-mark-late; }
.type-viz .band { animation: loop-band 6s ease-in-out infinite; }
.type-viz .coins circle { fill: #fbbf24; animation: loop-coin 6s ease-out infinite; transform-box: fill-box; transform-origin: center; }
.type-viz .bars rect { fill: rgba(167, 139, 250, 0.55); animation: loop-bar 6s ease-out infinite; transform-box: fill-box; transform-origin: 50% 100%; }
.type-viz .coins circle:nth-child(2), .type-viz .bars rect:nth-child(2) { animation-delay: 0.45s; }
.type-viz .coins circle:nth-child(3), .type-viz .bars rect:nth-child(3) { animation-delay: 0.9s; }
.type-viz .coins circle:nth-child(4), .type-viz .bars rect:nth-child(4) { animation-delay: 1.35s; }
.type-viz .bars rect:nth-child(5) { animation-delay: 1.8s; }
.type-viz .bars rect:nth-child(6) { animation-delay: 2.25s; }
@keyframes loop-draw { 0% { stroke-dashoffset: 1; opacity: 1; } 50%, 90% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes loop-mark { 0%, 14% { opacity: 0; transform: scale(0); } 20%, 90% { opacity: 1; transform: scale(1); } 100% { opacity: 0; } }
@keyframes loop-mark-late { 0%, 44% { opacity: 0; transform: scale(0); } 50%, 90% { opacity: 1; transform: scale(1); } 100% { opacity: 0; } }
@keyframes loop-band { 0%, 30% { opacity: 0; } 55%, 90% { opacity: 1; } 100% { opacity: 0; } }
@keyframes loop-coin { 0%, 8% { opacity: 0; transform: translateY(-14px) scale(0.4); } 16%, 90% { opacity: 1; transform: none; } 100% { opacity: 0; } }
@keyframes loop-bar { 0%, 6% { transform: scaleY(0); opacity: 1; } 14%, 90% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }

/* Why Selltix: numbered. */
#why .grid-3 { counter-reset: why; }
#why .card::before {
  counter-increment: why; content: counter(why, decimal-leading-zero); display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 26px; font-weight: 800; letter-spacing: -0.02em;
  background: linear-gradient(120deg, #60a5fa, #34d399); -webkit-background-clip: text; background-clip: text; color: transparent; opacity: 0.85;
}

/* Risk: the big figures glow, the bars compare leverage. */
.risk-fig { position: relative; overflow: hidden; }
.risk-fig::after { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: linear-gradient(180deg, #34d399, transparent); }
.lev { margin-bottom: 16px; }
.lev h3 { margin-top: 0; }
.lev p { margin-top: 14px; font-size: 13px; color: var(--faint); }
.lev-row { display: grid; grid-template-columns: 44px 1fr 56px; gap: 14px; align-items: center; padding: 7px 0; font-variant-numeric: tabular-nums; }
.lev-row b { font-size: 16px; }
.lev-row em { font-style: normal; font-weight: 700; text-align: right; color: var(--c); }
.lev-track { height: 12px; border-radius: 12px; background: var(--surface-2); overflow: hidden; }
.lev-track i { display: block; height: 100%; width: var(--w); border-radius: 12px; background: linear-gradient(90deg, var(--c), color-mix(in srgb, var(--c) 55%, transparent)); transition: width 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) 0.25s; }
.lev.reveal:not(.in) .lev-track i { width: 0; }
.lev-ours { --c: #34d399; }
.lev-mid { --c: #fbbf24; }
.lev-high { --c: #f87171; }

/* Backtest: a sample of the matrix. */
.bt-demo { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 32px; align-items: center; margin-bottom: 16px; }
.bt-demo h3 { margin-top: 0; font-size: 22px; }
.bt-note { margin-top: 12px !important; font-size: 13px !important; color: var(--faint) !important; }
.bt-grid { display: grid; gap: 6px; font-size: 14px; font-variant-numeric: tabular-nums; }
.bt-row { display: grid; grid-template-columns: 84px repeat(3, minmax(0, 1fr)); gap: 6px; align-items: center; }
.bt-head { color: var(--faint); font-size: 12px; text-align: center; }
.bt-h { color: var(--faint); font-size: 12px; text-align: left; }
.bt-c { padding: 11px 6px; border-radius: 9px; text-align: center; font-weight: 700; background: var(--surface-2); transition: transform 0.2s; }
.bt-c:hover { transform: scale(1.06); }
.bt-c.neg3 { color: #f87171; background: rgba(239, 68, 68, 0.20); }
.bt-c.neg2 { color: #fb923c; background: rgba(249, 115, 22, 0.15); }
.bt-c.neg1 { color: #fbbf24; background: rgba(245, 158, 11, 0.11); }
.bt-c.pos1 { color: #bef264; background: rgba(132, 204, 22, 0.11); }
.bt-c.pos2 { color: #86efac; background: rgba(34, 197, 94, 0.15); }
.bt-c.pos3 { color: #4ade80; background: rgba(34, 197, 94, 0.22); }
.bt-c.best { color: #052e16; background: #4ade80; box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5); animation: best 2.2s ease-out infinite; }
@keyframes best { to { box-shadow: 0 0 0 12px rgba(74, 222, 128, 0); } }

/* Exchanges: chips lift under the pointer. */
.home a.chip { transition: border-color 0.15s, color 0.15s, transform 0.15s, background 0.15s; }
.home a.chip:hover { transform: translateY(-2px); background: var(--surface-2); }

/* The closing call: a frame with a light running around it. */
@property --turn { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
.cta-box { position: relative; max-width: 820px; margin: 0 auto; padding: 52px 28px; border-radius: 22px; background: rgba(31, 31, 31, 0.8); }
.cta-box::before {
  content: ''; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: conic-gradient(from var(--turn), rgba(59, 130, 246, 0.9), rgba(34, 197, 94, 0.7), rgba(167, 139, 250, 0.8), rgba(64, 64, 64, 0.6), rgba(59, 130, 246, 0.9));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  animation: turn 7s linear infinite;
}
.cta-box .section-lead { margin-bottom: 28px; }
@keyframes turn { to { --turn: 360deg; } }

@media (max-width: 900px) {
  .bt-demo { grid-template-columns: 1fr; gap: 20px; }
}
@media (max-width: 600px) {
  .type-card::before { margin: 0 -20px; }
  .cta-box { padding: 36px 18px; }
  .bt-row { grid-template-columns: 64px repeat(3, minmax(0, 1fr)); }
  .bt-c { padding: 9px 2px; font-size: 13px; }
  .lev-row { grid-template-columns: 36px 1fr 48px; gap: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .home .signal, .home .dot, .bt-c.best, .cta-box::before,
  .type-viz .loop, .type-viz .blip, .type-viz .gap, .type-viz .band, .type-viz .coins circle, .type-viz .bars rect { animation: none; }
  .card, .risk-fig, .home a.chip, #features .icon, .bt-c { transition: none; }
  .card:hover, .risk-fig:hover, .home a.chip:hover { transform: none; }
  html { scroll-behavior: auto; }
}
