/* PipelineIQ marketing site — editorial luxe.
 *
 * Design direction: Stripe / Ramp / Mercury. Paper background, real serif
 * headlines, restrained motion, single accent. Type carries the prestige —
 * not gradients, not glow, not glass.
 *
 * Single source of truth for all 10 pages. No inline <style> blocks should
 * exist after the migration; if a page needs something local, add it here
 * with a page-scoped class.
 */

/* ------------------------------------------------------------------ *
 * 1. Tokens
 * ------------------------------------------------------------------ */
:root {
  /* Surfaces */
  --paper:        #FAF8F3;   /* warm cream — primary background */
  --paper-soft:   #F2EFE7;   /* slightly deeper for alternating sections */
  --paper-edge:   #E6E2D6;   /* hairline rule color */
  --ink:          #14181F;   /* near-black, slightly cool — primary text */
  --ink-soft:     #4A4F58;   /* secondary text */
  --ink-faint:    #7A7F88;   /* tertiary, captions */

  /* Accents (used surgically, not decoratively) */
  --navy:         #0A1628;   /* deep navy — single primary accent */
  --navy-soft:    #1F2D44;   /* hover/pressed */
  --gold:         #A88758;   /* warm metal — used sparingly on premium accents */
  --signal:       #B23B2C;   /* oxblood — emergencies / alerts only */

  /* Type */
  --font-display: 'Source Serif 4', 'Source Serif Pro', Georgia, 'Times New Roman', serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  /* Scale (editorial — wider range than typical app) */
  --text-xs:    12px;
  --text-sm:    14px;
  --text-base:  16px;
  --text-md:    18px;
  --text-lg:    21px;
  --text-xl:    24px;
  --text-2xl:   32px;
  --text-3xl:   42px;
  --text-4xl:   56px;
  --text-5xl:   76px;   /* hero only */

  /* Rhythm */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-6:  24px;
  --space-8:  32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;
  --space-32: 128px;

  /* Motion — kept deliberately small. No lifts, no glows. */
  --t-fast:   140ms;
  --t-normal: 220ms;
  --ease:     cubic-bezier(0.2, 0, 0, 1);
}

/* ------------------------------------------------------------------ *
 * 2. Reset + base
 * ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  font-size: var(--text-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

::selection { background: var(--navy); color: var(--paper); }

/* ------------------------------------------------------------------ *
 * 3. Typography — serif display, sans body, real editorial details
 * ------------------------------------------------------------------ */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 400;          /* serif at regular reads more confident than bold */
  letter-spacing: -0.015em;
  color: var(--ink);
  line-height: 1.1;
}
h1 { font-size: var(--text-5xl); letter-spacing: -0.025em; line-height: 1.02; }
h2 { font-size: var(--text-4xl); letter-spacing: -0.02em; line-height: 1.05; }
h3 { font-size: var(--text-2xl); line-height: 1.15; }
h4 { font-size: var(--text-xl); line-height: 1.25; }
h5 { font-size: var(--text-md); line-height: 1.3; }

p { color: var(--ink-soft); line-height: 1.65; }
.lede { font-size: var(--text-lg); color: var(--ink-soft); line-height: 1.55; max-width: 60ch; }
.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: var(--space-6);
}
.rule { width: 64px; height: 1px; background: var(--ink); display: block; margin: var(--space-8) 0; }

/* Drop-cap for editorial passages — apply with class .editorial > p:first-of-type::first-letter */
.editorial > p:first-of-type::first-letter {
  font-family: var(--font-display);
  float: left;
  font-size: 4.2em;
  line-height: 0.85;
  padding: 4px 8px 0 0;
  color: var(--ink);
}

/* ------------------------------------------------------------------ *
 * 4. Layout
 * ------------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-8);
}
.container-narrow { max-width: 760px; }
.container-wide   { max-width: 1320px; }

section { padding: var(--space-32) 0; }
section.compact { padding: var(--space-20) 0; }
section.alt { background: var(--paper-soft); }

.grid { display: grid; gap: var(--space-8); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 920px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  h1 { font-size: 44px; }
  h2 { font-size: 32px; }
  section { padding: var(--space-20) 0; }
}

/* ------------------------------------------------------------------ *
 * 5. Navigation — fixed but quiet, no glass blur
 * ------------------------------------------------------------------ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 248, 243, 0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--paper-edge);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 1320px; margin: 0 auto;
  padding: 18px var(--space-8);
}
.nav-brand {
  display: flex; align-items: center; gap: var(--space-3);
  font-family: var(--font-display);
  /* Wordmark-only lockup — no companion mark, so we let the type carry
     the brand at a slightly larger size than the legacy lockup. */
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: -0.018em;
  color: var(--ink);
  line-height: 1;
}
.footer-brand .nav-brand { font-size: 1.5rem; }
/* Brand mark — the inlaid cross. Inline SVG so we don't pay an HTTP round-trip
 * on every page, and so the gold inlay color tracks the design tokens if we
 * ever recolor. The mark is set as a CSS background-image for two reasons:
 * (1) the markup stays an inline <span> in HTML, which keeps the lockup
 * accessible and avoids rewriting every page; (2) it makes light-on-dark
 * recoloring (footer) a one-liner via background-image swap instead of
 * forking the HTML.
 */
.nav-brand .mark {
  /* The mark — compass cross. Solid ink cross extending edge-to-edge with four
   * warm-gold "terminal beads" at the cardinal endpoints. The dots overlap the
   * bar ends and touch the canvas edges, reading as nodes capping each arm of
   * the cross. Inherits the lineage of the original PipelineIQ icon (which had
   * 4 colored circles at the same positions), recolored from blue gradient to
   * single warm metal.
   */
  width: 28px; height: 28px; display: inline-block;
  background-color: transparent;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'><polygon points='24,4 40,4 36,28 60,24 60,40 36,36 40,60 24,60 28,36 4,40 4,24 28,28' fill='%2314181F'/><polygon points='32,4 33,8 33,28 34,30 36,31 56,31 60,32 56,33 36,33 34,34 33,36 33,56 32,60 31,56 31,36 30,34 28,33 8,33 4,32 8,31 28,31 30,30 31,28 31,8' fill='%23A88758'/></svg>");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}
/* Inverted mark for dark surfaces (footer). Pattée cross flips to paper-cream
 * while the gold needle-star stays warm metal. */
.footer-brand .nav-brand .mark {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'><polygon points='24,4 40,4 36,28 60,24 60,40 36,36 40,60 24,60 28,36 4,40 4,24 28,28' fill='%23FAF8F3'/><polygon points='32,4 33,8 33,28 34,30 36,31 56,31 60,32 56,33 36,33 34,34 33,36 33,56 32,60 31,56 31,36 30,34 28,33 8,33 4,32 8,31 28,31 30,30 31,28 31,8' fill='%23A88758'/></svg>");
}
/* Wordmark — "Pipeline" stays ink, "IQ" picks up the same warm gold as the
 * square caps, tying the lockup together. Slight letter-spacing tightens the
 * monogram so the gold pair reads as a unit, not loose letters. */
.nav-brand .wordmark { display: inline-flex; align-items: baseline; }
.nav-brand .wm-iq {
  color: var(--gold);
  letter-spacing: -0.02em;
  margin-left: 0.04em;
}
.nav-links {
  display: flex; align-items: center; gap: var(--space-8);
  font-size: var(--text-sm);
  color: var(--ink-soft);
}
.nav-links a { transition: color var(--t-fast) var(--ease); }
.nav-links a:hover { color: var(--ink); }
.nav-cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px;
  background: var(--ink); color: var(--paper);
  border-radius: 4px;
  font-size: var(--text-sm); font-weight: 500;
  transition: background var(--t-fast) var(--ease);
}
.nav-cta:hover { background: var(--navy-soft); }

@media (max-width: 760px) {
  .nav-links a:not(.nav-cta) { display: none; }
}

/* ------------------------------------------------------------------ *
 * 6. Buttons
 * ------------------------------------------------------------------ */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 24px;
  border-radius: 4px;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.01em;
  cursor: pointer;
  border: none;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--navy); }
.btn-outline { background: transparent; color: var(--ink); border: 1px solid var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--paper); }
.btn-ghost { background: transparent; color: var(--ink); padding: 14px 0; }
.btn-ghost:hover { color: var(--navy); }
.btn-ghost::after { content: '→'; margin-left: 6px; transition: transform var(--t-fast) var(--ease); }
.btn-ghost:hover::after { transform: translateX(3px); }

/* ------------------------------------------------------------------ *
 * 7. Hero
 * ------------------------------------------------------------------ */
.hero { padding: var(--space-32) 0 var(--space-20); }
.hero h1 { max-width: 16ch; margin-bottom: var(--space-8); }
.hero .lede { margin-bottom: var(--space-10); }
.hero-actions { display: flex; align-items: center; gap: var(--space-6); flex-wrap: wrap; }

/* ------------------------------------------------------------------ *
 * 8. Product screenshot frame — flat, no glass, no glow
 * ------------------------------------------------------------------ */
.product-shot {
  position: relative;
  border: 1px solid var(--paper-edge);
  background: var(--paper);
  box-shadow:
    0 1px 0 var(--paper-edge),
    0 30px 60px -20px rgba(20, 24, 31, 0.18),
    0 12px 24px -12px rgba(20, 24, 31, 0.08);
  border-radius: 6px;
  overflow: hidden;
}
.product-shot img { width: 100%; height: auto; display: block; }
.product-shot.bordered { padding: 1px; }

/* Optional caption below product shot — italic serif, ink-faint */
.product-caption {
  margin-top: var(--space-6);
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-sm);
  color: var(--ink-faint);
  text-align: center;
}

/* ------------------------------------------------------------------ *
 * 9. Feature grid
 * ------------------------------------------------------------------ */
.feature {
  padding: var(--space-10) 0;
  border-top: 1px solid var(--paper-edge);
}
.feature:last-child { border-bottom: 1px solid var(--paper-edge); }
.feature-row {
  display: grid;
  grid-template-columns: minmax(0, 280px) 1fr;
  gap: var(--space-16);
  align-items: start;
}
.feature-row h3 { font-family: var(--font-display); font-size: var(--text-xl); line-height: 1.3; }
.feature-row p { font-size: var(--text-md); line-height: 1.6; color: var(--ink-soft); max-width: 56ch; }
.feature-num {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  margin-bottom: var(--space-3);
}

@media (max-width: 920px) {
  .feature-row { grid-template-columns: 1fr; gap: var(--space-4); }
}

/* ------------------------------------------------------------------ *
 * 10. Logo wall
 * ------------------------------------------------------------------ */
.logo-wall {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-12);
  align-items: center;
  opacity: 0.65;
}
.logo-wall > * {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  color: var(--ink);
  text-align: center;
  letter-spacing: -0.01em;
}
@media (max-width: 920px) {
  .logo-wall { grid-template-columns: repeat(2, 1fr); gap: var(--space-8); }
}

/* ------------------------------------------------------------------ *
 * 11. Pull quote — editorial centerpiece
 * ------------------------------------------------------------------ */
.pullquote {
  font-family: var(--font-display);
  font-size: var(--text-3xl);
  line-height: 1.2;
  letter-spacing: -0.015em;
  max-width: 22ch;
  color: var(--ink);
}
.pullquote-attr {
  margin-top: var(--space-8);
  font-size: var(--text-sm);
  color: var(--ink-faint);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* ------------------------------------------------------------------ *
 * 12. Footer
 * ------------------------------------------------------------------ */
footer {
  background: var(--ink);
  color: var(--paper);
  padding: var(--space-20) 0 var(--space-10);
}
footer h5 {
  color: var(--paper);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
  opacity: 0.6;
}
footer ul { list-style: none; }
footer li { margin-bottom: var(--space-3); }
footer a {
  color: var(--paper);
  font-size: var(--text-sm);
  opacity: 0.8;
  transition: opacity var(--t-fast) var(--ease);
}
footer a:hover { opacity: 1; }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: var(--space-12);
  padding-bottom: var(--space-12);
  border-bottom: 1px solid rgba(250, 248, 243, 0.1);
}
.footer-brand .nav-brand { color: var(--paper); }
.footer-brand .nav-brand .mark { background: var(--paper); }
.footer-brand p { color: var(--paper); opacity: 0.6; max-width: 32ch; margin-top: var(--space-4); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: var(--space-8);
  font-size: var(--text-xs);
  color: var(--paper);
  opacity: 0.5;
}

@media (max-width: 920px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--space-8); }
  .footer-brand { grid-column: 1 / -1; }
}

/* ------------------------------------------------------------------ *
 * 13. Stat row
 * ------------------------------------------------------------------ */
.stat {
  padding: var(--space-8) 0;
  border-top: 1px solid var(--paper-edge);
}
.stat-num {
  font-family: var(--font-display);
  font-size: var(--text-4xl);
  letter-spacing: -0.02em;
  color: var(--ink);
  display: block;
  margin-bottom: var(--space-2);
}
.stat-label {
  font-size: var(--text-sm);
  color: var(--ink-faint);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* ------------------------------------------------------------------ *
 * 14. Pricing
 * ------------------------------------------------------------------ */
.price-card {
  padding: var(--space-10);
  background: var(--paper);
  border: 1px solid var(--paper-edge);
  border-radius: 6px;
}
.price-card.featured {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.price-card.featured h3,
.price-card.featured .price { color: var(--paper); }
.price {
  font-family: var(--font-display);
  font-size: 56px;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.price-period {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--ink-faint);
}
.price-card ul { list-style: none; margin-top: var(--space-8); }
.price-card li {
  padding: var(--space-3) 0;
  font-size: var(--text-sm);
  color: var(--ink-soft);
  border-top: 1px solid var(--paper-edge);
}
.price-card.featured li { color: var(--paper); border-top-color: rgba(250, 248, 243, 0.12); opacity: 0.85; }

/* ------------------------------------------------------------------ *
 * 15. Reduced motion
 * ------------------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
