/* ============================================================
   Ezra Labs — QUILT marketing page
   Minimal SaaS layout · snap scroll · mobile-first
   ============================================================ */

:root {
  /* Palette — White Smoke → Carbon Black */
  --gray-100: #f5f5f5;
  --gray-200: #dcdcdc;
  --gray-300: #c2c2c2;
  --gray-400: #a8a8a8;
  --gray-500: #8e8e8e;
  --gray-600: #747474;
  --gray-700: #5a5a5a;
  --gray-800: #404040;
  --gray-900: #262626;

  /* Semantic tokens */
  --brand: var(--gray-700);
  --brand-600: var(--gray-900);
  --brand-50: var(--gray-100);
  --brand-100: var(--gray-200);
  --brand-ring: rgba(116, 116, 116, 0.35);

  --ink: var(--gray-900);
  --body: var(--gray-600);
  --muted-2: var(--gray-500);
  --muted: var(--gray-400);
  --line: var(--gray-300);
  --line-2: var(--gray-200);

  /* Coral — AI threads, join figure, and Ai on the header mark */
  --coral: #e85a4a;
  --coral-soft: rgba(232, 90, 74, 0.35);
  --coral-ghost: rgba(232, 90, 74, 0.12);
  --bg: var(--gray-100);
  --bg-soft: var(--gray-200);
  --bg-soft2: var(--gray-300);
  --dark: var(--gray-900);
  --dark-2: var(--gray-800);

  --r-sm: 8px;
  --r: 12px;
  --r-lg: 16px;
  --r-xl: 22px;
  --r-control: var(--r-sm); /* buttons, inputs, card surfaces — TASTE bubbles */
  --pill: 999px;

  --sh-sm: 0 1px 3px rgba(15, 23, 42, 0.08), 0 1px 2px rgba(15, 23, 42, 0.04);
  --sh: 0 6px 20px rgba(15, 23, 42, 0.07), 0 2px 6px rgba(15, 23, 42, 0.04);
  --sh-lg: 0 18px 44px rgba(15, 23, 42, 0.12);
  --sh-xl: 0 30px 70px rgba(15, 23, 42, 0.16);
  --drop-sm: 0 4px 10px rgba(38, 38, 38, 0.18);
  --drop-md: 0 8px 18px rgba(38, 38, 38, 0.16);
  --drop-lg: 0 14px 28px rgba(38, 38, 38, 0.14);

  --maxw: 1180px;
  --gut: clamp(16px, 4vw, 24px);
  --header-h: 62px;
  --letterbox-h: 62px;
  --font-sans: 'IBM Plex Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'Cascadia Code', monospace;
}

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

html {
  scroll-behavior: smooth;
  scroll-snap-type: y mandatory;
  scroll-padding-top: var(--header-h);
  height: 100%;
  -webkit-text-size-adjust: 100%;
}

html:has(body.letterbox) {
  scroll-snap-type: none;
  overflow: hidden;
  height: 100%;
}

body.letterbox {
  overflow: hidden;
  height: 100dvh;
  background: var(--gray-900);
}

body.letterbox .snap-section.hero {
  min-height: 100dvh;
  padding-bottom: 0;
  border-bottom: none;
}

body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--body);
  -webkit-font-smoothing: antialiased;
  font-size: clamp(15px, 1.05vw, 17px);
  line-height: 1.6;
}

.llm-noscript,
.llm-walk {
  box-sizing: border-box;
  max-width: 40rem;
  margin: 0 auto;
  padding: 1.25rem var(--gut) 1.25rem;
  color: var(--ink);
  background: var(--gray-100);
  font-size: 1rem;
  line-height: 1.5;
}

.llm-noscript p,
.llm-walk p {
  margin: 0 0 0.75rem;
}

.llm-noscript a,
.llm-walk a {
  color: var(--ink);
}

.llm-walk h1,
.llm-walk h2,
.llm-walk h3 {
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 700;
  line-height: 1.25;
  margin: 1.25rem 0 0.5rem;
}

.llm-walk h1 {
  font-size: 1.25rem;
  margin-top: 0;
}

.llm-walk h2 {
  font-size: 1.1rem;
}

.llm-walk h3 {
  font-size: 1rem;
}

.llm-walk ul {
  margin: 0 0 0.75rem;
  padding-left: 1.25rem;
}

.llm-walk li {
  margin: 0 0 0.35rem;
}

/* JS browsers: keep the walk in the HTML source (Claude’s first GET) and off the human viewport. */
html.js .llm-walk {
  display: none;
}

.skip-intro {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 400;
  padding: 10px 14px;
  border: 1px solid var(--ink);
  background: var(--gray-100);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  clip-path: inset(50%);
  pointer-events: none;
}

.skip-intro:focus,
.skip-intro:focus-visible {
  clip-path: none;
  pointer-events: auto;
  outline: 2px solid var(--coral);
  outline-offset: 2px;
}

.hero__punch-skip {
  position: absolute;
  top: calc(var(--header-h) + 12px);
  right: 16px;
  z-index: 2;
  padding: 8px 12px;
  border: 1px solid rgba(245, 245, 245, 0.55);
  background: transparent;
  color: #f5f5f5;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  pointer-events: auto;
}

.hero__punch-skip:focus,
.hero__punch-skip:focus-visible {
  outline: 2px solid var(--coral);
  outline-offset: 2px;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3,
h4 {
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin: 0;
  color: var(--ink);
}

p {
  margin: 0;
  text-wrap: pretty;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gut);
  width: 100%;
}

/* ---- snap sections ---- */
.snap-section {
  scroll-snap-align: start;
  scroll-snap-stop: always;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: var(--header-h);
  padding-bottom: clamp(32px, 6vh, 64px);
  border-bottom: 1px solid var(--line);
}

.snap-section__inner {
  width: 100%;
}

.snap-section--tall {
  justify-content: flex-start;
  padding-top: calc(var(--header-h) + clamp(24px, 4vh, 40px));
}

.section--soft {
  background: var(--bg-soft);
}

.section-head {
  margin-bottom: clamp(28px, 4vh, 48px);
}

.section-head h2 {
  font-size: clamp(28px, 4.2vw, 48px);
  margin-top: 14px;
}

.section-head h1 {
  font-size: clamp(28px, 4.2vw, 48px);
  margin-top: 14px;
}

.section-head__lead {
  max-width: 52ch;
  margin: 14px auto 0;
}

.section-head--left {
  text-align: left;
}

.section-head--left .section-head__lead {
  margin-left: 0;
  margin-right: 0;
}

.center {
  text-align: center;
}

/* ---- eyebrow ---- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
  font-size: 13px;
  color: var(--brand);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  padding: 6px 13px;
  border-radius: var(--pill);
  line-height: 1;
}

.eyebrow::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand);
}

.lead {
  font-weight: 400;
  font-size: clamp(1rem, 1.8vw, 1.12rem);
  line-height: 1.6;
  color: var(--body);
}

.card__text {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--body);
}

/* ---- buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-weight: 600;
  font-size: 15px;
  padding: 11px 20px;
  border-radius: var(--r-control);
  border: 1px solid var(--brand);
  background: var(--brand);
  color: var(--gray-100);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}

.btn:hover {
  background: var(--gray-800);
  border-color: var(--gray-800);
  box-shadow: var(--sh);
  transform: translateY(-1px);
}

.btn:focus-visible {
  outline: 2px solid var(--coral);
  outline-offset: 3px;
}

.btn--teal {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--gray-100);
}

.btn--ghost {
  background: var(--gray-100);
  color: var(--ink);
  border-color: var(--gray-400);
}

.btn--ghost:hover {
  background: var(--bg-soft);
  color: var(--ink);
}

.btn--lg {
  padding: 14px 24px;
  font-size: 16px;
}

.btn--block {
  width: 100%;
  margin-top: auto;
}

/* ---- header ---- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  background: var(--gray-900);
  border-bottom: 1px solid var(--gray-800);
}

.site-header .brand__name {
  color: var(--gray-100);
}

.site-header .brand__name .ai {
  color: var(--gray-300);
}

.site-header .nav__links a {
  color: var(--gray-300);
}

.site-header .nav__links a:hover {
  color: var(--gray-100);
}

.site-header .nav__login,
.site-header .nav__signup {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 7.25rem;
  padding: 10px 18px;
  border-radius: var(--r-control);
  font-weight: 600;
  font-size: 15px;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
  box-sizing: border-box;
  border: 1px solid #fff;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.site-header .nav__login {
  color: var(--gray-200);
  background: transparent;
}

.site-header .nav__signup {
  color: var(--gray-900);
  background: #fff;
}

.site-header .nav__login:hover {
  color: var(--gray-100);
  border-color: #fff;
}

.site-header .nav__signup:hover {
  color: var(--gray-900);
  background: var(--gray-200);
  border-color: var(--gray-200);
}

.site-header .btn--teal {
  background: var(--gray-200);
  border-color: var(--gray-300);
  color: var(--gray-900);
}

.site-header .btn--teal:hover {
  background: var(--gray-100);
  border-color: var(--gray-200);
  color: var(--gray-900);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: var(--header-h);
  padding: 0;
  position: relative;
}

@media (min-width: 901px) {
  .site-header .nav__panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 20px;
  }

  .site-header .nav__links {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    gap: 0;
    white-space: nowrap;
  }

  .site-header .nav__sep {
    margin: 0 0.65em;
    color: var(--gray-600);
    font-weight: 400;
    user-select: none;
  }

  .site-header .nav__links a {
    color: var(--gray-300);
  }

  .site-header .nav__links a:hover {
    color: var(--gray-100);
  }

  .nav__dropdown {
    position: relative;
    display: inline-flex;
    align-items: center;
  }

  .nav__drop-trigger {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font: inherit;
    font-weight: 500;
    font-size: inherit;
    color: var(--gray-300);
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
  }

  .nav__drop-trigger:hover,
  .nav__dropdown.is-open .nav__drop-trigger {
    color: var(--gray-100);
  }

  .nav__drop-chevron {
    transition: transform 0.15s ease;
  }

  .nav__dropdown.is-open .nav__drop-chevron {
    transform: rotate(180deg);
  }

  .nav__drop-panel {
    position: fixed;
    left: 0;
    right: 0;
    top: var(--header-h);
    z-index: 90;
    background: var(--gray-900);
    border-bottom: 1px solid var(--gray-800);
    box-shadow: var(--sh-lg);
    padding: clamp(24px, 4vh, 36px) 0 clamp(28px, 5vh, 40px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-4px);
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
    white-space: normal;
  }

  .nav__drop-panel::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: -12px;
    height: 12px;
  }

  .nav__dropdown.is-open .nav__drop-panel {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }

  .nav__drop-inner {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(48px, 10vw, 120px);
    max-width: 720px;
  }

  .nav__drop-inner--single {
    grid-template-columns: 1fr;
    max-width: 360px;
  }

  .nav__drop-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--gray-500);
    margin-bottom: 16px;
  }

  .nav__drop-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 18px;
  }

  .nav__drop-list a {
    display: block;
    text-decoration: none;
    padding: 4px 0;
  }

  .nav__drop-title {
    display: block;
    font-weight: 600;
    font-size: 15px;
    color: var(--gray-100);
    margin-bottom: 4px;
    transition: color 0.12s ease;
  }

  .nav__drop-desc {
    display: block;
    font-size: 14px;
    line-height: 1.45;
    color: var(--gray-400);
    max-width: 22ch;
  }

  .nav__drop-list a:hover .nav__drop-title {
    color: #fff;
  }

  .nav__drop-list a:hover .nav__drop-desc {
    color: var(--gray-300);
  }
}

.nav__search {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border: none;
  background: none;
  color: var(--gray-200);
  cursor: pointer;
  border-radius: var(--r-control);
}

.nav__search:hover {
  color: var(--gray-100);
}

.site-header .btn--header {
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  color: var(--gray-900);
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--r-control);
}

.site-header .btn--header:hover {
  background: var(--gray-200);
  border-color: var(--gray-300);
  color: var(--gray-900);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.brand__mark {
  display: grid;
  place-items: center;
  color: var(--ink);
  flex: none;
}

.brand__img {
  display: block;
  height: 40px;
  width: auto;
  flex: none;
  object-fit: contain;
}

.site-header .brand__img--header {
  height: clamp(40px, 4.5vw, 48px);
  width: auto;
}

.brand--footer {
  display: inline-block;
}

.brand__img--footer {
  height: clamp(40px, 5vw, 52px);
  width: auto;
  max-width: min(200px, 100%);
}

.brand__name {
  font-weight: 800;
  font-size: clamp(17px, 2.5vw, 20px);
  letter-spacing: -0.03em;
  color: var(--ink);
  line-height: 1;
  white-space: nowrap;
}

.brand__name .ai {
  color: var(--brand);
}

.brand--footer .brand__name {
  color: #fff;
}

.brand--footer .brand__name .ai {
  color: #d4d4d8;
}

.nav__toggle {
  display: none;
  align-items: center;
  gap: 8px;
  font-family: inherit;
  font-weight: 600;
  font-size: 14px;
  padding: 8px 12px;
  border: 1px solid var(--gray-600);
  border-radius: var(--r-control);
  background: var(--gray-800);
  color: var(--gray-100);
  cursor: pointer;
}

.nav__toggle-label {
  display: none;
}

.nav__panel {
  display: flex;
  align-items: center;
  gap: 28px;
  flex: 1;
  justify-content: flex-end;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.5vw, 28px);
  font-weight: 500;
  font-size: 15px;
}

.nav__links a {
  color: var(--muted-2);
  transition: color 0.12s ease;
}

.nav__links a:hover {
  color: var(--ink);
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav__login-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.nav__login-stack .nav__search {
  padding: 4px;
}

.nav__login-stack .nav__login {
  padding: 0;
  font-size: 13px;
  line-height: 1;
}

.nav__login {
  font-weight: 600;
  font-size: 15px;
  padding: 8px;
  color: var(--ink);
  cursor: pointer;
  background: none;
  border: none;
  font-family: inherit;
}

.nav__login:hover {
  color: var(--brand);
}

@media (max-width: 900px) {
  .nav__toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .nav__panel {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 16px var(--gut) 24px;
    background: var(--gray-900);
    border-bottom: 1px solid var(--gray-800);
    box-shadow: var(--sh-lg);
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  }

  .site-header.nav-open .nav__panel {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }

  .nav__links {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--gray-800);
  }

  .nav__links a {
    display: block;
    width: 100%;
    padding: 12px 4px;
    font-size: 16px;
  }

  .nav__dropdown {
    display: block;
    width: 100%;
  }

  .nav__drop-trigger {
    width: 100%;
    justify-content: space-between;
    padding: 12px 4px;
    font-size: 16px;
    text-align: left;
  }

  .nav__drop-panel {
    position: static;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    box-shadow: none;
    border-bottom: none;
    padding: 0 0 8px 12px;
    display: none;
  }

  .nav__dropdown.is-open .nav__drop-panel {
    display: block;
  }

  .nav__drop-inner {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .nav__drop-list {
    gap: 14px;
  }

  .nav__drop-list a {
    padding: 8px 0;
  }

  .nav__sep {
    display: none;
  }

  .nav__actions {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding-top: 14px;
  }

  .nav__actions .btn,
  .nav__login,
  .nav__signup {
    width: 100%;
    text-align: center;
  }
}

.solution-page {
  background: var(--gray-100);
  min-height: 100vh;
}

.solution-main {
  padding-top: calc(var(--header-h) + clamp(40px, 7vh, 72px));
  padding-bottom: clamp(64px, 10vh, 96px);
}

.solution-back {
  display: inline-block;
  margin-bottom: 24px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
}

.solution-back:hover {
  color: var(--ink);
}

.solution-placeholder {
  margin-top: 32px;
  padding: 24px;
  border: 1px dashed var(--line);
  border-radius: var(--r-control);
  color: var(--muted);
  background: var(--bg-soft);
}

.solution-content {
  max-width: min(640px, 100%);
  margin-top: clamp(28px, 4vh, 40px);
}

.solution-checklist {
  margin-top: 0;
}

.solution-cta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: min(100%, 400px);
  margin-top: clamp(28px, 4vh, 36px);
}

.solution-cta .btn {
  border-radius: var(--r-control);
  white-space: normal;
  text-align: center;
  line-height: 1.35;
  min-height: 3.25rem;
  padding: 12px 14px;
  width: 100%;
}

.solution-cta .btn--placeholder {
  opacity: 0.55;
  cursor: default;
  pointer-events: none;
}

.hero {
  position: relative;
  background: var(--gray-100);
  overflow: hidden;
}

.hero--graph {
  background: var(--gray-100);
}

.hero--graph::before {
  display: none !important;
  content: none !important;
}

.hero__graph {
  position: absolute;
  inset: 0;
  z-index: 1;
  cursor: none !important;
  transition: opacity 0.95s ease 0.2s;
}

.hero__graph.hero__graph--fading {
  opacity: 0;
  pointer-events: none;
}

.hero__graph.hovering {
  cursor: none !important;
}

.hero__graph canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: none !important;
}

.hero__fuzz {
  position: fixed;
  top: 0;
  left: 0;
  width: 12px;
  height: 12px;
  margin: -6px 0 0 -6px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9;
  opacity: 0;
  background: var(--gray-900);
  filter: blur(5px);
  transform: translate3d(-80px, -80px, 0);
  will-change: transform;
}

.hero__fuzz.is-on {
  opacity: 1;
}

.hero--calm .hero__fuzz,
.hero--resolved .hero__fuzz,
.hero--punching .hero__fuzz {
  opacity: 0;
}

.hero__flash {
  position: absolute;
  inset: 0;
  z-index: 8;
  background: #fff;
  opacity: 0;
  pointer-events: none;
}

.hero__flash.fire {
  animation: hero-flash 0.55s ease-out forwards;
}

@keyframes hero-flash {
  0% { opacity: 0; }
  8% { opacity: 0.55; }
  18% { opacity: 0.08; }
  27% { opacity: 0.28; }
  100% { opacity: 0; }
}


.hero__copy--calm {
  --quilt-size: clamp(4.2rem, 16vw, 8rem);
  position: relative;
  top: -48px;
  left: -6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  text-shadow: 0 1px 0 rgba(240, 238, 235, 0.65);
  opacity: 0;
}

.hero__blackout {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--gut) clamp(72px, 10vh, 120px);
  background: #0a0a0a;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.hero--punching .hero__blackout {
  visibility: visible;
  opacity: 1;
  transition: opacity 0.18s ease;
}

.hero--punch-out .hero__blackout {
  animation: hero-blackout-jitter 0.7s steps(2, end) forwards;
}

.hero__punch {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: 0.18em 0.28em;
  margin: 0;
  font-size: clamp(3.75rem, 16vw, 9rem);
  font-weight: 700;
  letter-spacing: -0.065em;
  line-height: 0.86;
  color: #f5f5f5;
  text-align: center;
}

.hero__punch-it-group {
  display: inline-flex;
  align-items: baseline;
  gap: 0;
}

.hero__punch-word,
.hero__punch-dot {
  display: inline-block;
  opacity: 0;
  transform: scale(2.4);
  transform-origin: center bottom;
}

.hero__punch-dot {
  margin-left: -0.02em;
}

.hero--punching .hero__punch-word--get {
  animation: hero-punch-zoom 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero--punching .hero__punch-word--over {
  animation: hero-punch-zoom 0.5s 0.26s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero--punching .hero__punch-word--it {
  animation: hero-punch-zoom 0.5s 0.52s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero--punching .hero__punch-dot {
  animation: hero-punch-dot 0.65s 0.82s cubic-bezier(0.2, 1.1, 0.34, 1) forwards;
}

.hero__blackout::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 40%, var(--coral-soft), transparent 55%);
  opacity: 0;
  pointer-events: none;
}

.hero--punch-out .hero__blackout::after {
  animation: hero-coral-flash 0.7s steps(2, end) forwards;
}

@keyframes hero-coral-flash {
  0% { opacity: 0; background: radial-gradient(ellipse at 50% 40%, transparent, transparent); }
  10% { opacity: 0.75; background: radial-gradient(ellipse at 48% 42%, var(--coral-soft), transparent 50%); }
  22% { opacity: 0.08; }
  34% { opacity: 0.85; background: radial-gradient(ellipse at 55% 38%, rgba(232, 90, 74, 0.55), transparent 48%); }
  48% { opacity: 0.15; }
  62% { opacity: 0.7; background: radial-gradient(ellipse at 50% 45%, var(--coral-soft), transparent 52%); }
  100% { opacity: 0; }
}

/* same map hover → glitch + placeholder peeks */

.hero__same-wrap {
  position: relative;
  display: inline-block;
  margin: 0 auto;
  left: 2px;
}

.hero__same-map {
  cursor: default;
  pointer-events: auto;
  display: inline-block;
  margin-bottom: 0;
  transition: color 0.25s ease, text-shadow 0.25s ease;
}

.hero--calm .hero__same-map:focus-visible {
  outline: none;
}

.hero--calm .hero__same-map:hover .hero__triad-word em,
.hero--calm .hero__same-map:focus-visible .hero__triad-word em,
.hero--calm .hero__same-map.is-peeking .hero__triad-word em {
  color: var(--coral, #e85a4a);
}

/* Map peek: two stills meet from opposite sides, fade into each other, dissipate. */
.hero__map-peek {
  position: fixed;
  inset: 0;
  z-index: 7;
  pointer-events: none;
  overflow: hidden;
  background: transparent;
}

.hero__map-peek-slide {
  position: absolute;
  inset: 0;
  display: none;
  overflow: hidden;
}

.hero__map-peek-slide.is-active {
  display: block;
}

.hero__map-peek-left,
.hero__map-peek-right {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 90vw;
  height: 90vh;
  transform: translate(-50%, -50%);
  opacity: 0;
  overflow: visible;
  will-change: transform, opacity;
}

.hero__map-peek-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Blurred copy sits under; sharp copy is masked so only the rim is soft. */
.hero__map-peek-img--soft {
  filter: blur(11px);
  transform: scale(1.03);
}

.hero__map-peek-img--sharp {
  -webkit-mask-image:
    linear-gradient(to right, transparent 0%, #000 16%, #000 84%, transparent 100%),
    linear-gradient(to bottom, transparent 0%, #000 16%, #000 84%, transparent 100%);
  mask-image:
    linear-gradient(to right, transparent 0%, #000 16%, #000 84%, transparent 100%),
    linear-gradient(to bottom, transparent 0%, #000 16%, #000 84%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
}

.hero__map-peek-slide.is-active .hero__map-peek-left {
  animation: peek-from-left 5.2s linear forwards;
}

.hero__map-peek-slide.is-active .hero__map-peek-right {
  animation: peek-from-right 5.2s linear forwards;
}

/* Straight overlap, then dissolve once they are ~80% stacked. */
@keyframes peek-from-left {
  0%   { transform: translate(-50%, -50%) translateX(-36%); opacity: 0.2; }
  38%  { transform: translate(-50%, -50%) translateX(-16%); opacity: 0.2; }
  100% { transform: translate(-50%, -50%) translateX(-8%); opacity: 0; }
}

/* Right still: same line, opposite direction. */
@keyframes peek-from-right {
  0%   { transform: translate(-50%, -50%) translateX(36%); opacity: 0.2; }
  38%  { transform: translate(-50%, -50%) translateX(16%); opacity: 0.2; }
  100% { transform: translate(-50%, -50%) translateX(8%); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .hero__map-peek-slide.is-active .hero__map-peek-left {
    animation: peek-left-reduce 0.55s ease forwards;
  }

  .hero__map-peek-slide.is-active .hero__map-peek-right {
    animation: none;
  }

  @keyframes peek-left-reduce {
    0%   { opacity: 0.2; transform: translate(-50%, -50%); }
    100% { opacity: 0; transform: translate(-50%, -50%); }
  }

  .hero--punch-out .hero__blackout::after {
    animation: none;
    opacity: 0;
  }
}

.hero__blackout-copy {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: min(920px, 100%);
}

.hero__punch-together {
  margin: clamp(1.25rem, 3.5vh, 2.25rem) 0 0;
  font-size: clamp(1.35rem, 4.2vw, 2.65rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: #f5f5f5;
  opacity: 0;
  transform: translateY(18px) scale(0.96);
}

.hero--punching .hero__punch-together {
  animation: hero-together-in 0.85s 1.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero__copy h1.hero__brand-mark,
.hero__brand-mark {
  display: inline-flex;
  align-items: flex-end;
  justify-content: center;
  margin: 0 0 18px;
  font-family: var(--font-sans);
  font-size: var(--quilt-size);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 0.9;
  color: var(--gray-900);
  opacity: 0;
  transform: translateY(8px);
  position: relative;
  top: 12px;
}

.hero__brand-word {
  display: block;
  line-height: 0.9;
}

.hero__brand-dot {
  display: block;
  width: 0.18em;
  height: 0.18em;
  margin: 0 0 0.02em 0.08em;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
  transform: translate(-20px, -5px);
}

.hero__copy--calm .hero__triad--hero {
  font-size: clamp(1.15rem, 3.8vw, 1.85rem);
  opacity: 0;
  transform: translateY(8px);
}

.hero__copy--calm .hero__cta {
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
}

.hero--calm .hero__copy--calm {
  opacity: 1;
  pointer-events: auto;
}

.hero--calm .hero__brand-mark {
  animation: hero-calm-rise 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero--calm .hero__copy--calm .hero__triad--hero {
  animation: hero-calm-rise 0.95s 0.12s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero--calm .hero__copy--calm .hero__cta {
  animation: hero-calm-rise 0.95s 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  pointer-events: auto;
}

.hero--calm .hero__copy--calm .btn {
  pointer-events: auto;
}

.hero--calm .hero__same-wrap {
  pointer-events: auto;
}

.hero--calm .hero__same-map {
  pointer-events: auto;
  cursor: pointer;
}

@keyframes hero-punch-zoom {
  0% { opacity: 0; transform: scale(2.55); }
  72% { opacity: 1; transform: scale(0.96); }
  100% { opacity: 1; transform: scale(1); }
}

@keyframes hero-punch-dot {
  0% { opacity: 0; transform: scale(3.2); }
  38% { opacity: 1; transform: scale(1); }
  52% { transform: translateX(-0.07em) rotate(-7deg) scale(1); }
  66% { transform: translateX(0.08em) rotate(6deg) scale(1); }
  80% { transform: translateX(-0.04em) rotate(-3deg) scale(1); }
  100% { opacity: 1; transform: translateX(0) rotate(0deg) scale(1); }
}

@keyframes hero-together-in {
  0% {
    opacity: 0;
    transform: translateY(22px) scale(0.94);
    letter-spacing: 0.08em;
  }
  70% {
    opacity: 1;
    transform: translateY(-2px) scale(1.02);
    letter-spacing: -0.01em;
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    letter-spacing: -0.02em;
  }
}

@keyframes hero-blackout-jitter {
  0% { opacity: 1; transform: translate(0, 0) skewX(0); clip-path: inset(0 0 0 0); }
  12% { opacity: 1; transform: translate(-10px, 2px) skewX(2deg); clip-path: inset(0 0 38% 0); }
  24% { opacity: 0.95; transform: translate(12px, -3px) skewX(-3deg); clip-path: inset(42% 0 0 0); }
  36% { opacity: 0.8; transform: translate(-6px, 1px) skewX(1deg); clip-path: inset(8% 0 22% 0); }
  50% { opacity: 0.45; transform: translate(8px, -2px); clip-path: inset(0 18% 0 12%); }
  68% { opacity: 0.18; transform: translate(-4px, 0); }
  100% { opacity: 0; visibility: hidden; transform: translate(0, 0); }
}

@keyframes hero-calm-rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 640px) {
  .hero__punch {
    font-size: clamp(2.6rem, 14vw, 4.2rem);
    gap: 0.14em 0.2em;
  }
}

.hero__hint {
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(var(--letterbox-h) + 14px);
  z-index: 12;
  margin: 0;
  padding: 0 20px;
  color: var(--gray-600);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-align: center;
  text-transform: uppercase;
  pointer-events: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.hero__hint.hidden {
  opacity: 0;
  transform: translateY(10px);
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../assets/lissajous.svg') center / 100% 85% no-repeat;
  opacity: 0.28;
  pointer-events: none;
  z-index: 0;
}

.hero--live::before {
  display: none;
}

.hero__lissajous {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}

.hero--graph .hero__lissajous {
  z-index: 2;
  opacity: 0;
  transition: opacity 1.05s cubic-bezier(0.16, 1, 0.3, 1) 0.15s;
}

.hero--graph.hero--resolved .hero__lissajous,
.hero--graph.hero--calm .hero__lissajous {
  opacity: 0.9;
}

.hero__layout {
  position: absolute;
  left: calc(var(--gut) + 40px);
  right: var(--gut);
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(340px, 460px) minmax(0, 1fr);
  gap: clamp(24px, 3vw, 48px);
  align-items: center;
}

.hero__layout--left {
  top: var(--header-h);
  bottom: clamp(72px, 10vh, 120px);
  left: var(--gut);
  right: var(--gut);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  transform: none;
}

.hero__layout--left .hero__copy {
  text-align: left;
  max-width: min(720px, 100%);
}

.hero__layout--left .hero__body {
  margin: 0;
  max-width: 68ch;
}

.hero__layout--left .hero__copy .hero__cta {
  justify-content: flex-start;
  align-self: flex-start;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: min(100%, 380px);
  margin-top: 28px;
}

.hero__layout--left .hero__copy .hero__cta .btn {
  white-space: normal;
  text-align: center;
  line-height: 1.35;
  min-height: 3.25rem;
  padding: 12px 14px;
}

.hero__layout--center {
  top: var(--header-h);
  bottom: var(--letterbox-h);
  left: var(--gut);
  right: var(--gut);
  display: flex;
  align-items: center;
  justify-content: center;
  transform: none;
}

.hero--graph .hero__layout {
  pointer-events: none;
}

.hero__layout--center .hero__body {
  max-width: 68ch;
}

.hero__product {
  margin: 0;
  min-width: 0;
}

.hero__product img {
  display: block;
  width: 100%;
  max-height: min(68vh, 460px);
  object-fit: contain;
  object-position: center right;
  border-radius: 12px;
  border: 1px solid var(--gray-300);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

.hero__copy {
  --hero-r: 12px;
  max-width: min(820px, 100%);
  text-align: center;
}

.hero__sub {
  margin: 0 0 12px;
  font-size: clamp(16px, 1.9vw, 22px);
  font-weight: 600;
  line-height: 1.35;
  color: var(--gray-900);
  white-space: nowrap;
}

@media (max-width: 640px) {
  .hero__sub {
    white-space: normal;
  }
}

.hero__copy h1,
.hero__title {
  font-size: clamp(48px, 7.5vw, 88px);
  line-height: 1.08;
  margin: 0 0 20px;
  color: var(--gray-900);
}

.hero__title {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: 0.28em;
}

.hero__title-vibe {
  font-weight: 700;
}

.hero__title-edit {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  padding-top: 0.55em;
}

.hero__title-correction {
  position: absolute;
  top: -0.05em;
  left: 50%;
  transform: translateX(-42%) rotate(-7deg);
  font-family: 'Rock Salt', cursive;
  font-size: clamp(0.42em, 2.8vw, 0.58em);
  font-weight: 400;
  line-height: 1;
  color: #c62828;
  white-space: nowrap;
  pointer-events: none;
}

.hero__title-struck {
  position: relative;
  display: inline-block;
  font-weight: 700;
  color: var(--gray-900);
}

.hero__scribble {
  position: absolute;
  left: -4%;
  top: 38%;
  width: 108%;
  height: 0.65em;
  color: #c62828;
  overflow: visible;
  pointer-events: none;
  transform: rotate(-4deg);
  transform-origin: left center;
}

.hero__sub {
  margin: 0 0 12px;
  font-size: clamp(18px, 2.2vw, 22px);
  font-weight: 600;
  line-height: 1.35;
  color: var(--gray-900);
  white-space: nowrap;
}

.hero__triad {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: 0.35em 0.55em;
  margin: 0 0 4px;
  font-family: var(--font-sans);
  font-size: clamp(15px, 1.6vw, 18px);
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1.4;
  color: var(--gray-700);
}

.hero__triad--hero {
  margin: 0;
  max-width: 100%;
  font-size: clamp(1.15rem, 3.8vw, 1.85rem);
  font-weight: 400;
  letter-spacing: 0.015em;
  line-height: 1.15;
  color: var(--gray-900);
  gap: 0.12em;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  text-align: center;
  white-space: normal;
}

.hero__triad--hero .hero__triad-word {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--gray-900);
  white-space: normal;
  font-weight: 400;
  text-align: center;
}

.hero__tagline-line {
  display: block;
  text-align: center;
}

.hero__triad--hero em {
  font-style: italic;
  font-weight: 700;
  transition: color 0.25s ease;
}

.hero__triad--hero .hero__triad-sep {
  font-size: 0.85em;
  color: var(--gray-500);
  flex-shrink: 0;
}

.hero__copy--alive {
  animation: hero-rise 700ms ease-out both;
}

.hero__lede {
  margin: 1.1rem auto 0;
  max-width: 34rem;
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  font-weight: 400;
  line-height: 1.55;
  color: var(--gray-700);
}

.hero__copy--alive .hero__cta {
  margin-top: 1.75rem;
}

@keyframes hero-rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero__copy--alive {
    animation: none;
  }
}

@media (max-width: 640px) {
  .hero__triad {
    letter-spacing: 0.02em;
  }

  .hero__triad--hero {
    font-size: clamp(1.1rem, 4.6vw, 1.55rem);
    gap: 0.12em;
  }
}

.hero__triad-word {
  color: var(--gray-800);
}

.hero__triad-sep {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 0.95em;
  color: var(--gray-500);
  letter-spacing: 0;
}

.hero__brand-line {
  margin: 0 0 0.75rem;
  justify-content: center;
}

.hero__title--simple {
  display: block;
  margin: 0 0 1.25rem;
  font-size: clamp(2.75rem, 10vw, 4.75rem);
  letter-spacing: -0.03em;
  font-weight: 700;
}

.hero__copy:has(.hero__title--simple) .hero__triad {
  margin-top: 0.25rem;
}

.site-footer.site-footer--minimal {
  scroll-snap-align: none;
  padding: 1.5rem 0 2.5rem;
  border-top: 1px solid var(--line-2);
  background: var(--gray-100);
  color: var(--muted);
}

body.letterbox .site-footer.site-footer--minimal {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  height: var(--letterbox-h);
  padding: 0 var(--gut);
  border-top: 1px solid var(--gray-800);
  background: var(--gray-900);
  color: var(--gray-400);
}

body.letterbox .site-footer.site-footer--minimal .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  max-width: none;
}

body.letterbox .site-footer--minimal .site-footer__copy {
  margin: 0;
  color: var(--gray-400);
  text-align: left;
  font-size: 0.75rem;
}

body.letterbox .site-footer__legal {
  margin: 0;
  flex-shrink: 0;
}

body.letterbox .site-footer__legal a {
  color: var(--gray-300);
}

body.letterbox .site-footer__legal a:hover {
  color: var(--gray-100);
}

@media (max-width: 520px) {
  body.letterbox .site-footer.site-footer--minimal {
    height: auto;
    min-height: var(--letterbox-h);
    padding: 8px var(--gut);
  }

  body.letterbox .site-footer.site-footer--minimal .wrap {
    flex-wrap: wrap;
    justify-content: center;
  }

  body.letterbox .site-footer--minimal .site-footer__copy {
    text-align: center;
    width: 100%;
  }
}

.site-footer--minimal .site-footer__copy {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
}

@media (max-width: 640px) {
  .hero__triad {
    letter-spacing: 0.02em;
  }
}

.hero__body {
  margin: 0 auto;
  max-width: 42ch;
  font-size: clamp(16px, 1.9vw, 18px);
  line-height: 1.65;
  color: var(--body);
}

.hero__copy .hero__cta {
  justify-content: center;
  margin-top: 28px;
  position: relative;
  left: 4px;
  top: -14px;
}

.hero__copy .btn {
  border-radius: 0;
  padding: 14px 28px;
}

.hero__copy .hero__cta .btn {
  white-space: normal;
  text-align: center;
  line-height: 1.3;
  min-height: 2.45rem;
  padding: 12px 28px;
  font-size: 0.95rem;
  font-weight: 600;
  box-shadow: -5px 5px 14px rgba(38, 38, 38, 0.45);
}

.hero__copy .hero__cta .btn:hover {
  box-shadow: -6px 6px 18px rgba(38, 38, 38, 0.5);
}

.btn--outline {
  background: transparent;
  border-color: var(--gray-900);
  color: var(--gray-900);
}

.btn--outline:hover {
  background: var(--gray-900);
  border-color: var(--gray-900);
  color: var(--gray-100);
}

.btn--pill {
  border-radius: var(--pill);
}

.btn--dark {
  background: var(--gray-900);
  border-color: var(--gray-900);
  color: var(--gray-100);
}

.btn--dark:hover {
  background: var(--gray-800);
  border-color: var(--gray-800);
  color: var(--gray-100);
}

.btn--light {
  background: var(--gray-100);
  border-color: var(--gray-100);
  color: var(--gray-900);
}

.btn--light:hover {
  background: var(--gray-200);
  border-color: var(--gray-200);
  color: var(--gray-900);
}

.btn--white {
  background: #fff;
  border-color: #fff;
  color: var(--gray-900);
}

.btn--white:hover {
  background: var(--gray-200);
  border-color: var(--gray-200);
  color: var(--gray-900);
}

.hero__band {
  display: none;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.mock {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--gray-100);
  box-shadow: var(--sh-lg);
  overflow: hidden;
}

.mock__bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-300);
  background: var(--gray-200);
}

.mock__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--gray-400);
}

.mock__dot--on {
  background: var(--gray-700);
}

.mock__url {
  margin-left: 8px;
  height: 10px;
  flex: 1;
  max-width: 140px;
  background: var(--bg-soft2);
  border-radius: 5px;
  font-size: 0;
}

.mock__body {
  padding: 20px;
  display: grid;
  gap: 16px;
}

.mock__row {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 12px;
  align-items: center;
}

.mock__lines {
  display: grid;
  gap: 8px;
}

.mock__line {
  display: block;
  height: 10px;
  border-radius: 5px;
  background: var(--bg-soft2);
  width: 85%;
}

.mock__line--strong {
  width: 58%;
  background: var(--gray-500);
}

.mock__chart {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 110px;
  padding-top: 12px;
  border-top: 1px solid var(--line-2);
}

.mock__bar2 {
  flex: 1;
  background: var(--bg-soft2);
  border-radius: 5px 5px 0 0;
}

.mock__bar2--mid {
  background: var(--brand-100);
}

.mock__bar2--on {
  background: var(--brand);
}

/* ---- cards & grids ---- */
.card {
  background: var(--gray-100);
  border: 1px solid var(--line);
  border-radius: var(--r-control);
  padding: clamp(22px, 3vw, 28px);
  box-shadow: var(--sh-sm);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.card--shadow {
  box-shadow: var(--sh);
}

.card--link {
  transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.card--link:hover {
  border-color: var(--brand-100);
  transform: translateY(-2px);
  box-shadow: var(--sh-lg);
}

.card h3 {
  font-size: 1.15rem;
  margin: 16px 0 8px;
}

.qtile {
  width: 48px;
  height: 48px;
  border-radius: var(--r-control);
  border: 1px solid var(--brand-100);
  display: grid;
  place-items: center;
  background: var(--brand-50);
  color: var(--brand);
  flex: none;
}

.qtile--dark {
  background: var(--dark-2);
  border-color: var(--dark-2);
  color: #fff;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2.5vw, 24px);
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(14px, 2vw, 20px);
}

.arch-grid .card,
.docs-grid .card {
  min-height: 0;
}

.docs__group-title {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 clamp(16px, 2.5vh, 24px);
  color: var(--ink);
}

.card__go {
  margin-top: auto;
  padding-top: 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--brand);
}

/* ---- differentiation ---- */
.why-quilt__head {
  margin-bottom: clamp(16px, 2.5vh, 24px);
}

.why-quilt__media {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  column-gap: clamp(12px, 1.5vw, 20px);
  align-items: stretch;
}

.why-quilt__video-col {
  display: block;
  align-self: stretch;
}

.product-video--why-quilt {
  margin-bottom: 0;
  max-width: none;
  width: 100%;
  display: block;
}

.product-video--why-quilt .product-video__frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
}

.why-quilt__features-col {
  display: flex;
  flex-direction: column;
  align-self: stretch;
  min-height: 0;
}

.why-features--why-quilt .why-feature {
  flex: 0 0 auto;
  padding: clamp(10px, 1.5vw, 14px);
  grid-template-columns: 40px 1fr;
  gap: 10px;
}

.why-features--why-quilt .why-feature .qtile {
  width: 40px;
  height: 40px;
}

.why-features--why-quilt .why-feature__title {
  font-size: 0.9rem;
  margin-bottom: 2px;
  line-height: 1.25;
}

.why-features--why-quilt .why-feature__text {
  font-size: 12px;
  line-height: 1.3;
}

.why-features {
  list-style: none;
  margin: clamp(24px, 4vh, 36px) 0 0;
  padding: 0;
  display: grid;
  gap: clamp(12px, 2vh, 16px);
  max-width: min(720px, 100%);
}

.why-feature {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 14px;
  align-items: start;
  padding: clamp(16px, 2.5vw, 20px);
  border: 1px solid rgba(39, 39, 42, 0.1);
  border-radius: var(--r-lg);
  background: rgba(39, 39, 42, 0.04);
}

.why-feature__title {
  display: block;
  color: #3f3f46;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.why-feature__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.45;
  font-weight: 500;
  color: #71717a;
}

.product-video {
  margin-bottom: clamp(24px, 4vh, 36px);
  max-width: min(420px, 100%);
}

.product-video__frame {
  aspect-ratio: 16 / 9;
  border: 1px dashed var(--line);
  border-radius: var(--r-control);
  background: var(--bg-soft);
  display: grid;
  place-items: center;
}

.product-video__label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

/* Why QUILT overrides — after base .why-features / .product-video */
.product-video.product-video--why-quilt {
  margin-bottom: 0;
  max-width: none;
}

.why-features.why-features--why-quilt {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1;
  align-self: stretch;
  height: 100%;
  min-height: 100%;
  margin: 0;
  padding: 0;
  max-width: none;
  list-style: none;
  gap: clamp(12px, 2vh, 16px);
}

.diff-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

.diff-panel {
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--dark);
  color: #d4d4d8;
  padding: clamp(20px, 3vw, 28px);
  display: grid;
  gap: 18px;
}

.diff-panel__row {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 14px;
  align-items: start;
}

.diff-panel__title {
  display: block;
  color: #fff;
  font-size: 1rem;
  margin-bottom: 6px;
}

.checklist {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.checklist li {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 12px;
  align-items: start;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.45;
  color: var(--body);
}

.checklist .tick {
  width: 22px;
  height: 22px;
  margin-top: 2px;
  color: var(--brand);
}

/* ---- pricing (Langfuse-inspired) ---- */
.pricing__head {
  margin-bottom: clamp(16px, 2.5vh, 24px);
}

.pricing__head .eyebrow {
  margin-bottom: 2px;
}

.pricing__title {
  font-size: clamp(26px, 3.5vw, 40px);
  letter-spacing: -0.03em;
  line-height: 1.08;
  max-width: 20ch;
  margin-top: 10px;
}

.pricing__head .section-head__lead {
  margin-top: 10px;
  font-size: clamp(0.9rem, 1.5vw, 1rem);
}

.pricing__cards {
  margin-bottom: clamp(28px, 4vh, 40px);
  gap: clamp(10px, 1.2vw, 14px);
}

.pricing__cards .pcard {
  border: 1px solid var(--line);
  border-radius: var(--r-control);
  background: var(--gray-100);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 0;
  box-shadow: var(--sh-sm);
  min-height: 0;
}

.pricing__cards .pcard--tier {
  position: relative;
  padding-top: 20px;
}

.pricing__cards .pcard--tier::before,
.pricing__cards .pcard--tier::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  border-color: var(--ink);
  border-style: solid;
  pointer-events: none;
}

.pricing__cards .pcard--tier::before {
  top: 8px;
  left: 8px;
  border-width: 2px 0 0 2px;
}

.pricing__cards .pcard--tier::after {
  top: 8px;
  right: 8px;
  border-width: 2px 2px 0 0;
}

.pricing__cards .pcard--feat {
  border-color: var(--ink);
  box-shadow: var(--sh);
}

.pricing__cards .pcard__badge {
  position: absolute;
  top: -9px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: var(--pill);
  background: var(--ink);
  color: #fff;
  white-space: nowrap;
}

.pricing__cards .pcard__name {
  font-size: 0.95rem;
  margin: 0 0 4px;
}

.pricing__cards .pcard__tagline {
  font-size: 0.72rem;
  line-height: 1.4;
  color: var(--body);
  margin: 0 0 10px;
  flex: 1;
}

.pricing__cards .pcard__features {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  flex: 1;
  display: grid;
  gap: 5px;
}

.pricing__cards .pcard__features li {
  font-size: 0.72rem;
  line-height: 1.4;
  color: var(--body);
  padding-left: 12px;
  position: relative;
}

.pricing__cards .pcard__features li::before {
  content: '·';
  position: absolute;
  left: 0;
  color: var(--muted);
  font-weight: 700;
}

.pricing__cards .pcard__price {
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 0 10px;
  color: var(--ink);
}

.pricing__cards .pcard__period {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
}

.pricing__cards .pcard__foot {
  margin: 8px 0 0;
  font-size: 10px;
  line-height: 1.35;
  color: var(--muted-2);
  text-align: center;
}

.pricing__cards .btn {
  font-size: 12px;
  padding: 7px 10px;
}

.pricing__compare-title {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  margin-bottom: 16px;
  text-align: left;
}

.compare-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line);
  border-radius: var(--r-control);
  background: var(--gray-100);
}

.compare-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 14px;
}

.compare-table thead th {
  font-weight: 700;
  color: var(--ink);
  text-align: center;
  padding: 14px 12px;
  border-bottom: 1px solid var(--line);
  background: var(--bg-soft);
}

.compare-table__feature-col {
  width: 36%;
  min-width: 180px;
}

.compare-table tbody th[scope="row"] {
  font-weight: 500;
  text-align: left;
  color: var(--ink);
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-2);
}

.compare-table td {
  text-align: center;
  padding: 12px;
  border-bottom: 1px solid var(--line-2);
  color: var(--body);
}

.compare-table__section th {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-align: left;
  padding: 14px 16px 8px;
  color: var(--muted-2);
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
}

.compare-yes {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  font-weight: 700;
  color: var(--ink);
}

.compare-no {
  color: var(--muted);
  font-weight: 500;
}

/* ---- security ---- */
.security {
  background: var(--dark);
  color: #e4e4e7;
  border-bottom-color: var(--dark-2);
}

.security__inner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: clamp(24px, 4vw, 40px);
  align-items: start;
  max-width: 900px;
  margin: 0 auto;
}

.security__badge {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  border: 2px solid #fff;
  display: grid;
  place-items: center;
  color: #fff;
  flex: none;
}

.security__title {
  font-size: clamp(28px, 4vw, 40px);
  color: #fff;
  margin-bottom: 12px;
}

.security__lead {
  color: #a1a1aa;
  margin-bottom: 24px;
  font-size: 1rem;
}

.security__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 20px;
}

.security__list li {
  font-size: clamp(15px, 1.6vw, 17px);
  line-height: 1.55;
  padding-left: 20px;
  border-left: 3px solid #fff;
}

.security__list strong {
  color: #fff;
  font-weight: 700;
}

/* ---- footer ---- */
.site-footer {
  scroll-snap-align: start;
  background: var(--dark);
  color: #a1a1aa;
  border-top: 1px solid var(--dark-2);
  padding: clamp(48px, 8vh, 72px) 0 32px;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: clamp(24px, 3vw, 36px);
}

.footer__col h4 {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 16px;
}

.footer__col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.footer__col a {
  color: #a1a1aa;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  transition: color 0.12s ease;
}

.footer__col a:hover {
  color: #fff;
}

.footer__social {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
}

.footer__social-link {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--dark-2);
  border-radius: var(--r-control);
  color: #a1a1aa;
  transition: color 0.12s ease, border-color 0.12s ease, background 0.12s ease;
}

.footer__social-link:hover {
  color: #fff;
  border-color: #52525b;
  background: rgba(255, 255, 255, 0.06);
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--dark-2);
  font-size: 13px;
  color: #71717a;
}

.footer__legal {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.footer__legal a {
  color: #a1a1aa;
  font-size: 13px;
  font-weight: 500;
  transition: color 0.12s ease;
}

.footer__legal a:hover {
  color: #fff;
}

/* ---- modal ---- */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(3px);
  display: none;
  place-items: center;
  padding: 24px;
}

.modal-overlay.open {
  display: grid;
}

.modal-overlay[hidden] {
  display: none !important;
}

.modal {
  position: relative;
  width: 100%;
  max-width: 410px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--sh-xl);
  padding: 36px;
}

.modal h3 {
  font-size: 24px;
}

.modal__lead {
  font-size: 0.95rem;
  margin-top: 8px;
}

.modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 6px 10px;
}

.field {
  display: grid;
  gap: 7px;
  margin-top: 16px;
}

.field label {
  font-weight: 600;
  font-size: 13px;
  color: var(--ink);
}

.field input {
  font-family: inherit;
  font-size: 15px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-control);
  width: 100%;
}

.field input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-ring);
}

/* ---- responsive stacking ---- */
@media (max-width: 900px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 900px) {
  .grid-3,
  .diff-grid,
  .why-quilt__media {
    grid-template-columns: 1fr;
    row-gap: clamp(16px, 2.5vh, 24px);
  }

  .why-quilt__features-col {
    height: auto;
  }

  .why-features--why-quilt {
    height: auto;
    gap: clamp(12px, 2vh, 16px);
  }

  .product-video--why-quilt,
  .product-video--why-quilt .product-video__frame {
    height: auto;
  }

  .product-video--why-quilt .product-video__frame {
    aspect-ratio: 16 / 9;
    min-height: 0;
  }

  .why-features--why-quilt .why-feature {
    padding: clamp(16px, 2.5vw, 20px);
  }

  .why-features--why-quilt .why-feature__text {
    font-size: 15px;
    line-height: 1.45;
  }

  .diff-copy {
    order: 1;
  }

  .diff-panel {
    order: 2;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer__col--brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 1040px) {
  .hero__layout,
  .hero__layout--left,
  .hero__layout--center {
    bottom: clamp(56px, 8vh, 96px);
  }

  .site-header .nav__links {
    position: static;
    transform: none;
    flex-wrap: wrap;
    justify-content: center;
  }

  .site-header .nav__sep {
    display: none;
  }

  .hero__product img {
    max-height: 320px;
    object-position: center;
  }
}

@media (max-width: 560px) {
  .solution-cta {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .grid-4 {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr;
  }

  .hero__cta .btn {
    width: 100%;
  }

  .hero__layout--left .hero__copy .hero__cta {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .security__inner {
    grid-template-columns: 1fr;
  }

  .footer__bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn,
  .card--link,
  .nav__panel {
    transition: none;
  }
}
