:root {
  --ink: #12162a;
  --ink-2: #1d2340;
  --bg: #0a0d1c;
  --surface: #141933;
  --surface-2: #1c2242;
  --text: #f2f0ea;
  --accent: #ff6a4d;
  --accent-dark: #dd4e32;
  --accent-light: #ffe6dd;
  --teal: #1fae8e;
  --teal-light: #dff5ef;
  --muted: #9aa0bb;
  --border: rgba(255, 255, 255, 0.12);
  --radius-lg: 22px;
  --radius-md: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.2), 0 20px 40px -20px rgba(0, 0, 0, 0.55);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background:
    radial-gradient(60% 50% at 85% 0%, rgba(255, 106, 77, 0.08) 0%, transparent 60%),
    radial-gradient(50% 40% at 0% 30%, rgba(31, 174, 142, 0.07) 0%, transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 {
  font-family: 'Calistoga', 'Inter', serif;
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.01em;
  text-wrap: balance;
  margin: 0 0 0.4em;
  color: var(--text);
}
p { margin: 0 0 1em; }
a { color: var(--accent); text-decoration: none; }
img, svg { max-width: 100%; }

.container { width: 100%; max-width: 1120px; margin: 0 auto; padding-inline: 24px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5em;
  font-family: 'Inter', sans-serif; font-weight: 600; font-size: 0.95rem;
  padding: 0.85em 1.5em; border-radius: 999px; border: 1px solid transparent;
  cursor: pointer; transition: transform 0.08s ease, box-shadow 0.15s ease, background 0.15s ease;
  min-height: 48px;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 12px 24px -10px rgba(255, 106, 77, 0.55); }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-dark { background: var(--surface-2); color: #fff; border: 1px solid var(--border); }
.btn-dark:hover { background: #232a52; color: #fff; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { background: var(--surface); }
.btn-ghost-light { background: rgba(255,255,255,0.08); color: #fff; border-color: rgba(255,255,255,0.35); }
.btn-ghost-light:hover { background: rgba(255,255,255,0.16); }
.btn-lg { font-size: 1.05rem; padding: 1em 1.7em; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 20;
  background: rgba(10, 13, 28, 0.75);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav .container { display: flex; align-items: center; justify-content: space-between; padding-block: 16px; }
.brand { display: flex; align-items: center; gap: 9px; font-family: 'Inter', sans-serif; font-weight: 700; font-size: 1.25rem; color: var(--text); }
.brand .dot { width: 11px; height: 11px; border-radius: 50%; background: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { color: var(--text); font-weight: 600; font-size: 0.94rem; }
.nav-links a:hover { color: var(--accent); }
.nav-cta { display: flex; align-items: center; gap: 14px; }
@media (max-width: 760px) {
  .nav-links { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: radial-gradient(120% 140% at 15% -10%, #232a4d 0%, var(--ink) 55%, #0c0f1d 100%);
  color: #fff;
  overflow: hidden;
  padding-block: 96px 100px;
}
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,0.08) 1px, transparent 1px);
  background-size: 26px 26px;
  mask-image: radial-gradient(ellipse 65% 55% at 70% 30%, black 0%, transparent 75%);
  opacity: 0.6;
}
.hero-blob {
  position: absolute; border-radius: 50%; filter: blur(90px); pointer-events: none;
}
.hero-blob-1 { width: 480px; height: 480px; background: radial-gradient(circle, var(--accent) 0%, transparent 70%); top: -160px; right: -120px; opacity: 0.45; }
.hero-blob-2 { width: 380px; height: 380px; background: radial-gradient(circle, var(--teal) 0%, transparent 70%); bottom: -180px; left: -100px; opacity: 0.35; }
.hero .container { position: relative; z-index: 1; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 40px; align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }
.hero-inner { max-width: 640px; }
.hero-blob-3 { width: 300px; height: 300px; background: radial-gradient(circle, #6a5cff 0%, transparent 70%); top: 30%; left: 40%; opacity: 0.25; }
@keyframes blob-drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(24px, -20px) scale(1.06); }
}
.hero-blob-1, .hero-blob-2, .hero-blob-3 { animation: blob-drift 20s ease-in-out infinite; }
.hero-blob-2 { animation-duration: 26s; animation-delay: -6s; }
.hero-blob-3 { animation-duration: 23s; animation-delay: -12s; }
.hero .eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.18);
  padding: 6px 14px; border-radius: 999px; font-size: 0.82rem; font-weight: 700;
  letter-spacing: 0.03em; margin-bottom: 22px; color: #fff;
}
.hero h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); color: #fff; }
.hero h1 .accent { color: var(--accent); }
.hero .lede { font-size: 1.15rem; color: rgba(255,255,255,0.78); max-width: 56ch; margin-bottom: 30px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 40px; margin-top: 56px; flex-wrap: wrap; }
.hero-stat .num { font-family: 'Inter', sans-serif; font-size: 2rem; font-weight: 700; color: #fff; }
.hero-stat .label { color: rgba(255,255,255,0.6); font-size: 0.85rem; }

/* ---------- 3D hero card stack ---------- */
.hero-scene { position: relative; z-index: 1; perspective: 1400px; display: flex; align-items: center; justify-content: center; min-height: 420px; }
.scene-float { transform-style: preserve-3d; animation: scene-bob 6s ease-in-out infinite; }
@keyframes scene-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}
.scene-tilt {
  width: 320px; height: 320px; position: relative;
  transform-style: preserve-3d;
  transform: rotateX(10deg) rotateY(-16deg);
  transition: transform 0.25s ease-out;
}

.stack-card {
  position: absolute; width: 260px; height: 158px;
  border-radius: 20px; padding: 20px 22px; color: #fff;
  box-shadow: 0 30px 60px -22px rgba(0,0,0,0.55);
  transform-style: preserve-3d;
  overflow: hidden;
}
.stack-card-top .stack-biz { font-family: 'Inter', sans-serif; font-weight: 700; font-size: 1.05rem; }
.stack-card-top .stack-sub { font-size: 0.8rem; opacity: 0.8; margin-top: 2px; }
.stack-dots { display: flex; gap: 6px; margin-top: 16px; }
.stack-dots span { width: 12px; height: 12px; border-radius: 50%; background: rgba(255,255,255,0.22); border: 1px solid rgba(255,255,255,0.35); }
.stack-dots span.on { background: #fff; border-color: #fff; }
.stack-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 16px; font-size: 0.78rem; opacity: 0.85; }
.stack-wordmark { font-family: 'Inter', sans-serif; font-weight: 700; letter-spacing: 0.02em; }

.stack-card-1 {
  top: 50%; left: 50%; z-index: 3;
  transform: translate(-50%, -50%) translateZ(60px) rotate(-2deg);
  background: linear-gradient(155deg, var(--ink-2) 0%, var(--ink) 100%);
}
.stack-card-2 {
  top: 50%; left: 50%; z-index: 2; opacity: 0.94;
  transform: translate(-40%, -62%) translateZ(0px) rotate(9deg);
  background: linear-gradient(155deg, var(--accent) 0%, var(--accent-dark) 100%);
}
.stack-card-3 {
  top: 50%; left: 50%; z-index: 1; opacity: 0.88;
  transform: translate(-62%, -38%) translateZ(-60px) rotate(-15deg);
  background: linear-gradient(155deg, var(--teal) 0%, #106e59 100%);
}
.stack-shine {
  position: absolute; top: -60%; left: -70%; width: 55%; height: 220%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.28), transparent);
  transform: rotate(20deg);
  animation: stack-shine-sweep 5s ease-in-out infinite; animation-delay: 1s;
}
@keyframes stack-shine-sweep {
  0% { left: -70%; }
  45%, 100% { left: 140%; }
}

.float-badge {
  position: absolute; background: #ffffff; color: var(--ink);
  border: 1px solid rgba(18, 22, 42, 0.08); border-radius: 999px; padding: 9px 15px;
  font-size: 0.8rem; font-weight: 700; box-shadow: var(--shadow);
  display: flex; align-items: center; gap: 6px; white-space: nowrap;
  animation: badge-float 4.5s ease-in-out infinite; will-change: transform;
}
.fb-a { top: 2%; right: -6%; transform: translateZ(90px); animation-delay: 0s; }
.fb-b { bottom: 20%; left: -12%; transform: translateZ(90px); animation-delay: -1.4s; }
.fb-c { top: 46%; right: -16%; width: 34px; height: 34px; border-radius: 50%; justify-content: center; padding: 0; color: var(--teal); font-size: 1.1rem; transform: translateZ(90px); animation-delay: -2.4s; }
.fb-d { bottom: -6%; left: 22%; width: 34px; height: 34px; border-radius: 50%; justify-content: center; padding: 0; font-size: 1.05rem; transform: translateZ(90px); animation-delay: -3.2s; }
@keyframes badge-float {
  0%, 100% { transform: translateZ(90px) translateY(0); }
  50% { transform: translateZ(90px) translateY(-10px); }
}

@media (max-width: 900px) {
  .hero-scene { min-height: 320px; transform: scale(0.82); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-blob-1, .hero-blob-2, .hero-blob-3, .scene-float, .stack-shine, .float-badge { animation: none !important; }
  .scene-tilt { transition: none; }
}

/* ---------- Sections ---------- */
section { padding-block: 84px; }
.section-heading { max-width: 60ch; margin-bottom: 48px; }
.section-heading.center { margin-inline: auto; text-align: center; }
.eyebrow-sm { color: var(--accent); font-weight: 700; font-size: 0.82rem; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 10px; }
.section-heading h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); }
.section-heading p { color: var(--muted); font-size: 1.05rem; }

/* ---------- Feature grid ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 22px; }
.grid-3 { perspective: 1200px; }
.value-card {
  background: linear-gradient(165deg, var(--surface) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 28px 24px; box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  transform-style: preserve-3d;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  will-change: transform;
}
.value-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--teal));
  opacity: 0; transition: opacity 0.3s ease;
}
.value-card:hover::before { opacity: 1; }
.value-card:hover {
  border-color: rgba(255, 106, 77, 0.45);
  box-shadow: 0 30px 54px -20px rgba(255, 106, 77, 0.18), 0 16px 32px -18px rgba(0, 0, 0, 0.5);
}
.value-card .icon {
  width: 52px; height: 52px; display: flex; align-items: center; justify-content: center;
  border-radius: 14px; background: rgba(255, 106, 77, 0.14); color: var(--accent); margin-bottom: 18px;
}
.value-card .icon svg { width: 24px; height: 24px; }
.value-card h3 { font-size: 1.1rem; margin-bottom: 8px; color: var(--text); }
.value-card p { color: var(--muted); font-size: 0.95rem; margin: 0; }

/* ---------- Audience row ---------- */
.audience-row { display: flex; flex-wrap: wrap; gap: 14px; }
.audience-chip {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
  padding: 12px 20px; font-weight: 600; font-size: 0.95rem;
}

/* ---------- How it works steps ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 28px; counter-reset: step; }
.step { position: relative; padding-left: 54px; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--accent); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Inter', sans-serif; font-weight: 700; font-size: 1rem;
}
.step h3 { font-size: 1.05rem; margin-bottom: 6px; color: var(--text); }
.step p { color: var(--muted); font-size: 0.94rem; margin: 0; }

/* ---------- Client portal ---------- */
.portal-section { background: var(--ink); color: #fff; }
.portal-section .section-heading p { color: rgba(255,255,255,0.65); }
.portal-section .eyebrow-sm { color: var(--accent); }
.portal-section h2 { color: #fff; }

.client-search {
  display: flex; gap: 10px; max-width: 480px; margin-bottom: 32px;
}
.client-search input {
  flex: 1; font-family: inherit; font-size: 1rem; padding: 0.9em 1.1em;
  border-radius: 999px; border: 1.5px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.06); color: #fff;
}
.client-search input::placeholder { color: rgba(255,255,255,0.5); }
.client-search input:focus { outline: none; border-color: var(--accent); }

.client-list { display: flex; flex-direction: column; gap: 12px; }
.client-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-md); padding: 18px 22px;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.client-row:hover { background: rgba(255,255,255,0.09); border-color: rgba(255,255,255,0.25); }
.client-row .client-info { display: flex; align-items: center; gap: 14px; }
.client-row .client-badge {
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--accent); color: #fff; font-family: 'Inter', sans-serif; font-weight: 700;
  display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0;
}
.client-row .client-name { font-weight: 700; font-size: 1.02rem; }
.client-row .client-meta { color: rgba(255,255,255,0.55); font-size: 0.85rem; }
.client-empty { color: rgba(255,255,255,0.55); font-size: 0.95rem; padding: 18px 4px; display: none; }

/* ---------- CTA ---------- */
.cta-section {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #fff; text-align: center; border-radius: var(--radius-lg);
  margin-inline: 24px; padding: 64px 32px;
}
.cta-section h2 { color: #fff; }
.cta-section p { color: rgba(255,255,255,0.85); max-width: 50ch; margin-inline: auto 24px auto; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 24px; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding-block: 32px; color: var(--muted); font-size: 0.88rem; }
.site-footer .container { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--muted); }
.footer-links a:hover { color: var(--text); }

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s cubic-bezier(0.22,1,0.36,1), transform 0.7s cubic-bezier(0.22,1,0.36,1);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-stagger.is-visible .value-card,
.reveal-stagger.is-visible .step,
.reveal-stagger.is-visible .audience-chip {
  animation: reveal-pop 0.6s cubic-bezier(0.22,1,0.36,1) both;
}
.reveal-stagger .value-card:nth-child(1), .reveal-stagger .step:nth-child(1) { animation-delay: 0.02s; }
.reveal-stagger .value-card:nth-child(2), .reveal-stagger .step:nth-child(2) { animation-delay: 0.09s; }
.reveal-stagger .value-card:nth-child(3), .reveal-stagger .step:nth-child(3) { animation-delay: 0.16s; }
.reveal-stagger .value-card:nth-child(4), .reveal-stagger .step:nth-child(4) { animation-delay: 0.23s; }
.reveal-stagger .value-card:nth-child(5) { animation-delay: 0.3s; }
.reveal-stagger .value-card:nth-child(6) { animation-delay: 0.37s; }
@keyframes reveal-pop {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .reveal-stagger .value-card, .reveal-stagger .step, .reveal-stagger .audience-chip { animation: none !important; }
}

@media (max-width: 640px) {
  section { padding-block: 56px; }
  .hero { padding-block: 64px 72px; }
  .cta-section { margin-inline: 12px; padding: 48px 22px; }
  .client-search { flex-direction: column; }
}
