/* ============================================================
   landing-preview.html — standalone CRED-inspired redesign.
   Dark-only design system, scoped entirely to this file; does not
   touch style.css or any class name used there, so it can never
   collide with index.html/story.html's own theme.
   ============================================================ */

:root {
  --bg: #0A0A0A;
  --surface: #141414;
  --line: #262626;
  --text: #F5F5F5;
  --muted: #8C8C8C;
  --gold: #E3A72F;
  --green: #06C270;
  --red: #E5484D;
  --wrap: 1120px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
.lp-root { min-height: 100vh; }

.lp-mono { font-family: 'JetBrains Mono', monospace; }
.lp-disp { font-family: 'Fraunces', Georgia, serif; }

.lp-wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 900px) {
  .lp-wrap { padding: 0 40px; }
}

a { color: inherit; }
.lp-gold { color: var(--gold); }
.lp-muted { color: var(--muted); }

/* ---------- Reveal-on-scroll, progressive enhancement only.
   Default (no JS, or JS present but reduced-motion requested) =
   fully visible, zero special styling. The hidden starting state
   only exists under html.js AND prefers-reduced-motion: no-preference
   -- so content can never be stuck invisible for a crawler, a
   no-JS browser, print, or a screenshot that doesn't scroll. */
@media (prefers-reduced-motion: no-preference) {
  html.js .lp-reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity .7s ease, transform .7s ease;
  }
  html.js .lp-reveal.lp-in-view {
    opacity: 1;
    transform: none;
  }
}

/* ---------- Top bar: 72px tall, fixed height (not padding-derived)
   so it's exactly 72px at every breakpoint; shares .lp-wrap with the
   hero so its left edge and max-width always line up with the hero
   text above/below it. ---------- */
.lp-topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.lp-topbar-row {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.lp-wordmark { font-family: 'Fraunces', Georgia, serif; font-weight: 600; font-size: 19px; letter-spacing: -0.01em; }
.lp-wordmark-hold { color: var(--gold); }
.lp-nav-right { display: flex; align-items: center; gap: 18px; }
.lp-login-link { font-size: 14px; color: var(--text); text-decoration: none; }
.lp-login-link:hover { color: var(--gold); }

/* ---------- Buttons: NeoPOP-style pop, pure CSS ---------- */
.lp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
  border-radius: 0;
  padding: 13px 24px;
  transition: transform .12s ease, box-shadow .12s ease;
  white-space: nowrap;
}
.lp-btn-primary {
  background: #FFFFFF;
  color: #000000;
  border: none;
  box-shadow: 4px 4px 0 var(--gold);
}
.lp-btn-primary:active {
  transform: translate(4px, 4px);
  box-shadow: 0 0 0 var(--gold);
}
.lp-btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--text);
  box-shadow: none;
}
.lp-btn-secondary:active {
  transform: translate(4px, 4px);
}
.lp-btn-sm { padding: 9px 16px; font-size: 13px; }

/* ---------- Hero: single column under 1024px (chart falls under the
   buttons, full width); 2-column (text ~55% / visual ~45%, vertically
   centred) at 1024px+. min-height is viewport minus the topbar's own
   fixed 72px, so topbar + hero together fill exactly one screen --
   modest padding instead of the old 120px top gap, so headline and
   chart sit centred in the first screen on a 1440x900 viewport.

   display:grid + place-items:center (not flex+align-items:center)
   on purpose -- a flex container centering a single auto-width child
   via flex-item sizing rules does NOT reliably reproduce plain block
   margin:auto centering (confirmed live: it put the steps' own .lp-wrap
   ~276px off from the hero's, even though both used the identical
   .lp-wrap class). Grid's place-items:center centers a child at its
   own natural (here, max-width-bounded) size exactly the same way
   block margin:0 auto does, so .lp-split-row below is reused
   byte-identical between the hero and every step section and their
   left edges are therefore guaranteed to match, not just expected to. ---------- */
.lp-hero {
  min-height: calc(100vh - 72px);
  display: grid;
  place-items: center;
  padding: 36px 0;
}
.lp-split-row { display: flex; flex-direction: column; gap: 36px; width: 100%; }
@media (min-width: 1024px) {
  .lp-split-row { flex-direction: row; align-items: center; gap: 0; }
  .lp-split-text { flex: 0 0 55%; max-width: 55%; padding-right: 32px; }
  .lp-split-visual { flex: 0 0 45%; max-width: 45%; }
}
.lp-eyebrow {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 18px;
}
.lp-h1 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: clamp(32px, 6vw, 56px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0 0 20px;
  max-width: 620px;
}
.lp-sub {
  font-size: 16px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 480px;
  margin: 0 0 28px;
}
.lp-hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Hero chart: SVG lines only (no text) layered under
   plain-HTML labels. Labels are real Inter 12px DOM elements
   positioned by percentage of the chart box, NOT SVG <text> -- SVG
   text would scale down with the viewBox at mobile widths and become
   illegible; percentage-positioned HTML labels stay a true 12px at
   every screen size. ---------- */
.lp-hero-chart { position: relative; width: 100%; aspect-ratio: 560 / 320; }
.lp-hero-chart svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

.lp-line-path { fill: none; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
/* Self-contained (fill/width/cap included, not just color) so these
   two also work standalone -- e.g. the 03 step's mini chart reuses
   .lp-line-gold without the hero-only .lp-line-path draw-animation
   base, since that small static visual only needs the parent
   .lp-reveal fade-in, not its own per-path stroke-draw. */
.lp-line-white { fill: none; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; stroke: var(--text); }
.lp-line-gold { fill: none; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; stroke: var(--gold); }
.lp-line-grey {
  fill: none;
  stroke: #5A5A5A;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 6 5;
}
@media (prefers-reduced-motion: no-preference) {
  .lp-line-path {
    stroke-dasharray: 100;
    stroke-dashoffset: 100;
    animation: lp-draw 1s ease forwards;
  }
  .lp-line-1 { animation-delay: .1s; }
  .lp-line-3 { animation-delay: 1.0s; }
  .lp-line-4 { animation-delay: 1.9s; }
  .lp-line-grey { opacity: 0; animation: lp-fade-in .6s ease forwards; animation-delay: 1.1s; }
  .lp-dot { opacity: 0; animation: lp-dot-pop .4s ease forwards; }
  .lp-dot-1 { animation-delay: 1.0s; }
  .lp-dot-2 { animation-delay: 1.9s; }
}
.lp-dot { fill: var(--gold); opacity: 1; }
.lp-dot-white { fill: var(--text); }
@keyframes lp-draw { to { stroke-dashoffset: 0; } }
@keyframes lp-fade-in { to { opacity: 1; } }
@keyframes lp-dot-pop { from { opacity: 0; transform: scale(0.3); } to { opacity: 1; transform: scale(1); } }

.lp-chart-label {
  position: absolute;
  transform: translate(-50%, -50%);
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  line-height: 1.35;
  color: var(--muted);
  max-width: 108px;
  pointer-events: none;
}
/* trend-breaks sits below-LEFT of its dot: the incoming white line
   arrives from the upper-left and the two outgoing lines both head
   right, so lower-left is the one quadrant around that point no line
   ever crosses. */
.lp-chart-label-break { transform: translate(-108%, 15%); text-align: right; }
.lp-chart-label-gold { color: var(--gold); transform: translate(-50%, -175%); text-align: center; }
.lp-chart-label-grey { color: #5A5A5A; transform: translate(-28%, 35%); text-align: left; max-width: 100px; }
.lp-chart-label-heals { transform: translate(-8%, 45%); text-align: left; max-width: 118px; }
@media (max-width: 480px) {
  .lp-chart-label { font-size: 11px; max-width: 92px; }
  .lp-chart-label-break { max-width: 80px; }
  .lp-chart-label-grey { max-width: 84px; }
  .lp-chart-label-heals { max-width: 96px; }
}

/* ---------- Step visuals (01/02/03 side SVGs) -- same thin-line /
   dot / bar language as the hero chart, white+grey+gold only. ---------- */
.lp-step-visual svg { width: 100%; height: auto; display: block; }
.lp-dim-dot { fill: #3A3A3A; }
.lp-lit-dot { fill: var(--text); }
.lp-bar-grey { fill: #3A3A3A; }
.lp-bar-gold { fill: var(--gold); }

/* ---------- Steps (70vh, not 100vh) -- grid+place-items:center, same
   reasoning as .lp-hero above, so each step's .lp-wrap lines up with
   the hero's exactly. Text/visual split reuses .lp-split-row/-text/
   -visual byte-for-byte. ---------- */
.lp-step {
  min-height: 70vh;
  display: grid;
  place-items: center;
  border-top: 1px solid var(--line);
  padding: 56px 0;
}
.lp-step-text-inner { display: flex; flex-direction: column; gap: 18px; }
.lp-step-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: clamp(56px, 13vw, 110px);
  font-weight: 500;
  line-height: 1;
  color: var(--gold);
}
.lp-step-num .lp-muted { font-size: 0.45em; vertical-align: top; margin-left: 6px; }
.lp-step-title {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: clamp(26px, 4.5vw, 42px);
  line-height: 1.15;
  margin: 0;
}
.lp-step-body { font-size: 16px; line-height: 1.65; color: var(--muted); max-width: 480px; }

/* ---------- Proof ---------- */
.lp-proof {
  padding: 100px 0;
  border-top: 1px solid var(--line);
  text-align: center;
}
.lp-proof-group-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 20px;
}
.lp-proof-stats { display: flex; flex-wrap: wrap; justify-content: center; gap: 56px; margin-bottom: 36px; }
.lp-proof-stat-num {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: clamp(44px, 9vw, 84px);
  line-height: 1;
  color: var(--text);
}
.lp-proof-stat-num.lp-gold { color: var(--gold); }
.lp-proof-stat-cap { font-size: 13.5px; color: var(--muted); max-width: 320px; margin: 10px auto 0; line-height: 1.55; }
.lp-proof-honest {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13.5px;
  color: var(--red);
  margin: 28px 0 8px;
}
/* Same mono voice as .lp-proof-honest, but for a plain methodology note
   (e.g. "live, not backtested") rather than a worst-case disclosure --
   red there means "pay attention, this is the downside"; this note
   isn't cautionary, so it stays muted instead. */
.lp-proof-note {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13.5px;
  color: var(--muted);
  margin: 28px 0 8px;
}
.lp-proof-link { font-size: 14px; color: var(--gold); text-decoration: none; border-bottom: 1px solid rgba(227,167,47,0.4); }
.lp-proof-link:hover { border-color: var(--gold); }

/* ---------- What you get ---------- */
.lp-features { padding: 100px 0; border-top: 1px solid var(--line); }
.lp-section-title {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: clamp(26px, 4.5vw, 38px);
  margin: 0 0 48px;
}
.lp-feature-grid { display: grid; grid-template-columns: 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); }
@media (min-width: 740px) { .lp-feature-grid { grid-template-columns: 1fr 1fr; } }
.lp-feature-card { background: var(--surface); padding: 32px; display: flex; flex-direction: column; gap: 16px; }
.lp-feature-icon { width: 28px; height: 28px; color: var(--gold); }
.lp-feature-title { font-size: 16px; font-weight: 700; margin: 0; }
.lp-feature-body { font-size: 14px; line-height: 1.6; color: var(--muted); margin: 0; }

/* ---------- Trust ---------- */
.lp-trust { padding: 100px 0; border-top: 1px solid var(--line); }
.lp-trust-points { display: grid; grid-template-columns: 1fr; gap: 20px; margin: 40px 0 44px; }
@media (min-width: 740px) { .lp-trust-points { grid-template-columns: 1fr 1fr; } }
.lp-trust-point { display: flex; gap: 14px; align-items: flex-start; }
.lp-trust-check { width: 20px; height: 20px; flex-shrink: 0; margin-top: 2px; color: var(--green); }
.lp-trust-text { font-size: 15px; line-height: 1.5; color: var(--text); }
.lp-trust-links { display: flex; gap: 20px; flex-wrap: wrap; font-size: 14px; }
.lp-trust-links a { color: var(--muted); text-decoration: underline; text-decoration-color: var(--line); }
.lp-trust-links a:hover { color: var(--gold); text-decoration-color: var(--gold); }

/* ---------- FAQ ---------- */
.lp-faq { padding: 100px 0; border-top: 1px solid var(--line); }
.lp-faq-list { display: flex; flex-direction: column; gap: 1px; background: var(--line); border: 1px solid var(--line); margin-top: 40px; }
.lp-faq-item { background: var(--bg); }
.lp-faq-item summary {
  padding: 20px 4px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.lp-faq-item summary::-webkit-details-marker { display: none; }
.lp-faq-item summary::after {
  content: '+';
  font-family: 'JetBrains Mono', monospace;
  color: var(--gold);
  font-size: 18px;
  margin-left: 16px;
  flex-shrink: 0;
}
.lp-faq-item[open] summary::after { content: '\2212'; }
.lp-faq-body { padding: 0 4px 22px; font-size: 14px; line-height: 1.6; color: var(--muted); }

/* ---------- Final CTA ---------- */
.lp-final-cta {
  padding: 120px 0;
  border-top: 1px solid var(--line);
  text-align: center;
}
.lp-final-cta h2 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: clamp(30px, 6vw, 52px);
  margin: 0 0 32px;
}

/* ---------- Footer ---------- */
.lp-footer { padding: 56px 0 72px; border-top: 1px solid var(--line); }
.lp-footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.lp-footer-links { display: flex; flex-wrap: wrap; gap: 18px; font-size: 13.5px; }
.lp-footer-links a { color: var(--muted); text-decoration: none; }
.lp-footer-links a:hover { color: var(--gold); }
.lp-footer-contact { font-size: 13.5px; color: var(--muted); }
.lp-footer-contact a { color: var(--muted); text-decoration: none; }
.lp-footer-contact a:hover { color: var(--gold); }
.lp-footer-disclaimer { font-size: 11.5px; color: #5C5C5C; line-height: 1.6; max-width: 640px; }
