/* LYN – Light Years Network — marketing + legal site.
   Palette mirrors ios/Tradespek/DesignSystem/Tokens.swift (light scheme). */

:root {
  --bg: #f9f9f9;
  --surface: #ffffff;
  --surface-low: #f2f4f1;
  --text: #1b1b1b;
  --text-2: #3d4b37;
  --text-3: #6f7a6a;
  --border: #dfe4dc;
  --accent: #006e01;
  --accent-pressed: #004c00;
  --accent-muted: #c9f1c7;
  --bear: #b3261e;
  --bear-muted: #fbe4e2;
  --radius: 20px;
  --radius-sm: 12px;
  --max: 1080px;
  --font: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-pressed); text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.01em; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.2rem, 5.5vw, 3.6rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 700; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ---- Nav ---- */
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 0;
}
.brand { display: flex; align-items: center; gap: 12px; color: var(--text); font-weight: 700; }
.brand:hover { text-decoration: none; }
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.brand .word { color: var(--accent); font-size: 1.15rem; letter-spacing: -0.01em; }
.nav-links { display: flex; gap: 22px; font-weight: 600; font-size: 0.95rem; }
.nav-links a { color: var(--text-2); }
.nav-links a:hover { color: var(--accent); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px; border-radius: 999px;
  font-weight: 700; font-size: 1rem; line-height: 1;
  border: 2px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 8px 20px rgba(0, 110, 1, 0.22); }
.btn-primary:hover { background: var(--accent-pressed); color: #fff; }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn svg { width: 20px; height: 20px; }

/* ---- Hero ---- */
.hero { padding: 48px 0 24px; }
.hero-grid {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--accent-muted); color: var(--accent-pressed);
  font-weight: 700; font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 999px; margin-bottom: 18px;
}
.hero p.lede { font-size: 1.2rem; color: var(--text-2); max-width: 34rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.cta-note { color: var(--text-3); font-size: 0.9rem; margin-top: 14px; }

.phones { position: relative; display: flex; justify-content: center; align-items: flex-end; gap: 0; min-height: 520px; }
.phone {
  width: 250px; border-radius: 34px; overflow: hidden;
  border: 6px solid #111; background: #111;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.18);
}
.phone img { width: 100%; }
.phone.back { position: absolute; transform: scale(0.86); opacity: 0.95; z-index: 0; }
.phone.back.l { left: 0; bottom: 20px; transform: scale(0.84) rotate(-6deg); transform-origin: bottom right; }
.phone.back.r { right: 0; bottom: 20px; transform: scale(0.84) rotate(6deg); transform-origin: bottom left; }
.phone.front { position: relative; z-index: 1; }

/* ---- Sections ---- */
.section { padding: 64px 0; }
.section.alt { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 40rem; margin-bottom: 36px; }
.section-head p { color: var(--text-2); font-size: 1.1rem; }

.features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.feature {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px;
}
.section.alt .feature { background: var(--bg); }
.feature .ic {
  width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center;
  background: var(--accent-muted); color: var(--accent-pressed); margin-bottom: 16px;
}
.feature .ic svg { width: 22px; height: 22px; }
.feature p { color: var(--text-2); margin: 0; }

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: step; }
.step { position: relative; padding: 22px 22px 22px 22px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.step::before {
  counter-increment: step; content: counter(step);
  display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%;
  background: var(--accent); color: #fff; font-weight: 700; margin-bottom: 14px;
}
.step h3 { font-size: 1.05rem; }
.step p { color: var(--text-2); margin: 0; font-size: 0.97rem; }

.tags { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.tag { padding: 6px 12px; border-radius: 999px; font-weight: 700; font-size: 0.8rem; letter-spacing: 0.06em; }
.tag.bull { background: var(--accent-muted); color: var(--accent-pressed); }
.tag.bear { background: var(--bear-muted); color: var(--bear); }

.disclaimer {
  display: flex; gap: 14px; align-items: flex-start;
  background: var(--surface-low); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px 22px; color: var(--text-2); font-size: 0.95rem;
}
.disclaimer svg { flex: none; width: 22px; height: 22px; color: var(--accent); margin-top: 2px; }

/* ---- Footer ---- */
.footer { padding: 36px 0 48px; border-top: 1px solid var(--border); color: var(--text-3); font-size: 0.92rem; }
.footer-grid { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 18px; align-items: center; }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; }
.footer-links a { color: var(--text-2); font-weight: 600; }

/* ---- Legal pages ---- */
.legal { padding: 24px 0 72px; }
.legal-grid { display: grid; grid-template-columns: 240px 1fr; gap: 48px; align-items: start; }
.toc { position: sticky; top: 24px; font-size: 0.92rem; }
.toc ol { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--border); }
.toc li a { display: block; padding: 6px 14px; color: var(--text-2); }
.toc li a:hover { color: var(--accent); text-decoration: none; }
.prose { max-width: 46rem; }
.prose h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
.prose h2 { font-size: 1.35rem; margin-top: 2.2em; padding-top: 0.4em; }
.prose h3 { font-size: 1.05rem; margin-top: 1.6em; }
.prose p, .prose li { color: var(--text); font-size: 1.02rem; }
.prose ul { padding-left: 1.3em; }
.prose li { margin-bottom: 0.4em; }
.prose .meta { color: var(--text-3); font-size: 0.95rem; margin-bottom: 2em; }
.prose .callout {
  background: var(--surface-low); border: 1px solid var(--border); border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm); padding: 16px 18px; margin: 1.2em 0;
}
.prose table { border-collapse: collapse; width: 100%; font-size: 0.95rem; margin: 1em 0 1.6em; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--border); }
.prose th { color: var(--text-2); font-weight: 700; font-size: 0.85rem; letter-spacing: 0.04em; text-transform: uppercase; }
.table-wrap { overflow-x: auto; }
.prose strong { font-weight: 700; }

/* ---- Join page ---- */
.join { padding: 56px 0 80px; text-align: center; }
.join .card {
  max-width: 460px; margin: 0 auto; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 36px 28px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.06);
}
.join .card img { width: 84px; height: 84px; border-radius: 20px; margin: 0 auto 18px; }
.code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 2rem; font-weight: 700;
  letter-spacing: 0.18em; background: var(--surface-low); border: 1px dashed var(--border);
  border-radius: var(--radius-sm); padding: 16px 18px; margin: 18px 0; user-select: all;
}
.join ol { text-align: left; color: var(--text-2); padding-left: 1.3em; margin: 20px 0 26px; }
.join ol li { margin-bottom: 8px; }

/* ---- Responsive ---- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .phones { min-height: 460px; margin-top: 12px; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .legal-grid { grid-template-columns: 1fr; gap: 24px; }
  .toc { position: static; }
  .toc ol { display: flex; flex-wrap: wrap; gap: 4px 12px; border-left: 0; }
  .toc li a { padding: 4px 0; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .nav-links { gap: 14px; font-size: 0.9rem; }
  .features, .steps { grid-template-columns: 1fr; }
  .phone { width: 210px; }
  .phone.back.l, .phone.back.r { display: none; }
  .phones { min-height: 0; }
  .section { padding: 48px 0; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
