/* Marketing site chrome. */
:root {
      /* Matched to css/es.css */
      --bg-deep: #f6f7f9;
      --bg-surface: #ffffff;
      --bg-elevated: #f6f7f9;
      --bg-card: #ffffff;
      --border: #e5e7eb;
      --border-strong: #cfd4d9;
      --text-primary: #1c2128;
      --text-secondary: #6b7280;
      --text-muted: #9aa3ad;
      --accent: #2563eb;
      --accent-dim: #eff6ff;
      --accent-glow: rgba(37, 99, 235, 0.2);
      --brand: #fff000;
      --positive: #16a34a;
      --positive-dim: #eefaf1;
      --caution: #d97706;
      --caution-dim: #fff2d7;
      --negative: #dc2626;
      --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
      --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
      --radius: 12px;
      --radius-sm: 6px;
      --radius-lg: 12px;
      --shadow: 0 1px 2px rgba(16, 21, 27, 0.05), 0 4px 16px rgba(16, 21, 27, 0.05);
      --shadow-lg: 0 10px 40px rgba(16, 21, 27, 0.1);
      --max-width: 1180px;
    }

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

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

    body {
      font-family: var(--font-sans);
      background: var(--bg-deep);
      color: var(--text-primary);
      font-size: 14px;
      line-height: 1.5;
      -webkit-font-smoothing: antialiased;
    }

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

    /* ── Layout utilities ── */
    .container {
      width: 100%;
      max-width: var(--max-width);
      margin: 0 auto;
      padding: 0 24px;
    }

    section { padding: 96px 0; }

    .section-label {
      font-size: 12px;
      font-weight: 700;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: var(--accent);
      margin-bottom: 12px;
    }

    .section-title {
      font-size: clamp(26px, 4vw, 36px);
      font-weight: 700;
      letter-spacing: -0.01em;
      line-height: 1.2;
      margin-bottom: 16px;
    }

    .section-desc {
      font-size: 16px;
      color: var(--text-secondary);
      max-width: 560px;
      line-height: 1.55;
    }

    /* ── Buttons (match .es-btn) ── */
    .btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 6px;
      padding: 9px 16px;
      font-size: 14px;
      font-weight: 700;
      font-family: var(--font-sans);
      border-radius: var(--radius-sm);
      border: 1px solid transparent;
      cursor: pointer;
      transition: filter 0.15s, background 0.15s;
      white-space: nowrap;
    }

    .btn-primary {
      background: var(--brand);
      color: #000;
      border-color: var(--brand);
    }

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

    .btn-ghost {
      background: var(--bg-surface);
      color: var(--text-primary);
      border-color: var(--border-strong);
    }

    .btn-ghost:hover {
      background: var(--bg-deep);
      filter: none;
    }

    /* ── Wordmark (match .es-logo / .es-brand-mark) ── */
    @font-face {
      font-family: 'SF Pro Display';
      font-style: normal;
      font-weight: 800;
      font-display: swap;
      src: local('SFProDisplay-Heavy'),
           local('SF Pro Display Heavy'),
           local('SFProDisplay-Black'),
           local('SF Pro Display Black'),
           local('.SF NS Display');
    }

    .es-logo,
    .es-brand-mark,
    .site-footer-brand {
      --es-brand-font: 'SF Pro Display', 'SF Pro Text', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Helvetica, Arial, sans-serif;
      display: inline-block;
      margin: 0;
      padding: 8px 10px;
      background: var(--brand);
      color: #000;
      font-family: var(--es-brand-font);
      font-weight: 800 !important;
      font-style: normal;
      font-size: 17px;
      letter-spacing: -0.02em;
      line-height: 1.15;
      text-decoration: none;
      white-space: nowrap;
      border-radius: 0;
      -webkit-font-smoothing: antialiased;
    }

    .es-logo .dot,
    .es-brand-mark .dot,
    .site-footer-brand .dot {
      color: #000;
      font-weight: 800 !important;
    }

    /* ── Nav ── */
    nav.site-nav {
      position: fixed;
      top: 0;
      left: 0;
      right: 0;
      z-index: 100;
      background: rgba(255, 255, 255, 0.92);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
      border-bottom: 1px solid var(--border);
    }

    .site-nav-inner {
      display: flex;
      align-items: center;
      justify-content: space-between;
      height: 60px;
      padding-top: 0;
    }

    .site-nav-inner > .es-brand-mark {
      align-self: flex-start;
      margin: 0;
    }

    .site-nav-links {
      display: flex;
      align-items: center;
      gap: 28px;
      list-style: none;
    }

    .site-nav-links a {
      font-size: 14px;
      font-weight: 600;
      color: var(--text-secondary);
      transition: color 0.2s;
    }

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

    .site-nav-actions {
      display: flex;
      align-items: center;
      gap: 16px;
      margin-left: 12px;
    }

    .site-nav-sign-in {
      font-size: 14px;
      font-weight: 700;
      color: var(--text-primary);
      text-decoration: none;
      white-space: nowrap;
    }

    .site-nav-sign-in:hover {
      color: var(--text-primary);
      opacity: 0.75;
    }

    .site-nav-profile {
      display: flex;
      align-items: center;
      justify-content: center;
      border-radius: 50%;
      text-decoration: none;
    }

    .site-nav-profile:hover {
      opacity: 0.8;
    }

    .site-nav-profile:focus-visible {
      outline: 2px solid var(--text-primary);
      outline-offset: 3px;
    }

    .site-nav-actions .btn,
    .site-nav-open-app {
      padding: 7px 14px;
      font-size: 13px;
      font-weight: 700;
      background: #fff000;
      color: #000;
      border-color: #fff000;
      border-radius: var(--radius-sm);
      text-decoration: none;
    }

    .site-nav-open-app:hover {
      filter: brightness(1.04);
      text-decoration: none;
    }

    .site-nav-toggle {
      display: none;
      background: none;
      border: none;
      color: var(--text-primary);
      cursor: pointer;
      padding: 4px;
    }

    /* ── Hero ── */
    .hero {
      padding-top: 120px;
      padding-bottom: 80px;
      position: relative;
      overflow: hidden;
    }

    .hero::before {
      content: "";
      position: absolute;
      top: -200px;
      left: 50%;
      transform: translateX(-50%);
      width: 900px;
      height: 600px;
      background:
        radial-gradient(ellipse 70% 55% at 85% 10%, rgba(255, 240, 0, 0.22) 0%, transparent 55%),
        radial-gradient(ellipse 50% 40% at 12% 30%, rgba(37, 99, 235, 0.08) 0%, transparent 60%);
      pointer-events: none;
    }

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

    .hero-copy { position: relative; z-index: 1; }

    .hero h1 {
      display: inline-block;
      margin: 0 0 16px;
      padding: 10px 14px;
      background: var(--brand);
      color: #000;
      font-family: 'SF Pro Display', 'SF Pro Text', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Helvetica, Arial, sans-serif;
      font-size: clamp(28px, 4.5vw, 42px);
      font-weight: 800 !important;
      letter-spacing: -0.02em;
      line-height: 1.1;
      border-radius: 0;
    }

    .hero h1 .dot { color: #000; }

    .hero-tagline {
      font-size: clamp(18px, 2.5vw, 22px);
      color: var(--text-primary);
      font-weight: 600;
      margin-bottom: 12px;
      line-height: 1.35;
      letter-spacing: -0.01em;
    }

    .hero-support {
      font-size: 15px;
      color: var(--text-secondary);
      max-width: 420px;
      margin-bottom: 28px;
      line-height: 1.55;
    }

    .hero-actions {
      display: flex;
      flex-wrap: wrap;
      gap: 12px;
    }

    /* ── Product mockup ── */
    .mockup-wrap {
      position: relative;
      z-index: 1;
    }

    .mockup {
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: var(--radius-lg);
      box-shadow: var(--shadow-lg);
      overflow: hidden;
    }

    .mockup-bar {
      display: flex;
      align-items: center;
      gap: 6px;
      padding: 12px 16px;
      background: var(--bg-elevated);
      border-bottom: 1px solid var(--border);
    }

    .mockup-dot {
      width: 10px;
      height: 10px;
      border-radius: 50%;
      background: var(--border-strong);
    }

    .mockup-dot:nth-child(1) { background: #c96a5a; opacity: 0.7; }
    .mockup-dot:nth-child(2) { background: #d4a03d; opacity: 0.7; }
    .mockup-dot:nth-child(3) { background: #4caf82; opacity: 0.7; }

    .mockup-url {
      flex: 1;
      text-align: center;
      font-size: 11px;
      font-family: var(--font-mono);
      color: var(--text-muted);
    }

    .mockup-shot {
      display: block;
      width: 100%;
      height: auto;
    }

    /* ── Differentiator strip ── */
    .strip {
      padding: 48px 0;
      border-top: 1px solid var(--border);
      border-bottom: 1px solid var(--border);
      background: var(--bg-surface);
    }

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

    .strip-item h4 {
      font-size: 15px;
      font-weight: 600;
      margin-bottom: 8px;
    }

    .strip-item p {
      font-size: 14px;
      color: var(--text-secondary);
      line-height: 1.6;
    }

    .strip-not {
      color: var(--text-muted);
      font-size: 13px;
      margin-top: 4px;
    }

    /* ── Analysis example ── */
    .example-section { background: var(--bg-deep); }

    .example-layout {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 48px;
      align-items: start;
      margin-top: 48px;
    }

    .example-report {
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: var(--radius-lg);
      box-shadow: var(--shadow);
      overflow: hidden;
    }

    .example-report-header {
      padding: 20px 24px;
      border-bottom: 1px solid var(--border);
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .example-report-header h3 {
      font-size: 16px;
      font-weight: 600;
    }

    .report-status {
      font-size: 11px;
      font-family: var(--font-mono);
      color: var(--caution);
      background: var(--caution-dim);
      padding: 4px 10px;
      border-radius: 4px;
    }

    .example-steps { padding: 8px 0; }

    .example-step {
      padding: 20px 24px;
      border-bottom: 1px solid var(--border);
    }

    .example-step:last-child { border-bottom: none; }

    .step-num {
      font-size: 11px;
      font-family: var(--font-mono);
      color: var(--text-muted);
      margin-bottom: 6px;
    }

    .step-title {
      font-size: 13px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      margin-bottom: 8px;
    }

    .step-title.pattern { color: var(--accent); }
    .step-title.cause { color: var(--caution); }
    .step-title.focus { color: var(--positive); }
    .step-title.evidence { color: var(--text-secondary); }

    .step-body {
      font-size: 15px;
      color: var(--text-primary);
      line-height: 1.6;
    }

    .step-detail {
      font-size: 13px;
      color: var(--text-secondary);
      margin-top: 8px;
      line-height: 1.55;
    }

    .example-sidebar-cards { display: flex; flex-direction: column; gap: 16px; }

    .data-viz-card {
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      box-shadow: var(--shadow);
      padding: 20px;
    }

    .data-viz-card h4 {
      font-size: 13px;
      font-weight: 500;
      margin-bottom: 14px;
      color: var(--text-secondary);
    }

    .bar-chart { display: flex; flex-direction: column; gap: 10px; }

    .bar-row {
      display: grid;
      grid-template-columns: 80px 1fr 48px;
      align-items: center;
      gap: 10px;
      font-size: 12px;
    }

    .bar-label { color: var(--text-muted); font-family: var(--font-mono); font-size: 11px; }

    .bar-track {
      height: 8px;
      background: var(--bg-elevated);
      border-radius: 4px;
      overflow: hidden;
    }

    .bar-fill {
      height: 100%;
      border-radius: 4px;
      transition: width 1s ease;
    }

    .bar-fill.blue { background: var(--accent); }
    .bar-fill.green { background: var(--positive); }
    .bar-fill.amber { background: var(--caution); }

    .bar-val {
      font-family: var(--font-mono);
      font-size: 11px;
      text-align: right;
      color: var(--text-secondary);
    }

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

    .corr-cell {
      text-align: center;
      padding: 12px 8px;
      background: var(--bg-elevated);
      border-radius: 6px;
      border: 1px solid var(--border);
    }

    .corr-val {
      font-size: 16px;
      font-weight: 600;
      font-family: var(--font-mono);
    }

    .corr-val.strong { color: var(--negative); }
    .corr-val.moderate { color: var(--caution); }
    .corr-val.weak { color: var(--text-muted); }

    .corr-label {
      font-size: 10px;
      color: var(--text-muted);
      margin-top: 4px;
      line-height: 1.3;
    }

    /* ── Evidence section ── */
    .evidence-section { background: var(--bg-surface); }

    .evidence-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 20px;
      margin-top: 48px;
    }

    .paper-card {
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 24px;
      display: flex;
      flex-direction: column;
      box-shadow: var(--shadow);
      transition: border-color 0.2s;
    }

    .paper-card:hover { border-color: var(--border-strong); }

    .paper-meta {
      font-size: 11px;
      font-family: var(--font-mono);
      color: var(--text-muted);
      margin-bottom: 12px;
    }

    .paper-title {
      font-size: 15px;
      font-weight: 600;
      line-height: 1.4;
      margin-bottom: 10px;
    }

    .paper-excerpt {
      font-size: 13px;
      color: var(--text-secondary);
      line-height: 1.6;
      flex: 1;
    }

    .paper-link {
      font-size: 12px;
      color: var(--accent);
      margin-top: 16px;
      font-weight: 500;
    }

    .evidence-note {
      margin-top: 40px;
      padding: 24px;
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      font-size: 14px;
      color: var(--text-secondary);
      line-height: 1.65;
    }

    .evidence-note strong { color: var(--text-primary); font-weight: 500; }

    /* ── How it works ── */
    .how-grid {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 24px;
      margin-top: 48px;
    }

    .how-step {
      padding: 24px;
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      box-shadow: var(--shadow);
    }

    .how-num {
      font-size: 28px;
      font-weight: 600;
      font-family: var(--font-mono);
      color: var(--accent);
      opacity: 0.5;
      margin-bottom: 12px;
    }

    .how-step h4 {
      font-size: 15px;
      font-weight: 600;
      margin-bottom: 8px;
    }

    .how-step p {
      font-size: 13px;
      color: var(--text-secondary);
      line-height: 1.6;
    }

    /* ── Audience ── */
    .audience-section { padding-bottom: 64px; }

    .audience-pills {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
      margin-top: 32px;
    }

    .pill {
      font-size: 13px;
      font-weight: 600;
      padding: 8px 14px;
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      color: var(--text-secondary);
      background: var(--bg-surface);
    }

    /* ── CTA ── */
    .cta-section {
      padding: 80px 0;
      background: var(--bg-surface);
      border-top: 1px solid var(--border);
    }

    .cta-box {
      text-align: center;
      max-width: 560px;
      margin: 0 auto;
    }

    .cta-box h2 {
      font-size: clamp(24px, 3.5vw, 32px);
      font-weight: 700;
      letter-spacing: -0.01em;
      margin-bottom: 12px;
    }

    .cta-box p {
      font-size: 15px;
      color: var(--text-secondary);
      margin-bottom: 28px;
      line-height: 1.55;
    }

    .cta-actions {
      display: flex;
      justify-content: center;
      flex-wrap: wrap;
      gap: 12px;
    }

    /* ── Footer ── */
    .site-footer {
      padding: 40px 0;
      border-top: 1px solid var(--border);
    }

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

    .site-footer-copy {
      font-size: 13px;
      color: var(--text-muted);
    }

    .site-footer-links {
      display: flex;
      gap: 24px;
      list-style: none;
    }

    .site-footer-links a {
      font-size: 13px;
      color: var(--text-muted);
      transition: color 0.2s;
    }

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

    /* ── Animations ── */
    @keyframes fadeUp {
      from { opacity: 0; transform: translateY(20px); }
      to { opacity: 1; transform: translateY(0); }
    }

    .hero-copy { animation: fadeUp 0.7s ease both; }
    .mockup-wrap { animation: fadeUp 0.7s 0.15s ease both; }

    /* ── Responsive ── */
    @media (max-width: 1024px) {
      .hero-grid { grid-template-columns: 1fr; gap: 40px; }
      .example-layout { grid-template-columns: 1fr; }
      .evidence-grid { grid-template-columns: 1fr 1fr; }
      .how-grid { grid-template-columns: 1fr 1fr; }
      .strip-grid { grid-template-columns: 1fr; gap: 24px; }
    }

    @media (max-width: 768px) {
      section { padding: 64px 0; }
      .site-nav-links { display: none; }
      .site-nav-links.open {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: var(--bg-surface);
        border-bottom: 1px solid var(--border);
        padding: 16px 24px 24px;
        gap: 16px;
      }
      .site-nav-actions {
        margin-left: 0;
        padding-left: 0;
        border-left: none;
        flex-direction: column;
        align-items: stretch;
      }
      .site-nav-actions .btn { width: 100%; }
      .site-nav-toggle { display: block; }
      .evidence-grid { grid-template-columns: 1fr; }
      .how-grid { grid-template-columns: 1fr; }
      .site-footer-inner { flex-direction: column; text-align: center; }
    }

    @media (max-width: 480px) {
      .hero-actions { flex-direction: column; }
      .hero-actions .btn { width: 100%; }
      .correlation-grid { grid-template-columns: 1fr 1fr; }
    }


/* Knowledge subsection switcher */
.site-learn-tabs-wrap {
  padding-top: 84px;
  padding-bottom: 0;
}
.site-learn-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 8px;
  padding: 0;
  list-style: none;
}
.site-learn-tabs a {
  display: inline-flex;
  align-items: center;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.site-learn-tabs a:hover { color: var(--text-primary); border-color: var(--border-strong); }
.site-learn-tabs a[aria-current="page"] {
  color: var(--text-primary);
  border-color: var(--text-primary);
  background: var(--bg-elevated);
}

/* Interior page shells */
.site-page {
  padding: 40px 0 80px;
  min-height: 60vh;
}
.site-page--solo {
  padding-top: 100px;
}
.site-page__eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}
.site-page__title {
  font-size: clamp(26px, 4vw, 36px);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
  margin-bottom: 12px;
}
.site-page__lead {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 560px;
  line-height: 1.55;
  margin-bottom: 32px;
}
.site-page__placeholder {
  padding: 28px;
  background: var(--bg-surface);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.55;
  max-width: 640px;
}
.site-page__list {
  display: grid;
  gap: 12px;
  max-width: 640px;
  padding: 0;
  list-style: none;
}
.site-page__list a {
  display: block;
  padding: 16px 18px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-weight: 600;
  color: var(--text-primary);
  transition: border-color 0.15s;
}
.site-page__list a:hover { border-color: var(--border-strong); }
.site-page__list span {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 400;
  color: var(--text-secondary);
}

.site-nav-links a[aria-current="page"] { color: var(--text-primary); }

@media (max-width: 860px) {
  .btn {
    padding-top: 7px;
    padding-bottom: 7px;
  }
  .pill {
    padding-top: 6px;
    padding-bottom: 6px;
  }
}
