/* StyxLabs landing page — palette drawn from the logo (deep ocean → teal → ice blue) */
:root {
  --navy: #0d3a5c;
  --ocean: #1b5e8c;
  --teal: #2a8fb8;
  --ice: #bfe6f4;
  --mist: #eef6fa;
  --paper: #fafcfd;
  --ink: #12283a;
  --ink-soft: #4a6275;
  --line: #d6e5ee;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(13, 58, 92, .06), 0 8px 24px rgba(13, 58, 92, .07);
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ocean); }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; margin: 0; color: var(--navy); }
p { margin: 0; }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--navy); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; border-radius: 6px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 24px; border-radius: 10px;
  font-weight: 600; font-size: 16px; text-decoration: none;
  border: 1.5px solid transparent; transition: transform .15s, background .15s, box-shadow .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-sm { padding: 9px 16px; font-size: 15px; }
.btn-primary { background: var(--ocean); color: #fff; box-shadow: 0 6px 18px rgba(27, 94, 140, .25); }
.btn-primary:hover { background: var(--navy); }
.btn-secondary { background: #fff; color: var(--ocean); border-color: var(--line); }
.btn-secondary:hover { border-color: var(--teal); }
.btn-light { background: #fff; color: var(--navy); }
.btn-outline-light { color: #fff; border-color: rgba(255, 255, 255, .55); }
.btn-outline-light:hover { background: rgba(255, 255, 255, .1); }
.text-link { display: inline-block; margin-top: 18px; font-weight: 600; text-decoration: none; color: var(--teal); }
.text-link:hover { text-decoration: underline; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 252, 253, .85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.site-header.scrolled { border-bottom-color: var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { width: 29px; height: auto; }
.wordmark { font-family: var(--font-display); font-size: 24px; color: var(--ocean); letter-spacing: -.01em; }
.wordmark strong { font-weight: 700; }
.nav-menu { display: flex; align-items: center; gap: 28px; }
.nav-menu a:not(.btn) { color: var(--ink-soft); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav-menu a:not(.btn):hover { color: var(--ocean); }
.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; margin: 5px 0; background: var(--navy); transition: transform .2s, opacity .2s; }

/* Hero */
.hero { position: relative; overflow: hidden; padding: 88px 0 112px; background: radial-gradient(1200px 600px at 85% 10%, var(--mist), transparent 70%); }
.hero-flow { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.hero-flow path { fill: none; stroke: var(--teal); stroke-width: 1.5; opacity: .18; }
.hero-flow path:nth-child(2) { stroke: var(--ocean); opacity: .12; }
.hero-flow path:nth-child(3) { stroke: var(--ice); opacity: .6; stroke-width: 3; }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }
.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--teal); margin-bottom: 16px; }
.hero h1 { font-size: clamp(38px, 5.4vw, 64px); font-weight: 700; letter-spacing: -.025em; }
.accent { background: linear-gradient(100deg, var(--ocean), var(--teal)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lede { margin-top: 22px; font-size: 19px; color: var(--ink-soft); max-width: 560px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }

.hero-diagram { margin: 0; padding: 24px; background: #fff; border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); }
.hero-diagram svg { width: 100%; height: auto; display: block; }
.hero-diagram .links path { fill: none; stroke: var(--ice); stroke-width: 2.5; }
.hero-diagram .pulses circle { fill: var(--teal); }
.hero-diagram .node rect { fill: var(--mist); stroke: var(--line); }
.hero-diagram .node text { font: 600 13px var(--font-body); fill: var(--ocean); text-anchor: middle; }
.hero-diagram .node-root rect { fill: var(--ocean); stroke: none; }
.hero-diagram .node-root text { fill: #fff; font-size: 16px; font-family: var(--font-display); }
.hero-diagram .node-verify rect { fill: #fff; stroke: var(--teal); stroke-dasharray: 4 3; }
.hero-diagram .diagram-caption { font: 600 11px var(--font-body); letter-spacing: .12em; text-transform: uppercase; fill: var(--ink-soft); text-anchor: middle; }

/* Sections */
.section { padding: 104px 0; }
.section-head { max-width: 720px; margin-bottom: 56px; }
.section h2 { font-size: clamp(30px, 3.6vw, 44px); font-weight: 600; letter-spacing: -.02em; }
.section-lede { margin-top: 18px; font-size: 18px; color: var(--ink-soft); }
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.card, .feature { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.card h3, .feature h3 { font-size: 20px; font-weight: 600; margin-bottom: 10px; }
.card p, .feature p { color: var(--ink-soft); font-size: 16px; }
.card { border-top: 3px solid var(--teal); }
.callout { margin-top: 40px; font-family: var(--font-display); font-size: 22px; font-weight: 600; color: var(--ocean); }

/* Pillars */
.pillars { background: #fff; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.pillar-list { display: grid; gap: 0; }
.pillar { display: grid; grid-template-columns: 88px 1fr; gap: 24px; padding: 32px 0; border-top: 1px solid var(--line); }
.pillar:last-child { border-bottom: 1px solid var(--line); }
.pillar-num { font-family: var(--font-display); font-size: 40px; font-weight: 600; color: var(--ice); line-height: 1; transition: color .2s; }
.pillar:hover .pillar-num { color: var(--teal); }
.pillar-name { font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--teal); margin-bottom: 6px; }
.pillar h3 { font-size: 24px; font-weight: 600; margin-bottom: 8px; }
.pillar p:last-child { color: var(--ink-soft); max-width: 720px; }

/* Steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px; counter-reset: none; position: relative; }
.steps::before { content: ""; position: absolute; top: 22px; left: 22px; right: 22px; height: 2px; background: linear-gradient(90deg, var(--ocean), var(--teal), var(--ice)); }
.steps li { position: relative; }
.step-num {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--teal); color: var(--ocean);
  font-family: var(--font-display); font-weight: 700; margin-bottom: 18px; position: relative;
}
.steps h3 { font-size: 20px; font-weight: 600; margin-bottom: 8px; }
.steps p { font-size: 15.5px; color: var(--ink-soft); }

/* Platform */
.platform { background: var(--mist); }
.feature { position: relative; }
.feature::before { content: ""; display: block; width: 28px; height: 4px; border-radius: 2px; background: linear-gradient(90deg, var(--ocean), var(--teal)); margin-bottom: 18px; }

/* Use cases */
.uc-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; }
.uc-list li { padding: 28px 24px; border-right: 1px solid var(--line); }
.uc-list li:last-child { border-right: 0; }
.uc-list h3 { font-size: 18px; font-weight: 600; margin-bottom: 10px; }
.uc-list p { font-size: 15.5px; color: var(--ink-soft); }

/* Why */
.why-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; align-items: start; }
.why-grid .section-head { margin-bottom: 0; position: sticky; top: 112px; }
.why-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.why-list li { padding: 24px 28px; background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--teal); border-radius: var(--radius); }
.why-list h3 { font-size: 19px; font-weight: 600; margin-bottom: 6px; }
.why-list p { color: var(--ink-soft); font-size: 16px; }

/* CTA banner */
.cta-banner { position: relative; overflow: hidden; padding: 104px 0; background: linear-gradient(125deg, var(--navy) 0%, var(--ocean) 55%, var(--teal) 100%); color: #fff; }
.cta-banner::after {
  content: ""; position: absolute; right: -120px; top: -120px; width: 480px; height: 480px; border-radius: 50%;
  border: 60px solid rgba(191, 230, 244, .08);
}
.cta-inner { position: relative; z-index: 1; text-align: center; max-width: 820px; }
.cta-banner h2 { color: #fff; font-size: clamp(30px, 3.8vw, 46px); font-weight: 600; letter-spacing: -.02em; }
.cta-banner p { margin-top: 18px; font-size: 18px; color: rgba(255, 255, 255, .85); }
.cta-banner .cta-row { justify-content: center; }
.cta-banner .cta-email { margin-top: 24px; font-size: 15px; color: rgba(255, 255, 255, .75); }
.cta-email a { color: #fff; font-weight: 600; }

/* Footer */
.site-footer { background: #fff; border-top: 1px solid var(--line); padding: 64px 0 28px; font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr .8fr 1.4fr; gap: 40px; }
.footer-brand img { width: 240px; margin-bottom: 14px; }
.footer-brand p { color: var(--ink-soft); font-size: 14px; max-width: 320px; }
.site-footer h4 { font-size: 14px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 14px; color: var(--navy); }
.site-footer nav a { display: block; color: var(--ink-soft); text-decoration: none; padding: 4px 0; }
.site-footer nav a:hover { color: var(--ocean); }
.newsletter p { color: var(--ink-soft); margin-bottom: 14px; }
.nl-row { display: flex; gap: 8px; }
.nl-row input { flex: 1; min-width: 0; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; font: inherit; }
.nl-row input:focus { outline: 2px solid var(--teal); border-color: transparent; }
.legal { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--ink-soft); font-size: 14px; }
.legal a { color: var(--ink-soft); }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: none; }

/* Responsive */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .hero-diagram { max-width: 520px; }
  .steps { grid-template-columns: 1fr; gap: 28px; }
  .steps::before { top: 22px; bottom: 22px; left: 21px; right: auto; width: 2px; height: auto; background: linear-gradient(180deg, var(--ocean), var(--teal), var(--ice)); }
  .steps li { padding-left: 68px; }
  .step-num { position: absolute; left: 0; top: -6px; }
  .uc-list li { border-right: 0; border-bottom: 1px solid var(--line); }
  .uc-list li:last-child { border-bottom: 0; }
  .why-grid { grid-template-columns: 1fr; gap: 40px; }
  .why-grid .section-head { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav-menu {
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px 16px 20px; background: var(--paper); border-bottom: 1px solid var(--line);
    display: none;
  }
  .nav-menu.open { display: flex; }
  .nav-menu a:not(.btn) { padding: 14px 4px; border-bottom: 1px solid var(--line); font-size: 16px; }
  .nav-menu .btn { margin-top: 16px; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .grid-3 { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .hero { padding: 56px 0 72px; }
  .section, .cta-banner { padding: 72px 0; }
  .section-head { margin-bottom: 40px; }
  .pillar { grid-template-columns: 1fr; gap: 8px; }
  .pillar-num { font-size: 28px; }
  .cta-row .btn { flex: 1 1 100%; }
  .footer-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-diagram .pulses { display: none; }
  .btn { transition: none; }
}
