/* Self-hosted Stop font for brand display */
@font-face {
  font-family: 'Stop';
  src: url('/fonts/Stop.ttf') format('truetype');
  font-display: swap;
}

/* Brand palette — crimson primary, yellow secondary, on charcoal */
:root {
  --bg: #0F1419;
  --bg-card: #161B21;
  --border: #1F2429;
  --border-strong: #2A2F35;
  --text: #E8EBED;
  --text-body: #C5CACD;
  --text-muted: #A0A8AD;
  --text-faint: #6B7378;
  --crimson: #C8102E;
  --crimson-dark: #9E0D24;
  --yellow: #FFCC00;
}

/* Reset & base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }

/* Layout container */
.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Header / nav */
.site-header {
  position: sticky;
  top: 0;
  background: rgba(15, 20, 25, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  gap: 2rem;
}
.nav-logo { display: block; flex-shrink: 0; }
.nav-logo img { height: 44px; }
.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
  align-items: center;
  flex-wrap: wrap;
}
.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--text); }
.nav-links a.active { color: var(--crimson); }

/* Home hero (brand-led) */
.hero {
  padding: 4.5rem 0 3rem;
  text-align: center;
}
.brand-hero {
  margin-bottom: 1.5rem;
}
.brand-hero img {
  max-width: 380px;
  width: 70%;
  height: auto;
  margin: 0 auto;
}
.hero h1 {
  font-size: clamp(1.9rem, 4.5vw, 2.5rem);
  font-weight: 500;
  line-height: 1.2;
  color: var(--text);
  margin-bottom: 1.25rem;
  letter-spacing: -0.01em;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}
.hero-sub {
  font-size: 18px;
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

/* Product/page hero — flyer-style: logo + page title side by side */
.page-hero {
  padding: 4rem 0 2.5rem;
}
.page-hero-row {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin-bottom: 1.5rem;
}
.page-hero-logo {
  flex-shrink: 0;
  width: 115px;
  height: auto;
}
.page-hero-content { flex: 1; min-width: 0; }
.page-hero-title {
  font-family: 'Stop', monospace;
  font-size: clamp(1.75rem, 4.5vw, 2.5rem);
  color: var(--text);
  letter-spacing: 0.04em;
  margin: 0;
  line-height: 1;
}
.page-hero-title .accent { color: var(--crimson); }
.page-hero-sub {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 0.6rem;
  letter-spacing: 0.02em;
}
.page-hero-lead {
  font-size: 18px;
  color: var(--text);
  line-height: 1.5;
  margin-top: 1.75rem;
  max-width: 780px;
  font-weight: 500;
}
.page-hero-intro {
  font-size: 16px;
  color: var(--text-body);
  margin-top: 1.25rem;
  max-width: 780px;
  line-height: 1.7;
}

/* Accent rules */
.rule {
  width: 56px;
  height: 2px;
  background: var(--crimson);
  margin: 0 auto 1.75rem;
  border: none;
}
.rule-full {
  width: 100%;
  height: 2px;
  background: var(--crimson);
  margin: 0;
  border: none;
}

/* Sections */
.section { padding: 2.5rem 0; }
.section + .section { padding-top: 0; }
.section h2 {
  font-size: 24px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 1rem;
  letter-spacing: -0.005em;
}
.section h3 {
  font-size: 18px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 0.5rem;
}
.section p {
  color: var(--text-body);
  margin-bottom: 1rem;
  max-width: 720px;
}
.section p:last-child { margin-bottom: 0; }
.section .lead { font-size: 18px; color: var(--text); }
.section strong { color: var(--text); font-weight: 500; }
.section em { color: var(--text-muted); font-style: normal; }

/* Body text links — scoped to prose contexts so they don't fight button styles */
.section p a, .section li a {
  color: var(--crimson);
  text-decoration: none;
}
.section p a:hover, .section li a:hover { text-decoration: underline; }

/* Product card grid (home) */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, transform 0.15s;
  display: flex;
  flex-direction: column;
}
.product-card:hover {
  border-color: var(--crimson);
  transform: translateY(-2px);
}
.product-card-tag {
  font-size: 11px;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 0.5rem;
}
.product-card-name {
  font-family: 'Stop', monospace;
  font-size: 22px;
  color: var(--text);
  margin-bottom: 0.75rem;
  letter-spacing: 0.05em;
}
.product-card-name .accent { color: var(--crimson); }
.product-card p {
  flex: 1;
  font-size: 15px;
  color: var(--text-body);
  margin-bottom: 1.25rem;
  line-height: 1.6;
}
.product-card-cta {
  color: var(--crimson);
  font-size: 14px;
  font-weight: 500;
}

/* Feature grid (product pages) */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1.5rem;
}
.feature-card h3 {
  color: var(--crimson);
  font-size: 15px;
  margin-bottom: 0.5rem;
  letter-spacing: 0.01em;
}
.feature-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0;
  max-width: none;
}

/* "What X does for you" — short bullet section */
.value-list {
  margin-top: 1.5rem;
  display: grid;
  gap: 1.25rem;
}
.value-list li {
  list-style: none;
  padding-left: 1.5rem;
  position: relative;
  color: var(--text-body);
  line-height: 1.7;
  max-width: 780px;
}
.value-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7em;
  width: 8px;
  height: 8px;
  background: var(--crimson);
  border-radius: 50%;
}
.value-list strong { color: var(--text); font-weight: 500; }

/* Trigger types grid (from flyer) */
.trigger-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.5rem 1.75rem;
  margin-top: 1.5rem;
}
.trigger-box-title {
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}
.trigger-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.25rem 2rem;
  font-size: 15px;
  color: var(--text-body);
  list-style: none;
}
.trigger-grid li {
  padding: 0.45rem 0;
}
.trigger-grid li::before {
  content: "✓  ";
  color: var(--crimson);
  font-weight: 500;
}

/* RPM LOOP diagram (Enterprise page) */
.rpm-loop {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  max-width: 760px;
  margin: 2.5rem auto 0;
  position: relative;
}
.loop-step {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.75rem 1.5rem 1.25rem;
  position: relative;
}
.loop-step-num {
  position: absolute;
  top: -14px;
  left: 1.25rem;
  background: var(--crimson);
  color: white;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 500;
}
.loop-step-tag {
  font-size: 10px;
  color: var(--text-faint);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}
.loop-step h3 {
  color: var(--text);
  font-size: 16px;
  margin-bottom: 0.5rem;
}
.loop-step p {
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.55;
  max-width: none;
}
.loop-caption {
  text-align: center;
  margin: 2rem auto 0;
  max-width: 480px;
}
.loop-caption-eyebrow {
  font-family: 'Stop', monospace;
  font-size: 11px;
  color: var(--crimson);
  letter-spacing: 0.2em;
  margin-bottom: 0.5rem;
}
.loop-caption-text {
  font-size: 15px;
  color: var(--text);
  line-height: 1.5;
}

/* Application screenshot figure */
.app-shot {
  margin-top: 1.5rem;
}
.app-shot img {
  width: 100%;
  height: auto;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45);
}
.app-shot figcaption {
  margin-top: 0.9rem;
  font-size: 13px;
  color: var(--text-faint);
  text-align: center;
  line-height: 1.5;
  letter-spacing: 0.02em;
}

/* CTA buttons — uses a.cta selector + scoped rules so it beats body link styling */
a.cta, .cta {
  display: inline-block;
  background: var(--crimson);
  color: #FFFFFF;
  padding: 0.85rem 2rem;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.02em;
  transition: background 0.15s;
}
a.cta:hover, .cta:hover {
  background: var(--crimson-dark);
  color: #FFFFFF;
  text-decoration: none;
}
.cta-row {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}
.cta-row.center { justify-content: center; }

/* Two-column meta layout */
.meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 1.5rem;
}
.meta-block h3 {
  color: var(--yellow);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 0.75rem;
  font-weight: 500;
}
.meta-block ul {
  list-style: none;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.85;
}
.meta-block ul li {
  padding-left: 1.1rem;
  position: relative;
  margin-bottom: 0.35rem;
}
.meta-block ul li::before {
  content: "·";
  position: absolute;
  left: 0;
  color: var(--crimson);
  font-weight: 700;
}

/* Contact page */
.contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2.5rem;
  max-width: 540px;
  margin: 0 auto;
  text-align: center;
}
.contact-card h2 {
  font-family: 'Stop', monospace;
  font-size: 16px;
  color: var(--yellow);
  letter-spacing: 0.1em;
  margin-bottom: 1.75rem;
}
.contact-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
  font-size: 16px;
}
.contact-row:first-of-type { border-top: none; }
.contact-row .label {
  color: var(--text-faint);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  min-width: 80px;
  text-align: right;
}
.contact-row a {
  color: var(--yellow);
  text-decoration: none;
  font-weight: 500;
}
.contact-row a:hover { text-decoration: underline; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 3rem 0 2rem;
  margin-top: 4rem;
}
.footer-content {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 2rem;
  align-items: end;
}
.footer-logo img {
  height: 36px;
}
.footer-brand {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.7;
}
.footer-brand a {
  color: var(--yellow);
  text-decoration: none;
}
.footer-brand a:hover { text-decoration: underline; }
.footer-meta {
  text-align: right;
  font-size: 12px;
  color: var(--text-faint);
  line-height: 1.8;
}

/* Responsive */
@media (max-width: 720px) {
  .nav { padding: 0.75rem 1.25rem; gap: 1rem; }
  .nav-logo img { height: 34px; }
  .nav-links { gap: 1.1rem; }
  .nav-links a { font-size: 13px; }
  .container { padding: 0 1.25rem; }
  .hero { padding: 3rem 0 2rem; }
  .hero-sub { font-size: 16px; }
  .section { padding: 2rem 0; }
  .page-hero { padding: 3rem 0 2rem; }
  .page-hero-row { flex-direction: column; align-items: flex-start; gap: 1rem; }
  .page-hero-logo { width: 90px; }
  .rpm-loop { grid-template-columns: 1fr; }
  .trigger-grid { grid-template-columns: 1fr; }
  .footer-content { grid-template-columns: 1fr; gap: 1.5rem; text-align: left; }
  .footer-meta { text-align: left; }
  .contact-row { flex-direction: column; gap: 0.25rem; }
  .contact-row .label { text-align: center; min-width: 0; }
}
