/* ============================================================
   VELOCITY GTM — Design System
   Clean white · bold black type · one accent (blue)
   Hanken Grotesk × IBM Plex Mono
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Hanken+Grotesk:wght@400;500;600;700;800;900&family=IBM+Plex+Mono:wght@400;500;600&display=swap");

:root {
  /* ---- color ---- */
  --paper: #fbfbfc;
  --surface: #ffffff;
  --surface-2: #f4f5f7;
  --surface-3: #eceef1;
  --ink: #14161a;
  --ink-2: #3d424b;
  --muted: #71757e;
  --line: #e6e7ec;
  --line-2: #d7d9e0;
  --accent: #2a6fdb;
  --accent-ink: #1b57b5;
  --accent-soft: #eaf1fc;
  --accent-line: #c6dbf7;
  --green: #1b8a57;
  --green-soft: #e6f3ec;
  --red: #cf4242;
  --red-soft: #fbeaea;
  --amber: #b8821f;

  /* ---- type ---- */
  --font-sans: "Hanken Grotesk", system-ui, -apple-system, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", monospace;

  /* ---- radius ---- */
  --r-xs: 6px;
  --r-sm: 9px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  /* ---- shadow ---- */
  --sh-xs: 0 1px 2px rgba(20, 22, 26, 0.05);
  --sh-sm: 0 2px 6px rgba(20, 22, 26, 0.06), 0 1px 2px rgba(20, 22, 26, 0.04);
  --sh-md: 0 8px 24px rgba(20, 22, 26, 0.08), 0 2px 6px rgba(20, 22, 26, 0.05);
  --sh-lg:
    0 24px 60px rgba(20, 22, 26, 0.12), 0 8px 20px rgba(20, 22, 26, 0.07);

  /* ---- layout ---- */
  --maxw: 1200px;
  --gutter: clamp(20px, 4vw, 48px);
  --nav-h: 68px;
}

/* ---------- reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}
* {
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 90px;
}
body {
  font-family: var(--font-sans);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img,
svg {
  display: block;
  max-width: 100%;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}
ul {
  list-style: none;
}
::selection {
  background: var(--accent);
  color: #fff;
}

/* ---------- layout helpers ---------- */
.wrap {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section {
  padding-block: clamp(72px, 9vw, 130px);
}
.section-tight {
  padding-block: clamp(48px, 6vw, 80px);
}
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
}
.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--accent);
  transform: rotate(45deg);
}
.eyebrow.on-dark {
  color: #8fb6f2;
}
.eyebrow.on-dark::before {
  background: #8fb6f2;
}

/* ---------- type ---------- */
h1,
h2,
h3,
h4 {
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--ink);
  text-wrap: balance;
}
.display {
  font-size: clamp(2.7rem, 5.6vw, 4.7rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.98;
}
.h2 {
  font-size: clamp(2rem, 3.6vw, 3.1rem);
  letter-spacing: -0.028em;
}
.h3 {
  font-size: clamp(1.35rem, 2vw, 1.7rem);
  letter-spacing: -0.02em;
}
.lead {
  font-size: clamp(1.1rem, 1.5vw, 1.32rem);
  line-height: 1.5;
  color: var(--ink-2);
  font-weight: 400;
  text-wrap: pretty;
}
.muted {
  color: var(--muted);
}
.accent-text {
  color: var(--accent);
}
.mono {
  font-family: var(--font-mono);
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: 0.92em 1.4em;
  border-radius: var(--r-sm);
  transition:
    transform 0.16s ease,
    background 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
  white-space: nowrap;
  cursor: pointer;
}
.btn svg {
  width: 1.05em;
  height: 1.05em;
}
.btn-primary {
  background: var(--ink);
  color: #fff;
  box-shadow: var(--sh-sm);
}
.btn-primary:hover {
  background: #000;
  transform: translateY(-1px);
  box-shadow: var(--sh-md);
}
.btn-accent {
  background: var(--accent);
  color: #fff;
  box-shadow: var(--sh-sm);
}
.btn-accent:hover {
  background: var(--accent-ink);
  transform: translateY(-1px);
  box-shadow: var(--sh-md);
}
.btn-ghost {
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line-2);
}
.btn-ghost:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
}
.btn-light {
  background: #fff;
  color: var(--ink);
}
.btn-light:hover {
  transform: translateY(-1px);
  box-shadow: var(--sh-md);
}
.btn-outline-light {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.28);
}
.btn-outline-light:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.07);
}
.btn-lg {
  font-size: 1.06rem;
  padding: 1.05em 1.7em;
}
.btn-arrow {
  transition: transform 0.18s ease;
}
.btn:hover .btn-arrow {
  transform: translateX(3px);
}

/* ---------- tags / chips ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  padding: 0.38em 0.65em;
  border-radius: var(--r-xs);
  background: var(--surface-2);
  color: var(--ink-2);
  border: 1px solid var(--line);
}
.tag-green {
  background: var(--green-soft);
  color: var(--green);
  border-color: #cbe6d6;
}
.tag-blue {
  background: var(--accent-soft);
  color: var(--accent-ink);
  border-color: var(--accent-line);
}
.tag-red {
  background: var(--red-soft);
  color: var(--red);
  border-color: #f1cfcf;
}
.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
}

/* ---------- nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(251, 251, 252, 0.78);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition:
    border-color 0.2s ease,
    background 0.2s ease;
}
.nav.scrolled {
  border-bottom-color: var(--line);
}
.nav-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-size: 1.18rem;
}
.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #061022;
  overflow: hidden;
  display: grid;
  place-items: center;
  flex: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}
.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.brand sup {
  font-family: var(--font-mono);
  font-size: 0.52em;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.05em;
  top: -0.7em;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.nav-links a {
  white-space: nowrap;
}
.brand {
  white-space: nowrap;
}
.nav-links a {
  font-size: 0.96rem;
  font-weight: 500;
  color: var(--ink-2);
  transition: color 0.15s ease;
}
.nav-links a:hover {
  color: var(--ink);
}
.nav-cta {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.nav-toggle {
  display: none;
}

/* mobile drawer */
.nav-drawer {
  display: none;
  position: absolute;
  top: var(--nav-h);
  left: 0;
  right: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--sh-md);
  flex-direction: column;
  gap: 0.25rem;
  padding: 1rem var(--gutter) 1.4rem;
}
.nav-drawer[data-open] {
  display: flex;
}
.nav-drawer a {
  padding: 0.7rem 0;
  font-weight: 500;
  color: var(--ink-2);
  border-bottom: 1px solid var(--line);
}
.nav-drawer a.btn {
  color: #fff;
  border: none;
  justify-content: center;
  margin-top: 0.8rem;
}

/* ---------- footer ---------- */
.footer {
  background: var(--ink);
  color: #c9ccd2;
  padding-block: clamp(40px, 5vw, 52px) 40px;
}
.footer a {
  color: #c9ccd2;
  transition: color 0.15s ease;
}
.footer a:hover {
  color: #fff;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 2.5rem;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.footer .brand {
  color: #fff;
}
.footer-col h5 {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #7c808a;
  font-weight: 500;
  margin-bottom: 1rem;
}
.footer-col a {
  display: block;
  padding-block: 0.35rem;
  font-size: 0.96rem;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding-top: 28px;
  font-size: 0.85rem;
  color: #7c808a;
  flex-wrap: wrap;
}
.footer-tagline {
  max-width: 30ch;
  color: #9498a0;
  font-size: 0.96rem;
  margin-top: 1rem;
  line-height: 1.5;
}

/* ---------- generic card ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-sm);
}

/* ---------- mock UI primitives (shared) ---------- */
.ui {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-md);
  overflow: hidden;
}
.ui-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.ui-bar .dots {
  display: flex;
  gap: 6px;
}
.ui-bar .dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--surface-3);
  display: inline-block;
}
.ui-title {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: var(--muted);
}

/* data table */
.dtable {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}
.dtable th {
  text-align: left;
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}
.dtable td {
  padding: 0.62rem 0.8rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  vertical-align: middle;
}
.dtable tr:last-child td {
  border-bottom: none;
}
.cell-name {
  color: var(--ink);
  font-weight: 600;
}
.cell-mono {
  font-family: var(--font-mono);
  font-size: 0.76rem;
}
.avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-ink);
  display: inline-grid;
  place-items: center;
  font-size: 0.64rem;
  font-weight: 700;
  font-family: var(--font-mono);
  flex: none;
}

/* ---------- reveal-on-scroll (JS-gated so no-JS / IO-less contexts render) ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.7s cubic-bezier(0.22, 0.61, 0.36, 1),
    transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.reveal.in {
  opacity: 1;
  transform: none;
}
.reveal[data-d="1"] {
  transition-delay: 0.08s;
}
.reveal[data-d="2"] {
  transition-delay: 0.16s;
}
.reveal[data-d="3"] {
  transition-delay: 0.24s;
}
.reveal[data-d="4"] {
  transition-delay: 0.32s;
}
@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html {
    scroll-behavior: auto;
  }
}

/* ---------- section header block ---------- */
.shead {
  max-width: 720px;
}
.shead .eyebrow {
  margin-bottom: 1.1rem;
}
.shead .lead {
  margin-top: 1.1rem;
}
.center {
  text-align: center;
  margin-inline: auto;
}

/* ---------- divider ---------- */
.rule {
  height: 1px;
  background: var(--line);
  border: none;
}

/* ---------- responsive ---------- */
@media (max-width: 940px) {
  .nav-links {
    display: none;
  }
  .nav-cta > .btn-primary {
    display: none;
  }
  .nav-toggle {
    display: inline-grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: var(--r-sm);
    border: 1px solid var(--line-2);
  }
  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
  .footer .footer-col.brand-col {
    grid-column: 1 / -1;
  }
}
@media (max-width: 560px) {
  body {
    font-size: 16px;
  }
  .footer-top {
    grid-template-columns: 1fr;
  }
}
