/*
 * Turbodemand — base stylesheet.
 *
 * Inter is self-hosted from /assets/fonts/ (latin subset, weights 400/500/600/700).
 * The 400 weight is preloaded in public/index.php.
 *
 * Design tokens live in :root below. Outside :root, color literals are
 * forbidden — use var(--token). Enforced by scripts/check-tokens.sh.
 */

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/inter-latin-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/assets/fonts/inter-latin-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/assets/fonts/inter-latin-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/assets/fonts/inter-latin-700.woff2') format('woff2');
}

:root {
  --bg:            #fbfaf6;
  --bg-elev:       #ffffff;
  --bg-band:       #f4f1e8;
  --bg-hero:       #f5f1ea;
  --fg:            #0b1f33;
  --fg-muted:      #4a5b6e;
  --border:        #e7e2d4;
  --border-soft:   rgba(11, 31, 51, 0.08);
  --accent:        #0fa39a;
  --accent-hover:  #0b8d85;
  --accent-fg:     #ffffff;
  --accent-2:      #c8a14a;
  --cta-bg:        #0b1f33;
  --cta-fg:        #ffffff;
  --cta-hover:     #1a3454;
  --badge-bg:      #dff5f2;
  --badge-fg:      #0b8d85;
  --accent2-tint:     rgba(200, 161, 74, 0.14);
  --hero-glow-a: rgba(200, 161, 74, 0.10);
  --hero-glow-b: rgba(15, 163, 154, 0.07);
  --hero-glow-deep:  rgba(11, 31, 51, 0.10);
  --hero-noise:      rgba(11, 31, 51, 0.025);
  --glass:           rgba(255, 255, 255, 0.78);
  --glass-strong:    rgba(255, 255, 255, 0.92);
  --glass-line:      rgba(255, 255, 255, 0.65);
  --panel-dark:      #0b1f33;
  --panel-dark-2:    #122a44;
  --panel-line:      rgba(255, 255, 255, 0.08);
  --panel-fg:        rgba(255, 255, 255, 0.92);
  --panel-fg-muted:  rgba(255, 255, 255, 0.58);
  --chip-a:       rgba(15, 163, 154, 0.18);
  --chip-b:       rgba(200, 161, 74, 0.22);
  --shadow-card:     0 30px 60px -24px rgba(11, 31, 51, 0.35), 0 10px 24px -12px rgba(11, 31, 51, 0.18);
  --shadow-float:    0 18px 40px -18px rgba(11, 31, 51, 0.28), 0 4px 12px -4px rgba(11, 31, 51, 0.12);
  --shadow-soft:     0 8px 24px -12px rgba(11, 31, 51, 0.18);
  --dot-a:        #0fa39a;
  --dot-b:        #c8a14a;
  --success:       #16a34a;
  --danger:        #dc2626;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--fg-muted);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@media (max-width: 640px) {
  body {
    font-size: 16px;
  }
}

h1,
h2,
h3 {
  color: var(--fg);
  margin: 0;
}

h1 {
  font-size: 64px;
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.025em;
}

h2 {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.015em;
}

h3 {
  font-size: 18px;
  font-weight: 600;
}

@media (max-width: 640px) {
  h1 { font-size: 40px; }
  h2 { font-size: 28px; }
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-hover);
}

button {
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
}

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

p {
  margin: 0 0 16px;
}

ul {
  margin: 0 0 16px;
  padding-left: 20px;
}

img {
  max-width: 100%;
  height: auto;
}

/* Layout */

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

@media (min-width: 1024px) {
  .container {
    padding: 0 48px;
  }
}

.section {
  padding: 64px 0;
}

@media (min-width: 1024px) {
  .section {
    padding: 96px 0;
  }
}

/* Header */

.site-header {
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--fg);
  font-weight: 700;
  font-size: 22px;
  line-height: 1;
}

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

.brand__mark {
  display: block;
  width: 32px;
  height: 32px;
}

.brand__name {
  color: var(--fg);
  letter-spacing: -0.01em;
}

.site-header__cta {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Hero */

.section--hero {
  padding-top: 64px;
  padding-bottom: 80px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 70% 50% at 50% 0%, var(--hero-glow-a), transparent 60%),
    radial-gradient(ellipse 90% 60% at 50% 90%, var(--hero-glow-b), transparent 65%),
    radial-gradient(ellipse 120% 80% at 50% 50%, transparent 55%, var(--hero-glow-deep) 100%),
    var(--bg-hero);
}

@media (min-width: 1024px) {
  .section--hero {
    padding-top: 88px;
    padding-bottom: 112px;
  }
}

.section--hero .container {
  position: relative;
  z-index: 2;
  text-align: center;
}

.hero__mesh {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.hero__mesh svg {
  width: 100%;
  height: 100%;
  display: block;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--badge-bg);
  color: var(--badge-fg);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 28px;
  box-shadow: var(--shadow-soft);
}

.hero__badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--accent);
  display: inline-block;
}

.hero__headline {
  max-width: 22ch;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  font-family: 'Inter', Georgia, 'Times New Roman', serif;
  font-weight: 700;
  letter-spacing: -0.03em;
}

@media (min-width: 1024px) {
  .hero__headline {
    font-size: 80px;
    line-height: 1.02;
  }
}

.hero__headline-line {
  display: block;
}

.hero__headline-line--accent {
  color: var(--accent);
}

.hero__headline-line--accent2 {
  color: var(--accent-2);
}

.hero__sub {
  margin: 28px auto 0;
  max-width: 60ch;
  font-size: 19px;
  color: var(--fg-muted);
}

@media (max-width: 640px) {
  .hero__sub {
    font-size: 17px;
  }
}

.hero__ctas {
  margin-top: 36px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

/* Hero showcase — dashboard + floating AI cards */

.hero__showcase {
  position: relative;
  margin: 72px auto 0;
  max-width: 1120px;
  padding: 0 8px;
}

@media (max-width: 1023px) {
  .hero__showcase { margin-top: 56px; }
}

.dashboard {
  position: relative;
  z-index: 2;
  background: linear-gradient(180deg, var(--panel-dark-2) 0%, var(--panel-dark) 100%);
  border-radius: 18px;
  border: 1px solid var(--panel-line);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transform: perspective(2400px) rotateX(2deg);
  transform-origin: 50% 100%;
}

.dashboard__chrome {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--panel-line);
  background: var(--panel-dark);
}

.dashboard__dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--panel-line);
}

.dashboard__tab {
  margin-left: 16px;
  font-size: 12px;
  color: var(--panel-fg-muted);
  letter-spacing: 0.02em;
}

.dashboard__body {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: 360px;
}

@media (max-width: 768px) {
  .dashboard__body {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .dashboard__sidebar { display: none; }
}

.dashboard__sidebar {
  padding: 20px 16px;
  border-right: 1px solid var(--panel-line);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.dashboard__nav {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--panel-fg-muted);
  font-size: 13px;
  font-weight: 500;
}

.dashboard__nav--active {
  background: var(--chip-a);
  color: var(--panel-fg);
}

.dashboard__nav-bullet {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--panel-fg-muted);
}

.dashboard__nav--active .dashboard__nav-bullet {
  background: var(--accent);
  box-shadow: 0 0 12px 0 var(--accent);
}

.dashboard__main {
  padding: 24px;
  display: grid;
  gap: 20px;
}

.dashboard__kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.kpi {
  background: var(--panel-dark-2);
  border: 1px solid var(--panel-line);
  border-radius: 12px;
  padding: 14px 16px;
}

.kpi__label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--panel-fg-muted);
}

.kpi__value {
  margin-top: 6px;
  font-size: 22px;
  font-weight: 700;
  color: var(--panel-fg);
  letter-spacing: -0.01em;
}

.kpi__delta {
  margin-top: 4px;
  font-size: 12px;
  color: var(--accent);
}

.kpi--alt .kpi__delta { color: var(--accent-2); }

.dashboard__chart {
  background: var(--panel-dark-2);
  border: 1px solid var(--panel-line);
  border-radius: 12px;
  padding: 16px 18px;
}

.dashboard__chart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.dashboard__chart-title {
  font-size: 13px;
  color: var(--panel-fg);
  font-weight: 600;
}

.dashboard__chart-legend {
  display: inline-flex;
  gap: 14px;
  font-size: 11px;
  color: var(--panel-fg-muted);
}

.dashboard__legend-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  margin-right: 6px;
  vertical-align: middle;
}

.dashboard__legend-dot--a { background: var(--accent); }
.dashboard__legend-dot--b { background: var(--accent-2); }

.dashboard__bars {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 8px;
  align-items: end;
  height: 120px;
}

.dashboard__bar {
  border-radius: 4px 4px 0 0;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-hover) 100%);
  opacity: 0.85;
}

.dashboard__bar--alt {
  background: linear-gradient(180deg, var(--accent-2) 0%, var(--accent-2) 100%);
  opacity: 0.7;
}

/* Floating AI citation cards */

.ai-card {
  position: absolute;
  z-index: 3;
  background: var(--glass-strong);
  border: 1px solid var(--glass-line);
  border-radius: 14px;
  padding: 14px 16px;
  width: 260px;
  box-shadow: var(--shadow-float);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.ai-card__head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.ai-card__avatar {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-fg);
  font-size: 11px;
  font-weight: 700;
  background: var(--cta-bg);
  flex-shrink: 0;
}

.ai-card__avatar--primary { background: var(--accent); }
.ai-card__avatar--alt { background: var(--accent-2); }

.ai-card__source {
  font-size: 12px;
  font-weight: 600;
  color: var(--fg);
}

.ai-card__meta {
  display: block;
  font-size: 11px;
  color: var(--fg-muted);
  font-weight: 500;
}

.ai-card__body {
  font-size: 13px;
  line-height: 1.45;
  color: var(--fg);
  margin: 0;
}

.ai-card__cite {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  font-size: 11px;
  color: var(--accent);
  font-weight: 600;
}

.ai-card__cite::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 8px 0 var(--accent);
}

.ai-card--chatgpt {
  top: -28px;
  left: -32px;
  transform: rotate(-2deg);
}

.ai-card--perplexity {
  top: 38%;
  right: -56px;
  transform: rotate(2deg);
}

.ai-card--google {
  bottom: -32px;
  left: 18%;
  transform: rotate(-1.5deg);
}

@media (max-width: 1023px) {
  .ai-card { width: 220px; padding: 12px 14px; }
  .ai-card--chatgpt { top: -16px; left: -12px; }
  .ai-card--perplexity { right: -12px; }
  .ai-card--google { bottom: -16px; left: 8%; }
}

@media (max-width: 640px) {
  .ai-card--perplexity,
  .ai-card--google { display: none; }
  .ai-card--chatgpt { top: -10px; left: 50%; transform: translateX(-50%) rotate(-1deg); }
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  padding: 14px 22px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 150ms ease-out, border-color 150ms ease-out, color 150ms ease-out;
}

.btn__icon {
  flex-shrink: 0;
}

.btn--primary {
  background: var(--cta-bg);
  color: var(--cta-fg);
}

.btn--primary:hover {
  background: var(--cta-hover);
  color: var(--cta-fg);
}

.btn--secondary {
  background: transparent;
  color: var(--fg);
  border-color: transparent;
  padding: 14px 8px;
}

.btn--secondary .btn__icon {
  color: var(--accent);
}

.btn--secondary:hover {
  color: var(--accent);
}

/* Hero feature row (4-column) */

.feature-row {
  border-top: 1px solid var(--border);
  background: var(--bg);
}

.feature-row__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding: 32px 0;
}

@media (min-width: 768px) {
  .feature-row__inner {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .feature-row__inner {
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
  }
}

.feature {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 14px;
  align-items: start;
  background: var(--glass-strong);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  padding: 18px 18px;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.feature__icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--badge-bg);
  color: var(--accent);
}

.feature--alt .feature__icon {
  background: var(--accent2-tint);
  color: var(--accent-2);
}

.feature h3 {
  font-size: 16px;
  margin: 2px 0 4px;
}

.feature p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--fg-muted);
}

/* Problem */

#problem h2 {
  max-width: 22ch;
  margin-bottom: 24px;
}

#problem p {
  max-width: 70ch;
  font-size: 19px;
}

@media (max-width: 640px) {
  #problem p { font-size: 17px; }
}

/* What — tiles */

#what h2 {
  margin-bottom: 32px;
}

.tiles {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 768px) {
  .tiles {
    grid-template-columns: 1fr 1fr;
  }
}

.tile {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px;
}

.tile__icon {
  display: block;
  margin-bottom: 16px;
  color: var(--accent);
}

.tile:nth-child(2) .tile__icon { color: var(--accent-2); }
.tile:nth-child(3) .tile__icon { color: var(--accent); }
.tile:nth-child(4) .tile__icon { color: var(--accent-2); }

.tile h3 {
  margin-bottom: 8px;
}

.tile p {
  margin: 0;
}

/* How — 3-step flow */

#how h2 {
  margin-bottom: 32px;
}

.flow {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
}

@media (min-width: 1024px) {
  .flow {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 32px;
  }
}

.flow__step {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px;
}

.flow__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: var(--cta-bg);
  color: var(--cta-fg);
  font-weight: 700;
  margin-bottom: 16px;
}

.flow__step:nth-child(2) .flow__num { background: var(--accent); }
.flow__step:nth-child(3) .flow__num { background: var(--accent-2); }

.flow__step h3 {
  margin-bottom: 8px;
}

.flow__step p {
  margin: 0;
}

/* Who */

#who h2 {
  margin-bottom: 32px;
}

.who {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .who {
    grid-template-columns: 1fr 1fr;
    gap: 48px;
  }
}

.who__col h3 {
  margin-bottom: 12px;
}

/* Closing CTA band */

.band {
  background: var(--bg-band);
}

.band__copy {
  font-size: 22px;
  color: var(--fg);
  max-width: 60ch;
  margin: 0 0 24px;
}

@media (max-width: 640px) {
  .band__copy {
    font-size: 18px;
  }
}

.band__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 32px;
}

/* Waitlist form */

.waitlist {
  display: grid;
  gap: 16px;
  max-width: 520px;
}

.field {
  display: flex;
  flex-direction: column;
}

.field label {
  font-size: 14px;
  font-weight: 500;
  color: var(--fg);
  margin-bottom: 6px;
}

.field input,
.field textarea {
  font-family: inherit;
  font-size: 16px;
  color: var(--fg);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
}

.field input:focus-visible,
.field textarea:focus-visible {
  border-color: var(--accent);
  outline: none;
}

.field textarea {
  resize: vertical;
  min-height: 64px;
}

.honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
  font-size: 14px;
  color: var(--fg-muted);
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
}

.site-footer__left,
.site-footer__right {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.site-footer__tagline {
  color: var(--fg-muted);
}
