/* Tokens, reset, typography, buttons and shared motion. */

:root {
  --blue: #2e9bff;
  --blue-deep: #1677e0;
  --blue-soft: #e3f1ff;
  --glow: rgba(46, 155, 255, 0.45);

  --frame: #14171c;
  --sheet: #f1f3f6;
  --white: #ffffff;
  --line: #dce2ea;
  --graph: #1c2026;

  --ink: #16191e;
  --muted: #5d6977;
  --on-dark: #eaf0f6;
  --on-dark-muted: #98a4b3;

  /* dark "stage" panels with product mockups */
  --stage: #111216;
  --stage-muted: #a9b6c8;
  --bubble: #e8edf7;
  --bubble-muted: #6b7a90;

  /* black sidebar */
  --side-bg: #0a0b0d;
  --side-ink: #f2f5f8;
  --side-muted: #a9b3bf;
  --side-chip: #1f2329;

  --display: "Montserrat", "Manrope", system-ui, sans-serif;
  --body: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;

  --side: 300px;

  /* The desktop layout is drawn for a 1920px wide window (1vw = 19.2px) and the whole page is zoomed
     to the real window width by the script in <head>, so the proportions stay the same on any screen.
     On phones and tablets (no zoom) it is the real viewport unit. */
  --vw: 19.2px;
  color-scheme: light;
}

@media (max-width: 1000px) {
  :root {
    --vw: 1vw;
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
}

body {
  margin: 0;
  background: var(--frame);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* keeps the notch area dark on iOS */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  height: env(safe-area-inset-top, 0px);
  z-index: 90;
  background: var(--frame);
}

a {
  color: inherit;
}

p {
  margin: 0;
}

/* ---------- Typography ---------- */

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

h1 {
  letter-spacing: -0.03em;
}

h2 {
  font-size: clamp(28px, calc(3.4 * var(--vw)), 50px);
  line-height: 1.06;
}

h3 {
  font-size: 22px;
  line-height: 1.15;
}

/* blue accent words inside headings */
.hand {
  font-family: var(--display);
  font-weight: 700;
  color: var(--frame);
  letter-spacing: -0.02em;
  line-height: 1;
}

.kicker {
  font-family: var(--display);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.link {
  color: var(--blue-deep);
  font-weight: 700;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font: 700 16px/1 var(--body);
  letter-spacing: -0.01em;
  padding: 17px 24px;
  border: 1.5px solid transparent;
  border-radius: 99px;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.2s, background 0.2s, color 0.2s, border-color 0.2s;
}

.btn svg {
  width: 16px;
  height: 16px;
}

.btn .icon {
  stroke-width: 2.5;
}

.btn-dark {
  background: var(--graph);
  color: #fff;
}

.btn-dark:hover {
  background: var(--blue);
  transform: translateY(-2px);
}

.btn-blue {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 14px 30px -12px var(--glow);
}

.btn-blue:hover {
  background: var(--blue-deep);
  transform: translateY(-2px);
}

.btn-line {
  border-color: var(--ink);
  color: var(--ink);
}

.btn-line:hover {
  background: var(--ink);
  color: #fff;
}

.btn:focus-visible,
a:focus-visible,
summary:focus-visible,
button:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

/* ---------- Icons from the SVG sprite ---------- */

.icon {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Motion ---------- */

/* Reveal on scroll: content is visible by default; main.js adds .wait only to blocks below the fold. */
.rv {
  transition: transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1), opacity 0.8s;
}

.rv.wait {
  transform: translateY(36px);
  opacity: 0.001;
}

/* staggered entrance of the hero */
.load {
  animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.load.d1 {
  animation-delay: 0.08s;
}

.load.d2 {
  animation-delay: 0.16s;
}

.load.d3 {
  animation-delay: 0.24s;
}

.load.d4 {
  animation-delay: 0.32s;
}

@keyframes rise {
  from {
    transform: translateY(28px);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .rv.wait {
    transform: none;
    opacity: 1;
  }

  html {
    scroll-behavior: auto;
  }
}
