/* LogMotif — marketing site. Tokens match product DESIGN.md (dark). */

:root {
  --canvas: #08090c;
  --bg: #0b0d11;
  --panel: #0e1116;
  --raised: #171b23;
  --modal: #141821;
  --inset: #0b0d11;
  --border: rgba(255, 255, 255, 0.06);
  --border-strong: rgba(255, 255, 255, 0.1);
  --hair: rgba(255, 255, 255, 0.04);
  --hover: rgba(255, 255, 255, 0.04);
  --text: #e6e9ef;
  --text-2: #9aa3b2;
  --text-3: #7b8494;
  --label: #626b7a;
  --code-text: #a9b2c1;
  --accent: #4d7cfe;
  --accent-soft: rgba(77, 124, 254, 0.14);
  --green: #45c98a;
  --green-soft: rgba(69, 201, 138, 0.14);
  --red: #ef6461;
  --red-soft: rgba(239, 100, 97, 0.14);
  --amber: #e0a44b;
  --amber-soft: rgba(224, 164, 75, 0.14);
  --purple: #a17fff;
  --purple-soft: rgba(161, 127, 255, 0.14);
  --max: 1120px;
  --radius: 10px;
  --radius-lg: 14px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
}

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

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

code,
.mono {
  font-family: var(--mono);
}

/* ── Layout ─────────────────────────────────────────────── */

.wrap {
  width: min(100% - 40px, var(--max));
  margin-inline: auto;
}

.section {
  padding: 88px 0;
}

.section-sm {
  padding: 56px 0;
}

.eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--label);
  margin: 0 0 12px;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

h1 {
  font-size: clamp(2.1rem, 4.6vw, 3.25rem);
  max-width: 16ch;
}

h2 {
  font-size: clamp(1.55rem, 3vw, 2rem);
}

h3 {
  font-size: 1.05rem;
}

.lead {
  margin: 18px 0 0;
  color: var(--text-2);
  font-size: 1.05rem;
  max-width: 46ch;
  line-height: 1.6;
}

.muted {
  color: var(--text-3);
}

/* ── Buttons ────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: filter 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}

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

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  filter: brightness(1.08);
}

.btn-ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text-2);
}

.btn-ghost:hover {
  background: var(--hover);
  color: var(--text);
}

.btn-outline {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}

.btn-outline:hover {
  filter: brightness(1.08);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

/* ── Nav ────────────────────────────────────────────────── */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(8, 9, 12, 0.78);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
}

.brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--accent), var(--purple));
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 13px;
  color: var(--text-2);
}

.nav-links a:hover {
  color: var(--text);
}

.nav-cta {
  padding: 7px 14px;
  font-size: 12.5px;
}

@media (max-width: 720px) {
  .nav-links .hide-sm {
    display: none;
  }
}

/* ── Hero ───────────────────────────────────────────────── */

.hero {
  padding: 72px 0 40px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -20% 20% auto;
  height: 420px;
  background: radial-gradient(ellipse at center, rgba(77, 124, 254, 0.14), transparent 65%);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  align-items: center;
  position: relative;
}

@media (min-width: 960px) {
  .hero-grid {
    grid-template-columns: 0.92fr 1.08fr;
    gap: 40px;
  }
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 3px 8px;
  border-radius: 4px;
  color: var(--text-3);
  background: var(--raised);
  border: 1px solid var(--border);
}

.pill .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px var(--green-soft);
}

.pill.purple {
  color: var(--purple);
  background: var(--purple-soft);
  border-color: transparent;
}

.hero-note {
  margin-top: 16px;
  font-size: 12.5px;
  color: var(--text-3);
  font-family: var(--mono);
}

/* ── Product frame / demo ───────────────────────────────── */

.product-frame {
  background: var(--panel);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.02),
    0 30px 80px rgba(0, 0, 0, 0.45);
}

.chrome {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  padding: 0 12px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.traffic {
  display: flex;
  gap: 6px;
}

.traffic i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: block;
}

.traffic .r {
  background: #f0605d;
}
.traffic .y {
  background: #e0a44b;
}
.traffic .g {
  background: #45c98a;
}

.chrome-title {
  flex: 1;
  text-align: center;
  font-size: 11.5px;
  color: var(--label);
  font-weight: 500;
}

.mast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--panel);
  gap: 12px;
}

.mast-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mast-word {
  font-size: 13px;
  font-weight: 600;
}

.mast-meta {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text-3);
  display: flex;
  align-items: center;
  gap: 6px;
}

.mast-meta .live {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}

.mast-actions {
  display: flex;
  gap: 6px;
}

.mini-btn {
  font-size: 10.5px;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 6px;
  border: 1px solid var(--border-strong);
  color: var(--text-2);
  background: transparent;
}

.mini-btn.primary {
  background: var(--accent);
  border-color: transparent;
  color: #fff;
}

.app-body {
  display: grid;
  grid-template-columns: 140px 1fr 150px;
  min-height: 320px;
}

@media (max-width: 640px) {
  .app-body {
    grid-template-columns: 1fr;
  }
  .rail-right,
  .rail-left {
    display: none;
  }
}

.rail {
  background: var(--panel);
  border-right: 1px solid var(--border);
  padding: 10px;
  min-height: 0;
}

.rail-right {
  border-right: none;
  border-left: 1px solid var(--border);
}

.rail-label {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--label);
  margin-bottom: 8px;
}

.run-row {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  padding: 7px 8px;
  border-radius: 7px;
  border-left: 2px solid transparent;
  margin-bottom: 2px;
  font-size: 11.5px;
}

.run-row.active {
  background: var(--accent-soft);
  border-left-color: var(--accent);
}

.run-row .status {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-top: 4px;
  flex-shrink: 0;
}

.run-row .status.ok {
  background: var(--green);
}
.run-row .status.fail {
  background: var(--red);
}
.run-row .status.run {
  background: var(--accent);
}

.run-row .t {
  font-weight: 500;
  line-height: 1.25;
}
.run-row .m {
  font-family: var(--mono);
  font-size: 9.5px;
  color: var(--text-3);
  margin-top: 2px;
}

.center {
  background: var(--bg);
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.tabs {
  display: flex;
  gap: 14px;
  padding: 0 12px;
  border-bottom: 1px solid var(--border);
  font-size: 11.5px;
  color: var(--text-3);
}

.tabs span {
  padding: 10px 0 8px;
  border-bottom: 2px solid transparent;
  cursor: default;
}

.tabs span.active {
  color: var(--text);
  border-bottom-color: var(--accent);
}

.timeline {
  padding: 10px 12px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ev {
  display: grid;
  grid-template-columns: 10px 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 6px 8px;
  border-radius: 6px;
  font-size: 11.5px;
  border-left: 2px solid transparent;
  opacity: 0.35;
  transform: translateY(4px);
  transition: opacity 0.35s ease, background 0.25s ease, border-color 0.25s ease, transform 0.35s ease;
}

.ev.show {
  opacity: 1;
  transform: none;
}

.ev.highlight {
  background: var(--accent-soft);
  border-left-color: var(--accent);
}

.ev.fork-hl {
  background: var(--purple-soft);
  border-left-color: var(--purple);
}

.ev .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.ev .dot.model {
  background: var(--accent);
}
.ev .dot.tool {
  background: var(--amber);
}
.ev .dot.ckpt {
  background: var(--green);
}
.ev .dot.state {
  background: var(--text-3);
}

.ev .name {
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ev .meta {
  font-family: var(--mono);
  font-size: 9.5px;
  color: var(--text-3);
}

.fork-banner {
  display: none;
  margin: 0 12px 10px;
  padding: 8px 10px;
  border-radius: 8px;
  background: var(--purple-soft);
  border: 1px solid rgba(161, 127, 255, 0.25);
  font-size: 11.5px;
  color: var(--purple);
  font-weight: 500;
  align-items: center;
  gap: 8px;
}

.fork-banner.show {
  display: flex;
}

.fork-banner .glyph {
  font-family: var(--mono);
  font-size: 14px;
}

.compare {
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 10px 12px 12px;
  flex: 1;
}

.compare.show {
  display: grid;
}

.cmp-col {
  background: var(--raised);
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 10px;
  min-height: 140px;
}

.cmp-col h4 {
  margin: 0 0 8px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--label);
}

.cmp-col p {
  margin: 0;
  font-size: 11.5px;
  color: var(--text-2);
  line-height: 1.45;
}

.cmp-col.changed p {
  color: var(--text);
}

.verdict {
  display: none;
  margin: 0 12px 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--green-soft);
  border: 1px solid rgba(69, 201, 138, 0.28);
  color: var(--green);
  font-size: 12.5px;
  font-weight: 600;
  align-items: center;
  gap: 8px;
}

.verdict.show {
  display: flex;
}

.side-card {
  background: var(--raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 8px;
  font-size: 11px;
}

.side-card .k {
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--label);
  font-weight: 600;
  margin-bottom: 4px;
}

.side-card .v {
  color: var(--text-2);
  font-family: var(--mono);
  font-size: 10.5px;
}

.branch-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--purple);
  background: var(--purple-soft);
  padding: 2px 6px;
  border-radius: 4px;
  margin-top: 4px;
}

.demo-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-top: 1px solid var(--border);
  background: var(--panel);
}

.demo-controls .hint {
  font-size: 11px;
  color: var(--text-3);
  font-family: var(--mono);
}

.demo-controls button {
  font-size: 11.5px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 7px;
  border: 1px solid var(--border-strong);
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
}

.demo-controls button:hover {
  background: var(--hover);
  color: var(--text);
}

/* ── Video block ────────────────────────────────────────── */

.video-shell {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  max-width: 900px;
  margin: 0 auto;
}

.video-shell video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: var(--bg);
}

.video-shell.placeholder {
  display: grid;
  place-items: center;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(77, 124, 254, 0.12), transparent 50%),
    radial-gradient(ellipse at 70% 80%, rgba(161, 127, 255, 0.1), transparent 45%),
    var(--panel);
}

.video-shell:not(.placeholder) {
  display: block;
}

.video-shell.placeholder .video-placeholder-inner {
  display: block;
}

.video-shell:not(.placeholder) .video-placeholder-inner {
  display: none;
}

.video-placeholder-inner {
  text-align: center;
  padding: 32px;
  max-width: 420px;
}

.video-placeholder-inner .play {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  margin: 0 auto 16px;
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  display: grid;
  place-items: center;
  color: var(--accent);
  font-size: 18px;
}

.video-placeholder-inner p {
  margin: 8px 0 0;
  color: var(--text-3);
  font-size: 13px;
}

.video-note {
  text-align: center;
  margin-top: 14px;
  font-size: 12px;
  color: var(--label);
  font-family: var(--mono);
}

/* ── How it works ───────────────────────────────────────── */

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 36px;
}

@media (max-width: 900px) {
  .steps {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 520px) {
  .steps {
    grid-template-columns: 1fr;
  }
}

.step {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 16px;
}

.step-n {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 10px;
}

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

.step p {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.5;
}

/* ── Features ───────────────────────────────────────────── */

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

@media (max-width: 900px) {
  .features {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .features {
    grid-template-columns: 1fr;
  }
}

.feature {
  background: var(--raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 18px;
}

.feature .icon {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-size: 13px;
  margin-bottom: 14px;
}

.feature .icon.blue {
  background: var(--accent-soft);
  color: var(--accent);
}
.feature .icon.green {
  background: var(--green-soft);
  color: var(--green);
}
.feature .icon.purple {
  background: var(--purple-soft);
  color: var(--purple);
}
.feature .icon.amber {
  background: var(--amber-soft);
  color: var(--amber);
}

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

.feature p {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.5;
}

/* ── Split / code ───────────────────────────────────────── */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 840px) {
  .split {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

.code-block {
  background: var(--inset);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  overflow: hidden;
}

.code-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  font-size: 11px;
  font-family: var(--mono);
  color: var(--text-3);
}

.code-block pre {
  margin: 0;
  padding: 16px 18px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.7;
  color: var(--code-text);
}

.code-block .kw {
  color: var(--purple);
}
.code-block .fn {
  color: var(--accent);
}
.code-block .str {
  color: var(--green);
}
.code-block .cm {
  color: var(--label);
}

/* ── Compare table ──────────────────────────────────────── */

.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 28px;
  font-size: 13.5px;
}

.compare-table th,
.compare-table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--hair);
}

.compare-table th {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--label);
  background: var(--panel);
}

.compare-table td {
  color: var(--text-2);
}

.compare-table tr td:first-child {
  color: var(--text);
  font-weight: 500;
}

.compare-table tr td:last-child {
  color: var(--green);
}

.table-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--raised);
}

/* ── CTA band ───────────────────────────────────────────── */

.cta-band {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(77, 124, 254, 0.16), transparent 55%),
    var(--panel);
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  padding: 48px 32px;
  text-align: center;
}

.cta-band h2 {
  max-width: 18ch;
  margin-inline: auto;
}

.cta-band .lead {
  margin-inline: auto;
}

.cta-band .btn-row {
  justify-content: center;
}

/* ── Footer ─────────────────────────────────────────────── */

.footer {
  border-top: 1px solid var(--border);
  padding: 28px 0 40px;
  color: var(--text-3);
  font-size: 12.5px;
}

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

.footer a {
  color: var(--text-2);
}

.footer a:hover {
  color: var(--text);
}

.footer-links {
  display: flex;
  gap: 18px;
}

/* ── Utilities ──────────────────────────────────────────── */

.center-text {
  text-align: center;
}

.center-text .lead {
  margin-inline: auto;
}

.section-head {
  max-width: 560px;
}

.section-head.center {
  margin-inline: auto;
  text-align: center;
}

.section-head.center .lead {
  margin-inline: auto;
}

.divider {
  height: 1px;
  background: var(--border);
  border: none;
  margin: 0;
}
