/* Keyline landing. Tokens follow the app's "precision" system (src/ui/theme.ts). */
@font-face { font-family: Geist; src: url(/landing/fonts/Geist_400Regular.ttf) format('truetype'); font-weight: 400; font-display: swap; }
@font-face { font-family: Geist; src: url(/landing/fonts/Geist_500Medium.ttf) format('truetype'); font-weight: 500; font-display: swap; }
@font-face { font-family: Geist; src: url(/landing/fonts/Geist_600SemiBold.ttf) format('truetype'); font-weight: 600; font-display: swap; }
@font-face { font-family: Geist; src: url(/landing/fonts/Geist_700Bold.ttf) format('truetype'); font-weight: 700; font-display: swap; }

:root {
  /* "Midnight": the app's dark palette (src/ui/theme.ts) and the logo's colours. */
  --bg: #07080E;
  --surface: #10131E;
  --sunken: #0B0D16;
  --raised: #171B2A;
  --ink: #F3F5FB;
  --muted: #A1A8BF;
  --hairline: #1F2436;
  --hairline-strong: #2E3550;
  --accent: #5C8DFF;
  --accent-strong: #1F5FFF;
  --accent-hover: #3B74FF;
  --accent-soft: #13204A;
  --on-accent: #FFFFFF;
  --on-ink: #07080E;
  --brand-magenta: #F000F0;
  --brand-violet: #7B2FF7;
  --brand-blue: #0057FF;
  --danger: #FF6B6B;

  /* Five type steps. */
  --t-small: 15px;
  --t-body: 17px;
  --t-sub: 22px;
  --t-head: clamp(30px, 3vw, 44px);
  --t-hero: clamp(44px, 3.9vw, 64px);

  --margin: clamp(16px, 2.4vw, 32px);
  --radius: 16px;
  --bar-h: 64px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { color-scheme: dark; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--bar-h) + 16px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 var(--t-body)/1.55 Geist, system-ui, -apple-system, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }
h1, h2 { font-weight: 600; letter-spacing: -0.035em; line-height: 1.02; text-wrap: balance; }
h2 { font-size: var(--t-head); }
h3 { font-size: var(--t-sub); font-weight: 500; letter-spacing: -0.015em; line-height: 1.25; }
p { text-wrap: pretty; }
.soft { color: var(--muted); }
::selection { background: var(--accent); color: var(--on-ink); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip { position: absolute; left: -999px; top: 8px; z-index: 30; background: var(--accent-strong); color: var(--on-accent); padding: 10px 16px; border-radius: 999px; }
.skip:focus { left: 16px; }

/* Buttons: one shape (fully round), one fill. */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: 0 22px; border-radius: 999px;
  background: var(--accent-strong); color: var(--on-accent);
  font-size: var(--t-small); font-weight: 500; text-decoration: none;
  transition: transform 160ms var(--ease), background-color 160ms var(--ease);
}
.btn:hover { background: var(--accent-hover); }
.btn:active { transform: scale(0.97); }
.btn-lg { min-height: 52px; padding: 0 28px; font-size: var(--t-body); }
.btn-light { background: var(--ink); color: var(--on-ink); }
.btn-light:hover { background: #FFFFFF; }
.link { color: var(--accent); font-weight: 500; text-decoration: none; transition: color 160ms var(--ease); }
.link:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }

/* Bar: wordmark, four links, one action. */
.bar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  height: var(--bar-h); padding: 0 var(--margin);
  background: var(--bg);
}
.wordmark { display: inline-flex; align-items: center; text-decoration: none; }
.wordmark img { height: 30px; width: auto; }
/* "A CARVEX product": the company line beside or under the product logo. */
.made-by { display: inline-flex; align-items: center; gap: 7px; font-size: var(--t-small); color: var(--muted); white-space: nowrap; }
.made-by img { height: 14px; width: auto; }
.bar-brand { display: flex; align-items: center; gap: 18px; }
.bar-links { display: flex; gap: 28px; }
.bar-links a, .quiet { font-size: var(--t-small); color: var(--muted); text-decoration: none; transition: color 160ms var(--ease); }
.bar-links a:hover, .quiet:hover { color: var(--ink); }
.bar-actions { display: flex; align-items: center; gap: 20px; }

/* The split stage: reading column left, a fixed product view right. */
.stage {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px;
  padding: 0 var(--margin);
}
.read { min-width: 0; }

.hero {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: calc(100svh - var(--bar-h) - 12px);
  display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center;
  padding: 64px clamp(24px, 3vw, 56px);
  background: var(--surface); border-radius: var(--radius);
}
/* Brand exception: the logo's light falls on the panel behind the 3D mark. */
.hero::before {
  content: ''; position: absolute; z-index: -1; left: 50%; top: 4%; width: 560px; height: 560px; transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(123, 47, 247, 0.32), rgba(0, 87, 255, 0.12) 55%, transparent); /* taste-skill-ignore: brand light of the logo */
}
.hero-mark { width: clamp(112px, 11vw, 168px); height: auto; margin-bottom: 36px; }
.hero-made-by { display: none; }
.hero h1 { font-size: var(--t-hero); max-width: 17ch; }
.hero .lede { margin-top: 28px; font-size: var(--t-sub); line-height: 1.45; max-width: 31ch; }
.hero-actions { display: flex; align-items: center; gap: 24px; margin-top: 36px; }
.hero .lede { color: var(--muted); }
.hero .note { margin-top: 24px; font-size: var(--t-small); color: var(--muted); max-width: 40ch; }
.hero-phone { display: none; }

.pin { position: sticky; top: var(--bar-h); height: calc(100svh - var(--bar-h) - 12px); min-width: 0; }
.pin-field {
  position: relative; height: calc(100% - 56px);
  /* Brand exception: the logo's magenta → violet → blue, as the stage for the product. */
  background: linear-gradient(150deg, var(--brand-magenta) -20%, var(--brand-violet) 32%, var(--brand-blue) 100%); /* taste-skill-ignore: logo colours, brand asset */
  border-radius: var(--radius) var(--radius) 0 0; overflow: hidden;
}
.shot {
  position: absolute; left: 50%; top: 7%;
  width: auto; height: 108%; max-width: none;
  border-radius: 28px; outline: 1px solid rgba(255, 255, 255, 0.14); outline-offset: -1px;
  transform: translateX(-50%) translateY(14px);
  opacity: 0; transition: opacity 1.6s var(--ease), transform 1.6s var(--ease);
}
.shot.is-on { opacity: 1; transform: translateX(-50%); }
.pin-bar {
  display: flex; justify-content: space-between; align-items: center; height: 56px; padding: 0 20px;
  background: var(--raised); border-radius: 0 0 var(--radius) var(--radius);
  font-size: var(--t-small); color: var(--muted);
}
.pin-cap { color: var(--ink); font-weight: 500; }

.features { padding: 160px clamp(24px, 4vw, 72px) 120px; }
.features h2 { max-width: 14ch; margin-bottom: 72px; }
.mod { display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: 28px; align-items: start; max-width: 720px; }
.mod + .mod { margin-top: 112px; }
.panel { background: var(--surface); border-radius: var(--radius); overflow: hidden; outline: 1px solid var(--hairline); outline-offset: -1px; } /* taste-skill-ignore: edge of a real interface crop */
.panel img { width: 100%; }
.mod-text p { margin-top: 12px; font-size: 16px; }

/* Voice notes: the live demo. */
.voice {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 0 24px;
  padding: 200px var(--margin) 0;
}
.voice-list { grid-column: 1 / span 5; align-self: center; padding-left: clamp(0px, 3vw, 48px); }
.voice-lede { font-size: var(--t-sub); line-height: 1.45; max-width: 26ch; }
.voice-names { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-top: 36px; }
.name {
  appearance: none; border: 0; background: none; padding: 4px 0; cursor: pointer; text-align: left;
  font: 600 var(--t-head)/1.1 Geist, system-ui, sans-serif; letter-spacing: -0.035em;
  color: var(--muted);
  transition: color 200ms var(--ease), transform 200ms var(--ease);
}
.name:hover { color: var(--ink); transform: translateX(6px); }
.name[aria-selected='true'] { color: var(--ink); }
.name[aria-selected='true']::before { content: ''; display: inline-block; width: 12px; height: 12px; margin: 0 14px 6px 0; border-radius: 50%; background: var(--accent); vertical-align: middle; }
.voice-foot { margin-top: 36px; font-size: var(--t-small); max-width: 38ch; }
.voice-stage {
  grid-column: 7 / span 6; position: relative; height: min(88svh, 820px); overflow: hidden;
  background: #0E1636; border-radius: var(--radius);
}
.sheet {
  position: absolute; top: 72px; left: clamp(20px, 4vw, 64px); width: min(460px, calc(100% - 40px));
  background: var(--surface); border-radius: var(--radius); padding: 28px 28px 120px;
  font-size: var(--t-small); line-height: 1.45; color: var(--ink);
  outline: 1px solid var(--hairline-strong); outline-offset: -1px; /* taste-skill-ignore: app sheet edge inside data-ui */
  transition: opacity 220ms var(--ease), transform 220ms var(--ease);
}
.sheet.is-swapping { opacity: 0; transform: translateY(8px); }
.sheet-head { display: flex; justify-content: space-between; font-size: var(--t-body); font-weight: 600; }
.sheet-time { color: var(--muted); font-weight: 400; }
.said { margin: 20px 0 8px; padding: 16px; background: var(--raised); border-radius: 12px; font-size: var(--t-small); }
.row { display: flex; flex-direction: column; gap: 2px; padding: 14px 0; border-bottom: 1px solid var(--hairline); } /* taste-skill-ignore: app list divider inside the data-ui sheet */
.row-label { display: block; font-size: 13px; color: var(--muted); }
.said .row-label { margin-bottom: 4px; }
.row-value { font-size: var(--t-small); font-weight: 500; }
.tag { margin-left: 6px; padding: 2px 8px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 500; white-space: nowrap; }
.due { display: block; margin-top: 2px; color: var(--accent); font-weight: 500; }
.sheet-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }
.ui-btn { padding: 10px 16px; border-radius: 12px; background: var(--surface); border: 1px solid var(--hairline-strong); font-weight: 500; } /* taste-skill-ignore: app button inside the data-ui sheet */
.ui-btn-ink { background: var(--accent-strong); border-color: var(--accent-strong); color: var(--on-accent); }

/* Full-width photograph: the one break from the split. */
.photo-break { margin: 200px 0 0; }
.photo-frame { height: min(86svh, 900px); overflow: hidden; }
.photo-frame img { width: 100%; height: 115%; object-fit: cover; }
.photo-break figcaption {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 0 24px;
  padding: 40px var(--margin) 0;
}
.statement { grid-column: 2 / span 7; font-size: clamp(24px, 2.4vw, 34px); line-height: 1.3; letter-spacing: -0.02em; font-weight: 500; }
.credit { grid-column: 10 / span 3; font-size: var(--t-small); color: var(--muted); max-width: 60ch; }

.web {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 0 24px; align-items: center;
  padding: 200px var(--margin) 0;
}
.web-text { grid-column: 1 / span 4; padding-left: clamp(0px, 3vw, 48px); }
.web-text h2 { max-width: 11ch; }
.web-text p { margin-top: 24px; max-width: 36ch; }
.web-shot { grid-column: 6 / span 7; background: #0E1636; border-radius: var(--radius); overflow: hidden; padding: 40px 0 0 40px; }
.web-shot img { border-radius: 12px 0 0 0; }

/* Pricing on a full field of ink, set like a menu. */
.pricing {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 0 24px;
  margin-top: 200px; padding: 160px var(--margin);
  background: var(--surface); color: var(--ink);
}
.pricing h2 { grid-column: 1 / span 4; padding-left: clamp(0px, 3vw, 48px); max-width: 13ch; }
.menu { grid-column: 6 / span 7; }
.menu h3 { color: var(--ink); }
.menu ul { list-style: none; margin: 40px 0 0; padding: 0; columns: 2; column-gap: 64px; }
.menu li { display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; break-inside: avoid; margin-bottom: 28px; }
.item { font-size: var(--t-body); font-weight: 500; }
.price { font-size: var(--t-body); font-weight: 500; color: var(--accent); }
.desc { grid-column: 1 / -1; font-size: var(--t-small); color: var(--muted); max-width: 36ch; }
.pricing-note { margin: 24px 0 36px; max-width: 52ch; color: var(--ink); }

.faq {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 0 24px;
  padding: 200px var(--margin) 0;
}
.faq h2 { grid-column: 1 / span 3; padding-left: clamp(0px, 3vw, 48px); }
.faq-text { grid-column: 5 / span 8; columns: 2; column-gap: 56px; }
.faq-text p { break-inside: avoid; margin-bottom: 22px; font-size: var(--t-body); max-width: 62ch; }
.faq-text strong { font-weight: 600; }

.cta { padding: 34svh var(--margin) 22svh calc(var(--margin) + clamp(0px, 3vw, 48px)); }
.cta p { font-size: var(--t-sub); line-height: 1.4; max-width: 34ch; }
.cta-actions { display: flex; align-items: center; gap: 24px; margin-top: 24px; }

/* Footer: photograph half, menu half. */
.foot { display: grid; grid-template-columns: 1fr 1fr; min-height: 100svh; background: var(--surface); }
.foot-menu .made-by { margin-top: 14px; }
.foot-photo { overflow: hidden; }
.foot-photo img { width: 100%; height: 112%; object-fit: cover; object-position: 50% 40%; }
.foot-menu { display: flex; flex-direction: column; padding: 56px clamp(24px, 5vw, 96px) 32px; }
.foot-nav { display: flex; flex-direction: column; align-items: flex-start; gap: 18px; margin-top: 72px; }
.foot-nav a {
  font-size: var(--t-head); font-weight: 600; letter-spacing: -0.035em; line-height: 1.05; text-decoration: none;
  transition: transform 200ms var(--ease), color 200ms var(--ease);
}
.foot-nav:hover a { color: var(--muted); }
.foot-nav a:hover, .foot-nav a:focus-visible { color: var(--ink); transform: translateX(12px); }
.foot-blocks { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 64px; font-size: var(--t-small); }
.foot-blocks a { color: var(--accent); text-decoration: none; }
.foot-blocks a:hover { text-decoration: underline; }
.foot-legal { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: auto; padding-top: 48px; font-size: var(--t-small); }
.foot-legal a { color: var(--ink); text-decoration: none; }
.foot-legal a:hover { color: var(--accent); }
.foot .legal { margin-top: 16px; font-size: var(--t-small); color: var(--muted); max-width: 60ch; }

/* Entrances: only for elements that start below the fold (landing.js adds .pre). */
.pre { opacity: 0; transform: translateY(24px); }
.pre.in { opacity: 1; transform: none; transition: opacity 700ms var(--ease), transform 700ms var(--ease); transition-delay: var(--d, 0ms); }

@media (max-width: 1100px) {
  .bar-links { display: none; }
  .mod { grid-template-columns: 1fr; }
  .mod-text { max-width: 46ch; }
}

@media (max-width: 860px) {
  :root { --t-sub: 19px; --bar-h: 56px; }
  .quiet[hreflang] { display: none; }
  .bar-actions { gap: 14px; }
  .bar .made-by { display: none; }
  .hero .hero-made-by { display: inline-flex; margin-top: 18px; }
  .wordmark img { height: 26px; }
  .stage { grid-template-columns: 1fr; }
  .pin { display: none; }
  .hero { min-height: auto; padding: 48px 20px 0; overflow: hidden; }
  .hero h1 { font-size: clamp(34px, 9.2vw, 52px); }
  .hero-actions { flex-direction: column; gap: 16px; width: 100%; }
  .hero-actions .btn { width: 100%; }
  .hero-phone { display: block; width: 78%; max-width: 340px; margin: 48px auto 0; border-radius: 24px 24px 0 0; }
  .features { padding: 112px 4px 0; }
  .features h2 { margin-bottom: 48px; }
  .mod + .mod { margin-top: 64px; }
  .mod-text h3 { margin-top: 4px; }
  .voice, .web, .faq, .photo-break figcaption, .pricing { grid-template-columns: minmax(0, 1fr); }
  .voice { padding-top: 140px; }
  .voice-list, .voice-stage, .web-text, .web-shot, .pricing h2, .menu, .faq h2, .faq-text, .statement, .credit { grid-column: 1; padding-left: 0; }
  .voice-names { flex-direction: row; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 28px calc(-1 * var(--margin)) 0; padding: 0 var(--margin) 8px; }
  .name { flex: none; scroll-snap-align: start; font-size: 22px; white-space: nowrap; }
  .name[aria-selected='true']::before { width: 9px; height: 9px; margin: 0 10px 4px 0; }
  .voice-stage { margin-top: 28px; height: 80svh; }
  .sheet { top: 16px; left: 16px; width: min(460px, calc(100% - 32px)); padding: 20px 20px 80px; }
  .photo-break { margin-top: 140px; }
  .photo-frame { height: 56svh; }
  .credit { margin-top: 16px; }
  .web { padding-top: 140px; }
  .web-shot { margin-top: 32px; padding: 24px 0 0 24px; }
  .pricing { margin-top: 140px; padding: 112px var(--margin); }
  .pricing h2 { max-width: none; margin-bottom: 32px; }
  .menu ul { columns: 1; }
  .faq { padding-top: 140px; }
  .faq h2 { margin-bottom: 32px; }
  .faq-text { columns: 1; }
  .faq-text p { font-size: 16px; }
  .cta { padding: 20svh var(--margin) 14svh; }
  .foot { grid-template-columns: 1fr; }
  .foot-photo { height: 50svh; }
  .foot-menu { padding: 40px var(--margin) 32px; }
  .foot-nav { margin-top: 40px; }
  .foot-nav a { font-size: 8vw; }
  .foot-blocks { grid-template-columns: 1fr; margin-top: 40px; max-width: 60ch; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0ms !important; transition-delay: 0ms !important; }
  .pre { opacity: 1; transform: none; }
  .shot { transform: translateX(-50%); }
}
