:root {
  --c-bg: #ffffff;
  --c-heading: #061b31;
  --c-label: #273951;
  --c-body: #64748d;
  --c-border: #e5edf5;
  --c-border-soft: #d6d9fc;
  --c-purple: #533afd;
  --c-purple-hover: #4434d4;
  --c-purple-soft: #b9b9f9;
  --c-purple-bg: rgba(83, 58, 253, 0.05);
  --c-brand-dark: #1c1e54;
  --c-magenta: #f96bee;
  --c-ruby: #ea2261;
  --c-success-bg: rgba(21, 190, 83, 0.2);
  --c-success-text: #108c3d;

  --shadow-ambient: rgba(23, 23, 23, 0.06) 0 3px 6px;
  --shadow-standard: rgba(23, 23, 23, 0.08) 0 15px 35px;
  --shadow-elevated: rgba(50, 50, 93, 0.25) 0 30px 45px -30px,
    rgba(0, 0, 0, 0.1) 0 18px 36px -18px;
  --shadow-deep: rgba(3, 3, 39, 0.25) 0 14px 21px -14px,
    rgba(0, 0, 0, 0.1) 0 8px 17px -8px;

  --radius-tight: 4px;
  --radius-std: 5px;
  --radius-comfy: 6px;
  --radius-large: 8px;

  --font-sans: 'Inter', 'SF Pro Display', system-ui, -apple-system, Segoe UI, sans-serif;
  --font-mono: 'JetBrains Mono', SFMono-Regular, Menlo, monospace;

  --container: 1080px;
}

/* ---------- Reveal-on-scroll (only when JS enabled) ---------- */

html.js .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.7s cubic-bezier(.2,.8,.2,1),
    transform 0.7s cubic-bezier(.2,.8,.2,1);
  will-change: opacity, transform;
}

html.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

.hero .reveal { transition-delay: 0.05s; }
.hero .display.reveal { transition-delay: 0.10s; }
.hero .lead.reveal { transition-delay: 0.18s; }
.hero .cta-row.reveal { transition-delay: 0.26s; }
.hero .dashboard-preview.reveal { transition-delay: 0.34s; }
.hero .trust-strip.reveal { transition-delay: 0.42s; }

.grid-3 .card.reveal:nth-child(1) { transition-delay: 0.05s; }
.grid-3 .card.reveal:nth-child(2) { transition-delay: 0.10s; }
.grid-3 .card.reveal:nth-child(3) { transition-delay: 0.15s; }
.grid-3 .card.reveal:nth-child(4) { transition-delay: 0.20s; }
.grid-3 .card.reveal:nth-child(5) { transition-delay: 0.25s; }
.grid-3 .card.reveal:nth-child(6) { transition-delay: 0.30s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; opacity: 1; transform: none; }
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  font-weight: 400;
  font-feature-settings: 'ss01' on, 'cv11' on;
  background: var(--c-bg);
  color: var(--c-body);
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--c-purple);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--c-purple-hover);
}

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid transparent;
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.nav.is-scrolled {
  background: rgba(255, 255, 255, 0.88);
  border-bottom-color: var(--c-border);
  box-shadow: rgba(0, 55, 112, 0.08) 0 1px 0 0;
}

.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 32px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--c-heading);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: -0.16px;
  white-space: nowrap;
  flex-shrink: 0;
}

.brand:hover {
  color: var(--c-heading);
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.brand-name {
  font-weight: 500;
  letter-spacing: -0.16px;
  white-space: nowrap;
}

@media (max-width: 480px) {
  .brand-name { font-size: 15px; }
}

.nav-links {
  display: flex;
  gap: 28px;
  margin-left: 16px;
  flex: 1;
}

.nav-links a {
  font-size: 14px;
  font-weight: 400;
  color: var(--c-heading);
}

.nav-links a:hover {
  color: var(--c-purple);
}

.nav-cta {
  margin-left: auto;
}

@media (max-width: 720px) {
  .nav-links {
    display: none;
  }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 15px;
  font-feature-settings: 'ss01' on;
  padding: 9px 16px;
  border-radius: var(--radius-tight);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease,
    transform 0.15s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--c-purple);
  color: #fff;
}

.btn-primary:hover {
  background: var(--c-purple-hover);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--c-purple);
  border-color: var(--c-purple-soft);
}

.btn-ghost:hover {
  background: var(--c-purple-bg);
  color: var(--c-purple-hover);
}

.btn-light {
  background: #fff;
  color: var(--c-heading);
}

.btn-light:hover {
  background: rgba(255, 255, 255, 0.9);
  color: var(--c-brand-dark);
}

.btn-ghost-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.3);
}

.btn-ghost-light:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* ---------- Typography ---------- */

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--c-purple);
  background: var(--c-purple-bg);
  padding: 5px 10px;
  border-radius: var(--radius-tight);
  border: 1px solid var(--c-border-soft);
  margin-bottom: 24px;
}

.eyebrow-light {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
}

.display {
  font-size: clamp(32px, 5.4vw, 56px);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -1.4px;
  color: var(--c-heading);
  margin: 0 0 20px;
  max-width: 18ch;
  text-wrap: balance;
}

.lead {
  font-size: 18px;
  font-weight: 300;
  line-height: 1.5;
  color: var(--c-body);
  max-width: 640px;
  margin: 0 0 32px;
}

.section-title {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.8px;
  color: var(--c-heading);
  margin: 0 0 14px;
}

.section-title-light {
  color: #fff;
}

.section-lead {
  font-size: 17px;
  font-weight: 300;
  line-height: 1.5;
  color: var(--c-body);
  max-width: 640px;
  margin: 0 0 40px;
}

.section-lead-light {
  color: rgba(255, 255, 255, 0.7);
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding: 96px 0 32px;
  overflow: hidden;
}

.hero-ribbon {
  position: absolute;
  top: -40px;
  left: -8%;
  right: -8%;
  width: 116%;
  height: 720px;
  max-height: 80%;
  z-index: 0;
  pointer-events: none;
  transform: skewY(-6deg);
  transform-origin: top left;
  opacity: 0.7;
  filter: saturate(1.05);
}

.ribbon-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.rb-path {
  transform-origin: 50% 50%;
  animation: ribbon-drift 22s ease-in-out infinite alternate;
  will-change: transform, opacity;
}

.rb-a { animation-duration: 26s; }
.rb-b { animation-duration: 32s; animation-delay: -4s; }
.rb-c { animation-duration: 22s; animation-delay: -8s; }
.rb-d { animation-duration: 38s; animation-delay: -2s; }

@keyframes ribbon-drift {
  0%   { transform: translate3d(0,0,0) scale(1);     opacity: 0.95; }
  50%  { transform: translate3d(-3%, 2%, 0) scale(1.04); opacity: 1; }
  100% { transform: translate3d(2%, -2%, 0) scale(0.98); opacity: 0.9; }
}

.hero-grain {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  background:
    radial-gradient(1100px 520px at 85% -5%, rgba(255,255,255,0.5), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,0.55) 0%, rgba(255,255,255,0) 22%, rgba(255,255,255,0) 55%, rgba(255,255,255,0.97) 90%, #fff 100%);
  pointer-events: none;
}

.hero .container {
  position: relative;
  z-index: 2;
}

.hero .display { color: var(--c-heading); }
.hero .lead { color: var(--c-label); }

@media (prefers-reduced-motion: reduce) {
  .rb-path { animation: none; }
}

.cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

/* ---------- Dashboard preview ---------- */

.dashboard-preview {
  position: relative;
  margin: 16px auto 32px;
  max-width: 880px;
  perspective: 2000px;
}

.dash-window {
  position: relative;
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow:
    rgba(50, 50, 93, 0.25) 0 50px 100px -20px,
    rgba(0, 0, 0, 0.18) 0 30px 60px -30px,
    rgba(83, 58, 253, 0.12) 0 -2px 6px 0 inset;
  transform: rotateX(8deg) translateZ(0);
  transition: transform 0.6s cubic-bezier(.2,.8,.2,1);
}

.dashboard-preview:hover .dash-window {
  transform: rotateX(2deg) translateY(-4px);
}

.dash-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--c-border);
  background: linear-gradient(180deg, #fafbfd, #f6f8fb);
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}
.dot-r { background: #ff5f57; }
.dot-y { background: #febc2e; }
.dot-g { background: #28c840; }

.dash-url {
  margin-left: 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--c-body);
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 6px;
  padding: 4px 10px;
  flex: 1;
  text-align: center;
  max-width: 320px;
  margin-right: auto;
}

.dash-body {
  display: grid;
  grid-template-columns: 200px 1fr;
  min-height: 360px;
}

.dash-side {
  background: #fafbfd;
  border-right: 1px solid var(--c-border);
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.dash-logo {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, #533afd, #f96bee);
  margin-bottom: 16px;
}

.dash-link {
  font-size: 13px;
  font-weight: 400;
  color: var(--c-body);
  padding: 8px 10px;
  border-radius: 6px;
  cursor: default;
}

.dash-link.active {
  color: var(--c-purple);
  background: var(--c-purple-bg);
  font-weight: 500;
}

.dash-main {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.dash-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.stat-card {
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 8px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
}

.stat-label {
  font-size: 11px;
  color: var(--c-body);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-weight: 500;
}

.stat-value {
  font-size: 22px;
  font-weight: 300;
  letter-spacing: -0.4px;
  color: var(--c-heading);
  font-feature-settings: 'tnum' on, 'ss01' on;
}

.badge {
  font-size: 10px;
  font-weight: 500;
  padding: 2px 6px;
  border-radius: 4px;
  align-self: flex-start;
  margin-top: 2px;
}

.badge-success {
  background: var(--c-success-bg);
  color: var(--c-success-text);
  border: 1px solid rgba(21, 190, 83, 0.4);
}

.dash-chart {
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 8px;
  padding: 16px;
  flex: 1;
  min-height: 180px;
}

.dash-chart svg {
  width: 100%;
  height: 100%;
  display: block;
}

.dash-glow {
  position: absolute;
  inset: -40px -40px auto -40px;
  height: 60%;
  background: radial-gradient(ellipse at 50% 0%, rgba(83, 58, 253, 0.25), transparent 70%);
  filter: blur(40px);
  z-index: -1;
  pointer-events: none;
}

@media (max-width: 720px) {
  .dash-body { grid-template-columns: 1fr; min-height: 0; }
  .dash-side { display: none; }
  .dash-stats { grid-template-columns: 1fr 1fr; }
  .dash-window { transform: none; }
  .dashboard-preview { margin-bottom: 48px; }
}

.trust-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding-top: 28px;
  margin-top: 8px;
  border-top: 1px solid var(--c-border);
}

.trust-strip > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.trust-strip strong {
  color: var(--c-heading);
  font-weight: 500;
  font-size: 14px;
}

.trust-strip span {
  color: var(--c-body);
  font-size: 14px;
  font-weight: 300;
  line-height: 1.4;
}

@media (max-width: 720px) {
  .trust-strip {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .hero {
    padding: 64px 0 56px;
  }
}

/* ---------- Sections ---------- */

.section {
  padding: 80px 0;
}

@media (max-width: 720px) {
  .section {
    padding: 56px 0;
  }
}

.grid {
  display: grid;
  gap: 24px;
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 920px) {
  .grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* ---------- Cards ---------- */

.card {
  --mx: 50%;
  --my: 50%;
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: var(--radius-comfy);
  padding: 28px;
  overflow: hidden;
  transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry));
  transform-style: preserve-3d;
  transition: box-shadow 0.25s ease, transform 0.25s cubic-bezier(.2,.8,.2,1),
    border-color 0.25s ease;
}

.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    300px circle at var(--mx) var(--my),
    rgba(83, 58, 253, 0.10),
    transparent 60%
  );
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.card:hover {
  box-shadow: var(--shadow-elevated);
  border-color: var(--c-border-soft);
}

.card:hover::before {
  opacity: 1;
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-comfy);
  background: var(--c-purple-bg);
  color: var(--c-purple);
  margin-bottom: 18px;
}

.card h3 {
  font-size: 20px;
  font-weight: 400;
  letter-spacing: -0.2px;
  color: var(--c-heading);
  margin: 0 0 8px;
  line-height: 1.2;
}

.card p {
  font-size: 15px;
  font-weight: 300;
  line-height: 1.5;
  color: var(--c-body);
  margin: 0;
}

/* ---------- Method ---------- */

.method > div {
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: var(--radius-comfy);
  padding: 28px;
  position: relative;
}

.step {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--c-purple);
  background: var(--c-purple-bg);
  padding: 4px 10px;
  border-radius: var(--radius-tight);
  margin-bottom: 16px;
  letter-spacing: 1px;
}

.method h3 {
  font-size: 20px;
  font-weight: 400;
  letter-spacing: -0.2px;
  color: var(--c-heading);
  margin: 0 0 8px;
}

.method p {
  font-size: 15px;
  font-weight: 300;
  line-height: 1.5;
  color: var(--c-body);
  margin: 0;
}

/* ---------- Dark / Product ---------- */

.section-dark {
  background: var(--c-brand-dark);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.section-dark::before {
  content: '';
  position: absolute;
  top: -120px;
  left: -120px;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(249, 107, 238, 0.25), transparent 60%);
  filter: blur(60px);
  pointer-events: none;
}

.section-dark::after {
  content: '';
  position: absolute;
  bottom: -180px;
  right: -120px;
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(83, 58, 253, 0.35), transparent 65%);
  filter: blur(80px);
  pointer-events: none;
}

.product-callout {
  position: relative;
  z-index: 1;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-top: 56px;
}

.product-grid > div {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-comfy);
  padding: 24px;
}

.product-grid h4 {
  font-size: 16px;
  font-weight: 500;
  color: #fff;
  margin: 0 0 6px;
  letter-spacing: -0.1px;
}

.product-grid p {
  font-size: 14px;
  font-weight: 300;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.65);
  margin: 0;
}

@media (max-width: 720px) {
  .product-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- CTA Section ---------- */

.section-cta {
  padding: 80px 0 96px;
}

.cta-card {
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: var(--radius-large);
  padding: 56px 48px;
  text-align: center;
  box-shadow: var(--shadow-elevated);
}

.cta-card h2 {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.8px;
  color: var(--c-heading);
  margin: 0 0 12px;
}

.cta-card p {
  font-size: 17px;
  font-weight: 300;
  color: var(--c-body);
  max-width: 520px;
  margin: 0 auto 32px;
  line-height: 1.5;
}

.cta-card .cta-row {
  justify-content: center;
  margin-bottom: 0;
}

@media (max-width: 600px) {
  .cta-card {
    padding: 40px 24px;
  }
}

/* ---------- Footer ---------- */

.footer {
  background: #fff;
  border-top: 1px solid var(--c-border);
  padding: 56px 0 24px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.5fr 2fr;
  gap: 40px;
}

.footer-brand p {
  font-size: 14px;
  font-weight: 300;
  color: var(--c-body);
  margin: 12px 0 0;
  line-height: 1.5;
  max-width: 320px;
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.footer-cols > div {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-label {
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--c-heading);
  margin-bottom: 4px;
}

.footer-cols a {
  font-size: 14px;
  font-weight: 400;
  color: var(--c-body);
}

.footer-cols a:hover {
  color: var(--c-purple);
}

.footer-bottom {
  max-width: var(--container);
  margin: 40px auto 0;
  padding: 24px 24px 0;
  border-top: 1px solid var(--c-border);
  font-size: 13px;
  color: var(--c-body);
}

@media (max-width: 720px) {
  .footer-inner {
    grid-template-columns: 1fr;
  }
  .footer-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
