/* Trader Arena — shared styles (v2)
   Layout concept: a calm charcoal trading-terminal grid; content in a 1120px column,
   red and green used only as accents, mono labels borrowed from chart axes. */
:root {
  --bg: #0d0e0f;
  --bg-2: #121415;
  --surface: #171a1b;
  --surface-2: #1d2122;
  --line: #2a2f31;
  --line-soft: #202426;
  --fg: #f3f3f0;
  --fg-2: #c9ccca;
  --muted: #9aa09e;
  --red: #e5484d;
  --red-btn: #cf3338;
  --red-btn-hover: #b92a2f;
  --red-soft: rgba(229, 72, 77, 0.12);
  --green: #30c27a;
  --green-soft: rgba(48, 194, 122, 0.12);
  --focus: #ffd166;

  --font-display: "Chakra Petch", "Arial Narrow", system-ui, sans-serif;
  --font-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --step--1: 0.875rem;
  --step-0: 1rem;
  --step-1: 1.1875rem;
  --step-2: 1.5rem;
  --step-3: clamp(1.75rem, 1.3rem + 1.6vw, 2.375rem);
  --step-4: clamp(2.1rem, 1.4rem + 3vw, 3.5rem);

  --radius: 10px;
  --wrap: 1120px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px);
  z-index: 60; background: var(--bg);
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.005em;
  margin: 0;
  text-wrap: balance;
}
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--fg); color: var(--bg); padding: 10px 14px; border-radius: 6px;
  font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * 24px);
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 720px) {
  .wrap {
    padding-left: max(24px, env(safe-area-inset-left, 0px));
    padding-right: max(24px, env(safe-area-inset-right, 0px));
  }
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: rgba(13, 14, 15, 0.92);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; flex-shrink: 0; }
.brand img { height: 26px; width: auto; }
@media (min-width: 720px) { .brand img { height: 32px; } }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: transparent; color: var(--fg); border: 1px solid var(--line);
  border-radius: 8px; height: 42px; padding: 0 12px; font: inherit; font-size: var(--step--1); cursor: pointer;
}
.nav-toggle svg { width: 20px; height: 20px; }
.site-nav { display: none; }
.site-nav.open {
  display: block; position: absolute; left: 0; right: 0; top: 100%;
  background: var(--bg-2); border-bottom: 1px solid var(--line);
  padding: 8px max(16px, env(safe-area-inset-right, 0px)) 20px max(16px, env(safe-area-inset-left, 0px));
}
.site-nav ul { list-style: none; display: flex; flex-direction: column; gap: 2px; }
.site-nav a.nav-link {
  display: block; padding: 12px 4px; text-decoration: none; color: var(--fg-2);
  font-weight: 500; border-bottom: 1px solid var(--line-soft);
}
.site-nav a.nav-link[aria-current="page"] { color: var(--fg); }
.site-nav a.nav-link[aria-current="page"]::after {
  content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--green); margin-left: 8px; vertical-align: middle;
}
.site-nav .btn { margin-top: 16px; width: 100%; }

@media (min-width: 960px) {
  .nav-toggle { display: none; }
  .site-nav, .site-nav.open {
    display: flex; position: static; background: none; border: 0; padding: 0;
    align-items: center; gap: 28px;
  }
  .site-nav ul { flex-direction: row; gap: 26px; }
  .site-nav a.nav-link { padding: 6px 0; border: 0; position: relative; }
  .site-nav a.nav-link:hover { color: var(--fg); }
  .site-nav a.nav-link[aria-current="page"]::after {
    position: absolute; left: 0; right: 0; bottom: -2px; width: auto; height: 2px; border-radius: 2px; margin: 0;
    background: linear-gradient(90deg, var(--red), var(--green));
  }
  .site-nav .btn { margin-top: 0; width: auto; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 46px; padding: 0 20px; border-radius: 8px;
  font-family: var(--font-body); font-weight: 600; font-size: var(--step-0);
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: background-color .15s ease, border-color .15s ease, transform .15s ease;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn:active { transform: translateY(1px) scale(0.98); }
.btn-primary { background: var(--red-btn); color: #fff; box-shadow: 0 6px 18px -8px rgba(207,51,56,0.6); }
.btn-primary:hover { background: var(--red-btn-hover); }
.btn-ghost { background: transparent; color: var(--fg); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--muted); background: var(--surface); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: var(--step--1); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 420px) { .btn-row .btn { flex: 1 1 100%; } }

/* ---------- Generic sections ---------- */
.section { padding-block: clamp(56px, 8vw, 96px); }
.section + .section { border-top: 1px solid var(--line-soft); }
.section-alt { background: var(--bg-2); }
.eyebrow {
  font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--muted); display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow::before { content: ""; width: 18px; height: 2px; background: linear-gradient(90deg, var(--red), var(--green)); }
.section-head { display: grid; gap: 14px; max-width: 680px; margin-bottom: clamp(32px, 4vw, 48px); }
.section-head h2 { font-size: var(--step-3); }
.section-head p { color: var(--fg-2); font-size: var(--step-1); line-height: 1.6; }
.lead { color: var(--fg-2); font-size: var(--step-1); line-height: 1.6; max-width: 62ch; }
.text-link {
  display: inline-flex; align-items: center; gap: 8px; color: var(--fg); font-weight: 600;
  text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 5px; text-decoration-thickness: 2px;
}
.text-link:hover { text-decoration-color: var(--green); }
.text-link svg { width: 16px; height: 16px; }

/* chart grid texture */
.grid-bg {
  background-image:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 48px 48px;
  background-position: -1px -1px;
}

/* ---------- Page hero (inner pages) ---------- */
.page-hero { position: relative; padding-block: clamp(56px, 8vw, 96px) clamp(40px, 6vw, 72px); border-bottom: 1px solid var(--line-soft); overflow: hidden; }
.page-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent 40%, var(--bg) 100%);
}
.page-hero .wrap { position: relative; z-index: 1; display: grid; gap: 18px; }
.page-hero h1 { font-size: var(--step-4); max-width: 18ch; }

/* ---------- Home hero ---------- */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line-soft); }
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(520px 320px at 78% 40%, rgba(229,72,77,0.10), transparent 70%),
    radial-gradient(520px 320px at 92% 55%, rgba(48,194,122,0.09), transparent 70%),
    linear-gradient(180deg, transparent 55%, var(--bg) 100%);
}
.hero-grid {
  position: relative; z-index: 1;
  display: grid; gap: 40px; align-items: center;
  padding-block: clamp(48px, 7vw, 96px);
}
.hero-copy { display: grid; gap: 22px; min-width: 0; }
.hero h1 { font-size: var(--step-4); }
.hero h1 .accent-r { color: var(--red); }
.hero h1 .accent-g { color: var(--green); }
.hero-note { font-size: var(--step--1); color: var(--muted); display: flex; gap: 8px; align-items: flex-start; }
.hero-note svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 3px; }
.hero-visual { position: relative; }
.hero-visual img { width: 100%; max-width: 560px; margin-inline: auto; }
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.05fr 0.95fr; gap: 56px; }
}

/* ---------- Cards ---------- */
.cards { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .cards-2, .cards-4 { grid-template-columns: repeat(2, 1fr); } .cards-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .cards-4 { grid-template-columns: repeat(4, 1fr); } .cards-3 { grid-template-columns: repeat(3, 1fr); } }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; display: grid; gap: 12px; align-content: start; min-width: 0;
}
.card h3 { font-size: var(--step-1); }
.card p { color: var(--fg-2); font-size: 0.97rem; }
.card .meta { font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); letter-spacing: 0.04em; }
.icon-tile {
  width: 44px; height: 44px; border-radius: 9px; display: grid; place-items: center;
  border: 1px solid var(--line); background: var(--bg-2);
}
.icon-tile svg { width: 22px; height: 22px; }
.icon-tile.r { color: var(--red); background: var(--red-soft); border-color: rgba(229,72,77,0.25); }
.icon-tile.g { color: var(--green); background: var(--green-soft); border-color: rgba(48,194,122,0.25); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; }
.chips li {
  font-family: var(--font-mono); font-size: 0.78rem; padding: 3px 9px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--fg-2); background: var(--bg-2);
}

/* topic list (what you'll explore) */
.topic-grid { display: grid; gap: 0; grid-template-columns: 1fr; border-top: 1px solid var(--line); list-style: none; }
@media (min-width: 640px) { .topic-grid { grid-template-columns: repeat(2, 1fr); column-gap: 32px; } }
@media (min-width: 1000px) { .topic-grid { grid-template-columns: repeat(4, 1fr); } }
.topic-grid li {
  display: flex; align-items: center; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line);
  font-weight: 500;
}
.topic-grid .tick { width: 22px; height: 22px; color: var(--green); flex-shrink: 0; }

/* ---------- Learning path ---------- */
.path { display: grid; gap: 14px; list-style: none; counter-reset: step; }
@media (min-width: 860px) { .path { grid-template-columns: repeat(4, 1fr); gap: 0; } }
.path li { position: relative; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); display: grid; gap: 10px; align-content: start; }
@media (min-width: 860px) {
  .path li { border-radius: 0; border-right-width: 0; }
  .path li:first-child { border-radius: var(--radius) 0 0 var(--radius); }
  .path li:last-child { border-radius: 0 var(--radius) var(--radius) 0; border-right-width: 1px; }
  .path li:not(:last-child)::after {
    content: ""; position: absolute; right: -9px; top: 30px; width: 16px; height: 16px; z-index: 2;
    background: var(--surface); border-top: 1px solid var(--line); border-right: 1px solid var(--line);
    transform: rotate(45deg);
  }
}
.path .step-no { font-family: var(--font-mono); font-size: 0.8rem; color: var(--muted); letter-spacing: 0.08em; }
.path h3 { font-size: var(--step-1); }
.path p { color: var(--fg-2); font-size: 0.95rem; }
.path-note { margin-top: 18px; font-size: var(--step--1); color: var(--muted); }

/* ---------- Split / about preview ---------- */
.split { display: grid; gap: 40px; align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; gap: 64px; } }
.split > * { min-width: 0; }
.principles { display: grid; gap: 0; list-style: none; border-top: 1px solid var(--line); }
.principles li { display: grid; grid-template-columns: 44px 1fr; gap: 16px; padding: 20px 0; border-bottom: 1px solid var(--line); align-items: start; }
.principles h3 { font-size: var(--step-1); margin-bottom: 4px; }
.principles p { color: var(--fg-2); font-size: 0.97rem; }

/* ---------- CTA band ---------- */
.cta-band {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  padding: clamp(28px, 5vw, 56px);
  display: grid; gap: 24px; align-items: center;
}
.cta-band::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px;
  background: linear-gradient(90deg, var(--red) 0 50%, var(--green) 50% 100%);
}
.cta-band h2 { font-size: var(--step-3); }
.cta-band p { color: var(--fg-2); max-width: 56ch; }
@media (min-width: 860px) { .cta-band { grid-template-columns: 1fr auto; } }

/* ---------- Placeholder (owner to edit) ---------- */
.ph {
  display: inline-block; font-family: var(--font-mono); font-size: 0.86em; color: var(--focus);
  border: 1px dashed rgba(255, 209, 102, 0.45); border-radius: 5px; padding: 1px 7px; background: rgba(255,209,102,0.06);
}
.ph-block {
  border: 1px dashed rgba(255, 209, 102, 0.4); border-radius: var(--radius); padding: 22px;
  background: rgba(255,209,102,0.04); display: grid; gap: 8px;
}
.ph-block h3 { font-size: var(--step-1); }
.ph-block p { color: var(--fg-2); font-size: 0.95rem; }

/* ---------- Course page ---------- */
.course-layout { display: grid; gap: 40px; }
@media (min-width: 1000px) { .course-layout { grid-template-columns: minmax(0, 1fr) 320px; gap: 56px; align-items: start; } }
.index-summary { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-bottom: 20px; font-family: var(--font-mono); font-size: 0.85rem; color: var(--muted); }
.index-summary strong { color: var(--fg); font-weight: 600; }
.index-tools { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }

.course-index { list-style: none; display: grid; gap: 10px; }
.module {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.module-head, .module summary {
  display: grid; grid-template-columns: 52px 1fr auto; align-items: center; gap: 14px;
  padding: 16px 18px; min-height: 64px;
}
.module summary { cursor: pointer; list-style: none; }
.module summary::-webkit-details-marker { display: none; }
.module summary:hover { background: var(--surface-2); }
.mod-no {
  font-family: var(--font-mono); font-size: 0.85rem; color: var(--fg-2); font-weight: 500;
  border: 1px solid var(--line); border-radius: 6px; text-align: center; padding: 4px 0; background: var(--bg-2);
}
.mod-title { display: grid; gap: 2px; min-width: 0; }
.mod-title .label { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.mod-title h3 { font-size: 1.08rem; font-weight: 600; }
.mod-count { font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.mod-count svg { width: 18px; height: 18px; transition: transform .2s ease; }
.module[open] .mod-count svg { transform: rotate(180deg); }
.module[open] summary { border-bottom: 1px solid var(--line); }
.lessons { list-style: none; padding: 8px 18px 14px calc(18px + 52px + 14px); display: grid; }
.lessons li { display: flex; gap: 12px; align-items: baseline; padding: 9px 0; border-bottom: 1px dashed var(--line-soft); color: var(--fg-2); }
.lessons li:last-child { border-bottom: 0; }
.lessons .lno { font-family: var(--font-mono); font-size: 0.78rem; color: var(--muted); min-width: 36px; }
@media (max-width: 520px) {
  .module-head, .module summary { grid-template-columns: 42px 1fr auto; gap: 12px; padding: 14px; }
  .lessons { padding: 6px 14px 12px 14px; }
  .mod-count .txt { display: none; }
}

.side-card { position: sticky; top: calc(88px + env(safe-area-inset-top, 0px)); display: grid; gap: 16px; }
.facts { list-style: none; display: grid; border-top: 1px solid var(--line); }
.facts li { display: grid; gap: 4px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.facts .k { font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }

.risk-note {
  display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: var(--radius);
  border: 1px solid var(--line); background: var(--bg-2); color: var(--fg-2); font-size: 0.93rem;
}
.risk-note svg { width: 20px; height: 20px; color: var(--focus); flex-shrink: 0; margin-top: 2px; }

/* chart figure */
.chart-figure { margin: 0; display: grid; gap: 14px; }
.chart-frame {
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px;
}
.chart-frame-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 4px 6px 10px; font-family: var(--font-mono); font-size: 0.75rem; color: var(--muted); letter-spacing: 0.04em;
}
.chart-frame-bar .dots { display: inline-flex; gap: 6px; }
.chart-frame-bar .dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--line); display: block; }
.chart-frame img { width: 100%; border-radius: 6px; background: #000; }
.chart-figure figcaption { display: grid; gap: 4px; }
.chart-figure figcaption strong { font-family: var(--font-display); font-weight: 600; font-size: var(--step-1); }
.chart-figure figcaption span { color: var(--muted); font-size: var(--step--1); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: 32px; }
@media (min-width: 900px) { .contact-grid { grid-template-columns: 0.9fr 1.1fr; gap: 56px; align-items: start; } }
.contact-grid > * { min-width: 0; }
.contact-list { list-style: none; display: grid; gap: 12px; }
.contact-item { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: center; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.contact-item .k { font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); display: block; }
.form-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: clamp(20px, 4vw, 36px); display: grid; gap: 20px; }
.form-card h2 { font-size: var(--step-2); }
.field { display: grid; gap: 8px; }
.field label { font-weight: 600; font-size: 0.95rem; }
.field .hint { font-size: var(--step--1); color: var(--muted); }
.field input, .field textarea {
  width: 100%; font: inherit; color: var(--fg); background: var(--bg-2);
  border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; min-height: 48px;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:hover, .field textarea:hover { border-color: #3a4144; }
.field input:focus-visible, .field textarea:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; border-color: transparent; }
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-color: var(--red); }
.field .error { color: #ff8a8d; font-size: var(--step--1); display: flex; gap: 6px; align-items: center; }
.field .error svg { width: 14px; height: 14px; }
.form-success {
  display: grid; gap: 10px; padding: 22px; border-radius: var(--radius);
  border: 1px solid rgba(48,194,122,0.35); background: var(--green-soft);
}
.form-success h3 { display: flex; gap: 10px; align-items: center; font-size: var(--step-1); }
.form-success svg { width: 22px; height: 22px; color: var(--green); }
.form-success p { color: var(--fg-2); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--bg-2); padding-block: 56px 32px; margin-top: 0; }
.footer-grid { display: grid; gap: 32px; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1.2fr; gap: 48px; } }
.footer-grid > * { min-width: 0; }
.footer-brand img { height: 28px; width: auto; }
.footer-brand p { margin-top: 14px; color: var(--muted); font-size: var(--step--1); max-width: 36ch; }
.footer-title { font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.footer-links { list-style: none; display: grid; gap: 8px; }
.footer-links a { text-decoration: none; color: var(--fg-2); }
.footer-links a:hover { color: var(--fg); text-decoration: underline; text-underline-offset: 4px; }
.footer-contact { list-style: none; display: grid; gap: 8px; color: var(--fg-2); font-size: 0.95rem; }
.footer-contact .k { color: var(--muted); }
.disclaimer {
  margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line);
  display: grid; gap: 10px; color: var(--muted); font-size: var(--step--1);
}
.disclaimer strong { color: var(--fg-2); font-weight: 600; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ---------- v2 additions ---------- */
:root { --wa: #1fa855; --wa-hover: #188a45; }
.btn-wa { background: var(--wa); color: #fff; }
.btn-wa:hover { background: var(--wa-hover); }
.btn-wa svg { width: 20px; height: 20px; }

.wa-fab {
  position: fixed; z-index: 45;
  right: calc(16px + env(safe-area-inset-right, 0px));
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  display: inline-flex; align-items: center; gap: 10px;
  height: 52px; padding: 0 18px 0 14px; border-radius: 999px;
  background: var(--wa); color: #fff; text-decoration: none; font-weight: 600;
  box-shadow: 0 10px 28px -10px rgba(0,0,0,0.7), 0 0 0 1px rgba(255,255,255,0.08) inset;
  transition: background-color .15s ease, transform .15s ease;
}
.wa-fab:hover { background: var(--wa-hover); transform: translateY(-2px); }
.wa-fab:active { transform: scale(0.97); }
.wa-fab svg { width: 24px; height: 24px; }
@media (max-width: 560px) { .wa-fab { width: 54px; height: 54px; padding: 0; justify-content: center; } .wa-fab .txt { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); } }

/* reveal: content is visible by default; JS only animates sections that start below the fold */
.reveal-armed .reveal { opacity: 0; transform: translateY(14px); }
.reveal-armed .reveal.in { opacity: 1; transform: none; transition: opacity .5s ease, transform .5s ease; }
@media (prefers-reduced-motion: reduce) { .reveal-armed .reveal { opacity: 1; transform: none; } }

.card { transition: border-color .2s ease, transform .2s ease; }
a.card { text-decoration: none; color: inherit; }
a.card:hover { border-color: #3c4447; transform: translateY(-2px); }

/* hero with chart */
.hero-chart .chart-frame { box-shadow: 0 30px 60px -30px rgba(0,0,0,0.8); }
.hero-chart figcaption strong { font-size: 1rem; }
@media (min-width: 900px) { .hero-grid.hero-grid-chart { grid-template-columns: 0.9fr 1.1fr; } }

/* setups preview */
.setup-card .chips { margin-top: 2px; }
.setup-card ol.mini { list-style: none; display: grid; gap: 6px; }
.setup-card ol.mini li { display: flex; gap: 10px; color: var(--fg-2); font-size: 0.95rem; }
.setup-card ol.mini li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--green); margin-top: 0.6em; flex-shrink: 0; }

/* comparison */
.compare { display: grid; gap: 14px; }
.compare-row {
  display: grid; gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.compare-row > h3 {
  font-family: var(--font-mono); font-weight: 500; font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted); padding: 14px 18px; border-bottom: 1px solid var(--line); background: var(--bg-2);
}
.compare-cells { display: grid; grid-template-columns: 1fr; }
.compare-cell { padding: 16px 18px; display: grid; gap: 6px; min-width: 0; }
.compare-cell + .compare-cell { border-top: 1px solid var(--line-soft); }
.compare-cell .who { font-family: var(--font-display); font-weight: 600; font-size: 0.95rem; display: inline-flex; align-items: center; gap: 8px; }
.compare-cell .who::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--muted); }
.compare-cell.bbma { background: linear-gradient(180deg, rgba(48,194,122,0.06), transparent); }
.compare-cell.bbma .who::before { background: var(--green); }
.compare-cell p { color: var(--fg-2); font-size: 0.95rem; }
@media (min-width: 860px) {
  .compare-cells { grid-template-columns: 1.15fr 1fr 1fr; }
  .compare-cell + .compare-cell { border-top: 0; border-left: 1px solid var(--line-soft); }
}
.compare-foot { margin-top: 22px; display: grid; gap: 12px; max-width: 760px; color: var(--fg-2); }

/* trainer */
.trainer { display: grid; gap: 32px; align-items: center; }
@media (min-width: 900px) { .trainer { grid-template-columns: 1.05fr 0.95fr; gap: 56px; } }
.trainer > * { min-width: 0; }
.trainer-photo { margin: 0; position: relative; }
.trainer-photo img { width: 100%; border-radius: 14px; border: 1px solid var(--line); }
.trainer-photo::after {
  content: ""; position: absolute; left: 18px; right: 18px; bottom: -1px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, var(--red) 0 50%, var(--green) 50% 100%);
}
.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; display: grid; gap: 2px; }
.stat .num { font-family: var(--font-display); font-weight: 700; font-size: 2rem; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat .num small { font-size: 1rem; font-weight: 600; color: var(--fg-2); margin-left: 4px; }
.stat .lbl { color: var(--fg-2); font-size: 0.92rem; }
.role-tag { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: 0.8rem; color: var(--fg-2); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; width: fit-content; }
.role-tag::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.support-list { list-style: none; display: grid; gap: 0; border-top: 1px solid var(--line); }
.support-list li { display: grid; grid-template-columns: 26px 1fr; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--fg-2); }
.support-list .tick { width: 22px; height: 22px; color: var(--green); margin-top: 2px; }

/* contact v2 */
.contact-item a { color: var(--fg); font-weight: 600; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 4px; overflow-wrap: anywhere; }
.contact-item a:hover { text-decoration-color: var(--green); }
.contact-item .sub { display: block; font-size: var(--step--1); color: var(--muted); }
.wa-ready { display: grid; gap: 12px; padding: 22px; border-radius: var(--radius); border: 1px solid rgba(31,168,85,0.4); background: rgba(31,168,85,0.08); }
.wa-ready h3 { font-size: var(--step-1); display: flex; gap: 10px; align-items: center; }
.wa-ready h3 svg { width: 22px; height: 22px; color: var(--wa); }
.wa-ready p { color: var(--fg-2); }
.wa-preview { font-family: var(--font-mono); font-size: 0.82rem; white-space: pre-wrap; background: var(--bg-2); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; color: var(--fg-2); overflow-wrap: anywhere; }
.form-note { font-size: var(--step--1); color: var(--muted); display: flex; gap: 8px; align-items: flex-start; }
.form-note svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 3px; color: var(--wa); }

.footer-contact a { color: var(--fg-2); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 4px; }
.footer-contact a:hover { color: var(--fg); }
.disclaimer p { max-width: 90ch; }
.site-footer { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }

/* ---------- v3: motion + comparison ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes logoIn { from { opacity: 0; transform: scale(.94) translateY(12px); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes floatY { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes glowPulse { 0%, 100% { opacity: .55; transform: scale(1); } 50% { opacity: .85; transform: scale(1.06); } }
@keyframes drawLine { to { stroke-dashoffset: 0; } }
@keyframes candleUp { from { transform: scaleY(0); opacity: 0; } to { transform: scaleY(1); opacity: 1; } }
@keyframes sweep { from { transform: translateX(-120%); } to { transform: translateX(220%); } }

.anim-in { animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) both; animation-delay: calc(var(--i, 0) * 90ms + 80ms); }

.hero-line { position: absolute; inset: auto 0 0 0; width: 100%; height: 70%; z-index: 0; pointer-events: none; opacity: .5; }
.hero-line path { fill: none; stroke: var(--green); stroke-width: 2; stroke-dasharray: 2400; stroke-dashoffset: 2400; animation: drawLine 2.6s ease-out .5s forwards; opacity: .35; }

.logo-stage { position: relative; display: grid; place-items: center; min-height: 260px; }
.logo-glow { position: absolute; inset: 10% 8%; border-radius: 50%; z-index: 0;
  background: radial-gradient(closest-side at 35% 50%, rgba(229,72,77,.28), transparent 70%), radial-gradient(closest-side at 65% 50%, rgba(48,194,122,.24), transparent 70%);
  filter: blur(30px); animation: glowPulse 7s ease-in-out infinite 1.2s; }
.logo-float { position: relative; z-index: 2; animation: logoIn 1.1s cubic-bezier(.2,.7,.2,1) .25s both, floatY 7s ease-in-out 1.6s infinite; }
.hero-ticker { position: absolute; z-index: 1; left: 6%; right: 6%; bottom: 4%; height: 38%; display: flex; align-items: flex-end; justify-content: space-between; opacity: .22; }
.hero-ticker i { display: block; width: 6%; height: var(--h); border-radius: 2px; transform-origin: bottom; animation: candleUp .6s cubic-bezier(.2,.7,.2,1) both; animation-delay: calc(var(--d) + .4s); }
.hero-ticker i.g { background: var(--green); }
.hero-ticker i.r { background: var(--red); }

.hero-facts { list-style: none; display: flex; flex-wrap: wrap; gap: 10px 28px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.hero-facts li { display: flex; align-items: baseline; gap: 8px; color: var(--fg-2); font-size: .92rem; }
.hero-facts .num { font-family: var(--font-display); font-weight: 700; font-size: 1.6rem; color: var(--fg); font-variant-numeric: tabular-nums; min-width: 1.2ch; }

/* button shine */
.btn-primary, .btn-wa { position: relative; overflow: hidden; }
.btn-primary::after, .btn-wa::after { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 40%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.22), transparent); transform: translateX(-120%); pointer-events: none; }
.btn-primary:hover::after, .btn-wa:hover::after { animation: sweep .8s ease; }

/* header on scroll */
.site-header { transition: background-color .25s ease, box-shadow .25s ease; }
.site-header.scrolled { background: rgba(13,14,15,0.97); box-shadow: 0 8px 24px -16px rgba(0,0,0,.9); }

/* staggered children */
.reveal-armed .stagger > * { opacity: 0; transform: translateY(16px); }
.reveal-armed .stagger.in > * { opacity: 1; transform: none; transition: opacity .55s ease, transform .55s cubic-bezier(.2,.7,.2,1), border-color .2s ease; transition-delay: calc(var(--si, 0) * 90ms); }
.reveal-armed .stagger.reveal { opacity: 1; transform: none; }

/* chart sweep once revealed */
.chart-frame { position: relative; overflow: hidden; }
.chart-frame::after { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 30%; pointer-events: none; background: linear-gradient(100deg, transparent, rgba(255,255,255,.07), transparent); transform: translateX(-120%); }
.reveal-armed .chart-reveal.in .chart-frame::after, .hero-chart .chart-frame::after { animation: sweep 1.6s ease .3s 1 both; }
.reveal-armed .chart-reveal .chart-frame { transform: scale(.98); transition: transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal-armed .chart-reveal.in .chart-frame { transform: none; }

/* comparison v3 */
.vs-grid { display: grid; gap: 16px; }
@media (min-width: 1000px) { .vs-grid { grid-template-columns: 1fr 1fr; } }
.vs-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; display: grid; grid-template-rows: auto 1fr auto; min-width: 0; transition: border-color .2s ease, transform .2s ease; }
.vs-card:hover { border-color: #3c4447; }
.vs-head { display: flex; align-items: center; gap: 14px; padding: 16px 20px; border-bottom: 1px solid var(--line); background: var(--bg-2); }
.vs-no { font-family: var(--font-mono); font-size: .8rem; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 2px 8px; }
.vs-head h3 { font-size: 1.08rem; }
.vs-cols { display: grid; grid-template-columns: 1fr; }
@media (min-width: 560px) { .vs-cols { grid-template-columns: 1fr 1fr; } .vs-col + .vs-col { border-left: 1px solid var(--line-soft); } }
@media (max-width: 559px) { .vs-col + .vs-col { border-top: 1px solid var(--line-soft); } }
.vs-col { padding: 16px 20px; display: grid; gap: 10px; align-content: start; min-width: 0; }
.vs-col .who { font-family: var(--font-mono); font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; }
.vs-col .who::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--muted); }
.vs-col.bbma { background: linear-gradient(180deg, rgba(48,194,122,0.07), transparent 70%); }
.vs-col.bbma .who { color: var(--green); }
.vs-col.bbma .who::before { background: var(--green); }
.vs-col ul { list-style: none; display: grid; gap: 8px; }
.vs-col li { color: var(--fg-2); font-size: .94rem; padding-left: 16px; position: relative; }
.vs-col li::before { content: ""; position: absolute; left: 0; top: .65em; width: 6px; height: 2px; background: var(--muted); }
.vs-col.bbma li::before { background: var(--green); }
.vs-take { padding: 14px 20px; border-top: 1px solid var(--line); display: grid; gap: 4px; color: var(--fg); font-size: .95rem; }
.vs-take span { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--red); }
.why-bbma { margin-top: 28px; display: grid; gap: 28px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: clamp(22px, 4vw, 40px); position: relative; overflow: hidden; }
.why-bbma::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--red) 0 50%, var(--green) 50% 100%); }
.why-bbma h3 { font-size: var(--step-2); }
.why-bbma p { color: var(--fg-2); }
.why-bbma .why-line { color: var(--fg); font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; }
@media (min-width: 900px) { .why-bbma { grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; } }

@media (prefers-reduced-motion: reduce) {
  .hero-line path { stroke-dashoffset: 0; }
  .reveal-armed .stagger > *, .reveal-armed .chart-reveal .chart-frame { opacity: 1; transform: none; }
}

/* ---------- v4: offer, FAQ, testimonials, extra motion ---------- */
.scroll-progress { position: fixed; z-index: 70; left: 0; right: 0; top: env(safe-area-inset-top, 0px); height: 2px; pointer-events: none; }
.scroll-progress span { display: block; height: 100%; width: 100%; transform-origin: left; transform: scaleX(var(--p, 0)); background: linear-gradient(90deg, var(--red), var(--green)); }

/* eyebrow line grows in */
.reveal-armed .reveal .eyebrow::before { width: 0; transition: width .6s ease .15s; }
.reveal-armed .reveal.in .eyebrow::before { width: 18px; }

/* icon micro-interaction */
.card .icon-tile, .vs-card .vs-no { transition: transform .3s cubic-bezier(.2,.7,.2,1); }
.card:hover .icon-tile { transform: translateY(-3px) rotate(-6deg); }
.card:hover { border-color: #3c4447; }

/* free offer */
@keyframes borderSpin { to { --ang: 360deg; } }
@property --ang { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
.offer {
  position: relative; display: grid; gap: 32px; padding: clamp(24px, 5vw, 52px); border-radius: 16px;
  background: linear-gradient(var(--surface), var(--surface)) padding-box,
              conic-gradient(from var(--ang), var(--red), transparent 30%, var(--green) 50%, transparent 80%, var(--red)) border-box;
  border: 1px solid transparent; animation: borderSpin 8s linear infinite;
}
@media (min-width: 900px) { .offer { grid-template-columns: 1.1fr 0.9fr; align-items: center; gap: 56px; } }
.offer > * { min-width: 0; }
.offer-copy { display: grid; gap: 18px; }
.offer-copy h2 { font-size: var(--step-4); }
.offer-copy p { color: var(--fg-2); font-size: var(--step-1); line-height: 1.6; max-width: 54ch; }
.offer-copy strong { color: var(--fg); }
.offer-badge { width: fit-content; font-family: var(--font-mono); font-size: .76rem; letter-spacing: .12em; text-transform: uppercase; color: #06150d; background: var(--green); border-radius: 999px; padding: 5px 12px; font-weight: 500; }
.offer-note { font-size: var(--step--1) !important; color: var(--muted) !important; }
.offer-steps { list-style: none; display: grid; gap: 12px; position: relative; }
.offer-steps li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; padding: 16px; border-radius: var(--radius); background: var(--bg-2); border: 1px solid var(--line); }
.offer-steps strong { font-family: var(--font-display); font-size: 1.08rem; display: block; margin-bottom: 2px; }
.offer-steps p { color: var(--fg-2); font-size: .94rem; }
.os-no { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; border: 1px solid var(--line); background: var(--surface); color: var(--fg); }
.offer-steps li:nth-child(1) .os-no { border-color: rgba(229,72,77,.5); color: var(--red); }
.offer-steps li:nth-child(3) .os-no { border-color: rgba(48,194,122,.5); color: var(--green); }

/* FAQ */
.faq-layout { display: grid; gap: 32px; }
@media (min-width: 960px) { .faq-layout { grid-template-columns: 0.8fr 1.2fr; gap: 56px; align-items: start; } .faq-layout .section-head { position: sticky; top: calc(96px + env(safe-area-inset-top, 0px)); } }
.faq-layout > * { min-width: 0; }
.faq-list { display: grid; gap: 10px; }
.faq-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .2s ease, background-color .2s ease; }
.faq-item[open] { border-color: #3c4447; background: var(--surface-2); }
.faq-item summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 20px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary h3 { font-size: 1.04rem; font-weight: 600; }
.faq-icon { width: 22px; height: 22px; flex-shrink: 0; position: relative; border: 1px solid var(--line); border-radius: 50%; }
.faq-icon::before, .faq-icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 2px; background: var(--fg-2); transform: translate(-50%, -50%); transition: transform .25s ease; }
.faq-icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq-item[open] .faq-icon::after { transform: translate(-50%, -50%) rotate(0deg); }
.faq-item[open] .faq-icon { border-color: var(--green); }
.faq-body { padding: 0 20px 18px; color: var(--fg-2); max-width: 70ch; }
.faq-item[open] .faq-body { animation: fadeUp .35s ease both; }

/* testimonials (shown only when real entries exist) */
.t-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.t-card { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: grid; gap: 16px; }
.t-card blockquote { margin: 0; color: var(--fg); font-size: 1.02rem; }
.t-card figcaption { display: grid; color: var(--muted); font-size: .9rem; }
.t-card figcaption strong { color: var(--fg); }

/* hero: subtle parallax hook */
.logo-stage { transition: transform .2s ease-out; will-change: transform; }

@media (prefers-reduced-motion: reduce) {
  .offer { animation: none; }
  .reveal-armed .reveal .eyebrow::before { width: 18px; }
}

/* ---------- v5: mobile refinements (desktop unchanged) ---------- */
[id] { scroll-margin-top: calc(84px + env(safe-area-inset-top, 0px)); }
.chart-hint { display: none; }
@media (max-width: 999px) { .side-card { position: static; } }

@media (max-width: 899px) {
  .hero-grid { gap: 12px; padding-block: 24px 48px; }
  .hero-visual { order: -1; }
  .logo-stage { min-height: 0; padding-top: 4px; }
  .logo-float { width: 86%; max-width: 340px; }
  .hero-ticker { bottom: 8%; height: 34%; }
  .hero-copy { gap: 18px; }
  .hero h1 { font-size: clamp(2rem, 8.6vw, 2.75rem); }
}

@media (max-width: 640px) {
  .header-row { min-height: 60px; }
  .nav-toggle { height: 40px; }
  .site-nav.open { max-height: calc(100vh - 60px); overflow-y: auto; }
  .site-nav a.nav-link { padding: 14px 4px; font-size: 1.05rem; }

  .section { padding-block: 52px; }
  .page-hero { padding-block: 40px 32px; }
  .page-hero h1 { font-size: clamp(1.9rem, 8.4vw, 2.5rem); }
  .section-head { margin-bottom: 26px; gap: 12px; }
  .section-head h2, .cta-band h2, .split h2, .trainer h2 { font-size: 1.7rem !important; }
  .lead, .section-head p, .offer-copy p { font-size: 1.02rem; }
  .hero .lead { font-size: 1.04rem; }
  .hero-note { font-size: .84rem; }

  .btn-row .btn { flex: 1 1 100%; }
  .btn { min-height: 50px; }
  .index-tools .btn { flex: 1 1 0; }

  .card { padding: 20px; }
  .path li { padding: 18px; }
  .cta-band, .why-bbma, .offer { padding: 22px 18px; border-radius: 14px; }
  .offer-copy h2 { font-size: 2.2rem; }
  .offer-steps li { padding: 14px; grid-template-columns: 40px 1fr; }
  .os-no { width: 40px; height: 40px; }

  .vs-head { padding: 14px 16px; }
  .vs-col { padding: 14px 16px; }
  .vs-take { padding: 12px 16px; }
  .faq-item summary { padding: 16px; }
  .faq-body { padding: 0 16px 16px; }

  .chart-frame { padding: 8px; }
  .chart-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: 6px; scrollbar-width: thin; }
  .chart-scroll img { min-width: 640px; }
  .chart-hint { display: block; font-family: var(--font-mono); font-size: .76rem; color: var(--muted); padding: 8px 4px 2px; }

  .contact-item { padding: 14px; }
  .form-card { padding: 20px 16px; }

  .footer-grid { gap: 24px; }
  .footer-links { gap: 0; }
  .footer-links a { display: block; padding: 9px 0; }
  .footer-contact { gap: 4px; }
  .footer-contact li { padding: 4px 0; }

  .wa-fab { width: 52px; height: 52px; right: calc(14px + env(safe-area-inset-right, 0px)); bottom: calc(14px + env(safe-area-inset-bottom, 0px)); }
}
