:root {
  --bg: oklch(0.975 0.003 90);
  --bg-raised: #ffffff;
  --bg-card: #ffffff;
  --border: rgba(0, 0, 0, 0.09);
  --border-strong: rgba(0, 0, 0, 0.2);
  --text: oklch(0.2 0.006 265);
  --text-muted: oklch(0.44 0.01 275);
  --text-faint: oklch(0.58 0.009 275);
  --ink: oklch(0.2 0.006 265);
  --ink-hover: oklch(0.3 0.006 265);
  --ink-text: oklch(0.97 0.003 250);
  --hover: rgba(0, 0, 0, 0.04);
  --nav-bg: rgba(248, 248, 246, 0.88);
  --menu-bg: rgba(248, 248, 246, 0.97);
  --chevron: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23000000' stroke-opacity='.55' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --serif: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  color-scheme: light;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.logo-mono { filter: invert(1); }

img { display: block; }
a { color: inherit; text-decoration: none; }
.mono { font-family: var(--mono); }

/* Match the app's controls and floating squircle surfaces at its default scale. */
.btn, .lang-select, .nav-links a, .chat-msg, .chat-file {
  border-radius: 9px;
}
.chip, .file-badge, .ext { border-radius: 6px; }
.nav-links, .terminal { border-radius: 12px; }
.panel, .chat-demo, .hero-frame img, .hero-placeholder, .price-card, .price-team {
  border-radius: 1.458rem;
  corner-shape: squircle;
}
@supports (corner-shape: squircle) {
  .panel, .chat-demo, .hero-frame img, .hero-placeholder, .price-card, .price-team { border-radius: 2.025rem; }
}
.terminal { overflow: hidden; }

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

.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.015em;
}

h1 {
  font-size: clamp(48px, 7.6vw, 96px);
  line-height: 0.98;
}

h2 {
  font-size: clamp(36px, 4.6vw, 56px);
  line-height: 1.02;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 500;
  white-space: nowrap;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-sm { padding: 9px 16px; font-size: 14px; }
.btn-lg { padding: 15px 28px; font-size: 16px; }

.btn-primary {
  background: var(--ink);
  color: var(--ink-text);
  border: 1px solid var(--ink);
}
.btn-primary:hover { background: var(--ink-hover); border-color: var(--ink-hover); }

.btn-secondary {
  background: var(--bg-raised);
  color: var(--text);
  border: 1px solid var(--border-strong);
}
.btn-secondary:hover { border-color: var(--text); }

.btn-ghost { color: var(--text-muted); background: var(--bg-raised); border: 1px solid var(--border); }
.btn-ghost:hover { color: var(--text); }

/* ---------- nav ---------- */

.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  padding: 16px 0;
  transition: background 0.2s ease, border-color 0.2s ease;
  border-bottom: 1px solid transparent;
}

.nav.scrolled {
  background: var(--nav-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 20px;
}

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

.brand-mark { width: 30px; height: 30px; }

.brand-name {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  gap: 4px;
  margin: 0 auto;
  padding: 4px;
  border: 1px solid var(--border);
  background: var(--bg-raised);
}

.nav-links a {
  padding: 6px 14px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.15s ease, background 0.15s ease;
}
.nav-links a:hover { color: var(--text); background: var(--hover); }

.nav-actions { display: flex; gap: 6px; align-items: center; }

.nav .btn, .nav .lang-select { height: 40px; }
.nav .btn, .nav .lang-select { padding-top: 0; padding-bottom: 0; }
.nav:not(.menu-open) .nav-links { height: 40px; }
.nav-links a { display: flex; align-items: center; padding-top: 0; padding-bottom: 0; }

.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  padding: 8px;
  cursor: pointer;
}
.nav-burger span {
  width: 20px;
  height: 2px;
  background: var(--text);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ---------- scenes ---------- */

.scene {
  position: relative;
  overflow: hidden;
}

.scene-sky {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
}

.scene > :not(.scene-sky) { position: relative; z-index: 1; }

/* ---------- hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  height: 100svh;
  min-height: 680px;
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
  grid-template-rows: 1fr;
  align-items: center;
  gap: 24px;
  padding: 100px 32px 32px;
  background: #f6f5ef;
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 0 clamp(0px, 3vw, 48px);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

.hero h1 { max-width: 16ch; font-size: clamp(48px, min(5.2vw, 9svh), 84px); line-height: 1.02; letter-spacing: -0.04em; }
.hero-sub { max-width: 45ch; margin: 26px 0 30px; font-size: clamp(15px, 1.2vw, 17px); color: var(--text-muted); }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.hero .hero-ctas { justify-content: flex-start; }

.hero-stage {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  isolation: isolate;
  max-width: 1440px;
  margin: 0 auto;
  border-radius: 32px;
  background: radial-gradient(ellipse at 20% 10%, #e5eadb, transparent 65%), #bdcdb6;
}
.hero-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; touch-action: pan-y; opacity: 0; transform: translateY(18px) scale(0.98); transition: opacity 800ms ease, transform 1000ms cubic-bezier(.2,.7,.2,1); }
.hero-stage canvas:active { cursor: grabbing; }
.hero-stage.is-3d canvas { opacity: 1; transform: translateY(0) scale(1); }
.hero-frame { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; opacity: 0; pointer-events: none; transition: opacity 500ms ease; }
.hero-frame img { width: 95%; height: auto; max-height: 100%; object-fit: contain; box-shadow: 0 24px 70px -24px rgba(27, 56, 48, 0.3); }
.hero-stage.has-fallback .hero-frame { opacity: 1; }
.hero-loader { position: absolute; top: 50%; left: 50%; display: flex; gap: 7px; transform: translate(-50%, -50%); transition: opacity 180ms ease, visibility 180ms; }
.hero-loader i { width: 6px; height: 6px; border-radius: 50%; background: #55704e; animation: scene-pulse 1200ms ease-in-out infinite; }
.hero-loader i:nth-child(2) { animation-delay: 150ms; }
.hero-loader i:nth-child(3) { animation-delay: 300ms; }
.hero-stage.is-3d .hero-loader, .hero-stage.has-fallback .hero-loader { opacity: 0; visibility: hidden; }
@keyframes scene-pulse { 0%, 80%, 100% { opacity: .25; transform: scale(.8); } 40% { opacity: .8; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .hero-stage canvas, .hero-frame, .hero-loader { transition: none; transform: none; }
  .hero-loader { transform: translate(-50%, -50%); }
  .hero-loader i { animation: none; opacity: .5; }
}

.hero-placeholder {
  display: none;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16 / 8.6;
  border: 1px dashed var(--border-strong);
  background: var(--bg-raised);
  color: var(--text-faint);
  font-size: 14px;
}
.hero-frame.no-shot .hero-placeholder { display: flex; }

/* ---------- sections ---------- */

section { padding: 112px 0; }
/* Fixed nav: keep anchored headings below it. */
html { scroll-padding-top: 88px; }

.section-sub {
  max-width: 52ch;
  margin: 18px auto 0;
  color: var(--text-muted);
  font-size: 17px;
}

.models h2, .artifacts h2, .artifacts .section-sub { text-align: center; }
.models h2, .artifacts h2 { margin-inline: auto; max-width: 20ch; }

/* Square bullet used by every check list. */
.check-row li::before,
.check-list li::before,
.price-list li::before {
  content: "";
  flex-shrink: 0;
  width: 7px;
  height: 7px;
  margin-top: 0.55em;
  background: var(--text);
}

/* ---------- models ---------- */

.model-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0 40px;
  margin-top: 56px;
}

.model-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 0;
  border-top: 1px solid var(--border);
}

.model-card img { height: 22px; width: 22px; object-fit: contain; }

.model-card strong { display: block; font-size: 15px; font-weight: 600; }
.model-card span { display: block; font-size: 13px; color: var(--text-faint); }

.check-row {
  display: flex;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
  margin-top: 40px;
  list-style: none;
}

.check-row li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  color: var(--text-muted);
}

/* ---------- panels ---------- */

.panels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.panel {
  background: var(--bg-raised);
  border: 1px solid var(--border);
}

.panel-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px 56px;
}
.panel-copy .section-sub { margin: 18px 0 32px; }

.scene-panel {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 640px;
  padding: 56px 40px;
  border-color: transparent;
}

.panel-log {
  display: flex;
  align-items: center;
  padding: 48px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 32px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  border: 1px solid var(--border-strong);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text);
}

.chip svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.chip-sm { padding: 2px 8px; font-size: 12.5px; gap: 5px; }

.check-list { list-style: none; display: grid; gap: 14px; }

.check-list li {
  display: flex;
  gap: 12px;
  font-size: 15.5px;
  color: var(--text-muted);
  line-height: 1.5;
}
.check-list strong { color: var(--text); font-weight: 600; }

/* ---------- chat demo ---------- */

.chat-demo {
  display: grid;
  gap: 14px;
  width: min(460px, 100%);
  padding: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 40px 80px -30px rgba(20, 40, 20, 0.5);
}

.chat-msg {
  padding: 13px 16px;
  font-size: 14px;
  line-height: 1.5;
  max-width: 90%;
}

.chat-user {
  justify-self: end;
  background: var(--ink);
  color: var(--ink-text);
}

.chat-ai {
  justify-self: start;
  border: 1px solid var(--border);
  color: var(--text-muted);
}

.chat-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-faint);
}

.chat-file {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  border: 1px solid var(--border);
}

.file-badge {
  padding: 5px 8px;
  border: 1px solid var(--border-strong);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
}

.chat-file strong { display: block; font-size: 14px; font-weight: 600; }
.chat-file span:not(.file-badge) { font-size: 12.5px; color: var(--text-faint); }

/* ---------- artifacts ---------- */

.artifact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  margin-top: 64px;
}

.artifact-card { padding-top: 18px; border-top: 1px solid var(--border); }

.ext {
  display: inline-block;
  margin-bottom: 14px;
  padding: 2px 7px;
  border: 1px solid var(--border-strong);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-muted);
}

.artifact-card strong { display: block; font-size: 17px; font-weight: 600; }
.artifact-card span:not(.ext) { display: block; margin-top: 4px; font-size: 14.5px; color: var(--text-muted); }

/* ---------- run log ---------- */

.terminal {
  width: 100%;
  border: 1px solid var(--border-strong);
  background: var(--bg-card);
}

.term-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 22px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  font-weight: 600;
}

.term-bar em {
  font-style: normal;
  font-weight: 400;
  font-size: 13px;
  color: var(--text-faint);
}

.term-body { padding: 20px 22px; display: grid; gap: 10px; }

.term-line {
  display: flex;
  gap: 14px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.term-line.shown { opacity: 1; transform: none; }

.t-time { flex-shrink: 0; font-family: var(--mono); font-size: 12.5px; color: var(--text-faint); padding-top: 2px; }
.t-ok::before { content: "✓"; color: var(--text); font-weight: 700; }
.t-next { color: var(--text-faint); }

/* ---------- language select ---------- */

.lang-select {
  appearance: none;
  -webkit-appearance: none;
  padding: 8px 32px 8px 14px;
  border: 1px solid var(--border-strong);
  background-color: var(--bg-raised);
  background-image: var(--chevron);
  background-repeat: no-repeat;
  background-position: right 13px center;
  color: var(--text-muted);
  font-family: var(--font);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.lang-select:hover { color: var(--text); border-color: var(--text); }
.lang-select option { background: var(--bg-raised); color: var(--text); }

/* ---------- extension band ---------- */

.extension { padding-top: 0; }

.ext-band {
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: 64px 56px;
}

.ext-icon {
  position: absolute;
  right: -120px;
  top: 50%;
  transform: translateY(-50%);
}

.ext-icon img {
  width: 420px;
  height: 420px;
  object-fit: contain;
  opacity: 0.08;
  filter: grayscale(1);
}

.ext-copy { position: relative; }
.ext-copy h2 { max-width: 16ch; }
.ext-copy p {
  margin: 18px 0 30px;
  max-width: 52ch;
  color: var(--text-muted);
  font-size: 17px;
}

/* ---------- cta + footer ---------- */

.cta { padding: 100px 0 160px; }
.cta .scene-sky { object-position: center 30%; opacity: 0.65; }

.cta-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.cta h2 { max-width: 16ch; font-size: clamp(40px, 5.6vw, 72px); }
.cta .section-sub { margin-top: 22px; }
.cta .hero-ctas { margin-top: 36px; }

.footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: var(--text-faint);
}
.footer-brand img { width: 22px; height: 22px; opacity: 0.8; }

.footer-right {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-links { display: flex; gap: 24px; flex-wrap: wrap; }
.footer-links a { font-size: 14px; color: var(--text-faint); transition: color 0.15s ease; }
.footer-links a:hover { color: var(--text); }

@media (prefers-reduced-motion: reduce) {
  .term-line { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */

@media (max-width: 960px) {
  .nav-links, .nav-actions { display: none; }
  .nav-burger { display: flex; }

  .nav.menu-open { background: var(--menu-bg); border-bottom-color: var(--border); }
  .nav.menu-open .nav-links {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 4px;
    padding: 16px 24px 24px;
    border: 0;
    background: var(--menu-bg);
    border-bottom: 1px solid var(--border);
  }
  .nav.menu-open .nav-links a { padding: 10px 0; font-size: 16px; }
  .nav.menu-open .nav-burger span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .nav.menu-open .nav-burger span:last-child { transform: translateY(-3.5px) rotate(-45deg); }

  .nav-inner .brand { margin-right: auto; }
  .hero { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); min-height: 680px; padding: 88px 24px 20px; gap: 24px; }
  .hero-inner { align-items: center; text-align: center; padding: 0; }
  .hero-stage { align-self: stretch; max-height: none; border-radius: 24px; }
  .hero h1 { max-width: 18ch; font-size: clamp(44px, 6vw, 64px); }
  .hero-sub { max-width: 58ch; margin: 16px 0 20px; }
  .hero .hero-ctas { justify-content: center; }

  .panels { grid-template-columns: 1fr; }
  .model-grid { grid-template-columns: repeat(2, 1fr); }
  .artifact-grid { grid-template-columns: repeat(2, 1fr); }
  .panel-copy { padding: 48px 36px; }
  .scene-panel { min-height: 560px; padding: 48px 24px; }
  .ext-band { padding: 48px 36px; }
  .ext-icon { right: -80px; }
  .ext-icon img { width: 220px; height: 220px; }
}

@media (max-width: 640px) {
  section { padding: 80px 0; }
  .hero { padding: 80px 16px 16px; gap: 24px; }
  .hero-inner { padding: 0; }
  .hero .hero-ctas { flex-wrap: nowrap; gap: 8px; }
  .hero .btn-lg { padding: 12px 18px; font-size: 14px; }
  .cta { padding-top: 100px; }

  .artifact-grid { grid-template-columns: 1fr; }
  .hero-sub { font-size: 14px; margin: 14px 0 18px; }
  .panel-copy { padding: 40px 24px; }
  .panel-log { padding: 24px; }
}

@media (max-height: 619px) {
  .hero { height: auto; min-height: 100svh; }
  .hero-stage { min-height: 380px; }
}

/* ---------- pricing ---------- */

.pricing h2, .pricing .section-sub { text-align: center; margin-inline: auto; }
.pricing h2 { max-width: 20ch; }

.price-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 64px;
}

.price-card, .price-team {
  padding: 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
}
.price-card { display: flex; flex-direction: column; }
.price-card.is-featured { border-color: var(--border-strong); }

.price-name { display: flex; align-items: center; gap: 8px; min-height: 26px; font-size: 15px; font-weight: 600; }
.price { display: flex; align-items: baseline; gap: 6px; margin-top: 18px; }
.price-amount { font-family: var(--serif); font-size: 48px; line-height: 1; letter-spacing: -0.02em; }
.price-per { font-size: 14px; color: var(--text-muted); }
.price-note { margin-top: 8px; min-height: 2.9em; font-size: 14.5px; line-height: 1.45; color: var(--text-muted); }

.price-list {
  flex: 1;
  list-style: none;
  display: grid;
  gap: 10px;
  align-content: start;
  margin: 20px 0 28px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.price-list li { display: flex; gap: 10px; font-size: 14.5px; line-height: 1.45; color: var(--text-muted); }
.price-card .btn { width: 100%; padding: 11px 16px; font-size: 14.5px; }

.price-team {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr);
  gap: 32px 48px;
  align-items: stretch;
  margin-top: 16px;
}
.price-team-copy { display: flex; flex-direction: column; align-items: flex-start; }
.price-team .price-note { min-height: 0; margin-bottom: 22px; }
.price-team .btn { padding: 11px 18px; font-size: 14.5px; }
.price-team .price-list {
  margin: 0;
  padding: 4px 0 4px 48px;
  border-top: 0;
  border-left: 1px solid var(--border);
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-content: center;
  gap: 14px 32px;
}

@media (max-width: 960px) {
  .price-grid { grid-template-columns: repeat(2, 1fr); }
  .price-team { grid-template-columns: 1fr; gap: 24px; align-items: start; }
  .price-team .price-list { padding: 24px 0 0; border-left: 0; border-top: 1px solid var(--border); }
}
@media (max-width: 640px) {
  .price-grid { grid-template-columns: 1fr; }
  .price-team .price-list { grid-template-columns: 1fr; }
  .price-card, .price-team { padding: 24px; }
}
