/* Stripe-inspired: light, airy pages, dark slate text, one blurple accent,
   and a colorful gradient wave in the hero. */
:root {
  --white: #ffffff;
  --mist: #f6f9fc;          /* pale blue-grey section background */
  --line: #e3e8ef;
  --ink: #1a1f36;           /* headings */
  --slate: #425466;         /* body text */
  --muted: #6b7c93;
  --blurple: #635bff;       /* the one accent */
  --blurple-dark: #4b45d6;
  --deep: #1a1f36;          /* dark section */
  --wave: linear-gradient(115deg, #f6a23a 0%, #ef7f45 18%, #d93fd0 38%, #b022f2 52%, #6a2cf5 70%, #4a14f2 82%, #2d6cf3 100%);
  --head: "Space Grotesk", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--white);
  color: var(--slate);
  font: 17px/1.65 var(--body);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { font-family: var(--head); color: var(--ink); letter-spacing: -0.02em; margin: 0; line-height: 1.08; text-wrap: balance; }
p { margin: 0; }
a { color: inherit; }
.wrap { max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--blurple); color: #fff; text-decoration: none;
  font-weight: 600; font-size: 16px;
  padding: 12px 22px; border-radius: 999px;
  border: 1px solid var(--blurple);
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-1px); background: var(--blurple-dark); box-shadow: 0 8px 20px -8px rgba(99,91,255,.6); }
.btn-ghost { background: rgba(255,255,255,.7); color: var(--ink); border-color: transparent; backdrop-filter: blur(6px); }
.btn-ghost:hover { background: #fff; box-shadow: 0 8px 20px -10px rgba(26,31,54,.25); }
.btn-small { padding: 8px 16px; font-size: 14px; }
.btn-large { padding: 16px 32px; font-size: 19px; }

/* Header */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 10;
  background: rgba(255,255,255,.78);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(227,232,239,.7);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.logo img { display: block; }
.logo .mark-img { width: 54px; height: auto; }
.logo .wordmark-img { height: 30px; width: auto; margin-top: 7px; }
.wordmark { font-family: "Montserrat", var(--body); font-weight: 600; font-size: 24px; letter-spacing: .01em; color: var(--ink); }
.wordmark b { font-weight: 700; color: #3d7ef5; }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a:not(.btn) { color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 500; opacity: .8; }
.nav-links a:not(.btn):hover { opacity: 1; }

/* Hero with gradient wave */
.hero {
  position: relative; overflow: hidden;
  background: var(--white);
  padding: 150px 0 210px;
}
.hero-bg {
  position: absolute; left: -10%; right: -10%; top: -30%; height: 142%;
  background: var(--wave);
  background-size: 130% 130%;
  transform: skewY(-11deg);
  transform-origin: top left;
  animation: wave 16s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes wave { from { background-position: 0% 50%; } to { background-position: 100% 50%; } }

.hero-grid { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 64px; align-items: center; }
.eyebrow { color: var(--ink); font-weight: 600; font-size: 14px; letter-spacing: .04em; margin-bottom: 20px; display: inline-block; background: rgba(255,255,255,.75); padding: 6px 14px; border-radius: 999px; }
.hero h1 { font-size: clamp(44px, 6.4vw, 80px); font-weight: 700; color: var(--ink); }
.hl { color: var(--ink); }
.hero .lede { font-size: clamp(18px, 2vw, 21px); color: var(--ink); margin-top: 24px; max-width: 480px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }

/* Capability orbit */
.orbit { position: relative; width: 100%; max-width: 480px; aspect-ratio: 1; margin-left: auto; }
.ring { position: absolute; border-radius: 50%; border: 1.5px dashed rgba(255,255,255,.45); }
.r1 { inset: 6%; animation: spin 60s linear infinite; }
.r2 { inset: 26%; border-style: solid; border-color: rgba(255,255,255,.25); animation: spin 40s linear infinite reverse; }
@keyframes spin { to { transform: rotate(360deg); } }
.core {
  position: absolute; left: 50%; top: 50%; width: 30%; aspect-ratio: 1; transform: translate(-50%, -50%);
  background: #fff; border-radius: 50%; display: grid; place-items: center;
  box-shadow: 0 30px 60px -20px rgba(26,31,54,.45), 0 0 0 10px rgba(255,255,255,.18);
}
.core img { width: 66%; height: auto; }
.chips { list-style: none; margin: 0; padding: 0; }
.chips li {
  position: absolute; left: var(--x); top: var(--y); transform: translate(-50%, -50%);
  background: #fff; color: var(--ink); font-weight: 600; font-size: 14px; white-space: nowrap;
  padding: 8px 14px; border-radius: 999px;
  box-shadow: 0 12px 28px -12px rgba(26,31,54,.45);
  opacity: 0; animation: pop .6s ease forwards, float 6s ease-in-out infinite;
  animation-delay: calc(.3s + var(--d) * .12s), calc(var(--d) * -.8s);
}
@keyframes pop { from { opacity: 0; } to { opacity: 1; } }
@keyframes float { 0%, 100% { margin-top: 0; } 50% { margin-top: -8px; } }

/* Statement */
.statement { padding: 130px 0 110px; }
.big { font-family: var(--head); font-weight: 600; font-size: clamp(32px, 5vw, 58px); line-height: 1.12; letter-spacing: -0.025em; max-width: 960px; color: var(--ink); }
.big .muted { color: var(--blurple); }

/* Sections */
.section { padding: 110px 0; }
.section h2 { font-size: clamp(34px, 4.5vw, 50px); margin-bottom: 52px; }
#services { background: var(--mist); }
.dark { background: var(--deep); color: #c1c9d2; }
.dark h2 { color: #fff; }

/* Services */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service {
  background: var(--white); border-radius: 14px;
  padding: 34px 30px 38px;
  box-shadow: 0 13px 27px -5px rgba(50,50,93,.12), 0 8px 16px -8px rgba(0,0,0,.12);
  transition: transform .3s ease, box-shadow .3s ease;
}
.service:hover { transform: translateY(-4px); box-shadow: 0 30px 60px -12px rgba(50,50,93,.22), 0 18px 36px -18px rgba(0,0,0,.2); }
.service svg { width: 44px; height: 44px; fill: none; stroke: var(--blurple); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.service .idx { color: var(--muted); font-size: 13px; font-weight: 600; margin-top: 30px; }
.service h3 { font-size: 30px; margin: 6px 0 12px; }
.service .hook { color: var(--ink); font-weight: 600; font-size: 18px; line-height: 1.4; margin-bottom: 10px; }

/* Pillars */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid rgba(255,255,255,.12); }
.pillar { padding: 36px 32px 8px 0; }
.pillar + .pillar { padding-left: 32px; border-left: 1px solid rgba(255,255,255,.12); }
.pn { display: block; font-family: var(--head); font-weight: 600; font-size: 26px; color: #fff; margin-bottom: 10px; letter-spacing: -0.02em; }
.pn::before { content: ""; display: block; width: 28px; height: 3px; border-radius: 3px; background: var(--wave); margin-bottom: 18px; }
.pillar p { font-size: 18px; }

/* CTA */
.cta { text-align: center; padding: 150px 0; position: relative; }
.cta h2 { font-size: clamp(40px, 6vw, 68px); margin-bottom: 0; }
.cta .lede { color: var(--slate); margin: 18px auto 40px; max-width: 520px; font-size: 19px; }

/* Footer */
.site-footer { background: var(--mist); color: var(--muted); font-size: 14px; padding: 32px 0; border-top: 1px solid var(--line); }
.footer-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.site-footer .logo .mark-img { width: 44px; }
.site-footer .logo .wordmark-img { height: 24px; margin-top: 5px; }
.site-footer .wordmark { font-size: 18px; }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .8s ease; }
.reveal.in { opacity: 1; transform: none; }
.services .reveal:nth-child(2), .pillars .reveal:nth-child(2) { transition-delay: .1s; }
.services .reveal:nth-child(3), .pillars .reveal:nth-child(3) { transition-delay: .2s; }

/* Responsive */
@media (max-width: 900px) {
  .hero { padding: 130px 0 90px; }
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .orbit { margin: 0 auto; max-width: 420px; }
  .services, .pillars { grid-template-columns: 1fr; }
  .pillar, .pillar + .pillar { padding: 28px 0; border-left: 0; }
  .pillar + .pillar { border-top: 1px solid rgba(255,255,255,.12); }
}
@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .hide-sm { display: none; }
  .statement, .section { padding: 80px 0; }
  .cta { padding: 100px 0; }
  .section h2 { margin-bottom: 36px; }
  .orbit { aspect-ratio: auto; max-width: none; }
  .ring, .core { display: none; }
  .chips { display: flex; flex-wrap: wrap; gap: 8px; }
  .chips li { position: static; transform: none; font-size: 13px; animation: pop .6s ease forwards; animation-delay: calc(.3s + var(--d) * .08s); }
  .btn-large { font-size: 17px; padding: 15px 26px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-bg { animation: none; }
  .reveal, .chips li { opacity: 1; transition: none; animation: none; }
  .ring { animation: none; }
}

/* Hero text on the logo-colored wave */
.hero h1, .hero .hl, .hero .lede { color: #fff; }
.hero h1 { text-shadow: 0 2px 24px rgba(26,31,54,.18); }
.hero .btn:not(.btn-ghost) { background: #fff; color: var(--ink); border-color: #fff; }
.hero .btn:not(.btn-ghost):hover { background: #f0f2ff; box-shadow: 0 10px 24px -10px rgba(26,31,54,.45); }
.hero .btn-ghost { background: rgba(255,255,255,.16); color: #fff; border-color: rgba(255,255,255,.45); }
.hero .btn-ghost:hover { background: rgba(255,255,255,.26); box-shadow: none; }

/* Worm character: crawls along the logo, then asks a question */
.logo-tab {
  display: flex; align-items: center; gap: 14px; margin-top: 36px; max-width: 470px;
  background: #fff; border-radius: 18px; padding: 14px 16px 14px 12px;
  box-shadow: 0 24px 48px -20px rgba(26,31,54,.45);
}
.tab-mark { width: 150px; flex: none; height: auto; display: block; overflow: visible; }
.t-track { stroke: #f1ebe6; }
.t-worm { stroke-dasharray: 0 99999; }
.t-eyes { transition: opacity .2s; }
.t-dot { r: 0; }
.t-ripple { opacity: 0; }
.tab-mark.pop .t-dot { animation: dotpop .45s cubic-bezier(.34,1.8,.64,1) forwards; }
.tab-mark.pop .t-ripple { animation: ripple .8s ease-out .1s; }
.sparks circle { opacity: 0; }
.sparks circle:nth-child(odd) { fill: #ffb23f; } .sparks circle:nth-child(even) { fill: #ff6a3d; }
.tab-mark.pop .sparks circle { animation: spark .7s ease-out .08s; }
@keyframes spark { 0% { opacity: 1; transform: translate(0, 0) scale(1); } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(.4); } }
@keyframes dotpop { 0% { r: 0; } 60% { r: 25px; } 100% { r: 19px; } }
@keyframes ripple { 0% { r: 20px; opacity: .8; } 100% { r: 56px; opacity: 0; } }

.bubble {
  position: relative; flex: 1; min-width: 0; min-height: 58px;
  display: flex; align-items: center;
  background: #fff1e6; color: var(--ink); text-decoration: none;
  border-radius: 14px; padding: 10px 14px;
  font-weight: 600; font-size: 15px; line-height: 1.35;
}
.bubble::before { content: ""; position: absolute; left: -7px; top: 50%; width: 14px; height: 14px; background: #fff1e6; transform: translateY(-50%) rotate(45deg); border-radius: 3px; }
.bubble .q { position: relative; opacity: 0; transform: translateY(6px) scale(.96); transition: opacity .25s, transform .45s cubic-bezier(.34,1.8,.64,1); }
.bubble.ask .q { opacity: 1; transform: none; }
.bubble.ask { animation: nudge .5s cubic-bezier(.34,1.8,.64,1); }
@keyframes nudge { 0% { transform: scale(.97); } 100% { transform: none; } }
.bubble.ask:hover .q { color: #e8572a; }
.typing { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); display: flex; gap: 5px; transition: opacity .2s; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: #ff8a4c; animation: dots .8s infinite; }
.typing i:nth-child(2) { animation-delay: .1s; } .typing i:nth-child(3) { animation-delay: .2s; }
@keyframes dots { 0%, 60%, 100% { transform: translateY(0); opacity: .4; } 30% { transform: translateY(-4px); opacity: 1; } }
.bubble.ask .typing { opacity: 0; }
@media (max-width: 560px) { .tab-mark { width: 118px; } .bubble { font-size: 14px; } }

@media (prefers-reduced-motion: reduce) {
  .typing i { animation: none; }
  .tab-mark.pop .t-dot { animation: none; r: 19px; }
  .tab-mark.pop .t-ripple, .tab-mark.pop .sparks circle, .bubble.ask { animation: none; }
}
