/* GoBolt launch kit v2. base. Needs tokens.css first. Mobile first.
   v2: h1, h2, .display and .headline are the serif. Everything else, and every product mock, stays the grotesque. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--k-paper);
  color: var(--k-ink);
  font: 400 var(--k-body) / var(--k-lead-body) var(--k-font);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
h1, h2, h3, p, figure, ul, ol { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img, svg, video { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--k-green); outline-offset: 4px; border-radius: 4px; }
::selection { background: var(--k-ink); color: var(--k-paper); }

/* ── type ─────────────────────────────────────────────────────────── */
.display, .headline, .title { text-wrap: balance; }
/* a word longer than the line (a long Tamil or German compound) breaks rather than widening the page at 360 px */
h1, h2, .display, .headline, .title { overflow-wrap: anywhere; }
h1, h2, .display, .headline {
  font-family: var(--k-serif); font-weight: var(--k-weight-display);
  font-size: var(--k-headline); line-height: var(--k-lead-headline); letter-spacing: var(--k-track-headline);
  -webkit-font-smoothing: auto; text-rendering: optimizeLegibility;
}
h1, .display { font-size: var(--k-display); line-height: var(--k-lead-display); letter-spacing: var(--k-track-display); }
.display em, .headline em, h1 em, h2 em { font-style: normal; }   /* the display face has no italic, and a slanted one is never faked */
.title    { font-size: var(--k-title); font-weight: var(--k-weight); line-height: 1.2; letter-spacing: -0.025em; }
/* the mocks keep the grotesque: they are product UI, not page type */
.k-ui h1, .k-ui h2 { font-family: var(--k-font-ui); font-weight: 600; font-size: inherit; line-height: inherit; letter-spacing: -0.01em; }
.body     { font-size: var(--k-body); color: var(--k-ink-2); text-wrap: pretty; }
.small    { font-size: var(--k-small); line-height: 1.5; color: var(--k-ink-3); }

/* long-form reading (blog, release notes) */
.prose { max-width: var(--k-measure); color: var(--k-ink-2); }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: clamp(1.75rem, 1.4rem + 1vw, 2.125rem); line-height: 1.1; letter-spacing: -0.01em; color: var(--k-ink); margin-top: 2em; }
.prose a { color: var(--k-ink); text-underline-offset: 4px; text-decoration-color: var(--k-ink-3); }
.prose ul { list-style: disc; padding-left: 1.2em; }
.prose li + li { margin-top: 0.4em; }

/* ── layout primitives ────────────────────────────────────────────── */
.wrap { width: 100%; max-width: var(--k-page); margin-inline: auto; padding-inline: var(--k-gutter); }

/* scene: one idea per screen */
.scene {
  position: relative; isolation: isolate;
  padding-block: var(--k-section);
}
.scene--full { min-height: 100svh; display: grid; align-items: center; padding-block: clamp(48px, 9vh, 96px); }   /* a phone mock still fits a 900px-tall screen */
.scene--center { text-align: center; }
.scene--center .two { margin-inline: auto; }

/* two-line block: a headline and at most one sentence */
.two { max-width: 60rem; }
.two > * + * { margin-top: clamp(16px, 2vw, 24px); }
.two .body { max-width: 30rem; text-wrap: balance; }
.scene--center .two .body { margin-inline: auto; }
.two .actions { margin-top: clamp(28px, 3.5vw, 40px); }

/* split: words on one side, the picture on the other. Stacks on mobile. */
.split { display: grid; gap: clamp(40px, 7vw, 96px); align-items: center; }
.split > .picture { display: flex; justify-content: center; min-width: 0; }
@media (min-width: 900px) {
  .split { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1fr); }
  .split--flip > .two { order: 2; }
  .split > .picture { justify-content: flex-end; }
  .split--flip > .picture { justify-content: flex-start; }
  .split--flip > .picture { order: 1; }
  .split--wide { grid-template-columns: minmax(0, 1fr); }
  .split--wide > .picture, .split--wide.split--flip > .picture { justify-content: center; order: 2; }
  .split--wide.split--flip > .two { order: 1; }
}
/* the product page needs room for its two columns: side by side only when there is space */
@media (min-width: 1080px) {
  .split--wide { grid-template-columns: minmax(0, 0.56fr) minmax(0, 1fr); gap: clamp(40px, 5vw, 72px); }
  .split--wide > .picture { justify-content: flex-end; }
  .split--wide.split--flip { grid-template-columns: minmax(0, 1fr) minmax(0, 0.56fr); }
  .split--wide.split--flip > .picture { order: 1; justify-content: flex-start; }
  .split--wide.split--flip > .two { order: 2; }
}
/* big screens: the chat and the phone grow a little so the picture carries the scene */
@media (min-width: 1200px) and (min-height: 960px) {
  .split:not(.split--wide) > .picture > [data-ui]:not([data-ui="phone"]) { --k-ui-scale: 1.12; }
}

/* stack: vertical rhythm */
.stack > * + * { margin-top: var(--stack, var(--k-5)); }

/* ── the one button, the one link ─────────────────────────────────── */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 52px; padding: 14px 28px;
  border-radius: var(--k-r-pill);
  background: var(--k-ink); color: var(--k-surface);
  font-size: 1.0625rem; font-weight: 500; line-height: 1; text-decoration: none; white-space: nowrap;
  box-shadow: var(--k-shadow-button);
  transition: transform var(--k-fast) var(--k-ease), box-shadow var(--k-fast) ease;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(30, 29, 26, 0.13); }
.button:active { transform: none; }
/* the header's button is quiet, so the ink button stays the only loud thing in the view */
.button--small {
  min-height: 40px; padding: 9px 18px; font-size: 0.9375rem;
  background: transparent; color: var(--k-ink); box-shadow: inset 0 0 0 1.5px rgba(30, 29, 26, 0.16);
}
.button--small:hover { transform: none; box-shadow: inset 0 0 0 1.5px var(--k-ink); }

.link {
  color: var(--k-ink-2); font-size: inherit;
  text-decoration: underline; text-decoration-color: var(--k-line); text-decoration-thickness: 1.5px; text-underline-offset: 5px;
  transition: color var(--k-fast) ease, text-decoration-color var(--k-fast) ease;
}
.link:hover { color: var(--k-ink); text-decoration-color: var(--k-ink); }

/* ── header: logo, the links, the language globe, the button, and under 720px a menu ──────────
   Desktop: one row. Logo on the start, then Features, Pricing, Blog, the globe (the language control) and the quiet
   button on the end. Under 720px (rule 16, MKT-032): one row of logo, globe and the menu button; the links open as a
   sheet under the header when the menu is pressed (kitMenu in components.js writes .is-open and aria-expanded). The
   markup is the partial's: <nav> holds .nav-links (the three links), .lang and the button; .menu-toggle follows <nav>. */
.site-header {
  position: relative; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: var(--k-5);
  max-width: var(--k-page); margin-inline: auto;
  padding: 18px var(--k-gutter);
}
.site-header .logo img { width: 72px; height: auto; }
.site-header nav { display: flex; align-items: center; gap: clamp(16px, 2.6vw, 32px); }
.site-header .nav-links { display: contents; }
.site-header nav a:not(.button) { color: var(--k-ink-2); font-size: 1rem; text-decoration: none; transition: color var(--k-fast) ease; }
.site-header nav a:not(.button):hover, .site-header nav a[aria-current] { color: var(--k-ink); }
.site-header nav .lang { margin-inline-start: clamp(0px, 1vw, 8px); }
/* the menu button: three lines that become a cross. Hidden where the links fit on the row. */
.menu-toggle { display: none; position: relative; width: 44px; height: 44px; margin-inline-end: -8px; border-radius: var(--k-r-control); color: var(--k-ink); flex: none; }
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after {
  content: ""; position: absolute; left: 50%; width: 20px; height: 2px; margin-left: -10px; border-radius: 2px; background: currentColor;
  transition: transform var(--k-move) var(--k-ease), opacity var(--k-fast) ease;
}
.menu-toggle span { top: 50%; margin-top: -1px; }
.menu-toggle span::before { top: -6px; left: 0; margin-left: 0; }
.menu-toggle span::after { top: 6px; left: 0; margin-left: 0; }
.menu-toggle[aria-expanded="true"] span { background: transparent; }
.menu-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }
html:not(.js) .menu-toggle { display: none !important; }
@media (max-width: 719px) {
  .site-header { gap: var(--k-3); padding-block: 12px; }
  .site-header nav { gap: 4px; }
  /* the sheet: the links, then the language row (kitMenu moves the control in), rounded at the foot, over a
     backdrop that greys the page (the header's ::before, fixed, under the sheet); the page holds still behind it */
  .site-header .nav-links {
    display: grid; gap: 0; position: absolute; inset-inline: 0; top: 100%; z-index: 6;
    padding: 4px var(--k-gutter) 12px; background: var(--k-paper); border-bottom: 1px solid var(--k-line);
    border-radius: 0 0 var(--k-r-sheet) var(--k-r-sheet); box-shadow: 0 24px 48px rgba(30, 29, 26, 0.14);
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity var(--k-fast) ease, transform var(--k-move) var(--k-ease), visibility 0s linear var(--k-move);
  }
  .site-header::before {
    content: ""; position: fixed; inset: 0; z-index: 4; background: rgba(30, 29, 26, 0.38);
    opacity: 0; visibility: hidden; transition: opacity var(--k-move) ease, visibility 0s linear var(--k-move);
  }
  .site-header.is-open::before { opacity: 1; visibility: visible; transition-delay: 0s; }
  .site-header nav { position: static; }
  .site-header .logo, .site-header nav > .button, .menu-toggle { position: relative; z-index: 6; }
  .site-header.is-open { background: var(--k-paper); }
  html.menu-open { overflow: hidden; }
  .site-header.is-open .nav-links { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
  .site-header .nav-links a { display: block; padding-block: 16px; font-size: 1.25rem; font-weight: 500; color: var(--k-ink); border-top: 1px solid var(--k-line); }
  .site-header .nav-links a:first-child { border-top: 0; }
  .nav-lang { display: flex; align-items: center; padding-block: 8px 4px; border-top: 1px solid var(--k-line); }
  .nav-lang .lang { margin: 0 0 0 -8px; padding: 10px 6px 10px 8px; gap: 10px; color: var(--k-ink); font-size: 1.125rem; }
  .nav-lang .lang-globe { width: 22px; height: 22px; }
  .nav-lang .lang-name { position: static; width: auto; height: auto; margin: 0; overflow: visible; clip-path: none; white-space: nowrap; }
  .site-header nav .lang { margin-inline-start: 0; }
  /* without JavaScript there is no menu: the links stay a quiet second row under the logo, as before */
  html:not(.js) .site-header { flex-wrap: wrap; }
  html:not(.js) .site-header .nav-links { position: static; display: flex; gap: 20px; padding: 6px 0 0; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; flex-basis: 100%; }
  html:not(.js) .site-header .nav-links a { border: 0; padding-block: 8px; font-size: 0.9375rem; }
  .js .menu-toggle { display: inline-flex; align-items: center; justify-content: center; }
  /* with the sheet open the header row sits on paper over the backdrop; the logo keeps its place */
  .site-header.is-open .logo { position: relative; }
}
/* a thumb gets 44 px: the header's links and logo keep their size and get a taller hit area, centred on them. */
@media (pointer: coarse) {
  .site-header nav a:not(.button), .site-header nav .button, .site-header .logo { position: relative; }
  .site-header .logo::after, .site-header nav a:not(.button)::after, .site-header nav .button::after {
    content: ""; position: absolute; left: -6px; right: -6px; top: 50%; height: 44px; transform: translateY(-50%);
  }
  .site-header .nav-links a::after { content: none; }
}

/* ── the logo in motion (rule 23; motion.js kitLogo swaps the <img> for this drawing) ─────────
   At rest it is the same picture as bolt-logo.svg. On arrival the slash strikes in along its own diagonal, from
   above right, lands with one overshoot, and a glint runs down it; B, o, l, t settle up from the baseline after it,
   70 ms apart. Under a pointer the slash flicks (a kick back and a settle) and the letters hop in turn, so the mark
   answers the hand without ever changing its shape. Nothing here runs under ?still or reduced motion. */
.logo .k-logo { display: block; overflow: visible; width: 72px; height: auto; }
.site-footer .logo .k-logo { width: 60px; }
.logo .k-logo-letter { fill: currentColor; transform-box: fill-box; transform-origin: 50% 100%; }
.logo .k-logo-blade { fill: var(--k-yellow); stroke: #cfae00; stroke-width: 2; stroke-linejoin: round; paint-order: stroke; }
.logo .k-logo-slash { transform-box: fill-box; transform-origin: 50% 50%; }
.logo .k-logo-glint { fill: #fffbe4; opacity: 0; transform: translateX(-16px) skewX(-18deg); transform-box: fill-box; }
.js .logo.is-arriving .k-logo-slash { animation: k-logo-strike 760ms var(--k-ease-spring) both; }
.js .logo.is-arriving .k-logo-glint { animation: k-logo-glint 520ms 300ms ease-out both; }
.js .logo.is-arriving .k-logo-letter { animation: k-logo-settle 560ms var(--k-ease) both; animation-delay: calc(280ms + var(--i) * 70ms); }
@media (hover: hover) and (pointer: fine) {
  .js .logo.k-logo-host:hover .k-logo-slash { animation: k-logo-flick 640ms var(--k-ease-spring) both; }
  .js .logo.k-logo-host:hover .k-logo-glint { animation: k-logo-glint 460ms 60ms ease-out both; }
  .js .logo.k-logo-host:hover .k-logo-letter { animation: k-logo-hop 480ms var(--k-ease) both; animation-delay: calc(var(--i) * 50ms); }
}
@keyframes k-logo-strike {
  0%   { opacity: 0; transform: translate(34px, -46px) rotate(12deg) scale(1.2); }
  55%  { opacity: 1; transform: translate(-3px, 4px) rotate(-3deg) scale(0.97); }
  100% { opacity: 1; transform: none; }
}
@keyframes k-logo-settle {
  0%   { opacity: 0; transform: translateY(11px) scaleY(0.9); }
  100% { opacity: 1; transform: none; }
}
@keyframes k-logo-glint {
  0%   { opacity: 0; transform: translateX(-16px) skewX(-18deg); }
  25%  { opacity: 0.9; }
  100% { opacity: 0; transform: translateX(40px) skewX(-18deg); }
}
@keyframes k-logo-flick {
  0%   { transform: none; }
  35%  { transform: translate(-3px, 3px) rotate(-9deg) scale(1.06); }
  70%  { transform: translate(1px, -1px) rotate(2deg); }
  100% { transform: none; }
}
@keyframes k-logo-hop {
  0%   { transform: none; }
  40%  { transform: translateY(-4px); }
  100% { transform: none; }
}
.still .logo .k-logo * { animation: none !important; }

/* ── footer (MKT-030): ink ground, the light logo, one line, the handles, three columns, the ethos line ── */
.site-footer {
  margin-top: var(--k-section); padding: var(--k-8) var(--k-gutter) var(--k-6);
  background: var(--k-ink); color: var(--k-paper);
  font-size: var(--k-small);
}
.site-footer .footer-grid, .site-footer .footer-line, .site-footer .note { max-width: var(--k-page); margin-inline: auto; }
.site-footer .footer-grid { display: grid; gap: var(--k-6) var(--k-6); }
.site-footer .logo img { width: 84px; height: auto; display: block; }
.site-footer .footer-about p { max-width: 36ch; line-height: 1.55; color: rgba(246, 245, 241, 0.66); }
.site-footer .footer-about .logo + p { margin-top: var(--k-4); }
.site-footer .footer-social { display: flex; gap: 10px; margin-top: var(--k-4); }
.site-footer .footer-social a { width: 36px; height: 36px; border: 1px solid rgba(246, 245, 241, 0.22); border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: var(--k-paper); }
.site-footer .footer-social a:hover { border-color: var(--k-paper); }
.site-footer .footer-col h2 { margin: 0 0 var(--k-3); font-family: var(--k-font); font-size: 0.75rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(246, 245, 241, 0.66); }
.site-footer .footer-col ul { display: grid; gap: 8px; }
.site-footer a { display: inline-flex; align-items: center; min-height: 24px; color: var(--k-paper); text-decoration: none; }
.site-footer .footer-col a:hover { text-decoration: underline; text-underline-offset: 3px; }
.site-footer .footer-line { margin-top: var(--k-7); padding-top: var(--k-5); border-top: 1px solid rgba(246, 245, 241, 0.16); font-size: 0.8125rem; color: rgba(246, 245, 241, 0.66); }
.site-footer .note { margin-top: var(--k-3); max-width: 36rem; line-height: 1.5; color: rgba(246, 245, 241, 0.5); }
.site-footer .note:empty { display: none; }
/* under a thumb the links are 44 px rows, so neighbouring rows never share a tap */
@media (pointer: coarse) {
  .site-footer .footer-col ul { gap: 0; }
  .site-footer .footer-col a { min-height: 44px; }
}
@media (min-width: 600px) { .site-footer .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .site-footer .footer-about { grid-column: 1 / -1; } }
@media (min-width: 900px) { .site-footer .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; } .site-footer .footer-about { grid-column: auto; } }

/* ── reveal: lines first, then the picture (driven by motion.js) ──── */
.js [data-reveal] [data-line],
.js [data-reveal] [data-picture] { opacity: 0; transform: translate3d(0, var(--k-rise), 0); }
.js [data-reveal] [data-picture] { --k-rise: 22px; }
/* the transition lives on the arrived state only, so hiding is instant and arriving always travels */
.js [data-reveal].is-in [data-line],
.js [data-reveal].is-in [data-picture] {
  opacity: 1; transform: none;
  transition: opacity var(--k-slow) var(--k-ease), transform var(--k-slow) var(--k-ease);
  transition-delay: calc(var(--i, 0) * var(--k-line-gap));
}
/* keyboard focus reached the block before the scroll did (motion.js): it is there at once */
.js [data-reveal].is-in.is-now [data-line],
.js [data-reveal].is-in.is-now [data-picture] { transition-duration: 160ms; transition-delay: 0s; }

/* The page's first scene arrives from CSS alone, from the first paint: it never waits for the scripts at the end of
   the page (a slow phone would read blank paper for seconds). The lines rise in order (headline, sentence, button),
   then the picture. motion.js still marks the block .is-in, which changes nothing here. */
/* from 0.01, not 0: a first paint at opacity 0 is not a Largest Contentful Paint candidate, so the headline and
   picture would lose LCP to whatever autoplays in later. 0.01 is invisible. */
@keyframes k-arrive { from { opacity: 0.01; transform: translate3d(0, var(--k-rise), 0); } to { opacity: 1; transform: none; } }
.js main > :first-child [data-reveal] :is([data-line], [data-picture]) {
  opacity: 1; transform: none;
  animation: k-arrive var(--k-slow) var(--k-ease) both;
  animation-delay: calc(var(--k-first, 0) * var(--k-line-gap));
}
main > :first-child [data-reveal] [data-line] ~ [data-line] { --k-first: 1; }
main > :first-child [data-reveal] [data-line] ~ [data-line] ~ [data-line] { --k-first: 2; }
main > :first-child [data-reveal] [data-line] ~ [data-line] ~ [data-line] ~ [data-line] { --k-first: 3; }
/* a headline written as two lines: the lines after it wait for both */
main > :first-child [data-reveal] :has(> [data-line] + [data-line]) ~ [data-line] { --k-first: 2; }
main > :first-child [data-reveal] :has(> [data-line] + [data-line]) ~ [data-line] ~ [data-line] { --k-first: 3; }
main > :first-child [data-reveal] [data-picture] { --k-first: 4; }

/* ── scenes that cross-dissolve (pitch, end cards) ────────────────── */
[data-scenes] { position: relative; display: grid; }
[data-scenes] > [data-scene] {
  grid-area: 1 / 1; opacity: 0; visibility: hidden;
  transition: opacity var(--k-slow) var(--k-ease), visibility 0s linear var(--k-slow);
}
[data-scenes] > [data-scene].is-active { opacity: 1; visibility: visible; transition-delay: 0s; }

/* ── scroll-tied steps (kitScrub in motion.js) ─────────────────────
   Only while motion.js has it scrubbing: the section is one screen plus --scrub-step per step, and its
   .scrub-stage sticks to the top, one screen tall, with its content centred. Otherwise (a phone, a stage
   taller than the screen, ?still, reduced motion, no JS) it is an ordinary scene. */
[data-scrub].is-scrubbing {
  height: calc(100svh + var(--scrub-count, 4) * var(--scrub-step, 30svh));
  padding-block: 0;
}
[data-scrub].is-scrubbing > .scrub-stage {
  position: sticky; top: 0; height: 100svh;
  display: grid; align-content: center;
}
/* a scene whose picture runs out of its lower edge (the cropped phone) */
.scene--flush { padding-bottom: 0; }
.scene--flush .picture { align-self: end; }

/* ?still: everything is already on its final state, with no travel time (screenshots, frame capture) */
.still [data-reveal] [data-line], .still [data-reveal] [data-picture] { opacity: 1 !important; transform: none !important; transition: none !important; animation: none !important; }
.still [data-scenes] > [data-scene] { transition: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal] [data-line], .js [data-reveal] [data-picture] { opacity: 1 !important; transform: none !important; transition: none !important; animation: none !important; }
  [data-scenes] > [data-scene] { transition: none; }
  .button { transition: none; }
  .logo .k-logo * { animation: none !important; }
}
