/* OnBook Chess — marketing site. Single-page, static, host-ready. */
:root {
  --bg: #0b1120;
  --bg-2: #0f172a;
  --panel: #1e293b;
  --panel-2: #16233b;
  --line: #334155;
  --line-soft: #25324a;
  --text: #e2e8f0;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --emerald: #10b981;
  --emerald-2: #34d399;
  --amber: #f59e0b;
  --radius: 14px;
  --maxw: 1140px;
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.6);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(1100px 600px at 80% -10%, rgba(16, 185, 129, 0.12), transparent 60%),
    radial-gradient(900px 500px at 0% 0%, rgba(59, 130, 246, 0.08), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { line-height: 1.15; margin: 0; letter-spacing: -0.02em; }
p { margin: 0; }
section { scroll-margin-top: 84px; }

.grad {
  background: linear-gradient(90deg, var(--emerald-2), #6ee7b7);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--emerald-2);
  margin-bottom: 14px;
}

/* ---------- Buttons ---------- */
.btn {
  --b: var(--emerald);
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--b);
  color: #04140d;
  font-weight: 700;
  padding: 11px 18px;
  border-radius: 10px;
  border: 1px solid transparent;
  transition: transform 0.12s ease, background 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 8px 24px -10px rgba(16, 185, 129, 0.7);
}
.btn:hover { background: var(--emerald-2); transform: translateY(-1px); }
.btn-lg { padding: 14px 24px; font-size: 1.05rem; border-radius: 12px; }
.btn-sm { padding: 8px 14px; font-size: 0.9rem; }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
  box-shadow: none;
}
.btn-ghost:hover { background: rgba(148, 163, 184, 0.08); border-color: var(--muted-2); }

/* ---------- Beta strip ---------- */
.beta-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  text-align: center;
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.16), rgba(245, 158, 11, 0.06));
  border-bottom: 1px solid rgba(245, 158, 11, 0.3);
  color: #fcd9a3;
  font-size: 0.86rem;
  padding: 9px 16px;
}
.beta-strip strong { color: #fde9c8; }
.beta-strip .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--amber); box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.2);
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px clamp(16px, 4vw, 40px);
  background: rgba(11, 17, 32, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 1.1rem;
}
.brand img { border-radius: 7px; }
.brand strong { color: var(--emerald-2); font-weight: 800; }
.tag {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--amber);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 999px;
  padding: 2px 7px;
}
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { color: var(--muted); font-weight: 500; transition: color 0.15s; }
.nav-links a:hover { color: var(--text); }
.nav-links a.btn { color: #04140d; }
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; }

/* ---------- Layout ---------- */
.section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(56px, 9vw, 110px) clamp(16px, 4vw, 40px);
}
.section.alt {
  max-width: none;
  background: linear-gradient(180deg, transparent, rgba(30, 41, 59, 0.35), transparent);
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}
.section.alt > .split { max-width: var(--maxw); margin: 0 auto; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
.section-head p { color: var(--muted); margin-top: 14px; font-size: 1.05rem; }

/* ---------- Window frame ---------- */
.window {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-2);
  box-shadow: var(--shadow);
}
.window-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 14px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}
.window-bar i { width: 11px; height: 11px; border-radius: 50%; background: #475569; }
.window-bar i:nth-child(1) { background: #ef4444; }
.window-bar i:nth-child(2) { background: #f59e0b; }
.window-bar i:nth-child(3) { background: #10b981; }
.window img { width: 100%; height: auto; }

/* ---------- Hero ---------- */
.hero {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(48px, 7vw, 88px) clamp(16px, 4vw, 40px) clamp(40px, 6vw, 70px);
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); font-weight: 800; }
.lede { color: var(--muted); font-size: 1.12rem; margin-top: 18px; max-width: 36ch; }
.lede strong { color: var(--text); }
.lede em { color: var(--emerald-2); font-style: normal; }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  list-style: none;
  padding: 0;
  margin: 26px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}
.trust li { display: flex; align-items: center; gap: 8px; }
.trust li::before {
  content: '';
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--emerald); box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.18);
}
.hero-logo {
  width: 132px;
  height: auto;
  margin-bottom: 20px;
  filter: drop-shadow(0 16px 30px rgba(0, 0, 0, 0.55));
}
.hero-shot .window { transform: perspective(1400px) rotateY(-4deg) rotateX(2deg); }

/* ---------- Feature grid ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.card {
  background: linear-gradient(180deg, var(--panel), var(--panel-2));
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.card:hover { transform: translateY(-3px); border-color: rgba(16, 185, 129, 0.45); }
.card .ic {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 11px;
  background: rgba(16, 185, 129, 0.14);
  color: var(--emerald-2);
  font-size: 1.4rem;
  margin-bottom: 16px;
}
.card h3 { font-size: 1.12rem; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 0.97rem; }

/* ---------- Split (practice) ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: clamp(28px, 5vw, 60px);
  align-items: center;
}
.split-text h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
.mode-list { list-style: none; padding: 0; margin: 24px 0 28px; display: grid; gap: 14px; }
.mode-list li {
  position: relative;
  padding: 14px 16px 14px 18px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--line-soft);
  border-left: 3px solid var(--emerald);
  border-radius: 10px;
  color: var(--muted);
  font-size: 0.98rem;
}
.mode-list strong { color: var(--text); }

/* ---------- Screenshots ---------- */
.shots { display: grid; gap: clamp(40px, 6vw, 72px); }
.shot {
  margin: 0;
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: clamp(24px, 4vw, 52px);
  align-items: center;
}
.shot.reverse { grid-template-columns: 1fr 1.25fr; }
.shot.reverse .window { order: 2; }
.shot figcaption h3 { font-size: 1.4rem; margin-bottom: 10px; }
.shot figcaption p { color: var(--muted); }

/* ---------- Download ---------- */
.download .dl-card {
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.02));
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 20px;
  padding: clamp(32px, 5vw, 56px);
}
.dl-card h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); margin-top: 6px; }
.dl-card .lede { margin: 16px auto 28px; max-width: 52ch; }
.dl-card .btn-lg { font-size: 1.12rem; }
.dl-meta { color: var(--muted-2); font-size: 0.9rem; margin-top: 14px; }
.notes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 32px;
  text-align: left;
}
.note {
  background: rgba(11, 17, 32, 0.55);
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  padding: 16px 18px;
}
.note h4 { font-size: 0.98rem; margin-bottom: 6px; }
.note p { color: var(--muted); font-size: 0.9rem; }
.note strong { color: var(--text); }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line-soft); margin-top: 40px; }
.foot-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 36px clamp(16px, 4vw, 40px);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.muted { color: var(--muted-2); font-size: 0.86rem; }
.muted a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.muted a:hover { color: var(--emerald-2); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  .hero-shot .window { transform: none; }
  .lede { max-width: none; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .shot, .shot.reverse { grid-template-columns: 1fr; }
  .shot.reverse .window { order: 0; }
  .notes { grid-template-columns: 1fr; }

  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 14px clamp(16px, 4vw, 40px) 20px;
    background: rgba(11, 17, 32, 0.97);
    border-bottom: 1px solid var(--line);
    display: none;
  }
  .nav-links a { padding: 10px 4px; }
  .nav-links a.btn { text-align: center; }
  body.nav-open .nav-links { display: flex; }
}
@media (max-width: 560px) {
  .grid { grid-template-columns: 1fr; }
  .cta-row .btn { width: 100%; justify-content: center; }
}
