/* ==========================================================================
   FastCodec — design system
   Tokens are the Nice Prototypes UI system (niceprototypes.com/ui), kept under
   their original `--np--*` names so values can be checked against the source.
   Day is the default; night follows prefers-color-scheme. `--ink*` tokens are
   the always-dark feature surfaces (hero, query, CTA) and do not flip.
   ========================================================================== */

/* ---------------------------------------------------------------- tokens */
:root {
  color-scheme: light dark;

  /* type */
  --np--font-family: "Google Sans Flex", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --np--font-family--heading: var(--np--font-family);
  --np--font-family--code: "Roboto Mono", "Courier New", monospace;
  --np--font-weight--light: 300;
  --np--font-weight: 400;
  --np--font-weight--medium: 500;
  --np--font-weight--semibold: 600;
  --np--font-weight--bold: 700;
  --np--letter-spacing--tight: -.025em;
  --np--letter-spacing: 0;
  --np--letter-spacing--wide: .025em;
  --np--letter-spacing--wider: .05em;
  --np--line-height--single: 1;
  --np--line-height--condensed: 1.25;
  --np--line-height: 1.5;
  --np--line-height--expanded: 1.75;
  --np--font-size--smaller: 12px;
  --np--font-size--small: 14px;
  --np--font-size: 16px;
  --np--font-size--large: 24px;
  --np--font-size--larger: 32px;

  /* shape */
  --np--border-radius--smaller: 2px;
  --np--border-radius--small: 4px;
  --np--border-radius: 8px;
  --np--border-radius--large: 16px;
  --np--border-radius--larger: 32px;
  --np--border-width--small: 1px;
  --np--border-width: 1.5px;
  --np--border-width--large: 2px;
  --np--box-shadow: 0 1px 4px hsla(0, 0%, 0%, .075);
  --np--box-shadow--large: 0 2px 8px hsla(0, 0%, 0%, .1);

  /* space & size */
  --np--gap--smaller: 4px;
  --np--gap--small: 8px;
  --np--gap: 16px;
  --np--gap--large: 32px;
  --np--gap--larger: 48px;
  --np--size--smaller: 24px;
  --np--size--small: 32px;
  --np--size: 48px;
  --np--size--large: 64px;

  /* motion */
  --np--animation-duration--faster: .12s;
  --np--animation-duration--fast: .16s;
  --np--animation-duration: .24s;
  --np--animation-duration--slow: .48s;
  --np--animation-duration--slower: .96s;
  --np--animation-easing: ease-in-out;
  --ease-out-expo: cubic-bezier(.16, 1, .3, 1);

  /* brand */
  --np--brand-color: hsla(240, 100%, 74.5%, 1);
  --np--brand-color--secondary: hsla(198, 100%, 54.1%, 1);
  --brand-gradient: linear-gradient(100deg, var(--np--brand-color) 0%, var(--np--brand-color--secondary) 100%);

  /* day */
  --np--color: hsla(210, 5%, 5%, 1);
  --np--color--light: hsla(210, 5%, 25%, 1);
  --np--color--lighter: hsla(210, 5%, 42%, 1);   /* source 50%; darkened for 4.5:1 on raised */
  --np--color--lightest: hsla(210, 5%, 75%, 1);
  --np--color--link: hsla(212, 100%, 46%, 1);
  --np--color--success: hsla(146, 68%, 34%, 1);
  --np--color--error: hsla(10, 80%, 46%, 1);
  --np--background-color: hsla(212, 10%, 100%, 1);
  --np--background-color--raised: hsla(212, 10%, 97%, 1);
  --np--background-color--link: hsla(212, 100%, 95%, 1);
  --np--background-color--error: hsla(10, 100%, 95%, 1);
  --np--border-color--subtle: hsla(240, 9%, 95%, 1);
  --np--border-color: hsla(240, 9%, 91%, 1);
  --np--border-color--strong: hsla(210, 8%, 58%, 1);

  --surface: var(--np--background-color);
  --surface-alt: var(--np--background-color--raised);
  --tile: var(--np--background-color--raised);
  --tile-on-alt: var(--np--background-color);
  --accent-text: hsla(240, 62%, 54%, 1);   /* brand hue, deep enough for body text */

  /* ink: always-dark feature surfaces */
  --ink: hsla(212, 10%, 4%, 1);
  --ink-raised: hsla(212, 10%, 11%, 1);
  --ink-raised-2: hsla(212, 10%, 15%, 1);
  --ink-line: hsla(240, 5%, 22%, 1);
  --ink-text: hsla(210, 5%, 95%, 1);
  --ink-text-light: hsla(210, 5%, 95%, .72);
  --ink-text-lighter: hsla(210, 5%, 95%, .55);
  --ink-link: hsla(202, 90%, 65%, 1);

  /* layout */
  --gutter: clamp(16px, 4vw, 32px);
  --wrap: 1080px;
  --wrap-wide: 1280px;
  --nav-h: 52px;
  --section-pad: clamp(88px, 12vw, 168px);
}

@media (prefers-color-scheme: dark) {
  :root {
    --np--color: hsla(210, 5%, 95%, 1);
    --np--color--light: hsla(210, 5%, 95%, .85);
    --np--color--lighter: hsla(210, 5%, 95%, .6);
    --np--color--lightest: hsla(210, 5%, 95%, .25);
    --np--color--link: hsla(202, 90%, 65%, 1);
    --np--color--success: hsla(146, 58%, 59%, 1);
    --np--color--error: hsla(10, 82%, 75%, 1);
    --np--background-color: hsla(212, 10%, 4%, 1);
    --np--background-color--raised: hsla(212, 10%, 9%, 1);
    --np--background-color--link: hsla(202, 50%, 18%, 1);
    --np--background-color--error: hsla(10, 55%, 20%, 1);
    --np--border-color--subtle: hsla(240, 5%, 14%, 1);
    --np--border-color: hsla(240, 5%, 22%, 1);
    --np--border-color--strong: hsla(240, 5%, 50%, 1);
    --tile: hsla(212, 10%, 11%, 1);
    --tile-on-alt: hsla(212, 10%, 13%, 1);
    --accent-text: var(--np--brand-color);
    --np--box-shadow: 0 1px 4px hsla(0, 0%, 0%, .4);
    --np--box-shadow--large: 0 2px 8px hsla(0, 0%, 0%, .5);
  }
}

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--nav-h) + 56px);
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--np--color);
  font-family: var(--np--font-family);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -.011em;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, p, figure, blockquote, dl, dd { margin: 0; }
h1, h2, h3, h4 { font-family: var(--np--font-family--heading); font-weight: var(--np--font-weight--semibold); }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
strong { font-weight: var(--np--font-weight--semibold); }
code, .mono { font-family: var(--np--font-family--code); }
button, input, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
::selection { background: hsla(240, 100%, 74.5%, .35); }

:focus-visible {
  outline: 2px solid var(--np--color--link);
  outline-offset: 3px;
  border-radius: 6px;
}

.site { overflow-x: hidden; }
@supports (overflow: clip) { .site { overflow-x: clip; } }
.site--flex { min-height: 100vh; display: flex; flex-direction: column; }
.site--flex main { flex: 1; }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 10000;
  padding: 10px 16px; border-radius: 999px;
  background: var(--np--color--link); color: #fff; font-size: 14px; font-weight: 600;
  transition: top var(--np--animation-duration);
}
.skip-link:focus { top: 12px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------------------------------------------------------------- layout */
.wrap { width: 100%; max-width: calc(var(--wrap) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.wrap--wide { max-width: calc(var(--wrap-wide) + var(--gutter) * 2); }
.wrap--narrow { max-width: calc(760px + var(--gutter) * 2); }

.section { padding: var(--section-pad) 0; background: var(--surface); position: relative; }
.section--alt { background: var(--surface-alt); }
.section--alt .tile { background: var(--tile-on-alt); }
.section--tight { padding-top: clamp(56px, 7vw, 96px); padding-bottom: clamp(56px, 7vw, 96px); }
.section--flush-top { padding-top: 0; }

.ink {
  background: var(--ink);
  color: var(--ink-text);
  --np--color: var(--ink-text);
  --np--color--light: var(--ink-text-light);
  --np--color--lighter: var(--ink-text-lighter);
  --np--color--link: var(--ink-link);
  --np--border-color: var(--ink-line);
  --np--border-color--subtle: hsla(240, 5%, 16%, 1);
  --accent-text: var(--np--brand-color);
  --tile: var(--ink-raised);
  --tile-on-alt: var(--ink-raised);
}

.center { text-align: center; }
.center .lede, .center .headline, .center .display { margin-left: auto; margin-right: auto; }

/* ------------------------------------------------------------ typography */
.eyebrow {
  display: block;
  font-size: clamp(17px, 1.6vw, 21px);
  font-weight: var(--np--font-weight--semibold);
  letter-spacing: -.01em;
  color: var(--accent-text);
  margin-bottom: 14px;
}
.eyebrow--gradient {
  background: var(--brand-gradient);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  width: fit-content;
}
.center .eyebrow--gradient { margin-left: auto; margin-right: auto; }

.display {
  font-size: clamp(46px, 8.4vw, 104px);
  line-height: 1.02;
  letter-spacing: -.038em;
  font-weight: var(--np--font-weight--semibold);
  max-width: 11ch;
}
.headline {
  font-size: clamp(36px, 5.6vw, 72px);
  line-height: 1.04;
  letter-spacing: -.032em;
  font-weight: var(--np--font-weight--semibold);
  max-width: 16ch;
}
.headline--md { font-size: clamp(32px, 4.4vw, 56px); max-width: 18ch; }
.headline--wide { max-width: 22ch; }
.title {
  font-size: clamp(22px, 2.2vw, 28px);
  line-height: 1.14;
  letter-spacing: -.022em;
  font-weight: var(--np--font-weight--semibold);
}
.title--lg { font-size: clamp(28px, 3.2vw, 40px); letter-spacing: -.028em; line-height: 1.08; }
.lede {
  font-size: clamp(19px, 1.9vw, 24px);
  line-height: 1.38;
  letter-spacing: -.016em;
  color: var(--np--color--light);
  max-width: 36em;
  margin-top: 22px;
}
.lede strong { color: var(--np--color); }
.body { color: var(--np--color--light); margin-top: 12px; }
.body + .body { margin-top: 14px; }
.small { font-size: 14px; color: var(--np--color--lighter); line-height: 1.43; }

.gradient-text {
  background: var(--brand-gradient);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  padding-bottom: .06em;
}
.muted { color: var(--np--color--lighter); }

.head { margin-bottom: clamp(48px, 6vw, 80px); }
.head.center .lede { margin-left: auto; margin-right: auto; }

/* --------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--np--size);
  padding: 0 calc(var(--np--size) / 2);
  border-radius: 999px;
  border: 0;
  background: var(--np--color--link);
  color: #fff;
  font-size: 17px;
  font-weight: var(--np--font-weight--medium);
  letter-spacing: -.01em;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--np--animation-duration), transform var(--np--animation-duration--fast), box-shadow var(--np--animation-duration);
}
.btn:hover { background: hsla(212, 100%, 40%, 1); }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .6; cursor: progress; }
.ink .btn, .btn--brand { background: #fff; color: var(--ink); }
.ink .btn:hover, .btn--brand:hover { background: hsla(210, 5%, 86%, 1); }
@media (prefers-color-scheme: dark) {
  /* 46% is the lightest this blue goes while white text keeps 4.5:1. */
  .btn { background: hsla(212, 100%, 46%, 1); }
  .btn:hover { background: hsla(212, 100%, 40%, 1); }
  .ink .btn { background: #fff; }
  .ink .btn:hover { background: hsla(210, 5%, 86%, 1); }
}
.btn--sm { min-height: 30px; padding: 0 14px; font-size: 13px; font-weight: var(--np--font-weight--medium); }
.btn--ghost {
  background: transparent; color: var(--np--color);
  box-shadow: inset 0 0 0 var(--np--border-width) var(--np--border-color--strong);
}
.btn--ghost:hover { background: var(--np--border-color--subtle); }
.ink .btn--ghost { background: transparent; color: var(--ink-text); box-shadow: inset 0 0 0 var(--np--border-width) hsla(210, 5%, 95%, .35); }
.ink .btn--ghost:hover { background: hsla(210, 5%, 95%, .08); }
.btn--block { width: 100%; }

.link {
  display: inline-flex; align-items: center; gap: 2px;
  color: var(--np--color--link);
  font-size: 17px;
  font-weight: var(--np--font-weight);
}
.link::after { content: "›"; font-size: 1.15em; line-height: 1; transform: translateY(-.02em); transition: transform var(--np--animation-duration); }
.link:hover { text-decoration: underline; text-underline-offset: 3px; }
.link:hover::after { transform: translate(2px, -.02em); }
.link--lg { font-size: clamp(17px, 1.6vw, 21px); }

.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; margin-top: 36px; }
.center .cta-row { justify-content: center; }
.reassure { display: flex; align-items: center; gap: 8px; margin-top: 22px; font-size: 14px; color: var(--np--color--lighter); }
.center .reassure { justify-content: center; }
.reassure svg { flex: none; width: 16px; height: 16px; color: var(--np--color--success); }
.ink .reassure svg { color: hsla(146, 58%, 59%, 1); }

/* ------------------------------------------------------------------- nav */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 1000;
  height: var(--nav-h);
  background: hsla(212, 10%, 9%, .78);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  color: var(--ink-text);
  transition: transform var(--np--animation-duration--slow) var(--ease-out-expo), background-color var(--np--animation-duration);
}
.nav.is-scrolled { background: hsla(212, 10%, 9%, .86); box-shadow: 0 1px 0 hsla(0, 0%, 100%, .06); }
.nav.is-hidden { transform: translateY(-100%); }
.nav__inner {
  height: 100%; max-width: calc(var(--wrap) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--ink-text); }
.brand__mark { width: 22px; height: 22px; flex: none; }
.brand__name { font-size: 17px; font-weight: var(--np--font-weight--semibold); letter-spacing: -.02em; }
.nav__links { display: none; align-items: center; gap: 32px; }
.nav__link { font-size: 13px; color: var(--ink-text-light); letter-spacing: -.005em; transition: color var(--np--animation-duration--fast); }
.nav__link:hover, .nav__link.is-active { color: var(--ink-text); }
.nav .btn--sm { background: #fff; color: var(--ink); }
.nav .btn--sm:hover { background: hsla(210, 5%, 86%, 1); }

.burger {
  width: 44px; height: 44px; margin-right: -10px;
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  background: none; border: 0; cursor: pointer; color: var(--ink-text);
}
.burger__bar { width: 18px; height: 1.5px; background: currentColor; border-radius: 2px; transition: transform var(--np--animation-duration) var(--ease-out-expo), opacity var(--np--animation-duration--fast); }
.burger.is-open .burger__bar:nth-child(1) { transform: translateY(3.75px) rotate(45deg); }
.burger.is-open .burger__bar:nth-child(2) { transform: translateY(-3.75px) rotate(-45deg); }
.burger.is-open .burger__bar:nth-child(3) { display: none; }

.mobile-menu {
  position: fixed; inset: var(--nav-h) 0 0 0; z-index: 999;
  background: hsla(212, 10%, 6%, .97);
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
  padding: 20px calc(var(--gutter) + 16px) 40px;
  display: flex; flex-direction: column;
  overflow-y: auto;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu__link {
  color: var(--ink-text); font-size: 28px; font-weight: var(--np--font-weight--semibold); letter-spacing: -.025em;
  padding: 10px 0;
}
.mobile-menu__link.is-active { color: var(--ink-text); }
.mobile-menu__link:not(.is-active) { color: var(--ink-text-light); }
.mobile-menu .btn { margin-top: 28px; align-self: flex-start; }
.mobile-menu.is-open .mobile-menu__link { animation: menu-in var(--np--animation-duration--slow) var(--ease-out-expo) both; }
.mobile-menu.is-open .mobile-menu__link:nth-child(2) { animation-delay: .03s; }
.mobile-menu.is-open .mobile-menu__link:nth-child(3) { animation-delay: .06s; }
.mobile-menu.is-open .mobile-menu__link:nth-child(4) { animation-delay: .09s; }
@keyframes menu-in { from { opacity: 0; transform: translateY(-8px); } }

@media (min-width: 768px) {
  .nav__links { display: flex; }
  .burger { display: none; }
}

/* local (in-page) nav — technology */
.subnav {
  position: sticky; top: 0; z-index: 900;
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--np--border-color);
  transition: top var(--np--animation-duration--slow) var(--ease-out-expo);
}
.nav:not(.is-hidden) ~ main .subnav { top: var(--nav-h); }
.subnav__inner { height: 52px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.subnav__title { font-size: 19px; font-weight: var(--np--font-weight--semibold); letter-spacing: -.02em; white-space: nowrap; }
.subnav__links { display: flex; align-items: center; gap: 22px; overflow-x: auto; scrollbar-width: none; }
.subnav__links::-webkit-scrollbar { display: none; }
.subnav__link { font-size: 13px; color: var(--np--color--light); white-space: nowrap; }
.subnav__link:hover { color: var(--np--color--link); }
@media (max-width: 767px) {
  .subnav__title { display: none; }
  .subnav__inner { justify-content: flex-start; }
}

/* ------------------------------------------------------------------ hero */
.hero {
  position: relative;
  padding: calc(var(--nav-h) + clamp(72px, 11vw, 140px)) 0 clamp(72px, 9vw, 120px);
  overflow: hidden;
  isolation: isolate;
}
.hero__glow {
  position: absolute; z-index: -1; pointer-events: none;
  left: 50%; top: -10%;
  width: min(1200px, 140vw); aspect-ratio: 1.6;
  transform: translateX(-50%);
  background:
    radial-gradient(closest-side at 35% 55%, hsla(240, 100%, 74.5%, .30), transparent 70%),
    radial-gradient(closest-side at 68% 45%, hsla(198, 100%, 54.1%, .24), transparent 70%);
  filter: blur(40px);
}
.hero__glow--low { top: auto; bottom: -55%; }
.hero .display, .hero .headline { margin: 0 auto; }
.hero--page { padding-bottom: clamp(64px, 8vw, 104px); }
.hero--page .headline { max-width: 15ch; }

/* hero product visual: the .fhc container */
.codec {
  position: relative;
  max-width: 920px; margin: clamp(64px, 8vw, 96px) auto 0;
  border-radius: var(--np--border-radius--larger);
  padding: 1px;
  background: linear-gradient(140deg, hsla(240, 100%, 74.5%, .6), hsla(240, 5%, 30%, .35) 40%, hsla(198, 100%, 54.1%, .55));
  box-shadow: 0 40px 120px -30px hsla(240, 100%, 60%, .45);
}
.codec__inner {
  border-radius: calc(var(--np--border-radius--larger) - 1px);
  background: linear-gradient(180deg, hsla(212, 10%, 11%, .96), hsla(212, 10%, 7%, .98));
  padding: clamp(22px, 3.6vw, 40px);
  text-align: left;
}
.codec__head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px; font-family: var(--np--font-family--code); font-size: 12px; letter-spacing: var(--np--letter-spacing--wider); color: var(--ink-text-lighter); }
.codec__head b { font-weight: 500; color: var(--np--brand-color--secondary); }
.codec__lanes { margin-top: clamp(22px, 3vw, 32px); display: grid; gap: 12px; }
.lane {
  display: grid; grid-template-columns: 112px 1fr auto; align-items: center; gap: 18px;
  padding: 16px 18px; border-radius: var(--np--border-radius--large);
  background: hsla(210, 5%, 95%, .04);
  box-shadow: inset 0 0 0 1px hsla(210, 5%, 95%, .06);
}
.lane__name { font-size: 19px; font-weight: var(--np--font-weight--semibold); letter-spacing: -.02em; color: var(--ink-text); }
.lane__meta { font-family: var(--np--font-family--code); font-size: 12px; color: var(--ink-text-lighter); white-space: nowrap; }
.lane__track { position: relative; height: 6px; border-radius: 6px; background: hsla(210, 5%, 95%, .08); overflow: hidden; }
.lane__pulse {
  position: absolute; inset: 0 auto 0 0; width: 34%;
  border-radius: inherit; background: var(--brand-gradient);
  animation: lane 3.6s var(--ease-out-expo) infinite;
}
.lane:nth-child(2) .lane__pulse { animation-delay: .5s; }
.lane:nth-child(3) .lane__pulse { animation-delay: 1s; }
@keyframes lane { 0% { transform: translateX(-110%); } 60%, 100% { transform: translateX(310%); } }
.codec__foot { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px;
  font-size: 12px; font-weight: var(--np--font-weight--medium); letter-spacing: .01em;
  color: var(--ink-text-light);
  background: hsla(210, 5%, 95%, .06);
}
.chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--brand-gradient); }
@media (max-width: 640px) {
  .lane { grid-template-columns: 1fr auto; gap: 10px 14px; }
  .lane__track { grid-column: 1 / -1; grid-row: 2; }
}

/* ------------------------------------------------------------ proof bar */
.proof { border-top: 1px solid var(--np--border-color--subtle); }
.proof__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px 24px; padding: clamp(40px, 5vw, 56px) 0; }
.proof__value { font-size: clamp(32px, 3.6vw, 44px); font-weight: var(--np--font-weight--semibold); letter-spacing: -.035em; line-height: 1; font-variant-numeric: tabular-nums; }
.proof__value span { font-size: .5em; letter-spacing: -.01em; color: var(--np--color--light); margin-left: 3px; }
.proof__label { margin-top: 10px; font-size: 14px; color: var(--np--color--lighter); line-height: 1.4; max-width: 22ch; }
@media (min-width: 900px) { .proof__grid { grid-template-columns: repeat(4, 1fr); } }

/* ----------------------------------------------------------------- tiles */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: clamp(12px, 1.6vw, 20px); }
.bento > * { grid-column: span 6; }
@media (min-width: 834px) {
  .span-2 { grid-column: span 2 !important; }
  .span-3 { grid-column: span 3 !important; }
  .span-4 { grid-column: span 4 !important; }
}

.tile {
  position: relative; overflow: hidden;
  border-radius: var(--np--border-radius--larger);
  background: var(--tile);
  padding: clamp(28px, 3.6vw, 48px);
  display: flex; flex-direction: column;
  isolation: isolate;
}
.tile--ink { background: var(--ink); color: var(--ink-text); --np--color: var(--ink-text); --np--color--light: var(--ink-text-light); --np--color--lighter: var(--ink-text-lighter); --np--color--link: var(--ink-link); --accent-text: var(--np--brand-color); }
.ink .tile--ink, .tile--ink.tile--raised { background: var(--ink-raised); }
.section--alt .tile--ink { background: var(--ink); }
@media (prefers-color-scheme: dark) {
  /* At night --surface is the same colour as --ink, so an ink tile on a plain
     section would lose its edge; lift it above the neighbouring tiles instead. */
  .tile--ink { background: var(--ink-raised-2); }
}
.tile--brand, .section--alt .tile--brand {
  background:
    radial-gradient(120% 90% at 100% 0%, hsla(198, 100%, 54.1%, .55), transparent 60%),
    radial-gradient(120% 90% at 0% 100%, hsla(240, 100%, 74.5%, .65), transparent 60%),
    hsla(240, 45%, 22%, 1);
  color: #fff;
  --np--color: #fff; --np--color--light: hsla(0, 0%, 100%, .86); --np--color--lighter: hsla(0, 0%, 100%, .7); --np--color--link: #fff; --accent-text: #fff;
}
.tile--center { text-align: center; align-items: center; }
.tile--tall { min-height: clamp(420px, 44vw, 560px); }
a.tile { transition: transform var(--np--animation-duration--slow) var(--ease-out-expo); }
a.tile:hover { transform: scale(1.012); }
a.tile:hover .link { text-decoration: underline; text-underline-offset: 3px; }
.tile__label {
  font-family: var(--np--font-family--code); font-size: 12px; font-weight: 500;
  letter-spacing: var(--np--letter-spacing--wider); text-transform: uppercase;
  color: var(--np--color--lighter); margin-bottom: 18px;
}
.tile .title + .body { margin-top: 12px; }
.tile__figure {
  margin-top: auto; padding-top: clamp(32px, 4vw, 48px);
  font-size: clamp(48px, 5.6vw, 72px); font-weight: var(--np--font-weight--semibold);
  letter-spacing: -.045em; line-height: 1; font-variant-numeric: tabular-nums;
}
.tile__figure span { font-size: .32em; font-weight: var(--np--font-weight--medium); letter-spacing: -.01em; color: var(--np--color--lighter); margin-left: 6px; }
.tile__figure--gradient { background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.tile__figure--gradient span { -webkit-text-fill-color: var(--np--color--lighter); }
.tile .link { margin-top: 20px; }
.tile__spacer { flex: 1; min-height: 24px; }
.tile__icon {
  width: 44px; height: 44px; border-radius: 12px; margin-bottom: 22px;
  display: grid; place-items: center;
  background: var(--np--background-color--link); color: var(--np--color--link);
}
.tile--ink .tile__icon, .ink .tile__icon { background: hsla(210, 5%, 95%, .08); color: var(--np--brand-color); }
.tile__icon svg { width: 22px; height: 22px; }

/* decorative block field inside the compressed-query tile */
.blockfield { margin-top: auto; padding-top: 40px; display: grid; grid-template-columns: repeat(16, 1fr); gap: 5px; }
.blockfield i { aspect-ratio: 1; border-radius: 3px; background: hsla(210, 5%, 95%, .07); }
.blockfield i.on { background: var(--brand-gradient); box-shadow: 0 0 18px hsla(240, 100%, 74.5%, .6); }

/* ------------------------------------------------------------ comparison */
.compare { display: grid; gap: clamp(12px, 1.6vw, 20px); }
@media (min-width: 834px) { .compare { grid-template-columns: 1fr 1fr; } }
.compare .tile { padding: clamp(28px, 3.6vw, 44px); }
.checklist { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 16px; }
.checklist li { display: grid; grid-template-columns: 24px 1fr; gap: 12px; align-items: start; color: var(--np--color--light); }
.checklist li strong { color: var(--np--color); display: block; }
.checklist svg { width: 22px; height: 22px; margin-top: 1px; }
.checklist--no svg { color: var(--np--color--lighter); }
.checklist--yes svg { color: var(--np--brand-color); }

/* --------------------------------------------------------------- metrics */
.metrics { display: grid; grid-template-columns: 1fr; gap: 0; border-top: 1px solid var(--np--border-color); }
.metric { padding: 32px 0; border-bottom: 1px solid var(--np--border-color); }
@media (min-width: 640px) {
  .metrics { grid-template-columns: repeat(2, 1fr); column-gap: 48px; }
}
@media (min-width: 1000px) {
  .metrics--3 { grid-template-columns: repeat(3, 1fr); }
  .metrics--4 { grid-template-columns: repeat(4, 1fr); column-gap: 32px; }
}
.metric__value {
  font-size: clamp(52px, 6vw, 80px); font-weight: var(--np--font-weight--semibold);
  letter-spacing: -.045em; line-height: 1; font-variant-numeric: tabular-nums;
}
.metric__value span { font-size: .36em; letter-spacing: -.01em; color: var(--np--color--lighter); margin-left: 4px; font-weight: var(--np--font-weight--medium); }
.metric__value--gradient { background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; width: fit-content; }
.metric__label { margin-top: 14px; color: var(--np--color--light); max-width: 30ch; }
.footnote { margin-top: 32px; font-size: 12px; color: var(--np--color--lighter); max-width: 70ch; line-height: 1.5; }
.center .footnote { margin-left: auto; margin-right: auto; }

/* ---------------------------------------------------------------- quotes */
.query-example {
  display: block; margin-top: 22px; padding: 16px 18px;
  border-radius: var(--np--border-radius--large);
  font-family: var(--np--font-family--code); font-size: 14px; line-height: 1.55;
  color: var(--np--color);
  background: var(--np--background-color--link);
}
.tile--ink .query-example, .ink .query-example { background: hsla(210, 5%, 95%, .06); }
.query-example__prompt { color: var(--np--color--link); margin-right: 8px; }
.query-example + .query-example { margin-top: 10px; }

/* ----------------------------------------------------------------- steps */
.steps { display: grid; gap: clamp(12px, 1.6vw, 20px); counter-reset: step; }
@media (min-width: 834px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { counter-increment: step; }
.step::before {
  content: counter(step);
  display: grid; place-items: center;
  width: 40px; height: 40px; border-radius: 50%; margin-bottom: 26px;
  font-size: 17px; font-weight: var(--np--font-weight--semibold);
  color: #fff; background: var(--brand-gradient);
}
.steps--compact { gap: 22px; margin-top: 8px; }
.steps--compact .step { display: grid; grid-template-columns: 32px 1fr; gap: 14px; padding: 0; background: none; }
.steps--compact .step::before { width: 32px; height: 32px; margin: 0; font-size: 14px; }
.steps--compact .step h3 { font-size: 17px; font-weight: var(--np--font-weight--semibold); letter-spacing: -.015em; }
.steps--compact .step p { color: var(--np--color--light); font-size: 15px; margin-top: 4px; }
@media (min-width: 834px) { .steps--compact { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------- faq */
.faq { border-top: 1px solid var(--np--border-color); }
.faq details { border-bottom: 1px solid var(--np--border-color); }
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 26px 0;
  font-size: clamp(19px, 1.9vw, 24px); font-weight: var(--np--font-weight--semibold); letter-spacing: -.02em; line-height: 1.25;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 14px; height: 14px;
  background:
    linear-gradient(currentColor, currentColor) center / 14px 1.5px no-repeat,
    linear-gradient(currentColor, currentColor) center / 1.5px 14px no-repeat;
  color: var(--np--color--lighter);
  transition: transform var(--np--animation-duration) var(--ease-out-expo);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--np--color--link); }
.faq__a { padding: 0 0 28px; max-width: 62ch; color: var(--np--color--light); }
.faq__a p + p { margin-top: 12px; }

/* ------------------------------------------------------------------- cta */
.cta { position: relative; overflow: hidden; isolation: isolate; text-align: center; }
.cta .headline { margin: 0 auto; }
.cta .lede { margin-left: auto; margin-right: auto; }

/* ------------------------------------------------------------ technology */
.query-wrap { position: relative; height: 300vh; }
.query-sticky { position: sticky; top: 0; height: 100vh; height: 100svh; display: flex; align-items: center; }
.query-inner { width: 100%; text-align: center; padding-top: var(--nav-h); }
.query-readout {
  margin: clamp(36px, 5vh, 56px) auto 0; max-width: 860px;
  display: grid; grid-template-columns: 1fr; gap: 28px; align-items: center;
}
@media (min-width: 760px) { .query-readout { grid-template-columns: 300px 1fr; gap: 40px; } }
.query-num {
  font-size: clamp(64px, 8vw, 112px); font-weight: var(--np--font-weight--semibold);
  letter-spacing: -.05em; line-height: 1; font-variant-numeric: tabular-nums;
  background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.query-num__label { margin-top: 10px; font-family: var(--np--font-family--code); font-size: 12px; letter-spacing: var(--np--letter-spacing--wider); color: var(--ink-text-lighter); }
.query-blocks { padding: clamp(16px, 2.4vw, 28px); border-radius: var(--np--border-radius--larger); background: var(--ink-raised); }
.query-blocks__grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(4px, .7vw, 8px); }
.qblock {
  aspect-ratio: 1; border-radius: 4px;
  background: var(--brand-gradient);
  box-shadow: 0 0 14px hsla(240, 100%, 74.5%, .35);
  transition: opacity var(--np--animation-duration--slow), transform var(--np--animation-duration--slow) var(--ease-out-expo), box-shadow var(--np--animation-duration--slow);
}
.qblock.is-off { opacity: .1; transform: scale(.82); box-shadow: none; }
.query-caption { margin-top: clamp(28px, 4vh, 44px); font-size: clamp(19px, 1.9vw, 24px); letter-spacing: -.016em; color: var(--ink-text); min-height: 1.4em; }
.query-hint { margin-top: 12px; font-size: 13px; color: var(--ink-text-lighter); }

/* zero-knowledge flow */
.zk-flow { display: grid; grid-template-columns: 1fr; gap: 14px; align-items: stretch; margin-bottom: clamp(12px, 1.6vw, 20px); }
@media (min-width: 834px) { .zk-flow { grid-template-columns: 1fr auto 1fr; gap: 20px; } }
.zk-node { text-align: left; }
.zk-node .tile__icon { margin-bottom: 18px; }
.zk-wire { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 8px 0; }
.zk-wire__label { font-family: var(--np--font-family--code); font-size: 11px; letter-spacing: var(--np--letter-spacing--wider); color: var(--np--color--lighter); }
.zk-wire__line { position: relative; width: 120px; height: 2px; background: var(--np--border-color); overflow: hidden; border-radius: 2px; }
.zk-wire__line::after { content: ""; position: absolute; inset: 0; width: 40%; background: var(--brand-gradient); animation: lane 2.4s var(--ease-out-expo) infinite; }
@media (max-width: 833px) { .zk-wire__line { width: 2px; height: 48px; } .zk-wire__line::after { width: 100%; height: 40%; animation-name: lane-v; } }
@keyframes lane-v { 0% { transform: translateY(-110%); } 60%, 100% { transform: translateY(310%); } }

/* architecture */
.pipeline { display: grid; gap: 12px; }
@media (min-width: 900px) { .pipeline { grid-template-columns: 1fr 1.3fr 1.2fr; gap: 20px; align-items: stretch; } }
.pipe-stage { display: flex; flex-direction: column; gap: 10px; }
.pipe-stage .tile { padding: 28px; flex: 1; }
.pipe-step {
  padding: 16px 18px; border-radius: var(--np--border-radius--large);
  background: var(--surface); box-shadow: inset 0 0 0 1px var(--np--border-color);
}
.section--alt .pipe-step { background: var(--surface-alt); }
.pipe-step strong { display: block; font-size: 17px; letter-spacing: -.015em; }
.pipe-step span { font-family: var(--np--font-family--code); font-size: 12px; color: var(--np--color--lighter); }
.pipe-step--summary { box-shadow: inset 0 0 0 1.5px var(--np--brand-color); background: var(--np--background-color--link); }
.pipe-list { display: grid; gap: 10px; margin-top: 18px; }
.pipe-note { margin-top: clamp(12px, 1.6vw, 20px); }

code.code {
  font-size: .88em; padding: 2px 7px; border-radius: 6px;
  background: var(--np--background-color--link); color: var(--np--color);
}

/* ---------------------------------------------------------------- company */
.prose { margin-top: 28px; display: grid; gap: 20px; font-size: clamp(19px, 1.7vw, 21px); line-height: 1.5; letter-spacing: -.014em; color: var(--np--color--light); }
.prose strong { color: var(--np--color); }
.pullquote {
  margin: clamp(48px, 6vw, 72px) 0;
  font-size: clamp(28px, 3.6vw, 44px); font-weight: var(--np--font-weight--semibold);
  line-height: 1.12; letter-spacing: -.03em;
}
.pullquote cite { display: block; margin-top: 16px; font-size: 15px; font-weight: var(--np--font-weight); font-style: normal; letter-spacing: 0; color: var(--np--color--lighter); }

/* ---------- Legal pages (privacy, terms) ---------- */
.legal { font-size: 17px; line-height: 1.65; color: var(--np--color--light); }
.legal > * { margin: 0; }
.legal > * + * { margin-top: 16px; }
.legal h2 { margin-top: 52px; font-size: clamp(22px, 2.4vw, 28px); letter-spacing: -.022em; line-height: 1.2; color: var(--np--color); scroll-margin-top: calc(var(--nav-h) + 24px); }
.legal h3 { margin-top: 30px; font-size: 18px; letter-spacing: -.012em; color: var(--np--color); }
.legal h2 + *, .legal h3 + * { margin-top: 12px; }
.legal h2 + h3 { margin-top: 20px; }
.legal ul { padding-left: 1.3em; display: grid; gap: 8px; }
.legal a { color: var(--np--color--link); text-decoration: underline; text-underline-offset: 3px; }
.legal strong { color: var(--np--color); font-weight: var(--np--font-weight--semibold); }

/* ---------------------------------------------------------------- contact */
.contact { padding: calc(var(--nav-h) + clamp(56px, 8vw, 104px)) 0 clamp(72px, 9vw, 120px); position: relative; overflow: hidden; isolation: isolate; }
.contact__grid { display: grid; gap: clamp(40px, 6vw, 80px); align-items: start; }
@media (min-width: 960px) { .contact__grid { grid-template-columns: 1fr 1.05fr; } }
.contact .headline { max-width: 12ch; }
.contact__block { margin-top: clamp(36px, 4vw, 48px); }
.contact__block-title { font-size: 13px; font-weight: var(--np--font-weight--semibold); letter-spacing: var(--np--letter-spacing--wide); text-transform: uppercase; color: var(--np--color--lighter); margin-bottom: 18px; }
.contact__details { display: grid; gap: 6px; }
.contact__details a { font-size: 19px; letter-spacing: -.015em; color: var(--np--color--link); width: fit-content; }
.contact__details a:hover { text-decoration: underline; text-underline-offset: 3px; }

.form-card {
  border-radius: var(--np--border-radius--larger);
  background: var(--ink-raised);
  padding: clamp(24px, 4vw, 48px);
  box-shadow: 0 40px 120px -40px hsla(240, 100%, 60%, .45), inset 0 0 0 1px hsla(210, 5%, 95%, .08);
  --np--color--error: hsla(10, 82%, 75%, 1);
  --np--background-color--error: hsla(10, 55%, 20%, 1);
  --np--color--success: hsla(146, 58%, 59%, 1);
  --np--border-color--strong: hsla(240, 5%, 50%, 1);
}
.form-card__title { font-size: 24px; font-weight: var(--np--font-weight--semibold); letter-spacing: -.022em; }
.form-card__sub { margin-top: 6px; font-size: 15px; color: var(--np--color--lighter); }
.form { display: grid; gap: 14px; margin-top: 28px; }
.form__row { display: grid; gap: 14px; }
@media (min-width: 560px) { .form__row { grid-template-columns: 1fr 1fr; } }
.form__label { display: block; font-size: 13px; font-weight: var(--np--font-weight--medium); color: var(--np--color--light); margin: 0 0 6px 2px; }
.form__label span { color: var(--np--color--lighter); font-weight: var(--np--font-weight); }
.field {
  width: 100%; min-height: var(--np--size);
  padding: 12px 16px;
  border-radius: 12px;
  border: var(--np--border-width) solid var(--np--border-color);
  background: hsla(212, 10%, 6%, 1);
  color: var(--np--color);
  font-size: 17px;
  transition: border-color var(--np--animation-duration--fast), box-shadow var(--np--animation-duration--fast);
  -webkit-appearance: none; appearance: none;
}
.field::placeholder { color: var(--np--color--lighter); opacity: 1; }
.field:hover { border-color: var(--np--border-color--strong); }
.field:focus { outline: none; border-color: var(--np--color--link); box-shadow: 0 0 0 4px color-mix(in srgb, var(--np--color--link) 18%, transparent); }
textarea.field { resize: vertical; min-height: 120px; line-height: 1.45; }
.form .btn { margin-top: 8px; min-height: 52px; }
.form__pot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form__error {
  padding: 14px 16px; border-radius: 12px;
  font-size: 15px; color: var(--np--color--error); background: var(--np--background-color--error);
}
.form__error[hidden] { display: none; }
.form__note { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--np--color--lighter); line-height: 1.45; margin-top: 4px; }
.form__note svg { flex: none; width: 15px; height: 15px; margin-top: 1px; color: var(--np--color--success); }
.form__legal { font-size: 13px; line-height: 1.45; color: var(--np--color--lighter); margin-top: 4px; }
.form__legal a { color: var(--np--color--light); text-decoration: underline; text-underline-offset: 2px; }
.form__legal a:hover { color: var(--np--color); }

.thanks { display: none; text-align: center; padding: clamp(24px, 4vw, 40px) 0; }
.thanks.is-shown { display: block; }
.thanks:focus { outline: none; }
.thanks__mark {
  width: 64px; height: 64px; margin: 0 auto 24px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--brand-gradient); color: #fff;
}
.thanks__mark svg { width: 30px; height: 30px; }
.thanks__title { font-size: clamp(28px, 3vw, 36px); font-weight: var(--np--font-weight--semibold); letter-spacing: -.028em; line-height: 1.1; }
.thanks__copy { margin: 14px auto 0; max-width: 34ch; color: var(--np--color--light); }

/* 404 / thanks page */
.notice { position: relative; overflow: hidden; isolation: isolate; display: flex; align-items: center; padding: calc(var(--nav-h) + 96px) 0 120px; text-align: center; }
.notice .headline { margin: 0 auto; }
.notice__code { font-family: var(--np--font-family--code); font-size: 13px; letter-spacing: var(--np--letter-spacing--wider); color: var(--ink-text-lighter); margin-bottom: 20px; }

/* ---------------------------------------------------------------- footer */
.footer { background: var(--surface-alt); color: var(--np--color--lighter); font-size: 12px; line-height: 1.5; padding: 40px 0 28px; }
.footer__top { display: grid; gap: 32px; padding-bottom: 28px; border-bottom: 1px solid var(--np--border-color); }
@media (min-width: 768px) { .footer__top { grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; } }
.footer__brand { display: inline-flex; align-items: center; gap: 8px; color: var(--np--color); font-size: 15px; font-weight: var(--np--font-weight--semibold); letter-spacing: -.015em; }
.footer__brand .brand__mark { width: 18px; height: 18px; }
.footer__blurb { margin-top: 12px; max-width: 34ch; font-size: 12px; }
.footer__title { color: var(--np--color); font-weight: var(--np--font-weight--semibold); margin-bottom: 10px; }
.footer__list { display: grid; gap: 8px; }
.footer__link { color: var(--np--color--lighter); width: fit-content; }
.footer__link:hover { color: var(--np--color); text-decoration: underline; text-underline-offset: 2px; }
.footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-top: 18px; }
.footer__legal { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 18px; }
@media (max-width: 520px) { .footer__legal > span { flex-basis: 100%; } }

/* --------------------------------------------------------------- reveal */
.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--np--animation-duration--slower) var(--ease-out-expo), transform var(--np--animation-duration--slower) var(--ease-out-expo);
  transition-delay: var(--rd, 0s);
}
.js .reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .js .reveal { opacity: 1; transform: none; }
  .lane__pulse, .zk-wire__line::after { animation: none; transform: none; width: 100%; opacity: .6; }
  a.tile:hover { transform: none; }
}

@media print {
  .nav, .mobile-menu, .subnav, .hero__glow { display: none !important; }
  .ink, .tile--ink, .tile--brand { background: #fff !important; color: #000 !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* above-the-fold entrance (no observer needed) */
.js .rise { animation: rise var(--np--animation-duration--slower) var(--ease-out-expo) both; animation-delay: var(--rd, 0s); }
@keyframes rise { from { opacity: 0; transform: translateY(20px); } }
