/* ============================================================
   Prysm landing — single-file stylesheet
   ============================================================ */

:root {
  /* Brand palette — same tokens as the docs site */
  --bg: #0a0f1c;
  --bg-elev: #0d1424;
  --bg-panel: rgba(13, 24, 42, 0.6);
  --hairline: #1e2a44;
  --hairline-soft: #16203a;
  --hairline-bright: #233152;

  --blue: #3b82f6;
  --blue-bright: #60a5fa;
  --blue-soft: rgba(59, 130, 246, 0.18);
  --cyan: #22d3ee;

  --text: #cbd5e1;
  --text-strong: #ffffff;
  --text-muted: #6b7a99;

  /* Type */
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', monospace;

  /* Spacing */
  --container: 1200px;
  --gap: 1.5rem;
}

/* ============================================================ Reset */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* Page-level atmospheric backdrop — sits behind everything, fades out
   gracefully so the hero blends into the rest of the page without a seam. */
body::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 1100px;
  background:
    radial-gradient(ellipse 1100px 700px at 80% 0%, rgba(59, 130, 246, 0.16), transparent 65%),
    radial-gradient(ellipse 900px 700px at 10% 20%, rgba(96, 165, 250, 0.10), transparent 65%),
    radial-gradient(ellipse 1200px 500px at 50% 100%, rgba(34, 211, 238, 0.06), transparent 70%);
  -webkit-mask-image: linear-gradient(180deg, black 0%, black 70%, transparent 100%);
  mask-image: linear-gradient(180deg, black 0%, black 70%, transparent 100%);
  pointer-events: none;
  z-index: 0;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
ul, ol { list-style: none; }

/* ============================================================ Reveal */
.reveal-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 700ms cubic-bezier(.2,.8,.2,1), transform 700ms cubic-bezier(.2,.8,.2,1);
  transition-delay: var(--delay, 0ms);
}
.reveal-up.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .reveal-up { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* ============================================================ Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  border-radius: 0.625rem;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 180ms ease, background-color 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
  white-space: nowrap;
}
.btn-sm { padding: 0.55rem 1rem; font-size: 0.85rem; }
.btn-lg { padding: 1.1rem 2.25rem; font-size: 1rem; }

.btn-primary {
  background: var(--blue);
  color: white;
  box-shadow: 0 0 0 1px rgba(59, 130, 246, 0.4), 0 8px 24px -8px rgba(59, 130, 246, 0.5);
}
.btn-primary:hover {
  background: var(--blue-bright);
  transform: translateY(-1px);
  box-shadow: 0 0 0 1px rgba(96, 165, 250, 0.5), 0 12px 32px -8px rgba(96, 165, 250, 0.6);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-strong);
  border-color: var(--hairline-bright);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--blue);
}

/* ============================================================ Nav */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  background: transparent;
  transition: background-color 200ms ease, backdrop-filter 200ms ease, border-color 200ms ease;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: rgba(10, 15, 28, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--hairline);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--container);
  margin: 0 auto;
  padding: 1rem 1.5rem;
}
.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  color: var(--text-strong);
}
.nav-lockup {
  height: 44px;
  width: auto;
  display: block;
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}
.nav-link {
  font-size: 0.9rem;
  color: var(--text);
  transition: color 160ms ease;
}
.nav-link:hover {
  color: var(--text-strong);
}

/* ============================================================ Hero */
.hero {
  position: relative;
  max-width: var(--container);
  margin: 0 auto;
  padding: clamp(3rem, 8vw, 6rem) 1.5rem clamp(4rem, 10vw, 7rem);
  text-align: center;
  z-index: 1;
}
#hero-canvas {
  position: absolute;
  inset: -2rem 0 -6rem 0;
  width: 100%;
  height: calc(100% + 8rem);
  z-index: -1;
  opacity: 0.55;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, black 12%, black 70%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, black 12%, black 70%, transparent 100%);
}
.hero-content {
  max-width: 44rem;
  margin: 0 auto;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: var(--blue-soft);
  border: 1px solid rgba(59, 130, 246, 0.3);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--blue-bright);
  margin-bottom: 1.75rem;
}
.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 8px rgba(74, 222, 128, 0.7);
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.025em;
  color: var(--text-strong);
  margin-bottom: 1.25rem;
}
.hero-title em {
  font-style: italic;
  font-weight: 400;
  display: inline-block;
  padding-right: 0.12em;
  color: var(--blue-bright);
  background: linear-gradient(120deg, var(--blue-bright), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-sub {
  font-size: clamp(1rem, 2vw, 1.125rem);
  line-height: 1.55;
  color: var(--text);
  max-width: 36rem;
  margin: 0 auto 2.25rem;
}

.cta-row {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 3.5rem;
}

/* Hero mock card */
.hero-mock {
  max-width: 38rem;
  margin: 0 auto;
  padding: 1.5rem;
  background: rgba(8, 12, 24, 0.7);
  border: 1px solid var(--hairline);
  border-radius: 1rem;
  text-align: left;
  font-family: var(--font-mono);
  box-shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.mock-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
  color: var(--text-strong);
}
.mock-header strong {
  font-weight: 700;
  letter-spacing: 0.02em;
}
.sol-mark {
  width: 0.85em;
  height: auto;
  flex-shrink: 0;
}
.mock-pre {
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text);
  white-space: pre;
  overflow-x: auto;
  font-variant-ligatures: none;
}

/* ============================================================ Sections (shared) */
.section {
  position: relative;
  z-index: 1;
  max-width: var(--container);
  margin: 0 auto;
  padding: clamp(4rem, 8vw, 6.5rem) 1.5rem;
}
.section-head {
  text-align: center;
  max-width: 38rem;
  margin: 0 auto clamp(2.5rem, 5vw, 3.5rem);
}
.eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue-bright);
  margin-bottom: 1rem;
}
.section h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--text-strong);
  margin-bottom: 1rem;
}
.section-sub {
  font-size: 1.0625rem;
  color: var(--text);
  line-height: 1.55;
}

/* ============================================================ Chains grid */
.chains-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.75rem;
}
.chains-grid li {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 1rem 1.125rem;
  background: var(--bg-panel);
  border: 1px solid var(--hairline);
  border-radius: 0.75rem;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}
.chains-grid li:hover {
  transform: translateY(-2px);
  border-color: var(--hairline-bright);
  background: rgba(13, 24, 42, 0.9);
}
.chains-grid img {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}
.chains-grid span {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-strong);
}

/* ============================================================ Bento (features) */
.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1rem;
}
.bento-card {
  position: relative;
  grid-column: span 3;
  padding: 2rem;
  background: var(--bg-panel);
  border: 1px solid var(--hairline);
  border-radius: 1rem;
  transition: transform 200ms ease, border-color 200ms ease, background 200ms ease;
  isolation: isolate;
  overflow: hidden;
}
.bento-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(59, 130, 246, 0.08), transparent 60%);
  opacity: 0;
  transition: opacity 220ms ease;
  pointer-events: none;
}
.bento-card:hover {
  transform: translateY(-2px);
  border-color: var(--hairline-bright);
  background: rgba(15, 26, 46, 0.85);
}
.bento-card:hover::before { opacity: 1; }
.bento-lg {
  grid-column: span 6;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(34, 211, 238, 0.06)), var(--bg-panel);
  border-color: rgba(59, 130, 246, 0.3);
}
.bento-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 0.625rem;
  background: var(--blue-soft);
  border: 1px solid rgba(59, 130, 246, 0.25);
  color: var(--blue-bright);
  margin-bottom: 1.25rem;
}
.bento-icon svg { width: 22px; height: 22px; }
.bento-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-strong);
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}
.bento-lg h3 {
  font-size: 1.625rem;
}
.bento-card p {
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--text);
}
.bento-card code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  padding: 0.05em 0.4em;
  background: rgba(59, 130, 246, 0.12);
  color: var(--blue-bright);
  border-radius: 4px;
}
.tag-row {
  display: flex;
  gap: 0.5rem;
  margin-top: 1.25rem;
  flex-wrap: wrap;
}
.tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.3rem 0.6rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  color: var(--text);
}

@media (max-width: 720px) {
  .bento { grid-template-columns: 1fr; }
  .bento-card, .bento-lg { grid-column: span 1; }
}

/* ============================================================ Commands grid */
.commands-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.75rem;
}
.cmd-card {
  padding: 1.25rem;
  background: var(--bg-panel);
  border: 1px solid var(--hairline);
  border-radius: 0.75rem;
  transition: transform 180ms ease, border-color 180ms ease;
}
.cmd-card:hover {
  transform: translateY(-2px);
  border-color: var(--hairline-bright);
}
.cmd {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--blue-bright);
  background: rgba(59, 130, 246, 0.1);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  margin-bottom: 0.625rem;
}
.cmd-card p {
  font-size: 0.875rem;
  color: var(--text);
  line-height: 1.5;
}

/* ============================================================ How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  position: relative;
}
.steps::before {
  content: '';
  position: absolute;
  top: 32px;
  left: 12%;
  right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--hairline-bright), transparent);
  z-index: 0;
}
.step {
  position: relative;
  padding: 2rem 1.5rem;
  background: var(--bg-panel);
  border: 1px solid var(--hairline);
  border-radius: 1rem;
  text-align: center;
  z-index: 1;
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--blue-soft);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: var(--blue-bright);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 1rem;
}
.step h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-strong);
  margin-bottom: 0.5rem;
}
.step p {
  font-size: 0.9375rem;
  color: var(--text);
  line-height: 1.55;
}
@media (max-width: 720px) {
  .steps { grid-template-columns: 1fr; }
  .steps::before { display: none; }
}

/* ============================================================ Final CTA */
.final-cta {
  position: relative;
  z-index: 1;
  max-width: var(--container);
  margin: 0 auto clamp(3rem, 6vw, 4.5rem);
  padding: 0 1.5rem;
}
.final-cta-inner {
  position: relative;
  text-align: center;
  padding: clamp(3rem, 7vw, 5rem) 2rem;
  border-radius: 1.5rem;
  background:
    radial-gradient(circle at 30% 20%, rgba(59, 130, 246, 0.25), transparent 50%),
    radial-gradient(circle at 70% 80%, rgba(34, 211, 238, 0.18), transparent 55%),
    linear-gradient(135deg, #0d1730 0%, #0a0f1c 100%);
  border: 1px solid var(--hairline-bright);
  overflow: hidden;
}
.final-cta-inner h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-strong);
  margin-bottom: 0.75rem;
}
.final-cta-inner p {
  font-size: 1.0625rem;
  color: var(--text);
  margin-bottom: 2rem;
}

/* ============================================================ Footer */
.footer {
  position: relative;
  z-index: 1;
  max-width: var(--container);
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  border-top: 1px solid var(--hairline);
}
.footer-brand {
  display: inline-flex;
  align-items: center;
}
.footer-lockup {
  height: 28px;
  width: auto;
  display: block;
}
.footer-meta {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.footer-meta a {
  color: var(--text);
  transition: color 160ms ease;
}
.footer-meta a:hover {
  color: var(--text-strong);
}

/* ============================================================ Mobile fine-tuning */
@media (max-width: 640px) {
  .nav-inner { padding: 0.75rem 1rem; }
  .nav-actions { gap: 0.875rem; }
  .nav-link { display: none; }
  .hero { padding-top: 2rem; }
  .cta-row { flex-direction: column; align-items: stretch; }
  .cta-row .btn { width: 100%; }
  .footer { flex-direction: column; align-items: flex-start; }
}
