/* AptiStockX static website — dark-primary design system.
   Aligned with CLAUDE.MD §2:
     - Dark theme primary, light theme alternative for long-form docs
     - Single accent #26A69A (matches in-app chart "up" color)
     - Gold reserved for AptiStock lineage / heritage only — never a CTA
     - Semantic green/red exclusively for up/down
   Portable: pages open directly from the filesystem. */

/* ---------- Self-hosted webfont hooks ----------
   Drop the WOFF2 files into static/fonts/ to activate these.
   Until then we fall back gracefully to system UI fonts. */
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter-Bold.woff2") format("woff2");
  font-weight: 700 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/JetBrainsMono-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/JetBrainsMono-Bold.woff2") format("woff2");
  font-weight: 700 800;
  font-style: normal;
  font-display: swap;
}

/* ---------- Design tokens ---------- */
:root {
  /* Surfaces */
  --bg: #0B0E14;
  --bg-elev: #0F141C;
  --surface: #141821;
  --surface-2: #1A2030;
  --surface-3: #1E2535;

  /* Borders */
  --border: #232838;
  --border-strong: #2E3548;

  /* Ink */
  --ink: #E8EDF5;
  --ink-2: #C7D0DF;
  --ink-muted: #94A0B4;
  --ink-dim: #6B7689;

  /* Accent: chart "up" green, matches OptionsDialog.cpp (CLAUDE.MD §2.3) */
  --accent: #26A69A;
  --accent-hover: #2EBFB1;
  --accent-soft: rgba(38, 166, 154, 0.12);
  --accent-strong: rgba(38, 166, 154, 0.42);

  /* Semantic */
  --up: #26A69A;
  --down: #EF5350;
  --warn: #E0A030;

  /* Heritage gold — lineage only */
  --gold: #C8993D;
  --gold-soft: rgba(200, 153, 61, 0.12);
  --gold-line: rgba(200, 153, 61, 0.55);

  /* Geometry */
  --radius-sm: 4px;
  --radius: 6px;
  --radius-lg: 10px;
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.55);
  --shadow-soft: 0 1px 0 rgba(255, 255, 255, 0.03);

  --content-max: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; max-width: 100%; height: auto; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

code, .mono {
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
code {
  padding: 0.08em 0.35em;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  font-size: 0.92em;
}
pre {
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--ink);
  background: var(--bg-elev);
}
pre code { padding: 0; border: 0; background: transparent; color: inherit; }

.skip-link { position: absolute; left: -9999px; }
.skip-link:focus {
  position: fixed; top: 12px; left: 12px; z-index: 100;
  padding: 10px 14px; border-radius: var(--radius);
  color: var(--bg); background: var(--accent);
}

.container {
  width: min(var(--content-max), calc(100% - 48px));
  margin: 0 auto;
}
.container-narrow {
  width: min(820px, calc(100% - 48px));
  margin: 0 auto;
}
.center { text-align: center; }

/* ---------- Topline / ticker tape ---------- */
.topline {
  color: var(--ink-2);
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border);
  font-size: 12px;
}
.topline .container {
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px; padding-top: 8px; padding-bottom: 8px;
}
.ticker-tape {
  display: flex; align-items: center; gap: 22px; overflow: hidden;
  white-space: nowrap;
  font-size: 12px; letter-spacing: 0.3px;
}
.ticker-tape::after {
  content: "Illustrative";
  margin-left: 6px;
  padding: 2px 8px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  color: var(--ink-dim);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}
.up { color: var(--up); }
.down { color: var(--down); }

/* ---------- Site nav ---------- */
.site-nav {
  position: sticky; top: 0; z-index: 50;
  color: var(--ink);
  background: rgba(11, 14, 20, 0.88);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.site-nav .container {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 64px; gap: 24px;
}

.brand {
  display: inline-flex; align-items: center; gap: 12px;
  color: var(--ink);
}
.brand:hover { color: var(--ink); }
.brand-mark {
  width: 36px; height: 36px; border-radius: var(--radius); background: transparent;
  flex: 0 0 auto; overflow: visible;
}
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand-name {
  display: block; color: var(--ink);
  font-size: 17px; font-weight: 700; letter-spacing: -0.01em;
  line-height: 1.05;
}
.brand-sub {
  display: block; color: var(--ink-dim);
  font-size: 10px; font-weight: 600; letter-spacing: 1.4px;
  line-height: 1.2; text-transform: uppercase;
}

.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a {
  color: var(--ink-2);
  font-size: 14px; font-weight: 500; letter-spacing: 0.01em;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--ink); }

.nav-links .nav-cta {
  padding: 8px 14px; border-radius: var(--radius);
  color: var(--bg); background: var(--accent);
  font-weight: 700;
}
.nav-links .nav-cta:hover { color: var(--bg); background: var(--accent-hover); }

.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border: 1px solid var(--border-strong); border-radius: var(--radius);
  color: var(--ink); background: transparent; cursor: pointer;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  display: block; width: 18px; height: 2px; background: currentColor; content: "";
}
.nav-toggle span::before { transform: translateY(-6px); }
.nav-toggle span::after { transform: translateY(4px); }

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  margin: 0 0 14px; color: var(--ink);
  line-height: 1.15; letter-spacing: -0.015em;
}
h1 {
  font-size: clamp(38px, 6.4vw, 64px);
  line-height: 1.04; letter-spacing: -0.025em;
}
h2 { font-size: clamp(26px, 3.6vw, 40px); }
h3 { font-size: 19px; font-weight: 700; }
h4 {
  font-size: 13px; font-weight: 700;
  letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--ink-2);
}

p { color: var(--ink-2); }

/* ---------- Hero (home) ---------- */
.hero-home {
  position: relative; min-height: 72vh;
  display: flex; align-items: center;
  color: var(--ink); background: var(--bg);
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.hero-home::before {
  position: absolute; inset: 0; z-index: 0;
  background-image:
    radial-gradient(900px 460px at 84% -10%, rgba(38, 166, 154, 0.16), transparent 62%),
    radial-gradient(620px 360px at 0% 100%, rgba(46, 191, 177, 0.10), transparent 64%),
    linear-gradient(transparent 95%, rgba(255, 255, 255, 0.025) 95%),
    linear-gradient(90deg, transparent 95%, rgba(255, 255, 255, 0.025) 95%);
  background-size: 100% 100%, 100% 100%, 100% 28px, 28px 100%;
  content: "";
  pointer-events: none;
}
.hero-home .container {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(440px, 0.95fr);
  gap: 48px; align-items: center;
  padding-top: 80px; padding-bottom: 72px;
}

.hero-copy { min-width: 0; }
.hero-visual { min-width: 0; }

.hero-title-row {
  display: grid; grid-template-columns: max-content minmax(220px, 1fr);
  align-items: center; gap: 22px; margin-bottom: 16px;
}
.hero-title {
  margin: 0; white-space: nowrap; color: var(--ink);
  font-weight: 800; letter-spacing: -0.03em;
}
/* Single-color wordmark with a subtle accent on the trailing "X" only */
.title-apti, .title-stock { color: var(--ink); }
.title-x { color: var(--accent); }

.hero-slogan {
  width: 100%; min-width: 0;
  margin: 0;
  padding: 8px 0 8px 16px;
  border-left: 2px solid var(--accent);
  color: var(--ink-2);
  font-size: 15px; font-weight: 600; letter-spacing: 0.01em;
  line-height: 1.3;
}

.lede {
  max-width: 640px; margin: 18px 0 0;
  color: var(--ink-2);
  font-size: clamp(17px, 1.6vw, 20px); line-height: 1.5;
}

.hero-proof {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 0;
}
.proof-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 10px;
  border: 1px solid var(--border-strong); border-radius: 999px;
  color: var(--ink-2); background: var(--surface);
  font-size: 12.5px; font-weight: 500;
}
.proof-pill img { width: 14px; height: 14px; }

.cta-row {
  display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px;
}
.availability {
  max-width: 640px; margin-top: 16px;
  color: var(--ink-dim); font-size: 13px;
}

.checkout-panel {
  display: grid;
  gap: 14px;
  margin-top: 22px;
}

.paypal-button-container {
  min-height: 150px;
  max-width: 420px;
}

.stripe-checkout-button {
  width: min(100%, 420px);
  min-height: 46px;
  border: 0;
  border-radius: 6px;
  background: #635BFF;
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.stripe-checkout-button:disabled {
  opacity: .65;
  cursor: wait;
}
.checkout-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  width: min(100%, 420px);
  color: var(--ink-dim);
  font-size: 12px;
}
.checkout-divider::before,
.checkout-divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--border);
}

.checkout-message {
  min-height: 22px;
  margin: 0;
  color: var(--ink-dim);
  font-size: 13px;
}

.checkout-message.error { color: #FCA5A5; }
.checkout-message.success { color: #86EFAC; }

/* Hero stats — mono numbers, separated by a hairline */
.stats-row {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px; max-width: 640px; margin-top: 28px;
  padding-top: 22px; border-top: 1px solid var(--border);
}
.stat { min-width: 0; }
.stat .num {
  color: var(--ink);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 22px; font-weight: 700;
  letter-spacing: -0.01em; line-height: 1.1;
}
.stat .lbl {
  margin-top: 6px; color: var(--ink-dim);
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.9px;
  text-transform: uppercase;
}

/* Hero screenshot — clean frame, no fake browser chrome */
.chart-mock {
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.mock-chrome { display: none; }  /* hidden — borderless frame reads as honest */
.mock-body { background: var(--surface); }
.mock-body .shot { width: 100%; height: auto; display: block; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; min-height: 42px;
  padding: 10px 18px;
  border: 1px solid transparent; border-radius: var(--radius);
  font-weight: 600; font-size: 14.5px; letter-spacing: 0.01em;
  line-height: 1.2; cursor: pointer;
  transition: background-color 120ms ease, color 120ms ease, border-color 120ms ease;
}
.btn-primary { color: var(--bg); background: var(--accent); }
.btn-primary:hover { color: var(--bg); background: var(--accent-hover); }

.btn-secondary {
  color: var(--ink); border-color: var(--border-strong); background: transparent;
}
.btn-secondary:hover {
  color: var(--ink); border-color: var(--accent); background: var(--accent-soft);
}

.btn-light {
  color: var(--ink); border-color: var(--border-strong); background: var(--surface);
}
.btn-light:hover { color: var(--accent); border-color: var(--accent); }

.btn-gold { color: #1A1306; background: var(--gold); }
.btn-gold:hover { color: #1A1306; background: #E0AC4D; }

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section-tight { padding: 36px 0; }
.section-soft { background: var(--surface-2); }
.section-dark { background: var(--bg-elev); }
.section-lineage {
  background:
    linear-gradient(180deg, rgba(200, 153, 61, 0.06) 0%, transparent 100%),
    var(--bg);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-header { max-width: 720px; margin-bottom: 32px; }
.section-header.center { margin-right: auto; margin-left: auto; text-align: center; }
.section-header p { color: var(--ink-muted); font-size: 16.5px; }

.kicker {
  margin-bottom: 8px; color: var(--accent);
  font-size: 11.5px; font-weight: 700; letter-spacing: 1.4px;
  text-transform: uppercase;
}
.kicker.gold { color: var(--gold); }

/* ---------- Grids / cards ---------- */
.grid { display: grid; gap: 20px; }
.grid.two   { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.four  { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.card {
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  transition: border-color 140ms ease, transform 140ms ease, box-shadow 140ms ease;
}
.grid .card.padded:hover {
  border-color: var(--accent-strong);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
}
.card.padded { padding: 22px; }
.card h3 { font-size: 18px; color: var(--ink); }
.card p { color: var(--ink-muted); }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }

.icon-chip {
  width: 38px; height: 38px;
  display: grid; place-items: center; margin-bottom: 14px;
  border: 1px solid var(--accent-strong); border-radius: var(--radius);
  color: var(--accent); background: var(--accent-soft);
}
.icon-chip.gold {
  color: var(--gold); border-color: var(--gold-line); background: var(--gold-soft);
}
.icon-chip img { width: 22px; height: 22px; object-fit: contain; }

/* ---------- Screenshot frame ---------- */
.screenshot-frame {
  overflow: hidden;
  border: 1px solid var(--border-strong); border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.screenshot-frame.light {
  border-color: var(--border); background: var(--surface);
}
.screenshot-frame.dark {
  border-color: #29364b; background: #08111e;
}
.screenshot-frame img { width: 100%; display: block; }

/* ---------- Feature blocks ---------- */
.feature-showcase {
  display: grid; grid-template-columns: 0.92fr 1.08fr;
  gap: 32px; align-items: center;
}
.feature-list { display: grid; gap: 12px; }
.feature-list a, .doc-card, .article-card { color: inherit; }

.feature-row {
  padding: 18px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.feature-row h3 { margin-bottom: 6px; font-size: 17px; }
.feature-row p { margin: 0; color: var(--ink-muted); }

.feature-detail-list { display: grid; gap: 28px; }
.feature-detail {
  display: grid; grid-template-columns: minmax(0, 0.88fr) minmax(420px, 1.12fr);
  gap: 32px; align-items: center;
  padding: 28px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.feature-detail.reverse .feature-copy { order: 2; }
.feature-detail.reverse .feature-media { order: 1; }
.feature-copy h2 { margin-bottom: 14px; font-size: clamp(24px, 3.2vw, 34px); }
.feature-copy p { color: var(--ink-muted); font-size: 16px; }
.feature-media { min-width: 0; }

.media-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px; align-items: stretch;
}
.media-grid .screenshot-frame { height: 100%; }
.media-grid .screenshot-frame img { height: 100%; object-fit: cover; }

/* ---------- Platform / download tiles ---------- */
.platform-icons {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px;
}
.platform-icon {
  display: grid; gap: 12px; place-items: center; min-width: 0;
  padding: 22px 14px;
  border: 1px solid var(--border); border-radius: var(--radius);
  color: var(--ink); background: var(--surface); text-align: center;
}
.platform-mark {
  display: grid; place-items: center;
  width: 72px; height: 72px; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--surface-2);
  color: var(--ink-2);
}
.platform-mark img { width: 48px; height: 48px; object-fit: contain; }

.platform-showcase {
  display: grid; gap: 16px; padding: 22px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.platform-showcase p { margin: 0; color: var(--ink-muted); }

.screenshot-placeholder {
  display: grid; min-height: 320px; place-items: center;
  padding: 28px;
  border: 1px dashed var(--border-strong); border-radius: var(--radius);
  color: var(--ink-muted);
  background:
    linear-gradient(transparent 95%, rgba(255, 255, 255, 0.04) 95%),
    linear-gradient(90deg, transparent 95%, rgba(255, 255, 255, 0.04) 95%),
    var(--surface);
  background-size: 28px 28px;
  text-align: center;
}
.screenshot-placeholder span {
  color: var(--ink-dim); font-size: 11px; font-weight: 700;
  letter-spacing: 1.2px; text-transform: uppercase;
}
.screenshot-placeholder strong {
  color: var(--ink); font-size: clamp(24px, 3.6vw, 36px); line-height: 1.1;
}
.screenshot-placeholder p { max-width: 440px; margin: 0; color: var(--ink-muted); }

.monitor-pair {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 0.82fr);
  gap: 18px; align-items: end;
  padding-bottom: 30px;
}
.monitor-frame {
  position: relative;
  margin: 0;
  padding: 10px 10px 26px;
  border: 1px solid #29364b;
  border-bottom: 9px solid #141f30;
  border-radius: 10px 10px 7px 7px;
  background: linear-gradient(180deg, #2a3548 0%, #0f1726 100%);
  box-shadow: 0 18px 34px rgba(7, 17, 31, 0.18);
}
.monitor-frame::before,
.monitor-frame::after {
  position: absolute;
  left: 50%;
  content: "";
  transform: translateX(-50%);
}
.monitor-frame::before {
  bottom: -28px;
  width: 18%;
  min-width: 34px;
  height: 28px;
  border-radius: 0 0 5px 5px;
  background: linear-gradient(90deg, #101827 0%, #3c485d 52%, #0c1422 100%);
  clip-path: polygon(34% 0, 66% 0, 84% 100%, 16% 100%);
}
.monitor-frame::after {
  bottom: -36px;
  width: 42%;
  height: 9px;
  border-radius: 999px;
  background: linear-gradient(90deg, #080f1a 0%, #4d596e 52%, #080f1a 100%);
  box-shadow: 0 9px 18px rgba(7, 17, 31, 0.22);
}
.monitor-frame figcaption {
  margin-bottom: 8px; color: #d9e5f5;
  font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
}
.monitor-frame img {
  display: block;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 4px;
  background: #08111e;
}
.side-monitor { transform: translateY(-22px); }

.ai-panel-preview {
  display: grid; gap: 12px; min-height: 320px;
  padding: 18px;
  border: 1px solid var(--border-strong); border-radius: var(--radius);
  color: var(--ink-2); background: var(--surface);
  box-shadow: var(--shadow);
}
.ai-panel-top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding-bottom: 10px; border-bottom: 1px solid var(--border);
  font-weight: 700; color: var(--ink);
}
.ai-panel-top button {
  padding: 7px 11px; border: 1px solid var(--accent-strong); border-radius: var(--radius);
  color: var(--bg); background: var(--accent);
  font: inherit; font-size: 13px; font-weight: 700;
}
.ai-message {
  max-width: 86%; padding: 12px; border-radius: var(--radius);
  color: var(--ink-2); background: var(--surface-2);
}
.ai-message.user {
  justify-self: end;
  color: var(--bg); background: rgba(38, 166, 154, 0.85);
}
.ai-message.assistant {
  justify-self: start; border-left: 3px solid var(--gold);
}

/* ---------- Download tiles ---------- */
.download-platforms {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px;
}
.download-card {
  display: grid; gap: 16px; padding: 22px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.download-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.download-head .platform-icon {
  display: flex; flex: 1; justify-content: flex-start;
  padding: 0; border: 0; background: transparent; text-align: left;
}
.download-head .platform-mark { width: 38px; height: 38px; }
.download-head .platform-mark img { width: 22px; height: 22px; }

.download-meta { display: grid; gap: 6px; margin: 0; }
.download-meta div { display: grid; grid-template-columns: 88px 1fr; gap: 10px; }
.download-meta dt {
  color: var(--ink-dim); font-size: 12px; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
}
.download-meta dd {
  min-width: 0; margin: 0; color: var(--ink-2);
  overflow-wrap: anywhere;
  font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 13px;
}
.download-option {
  display: grid; gap: 12px;
  padding-top: 14px; border-top: 1px solid var(--border);
}
.download-option h3 {
  margin: 0; color: var(--ink); font-size: 16px;
}
.download-option p {
  margin: 0; color: var(--ink-muted); font-size: 13.5px;
}
.download-command-option pre {
  margin: 0; padding: 14px; font-size: 12.5px;
}
.download-option .btn { justify-self: start; }
.download-alt-panel {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  margin-top: 20px; padding: 18px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.download-alt-panel h3 { margin: 0 0 4px; color: var(--ink); font-size: 18px; }
.download-alt-panel p { margin: 0; color: var(--ink-muted); font-size: 14px; }
.download-alt-panel .btn { flex: 0 0 auto; }
.install-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px;
}
.install-card {
  display: grid; align-content: start; gap: 14px; padding: 22px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.install-card h3 { margin: 0; color: var(--ink); }
.install-card p { margin: 0; color: var(--ink-muted); }
.install-card pre { margin: 0; }
.install-steps {
  display: grid; gap: 10px; margin: 0; padding-left: 20px;
  color: var(--ink-muted);
}
.install-steps li::marker { color: var(--accent); font-weight: 700; }

/* ---------- Honesty / lineage / trial panels ---------- */
.honesty-panel {
  display: grid; grid-template-columns: auto 1fr auto;
  gap: 18px; align-items: center; padding: 20px;
  border: 1px solid var(--gold-line); border-left: 3px solid var(--gold);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(200, 153, 61, 0.08), rgba(200, 153, 61, 0.02));
}
.honesty-panel h3 { margin: 0 0 4px; color: var(--ink); }
.honesty-panel p { margin: 0; color: var(--ink-muted); }

.lineage-panel {
  display: grid; grid-template-columns: 120px 1fr;
  gap: 28px; align-items: center; padding: 28px;
  border: 1px solid var(--gold-line); border-radius: var(--radius);
  background: var(--surface); box-shadow: var(--shadow);
}
.lineage-panel .seal {
  display: grid; place-items: center;
  width: 120px; height: 120px;
  border: 1px solid var(--gold-line); border-radius: var(--radius);
  background: var(--gold-soft);
}
.lineage-panel .seal img { width: 76px; height: 76px; }
.lineage-panel blockquote {
  margin: 0 0 12px; color: var(--ink);
  font-size: clamp(22px, 3.4vw, 30px); font-weight: 700;
  line-height: 1.18; letter-spacing: -0.01em;
}
.lineage-panel p { color: var(--ink-muted); }

.trial-panel {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 0.76fr);
  gap: 26px; align-items: center;
  padding: 28px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface); box-shadow: var(--shadow);
}
.trial-panel h2 { font-size: clamp(24px, 3.2vw, 34px); }
.trial-panel p { color: var(--ink-muted); font-size: 15.5px; }

.trial-rules { display: grid; gap: 10px; }
.trial-rules div {
  padding: 14px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface-2);
}
.trial-rules strong { display: block; margin-bottom: 4px; color: var(--ink); }
.trial-rules span {
  display: block; color: var(--ink-muted);
  font-size: 13.5px; line-height: 1.45;
}

/* ---------- Trust strip ---------- */
.trust-strip {
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px; overflow: hidden;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--border);
}
.trust-item { padding: 18px; background: var(--surface); }
.trust-item strong { display: block; margin-bottom: 4px; color: var(--ink); font-size: 14px; }
.trust-item span, .trust-item a { color: var(--ink-muted); font-size: 12.5px; }
.trust-item a:hover { color: var(--accent); }

/* ---------- Page hero ---------- */
.page-hero {
  color: var(--ink); background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.page-hero .container { padding-top: 56px; padding-bottom: 52px; }
.page-hero h1 { color: var(--ink); font-size: clamp(34px, 5vw, 52px); }
.page-hero p { max-width: 760px; color: var(--ink-muted); font-size: 17px; }

.crumbs { margin-bottom: 12px; color: var(--ink-dim); font-size: 13px; }
.crumbs a { color: var(--ink-2); }
.crumbs a:hover { color: var(--accent); }

.badge-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.badge {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 4px 10px; border: 1px solid var(--border-strong); border-radius: 999px;
  color: var(--ink-2); background: var(--surface);
  font-size: 12px; font-weight: 600;
}
.badge.success {
  color: var(--accent); border-color: var(--accent-strong); background: var(--accent-soft);
}
.badge.gold {
  color: var(--gold); border-color: var(--gold-line); background: var(--gold-soft);
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  margin-bottom: 12px; padding: 5px 10px;
  border: 1px solid var(--border-strong); border-radius: 999px;
  color: var(--ink-2); background: var(--surface);
  font-size: 11.5px; font-weight: 700; letter-spacing: 0.7px; text-transform: uppercase;
}
.eyebrow.gold {
  color: var(--gold); border-color: var(--gold-line); background: var(--gold-soft);
}
.eyebrow::before {
  width: 7px; height: 7px; border-radius: 50%; background: currentColor; content: "";
}

/* ---------- Compare table ---------- */
.compare-table {
  width: 100%; border-collapse: collapse; overflow: hidden;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.compare-table th, .compare-table td {
  padding: 14px 16px; border-bottom: 1px solid var(--border);
  text-align: left; vertical-align: top; color: var(--ink-2);
}
.compare-table th {
  color: var(--ink); background: var(--surface-2);
  font-size: 12.5px; letter-spacing: 0.8px; text-transform: uppercase;
}
.compare-table tr:last-child td { border-bottom: 0; }

/* ---------- "Vs subscription platforms" comparison ---------- */
.compare-table td:first-child { color: var(--ink); font-weight: 600; }
.compare-table .col-apti {
  background: rgba(38, 166, 154, 0.05);
  border-left: 1px solid var(--accent-strong);
}
.compare-table th.col-apti { color: var(--accent); }
.cell-yes { color: var(--accent); font-weight: 600; }
.cell-yes::before { content: "\2713\00a0"; }
.cell-no { color: var(--ink-dim); }
.cell-note { display: block; margin-top: 2px; color: var(--ink-dim); font-size: 12.5px; font-weight: 400; }

.win-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.clean-list li.them::before { background: transparent; border: 1px solid var(--ink-dim); }

/* ---------- 5-year cost bars ---------- */
.cost-bars { display: grid; gap: 16px; margin: 24px 0 10px; }
.cost-bar .cost-label {
  display: flex; justify-content: space-between; gap: 12px; margin-bottom: 7px;
  color: var(--ink-2); font-size: 13.5px; font-weight: 600;
}
.cost-bar .cost-label .amount {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  color: var(--ink); font-weight: 700;
}
.cost-bar .bar {
  height: 22px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong); background: var(--surface-3);
}
.cost-bar.apti .bar {
  border-color: var(--accent-strong);
  background: linear-gradient(90deg, var(--accent), var(--accent-hover));
}
.cost-bar.apti .cost-label .amount { color: var(--accent); }
.cost-footnote { color: var(--ink-dim); font-size: 13px; }

/* ---------- FAQ collapse ---------- */
.faq-list { display: grid; gap: 10px; }
.faq-item {
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.faq-item summary {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 15px 18px; cursor: pointer;
  color: var(--ink); font-weight: 600; font-size: 15px;
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; flex: 0 0 auto;
  color: var(--accent);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 18px; font-weight: 700;
}
.faq-item[open] summary::after { content: "\2212"; }
.faq-item[open] { border-color: var(--accent-strong); }
.faq-body { padding: 0 18px 16px; color: var(--ink-muted); }
.faq-body p { margin: 0 0 8px; color: var(--ink-muted); }
.faq-body p:last-child { margin-bottom: 0; }

/* ---------- Pricing ---------- */
.pricing-grid { align-items: stretch; }
.pricing-card { display: flex; flex-direction: column; min-height: 100%; }
.pricing-card .cta-row { margin-top: auto; }
.pricing-card h2 { margin-top: 8px; }

.tier-intro { margin: 0 0 12px; color: var(--ink-muted); }

.highlight-card {
  border-color: var(--gold-line);
  background: linear-gradient(180deg, rgba(200, 153, 61, 0.08) 0%, var(--surface) 60%);
}
.pro-price-card {
  border-color: var(--accent-strong);
  background: linear-gradient(180deg, rgba(38, 166, 154, 0.10) 0%, var(--surface) 55%);
  box-shadow: var(--shadow);
}

.feature-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.feature-tags span {
  padding: 5px 10px; border: 1px solid var(--gold-line); border-radius: 999px;
  color: var(--gold); background: var(--gold-soft);
  font-size: 11.5px; font-weight: 700;
}

.pro-highlight-list { display: grid; gap: 8px; margin: 0 0 14px; }
.pro-highlight-list div {
  padding: 12px; border: 1px solid var(--accent-strong); border-radius: var(--radius);
  background: rgba(38, 166, 154, 0.05);
}
.pro-highlight-list strong, .pro-highlight-list span { display: block; }
.pro-highlight-list strong { color: var(--ink); }
.pro-highlight-list span { color: var(--ink-muted); font-size: 13px; }

/* ---------- License callout (multi-machine activation) ---------- */
.license-callout {
  display: flex; gap: 16px; align-items: flex-start;
  padding: 20px 22px; margin: 4px 0 0;
  border: 1px solid var(--accent-strong); border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(38, 166, 154, 0.10) 0%, var(--surface) 70%);
}
.license-callout .license-callout-count {
  flex: 0 0 auto;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 30px; font-weight: 700; line-height: 1;
  color: var(--accent); padding-top: 2px;
}
.license-callout h3 { margin: 0 0 6px; font-size: 18px; color: var(--ink); }
.license-callout p { margin: 0 0 8px; color: var(--ink-muted); }
.license-callout p:last-child { margin-bottom: 0; }
.license-callout .os-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0; }
.license-callout .os-chips span {
  padding: 4px 10px; border: 1px solid var(--accent-strong); border-radius: 999px;
  color: var(--accent); font-size: 12px; font-weight: 700;
  font-family: "JetBrains Mono", ui-monospace, monospace;
}

.tier-compare {
  display: grid; grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr);
  gap: 22px; align-items: stretch;
}
.tier-panel {
  padding: 26px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.tier-panel h3 { margin-top: 10px; font-size: clamp(22px, 2.8vw, 30px); }
.tier-panel p { color: var(--ink-muted); }
.pro-panel {
  border-color: var(--accent-strong);
  background: linear-gradient(180deg, rgba(38, 166, 154, 0.08) 0%, var(--surface) 55%);
  box-shadow: var(--shadow);
}

.pro-feature-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px;
}
.pro-feature-grid div {
  padding: 14px; border: 1px solid var(--accent-strong); border-radius: var(--radius);
  background: rgba(38, 166, 154, 0.04);
}
.pro-feature-grid h4 {
  margin-bottom: 6px; font-size: 14px;
  text-transform: none; letter-spacing: 0; color: var(--ink);
}
.pro-feature-grid p { margin: 0; font-size: 13.5px; color: var(--ink-muted); }

.provider-grid, .disclaimer-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px;
}
.provider-card {
  display: grid; gap: 14px; padding: 22px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.provider-card-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 18px;
}
.provider-card-head h3 { margin: 8px 0 0; font-size: 22px; }
.provider-card-head > span {
  max-width: 220px; color: var(--ink-muted);
  font-size: 12.5px; font-weight: 700; text-align: right;
}
.provider-card p { margin: 0; color: var(--ink-muted); }

.price {
  margin: 6px 0 14px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 32px; font-weight: 800; letter-spacing: -0.01em;
  color: var(--ink);
}
.price small { color: var(--ink-muted); font-size: 13px; font-weight: 500; }

/* ---------- Lists ---------- */
.clean-list { padding: 0; margin: 0; list-style: none; }
.clean-list li {
  position: relative; padding: 9px 0 9px 24px;
  border-top: 1px solid var(--border); color: var(--ink-2);
}
.clean-list li:first-child { border-top: 0; }
.clean-list li::before {
  position: absolute; top: 13px; left: 2px;
  width: 9px; height: 9px; border-radius: 50%; background: var(--accent); content: "";
}
.clean-list li.warn::before { background: var(--gold); }
.clean-list.warn-list li::before { background: var(--gold); }
.color-success { color: var(--accent); }
.color-warning { color: var(--gold); }
.clean-list li.no { color: var(--ink-muted); }
.clean-list li.no::before { background: transparent; border: 1px solid var(--ink-dim); }

.step-list { margin: 0; padding: 0; list-style: none; counter-reset: step; }
.step-list li {
  position: relative; min-height: 40px;
  margin: 0; padding: 6px 0 10px 50px;
  color: var(--ink-2); counter-increment: step;
}
.step-list li::before {
  position: absolute; top: 4px; left: 0;
  display: grid; place-items: center;
  width: 32px; height: 32px; border-radius: 50%;
  color: var(--bg); background: var(--accent);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 13px; font-weight: 700; content: counter(step);
}

/* ---------- Docs / articles ---------- */
.docs-grid {
  display: grid; grid-template-columns: 1.1fr 0.9fr;
  gap: 26px; align-items: start;
}
.doc-card, .article-card {
  display: block; padding: 20px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
}
.doc-card h3, .article-card h3 { color: var(--ink); }
.doc-card p, .article-card p { color: var(--ink-muted); }
.article-card h2 a { color: var(--ink); }
.article-card h2 a:hover { color: var(--accent); }
.doc-card:hover, .article-card:hover, .feature-row:hover {
  border-color: var(--accent);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
}
.article-list { display: grid; gap: 12px; }
.prose {
  color: var(--ink-muted);
  font-size: 17px;
  line-height: 1.75;
}
.prose h2 {
  margin-top: 34px;
  color: var(--ink);
  font-size: clamp(24px, 3vw, 34px);
}
.prose hr {
  margin: 38px 0 26px;
  border: 0;
  border-top: 1px solid var(--border);
}
.contact-form {
  display: grid;
  gap: 16px;
}
.contact-form textarea {
  resize: vertical;
}
.site-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.form-status {
  margin: 0;
  padding: 12px 14px;
  border-left: 4px solid var(--accent);
  border-radius: 6px;
  color: var(--ink);
  background: rgba(56, 169, 133, 0.12);
}
.form-status.error {
  border-left-color: var(--down);
  background: rgba(168, 18, 26, 0.12);
}

.split {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 30px; align-items: start;
}

/* ---------- Footer ---------- */
.footer {
  color: var(--ink-muted); background: var(--bg-elev);
  border-top: 1px solid var(--border);
}
.footer .container { padding-top: 44px; padding-bottom: 28px; }
.footer-grid {
  display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 28px;
}
.footer h4 {
  color: var(--ink); font-size: 12px; letter-spacing: 1.2px;
  text-transform: uppercase;
}
.footer a {
  display: block; padding: 3px 0; color: var(--ink-muted); font-size: 13.5px;
}
.footer a:hover { color: var(--ink); }
.footer .brand { display: inline-flex; align-items: center; padding: 0; }
.footer .brand-mark { width: 30px; height: 30px; border-radius: var(--radius); }
.footer .brand-name { font-size: 14px; }
.footer .brand-sub { font-size: 9px; letter-spacing: 1px; }
.footer .tagline { max-width: 340px; color: var(--ink-dim); font-size: 13px; }
.footer-bottom {
  display: flex; justify-content: space-between; gap: 18px;
  margin-top: 30px; padding-top: 20px;
  border-top: 1px solid var(--border);
  color: var(--ink-dim); font-size: 12px;
}
.footer-bottom a { display: inline; font-size: 12px; }

/* ---------- Forms ---------- */
form { display: grid; gap: 12px; }
label { display: block; margin-bottom: 6px; font-weight: 600; color: var(--ink); }
input, textarea {
  width: 100%; padding: 12px 14px;
  border: 1px solid var(--border-strong); border-radius: var(--radius);
  background: var(--surface); color: var(--ink);
  font: inherit;
}
input::placeholder, textarea::placeholder { color: var(--ink-dim); }
textarea { min-height: 130px; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .hero-home .container { grid-template-columns: 1fr; }
  .hero-visual { max-width: 760px; }
  .grid.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid.three,
  .download-platforms,
  .install-grid,
  .feature-detail,
  .feature-showcase,
  .provider-grid,
  .disclaimer-grid,
  .docs-grid,
  .split,
  .win-cols,
  .tier-compare { grid-template-columns: 1fr; }
  .download-alt-panel { align-items: flex-start; flex-direction: column; }
  .feature-detail.reverse .feature-copy,
  .feature-detail.reverse .feature-media { order: initial; }
  .trust-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  .container, .container-narrow { width: min(100% - 32px, 1180px); }
  .topline .container {
    align-items: flex-start; flex-direction: column; gap: 6px;
  }
  .ticker-tape {
    width: 100%; min-width: 0; max-width: 100%;
  }
  .nav-toggle { display: inline-flex; }
  .nav-links { display: none; }
  .site-nav.open .nav-links {
    position: absolute; top: 64px; right: 0; left: 0;
    display: grid; gap: 6px; padding: 14px;
    background: rgba(11, 14, 20, 0.98);
    border-bottom: 1px solid var(--border);
  }
  .site-nav.open .nav-links a { padding: 8px; }
  .hero-home .container { padding-top: 56px; padding-bottom: 44px; }
  .hero-title-row { grid-template-columns: 1fr; gap: 10px; }
  .stats-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-slogan { padding-left: 12px; }
  h1 { font-size: 42px; }
  .grid.two,
  .grid.four,
  .media-grid,
  .monitor-pair,
  .platform-icons,
  .pro-feature-grid,
  .trust-strip,
  .trial-panel,
  .lineage-panel { grid-template-columns: 1fr; }
  .feature-detail { padding: 22px; }
  .side-monitor { transform: none; }
  .lineage-panel .seal { width: 96px; height: 96px; }
  .honesty-panel { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; }
  .compare-table { display: block; overflow-x: auto; }
}

/* ---------- Print ---------- */
@media print {
  .topline, .site-nav, .footer { display: none; }
  body { color: #000; background: #fff; }
  a { color: #000; text-decoration: underline; }
}
