/* MH-1 AEO/SEO LP — v5 design system
 * Builds on v4. Adds: paper-soft surface, layered shadows, fade-up keyframe,
 * dark accordion, light-accordion w/ image swap, refined card stack tokens.
 * Geist throughout · Newsreader italic ONLY for the wordmark M tile.
 */

@import url('https://fonts.googleapis.com/css2?family=Geist:wght@400;450;500;600;700&family=Geist+Mono:wght@400;500;600&family=Newsreader:opsz,wght@6..72,500;6..72,600&display=swap');

:root {
  /* Brand */
  --color-brand-green: #6BFFDC;
  --color-brand-green-hover: #7FFFE2;
  --color-brand-green-deep: #0E6E5C;
  --color-competitor-pink: #88345B;

  /* Neutrals — multiple light tones for surface nuance */
  --color-white: #FFFFFF;
  --color-paper: #F8F8FA;        /* slight cool grey */
  --color-paper-soft: #F1F1F4;   /* darker neutral grey, "how it works" surface */
  --color-paper-warm: #FAFAFC;   /* near-white off-white for card-light */
  --color-ash: #EEEEF0;
  --color-stone: #E4E4E8;
  --color-slate: #D9D9DE;
  --color-graphite: #9394A1;
  --color-tungsten: #6F7080;
  --color-iron: #5A5B6A;
  --color-charcoal-2: #2E2F38;
  --color-onyx: #18181B;
  --color-charcoal: #0F0F12;
  --color-deep-space: #0A0A0C;
  --color-black: #000000;
  --color-error-red: #B33D2E;

  /* Gradients */
  --gradient-hero-aurora:
    radial-gradient(ellipse 60% 35% at 28% 0%, rgba(107, 255, 220, 0.10) 0%, transparent 60%),
    radial-gradient(ellipse 40% 30% at 78% 8%, rgba(107, 255, 220, 0.06) 0%, transparent 70%),
    linear-gradient(180deg, #FBFBFC 0%, #FFFFFF 65%);
  --gradient-card-light: linear-gradient(180deg, #FFFFFF 0%, var(--color-paper-warm) 100%);

  /* Typography */
  --font-sans: 'Geist', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --font-serif-mark: 'Newsreader', ui-serif, Georgia, serif;

  /* Type scale — v8: Linear-matched */
  --text-mono-cap: 11px;
  --text-caption: 13px;
  --text-body-sm: 15px;
  --text-body: 16px;
  --text-subheading: 20px;       /* v8: 18 → 20 */
  --text-h3: 26px;               /* v8: 22 → 26 */
  --text-h2: 48px;               /* v8.1: 56 → 48 to keep H2s on ≤2 lines */
  --text-display: 80px;          /* v8: 64 → 80 */

  /* Headline gradients — v8 (apply via .t-display, .t-h2, .t-h3 classes) */
  --gradient-text-light: linear-gradient(180deg, #0F0F12 0%, rgba(15,15,18,0.78) 100%);
  --gradient-text-dark: linear-gradient(180deg, rgba(255,255,255,1.0) 0%, rgba(255,255,255,0.55) 100%);

  /* Spacing & layout — v8: more breathing room */
  --page-max: 1280px;
  --container-padding: 24px;
  --section-pad: 120px;          /* v8: 96 → 120 */
  --section-pad-lg: 160px;       /* v8: 128 → 160 */

  /* Bento — v8: uniform tokens */
  --bento-visual-h: 220px;
  --bento-visual-pad: 20px;

  /* Radii */
  --radius-button: 10px;
  --radius-card: 12px;
  --radius-card-lg: 16px;
  --radius-input: 8px;
  --radius-pill: 9999px;

  /* Shadows — Linear/Clerk-style layered */
  --shadow-card:
    0 0 0 1px rgba(15,15,18,0.04),
    0 1px 2px 0 rgba(15,15,18,0.04),
    0 8px 24px -4px rgba(15,15,18,0.06);
  --shadow-card-hover:
    0 0 0 1px rgba(15,15,18,0.06),
    0 1px 2px 0 rgba(15,15,18,0.06),
    0 12px 32px -8px rgba(15,15,18,0.10),
    0 24px 48px -16px rgba(15,15,18,0.06);
  --shadow-hero-product:
    0 0 0 1px rgba(15,15,18,0.05),
    0 1px 2px 0 rgba(15,15,18,0.04),
    0 8px 24px -6px rgba(15,15,18,0.10),
    0 24px 48px -12px rgba(15,15,18,0.10),
    0 48px 96px -24px rgba(15,15,18,0.08);
  --shadow-glass-rim: inset 0 1px 0 0 rgba(255,255,255,0.04);
  --shadow-input-focus: rgba(107,255,220,0.45) 0 0 0 3px;
  --shadow-elevated:
    0 0 0 1px rgba(15,15,18,0.06),
    0 4px 12px -4px rgba(15,15,18,0.08),
    0 16px 40px -12px rgba(15,15,18,0.12);
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  font-feature-settings: "ss01", "ss03";
  font-size: var(--text-body);
  line-height: 1.5;
  color: var(--color-charcoal);
  background: var(--color-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
input, textarea { font: inherit; color: inherit; }

/* ================ OPACITY-ONLY REVEAL (v8) ================ */
/* Connor 2026-05-09: "use low opacity to high opacity fade in for element in general as user scrolls" */
.reveal {
  opacity: 0;
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.is-in {
  opacity: 1;
}
.reveal--delay-1 { transition-delay: 0.06s; }
.reveal--delay-2 { transition-delay: 0.12s; }
.reveal--delay-3 { transition-delay: 0.18s; }

/* Layout primitives */
.container {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}
.section { padding: var(--section-pad) 0; }
.section--lg { padding: var(--section-pad-lg) 0; }
.section--paper { background: var(--color-paper); }
.section--paper-soft { background: var(--color-paper-soft); }
.section--white { background: var(--color-white); }
.section--dark {
  background: var(--color-deep-space);
  color: var(--color-white);
  position: relative;
  overflow: hidden;
}
.section--dark .section__topglow {
  position: absolute;
  inset: -240px 0 auto 0;
  height: 600px;
  background: radial-gradient(circle at 50% 0%, rgba(107,255,220,0.10), transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.section--dark .container { position: relative; z-index: 1; }

/* Typography — v8: Linear-matched scale + vertical gradient on display/h2/h3 */
.t-display {
  font-size: var(--text-display);
  line-height: 1.05;
  letter-spacing: -2.4px;
  font-weight: 700;
  color: var(--color-charcoal);
  background: var(--gradient-text-light);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.section--dark .t-display {
  background: var(--gradient-text-dark);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.t-h2 {
  font-size: var(--text-h2);
  line-height: 1.1;
  letter-spacing: -0.7px;
  font-weight: 700;
  color: var(--color-charcoal);
  background: var(--gradient-text-light);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.section--dark .t-h2 {
  background: var(--gradient-text-dark);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.t-h3 {
  font-size: var(--text-h3);
  line-height: 1.25;
  letter-spacing: -0.5px;
  font-weight: 500;
  color: var(--color-charcoal);
}
.section--dark .t-h3 { color: var(--color-white); }
.t-subheading {
  font-size: var(--text-subheading);
  line-height: 1.5;
  letter-spacing: -0.2px;
  font-weight: 400;
  color: var(--color-iron);
}
.section--dark .t-subheading { color: rgba(255,255,255,0.72); }
.t-body { font-size: var(--text-body); line-height: 1.5; }
.t-body-sm { font-size: var(--text-body-sm); line-height: 1.53; color: var(--color-iron); }
.section--dark .t-body-sm { color: rgba(255,255,255,0.62); }
.t-caption { font-size: var(--text-caption); line-height: 1.54; color: var(--color-tungsten); }
.t-mono {
  font-family: var(--font-mono);
}
.t-mono-cap {
  font-family: var(--font-mono);
  font-size: var(--text-mono-cap);
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--color-tungsten);
  font-weight: 500;
}
.section--dark .t-mono-cap { color: rgba(255,255,255,0.55); }

/* Eyebrow / section number */
.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--text-mono-cap);
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--color-tungsten);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}
.eyebrow::before {
  content: ""; width: 6px; height: 6px; border-radius: 9999px;
  background: var(--color-brand-green);
  box-shadow: 0 0 0 3px rgba(107,255,220,0.14);
}
.section--dark .eyebrow { color: rgba(255,255,255,0.55); }

.section-num {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: var(--text-mono-cap);
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--color-tungsten);
  font-weight: 500;
}
.section--dark .section-num { color: rgba(255,255,255,0.55); }
.section-num__dot {
  width: 6px; height: 6px; border-radius: 9999px;
  background: var(--color-brand-green);
  box-shadow: 0 0 0 3px rgba(107,255,220,0.14);
}
.section-num__num { color: var(--color-charcoal); font-weight: 500; }
.section--dark .section-num__num { color: var(--color-white); }

/* Section header — v8.1: bias to LEFT (where H2 lives) so big headings fit on 2 lines */
.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 64px;
  align-items: end;
  margin-bottom: 72px;
}
.section-head__left { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.section-head__right { display: flex; flex-direction: column; gap: 16px; padding-bottom: 10px; min-width: 0; }
.section-head--centered { grid-template-columns: 1fr; text-align: center; max-width: 900px; margin-left: auto; margin-right: auto; }
.section-head--centered .section-head__left { align-items: center; gap: 16px; }
@media (max-width: 880px) {
  .section-head { grid-template-columns: 1fr; gap: 18px; margin-bottom: 40px; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-button);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.2px;
  transition: all 0.18s ease;
  white-space: nowrap;
  height: 56px;
  padding: 0 28px;
}
.btn--primary {
  background: var(--color-charcoal);
  color: var(--color-white);
  border: 1px solid var(--color-charcoal);
}
.btn--primary:hover { background: var(--color-black); transform: translateY(-1px); }
.btn--accent {
  background: var(--color-brand-green);
  color: var(--color-charcoal);
  border: 1px solid var(--color-brand-green);
  box-shadow: 0 6px 20px -8px rgba(107,255,220,0.55), 0 0 0 1px rgba(107,255,220,0.30);
}
.btn--accent:hover {
  background: var(--color-brand-green-hover);
  transform: translateY(-1px);
  box-shadow: 0 10px 28px -8px rgba(107,255,220,0.70), 0 0 0 1px rgba(107,255,220,0.45);
}
.btn--secondary {
  background: var(--color-white);
  color: var(--color-charcoal);
  border: 1px solid var(--color-slate);
}
.btn--secondary:hover { background: var(--color-paper); border-color: var(--color-graphite); }
.btn--secondary-dark {
  background: rgba(255,255,255,0.04);
  color: var(--color-white);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: var(--shadow-glass-rim);
}
.btn--secondary-dark:hover { background: rgba(255,255,255,0.08); }
.btn--ghost {
  background: transparent;
  color: var(--color-iron);
  border: 0;
  height: 36px;
  padding: 0 12px;
  font-size: 14px;
}
.btn--ghost:hover { color: var(--color-charcoal); background: var(--color-paper); }
.section--dark .btn--ghost { color: rgba(255,255,255,0.72); }
.section--dark .btn--ghost:hover { color: var(--color-white); background: rgba(255,255,255,0.04); }

/* Pills */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.pill--accent {
  background: rgba(107,255,220,0.12);
  color: var(--color-brand-green-deep);
  border: 1px solid rgba(107,255,220,0.32);
}
.section--dark .pill--accent {
  color: var(--color-brand-green);
  background: rgba(107,255,220,0.10);
}

/* Cards */
.card-light {
  background: var(--gradient-card-light);
  border: 1px solid var(--color-stone);
  border-radius: var(--radius-card);
  padding: 28px;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}
.card-light:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-1px);
}
.card-glass {
  background: rgba(255,255,255,0.025);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: var(--radius-card);
  padding: 28px;
  box-shadow: var(--shadow-glass-rim);
}

/* Sticky nav */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 14px 0;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--color-stone);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.nav__logo {
  font-family: var(--font-sans);
  font-weight: 600;
  letter-spacing: -0.4px;
  font-size: 17px;
  color: var(--color-charcoal);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.nav__logo .mark {
  width: 22px; height: 22px;
  background: var(--color-charcoal);
  border-radius: 5px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--color-white);
  font-family: var(--font-serif-mark);
  font-size: 14px;
  font-weight: 600;
  font-style: italic;
}
.nav__links { display: flex; align-items: center; gap: 4px; }
@media (max-width: 880px) {
  .nav__links a:not(:last-child) { display: none; }
}

/* Footer */
.footer { padding: 48px 0; background: var(--color-black); }
.footer__inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer .nav__logo { color: rgba(255,255,255,0.92); font-size: 15px; }
.footer__copy { color: rgba(255,255,255,0.55); font-size: 13px; }
.footer__links { display: flex; gap: 24px; }
.footer__links a { font-size: 13px; color: rgba(255,255,255,0.72); transition: color 0.18s ease; }
.footer__links a:hover { color: var(--color-white); }

/* ==================== ACCORDION (light + dark variants) ==================== */
.accord { display: flex; flex-direction: column; gap: 4px; }
.accord__item {
  border-radius: 12px;
  padding: 0;
  cursor: pointer;
  transition: background 0.2s ease;
  border: 1px solid transparent;
}
/* Dark variant */
.accord--dark .accord__item {
  background: transparent;
}
.accord--dark .accord__item:hover {
  background: rgba(255,255,255,0.02);
}
.accord--dark .accord__item.is-open {
  background: rgba(255,255,255,0.025);
  border-color: rgba(107,255,220,0.20);
}
/* Light variant */
.accord--light .accord__item:hover {
  background: rgba(15,15,18,0.02);
}
.accord--light .accord__item.is-open {
  background: var(--color-white);
  border-color: var(--color-stone);
  box-shadow: var(--shadow-card);
}

.accord__head {
  display: flex; align-items: flex-start;
  gap: 14px;
  padding: 18px 20px;
}
.accord__num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--color-tungsten);
  flex-shrink: 0;
  padding-top: 4px;
}
.section--dark .accord__num { color: rgba(255,255,255,0.55); }
.accord--dark .accord__item.is-open .accord__num,
.accord--light .accord__item.is-open .accord__num {
  color: var(--color-brand-green-deep);
}
.section--dark .accord--dark .accord__item.is-open .accord__num { color: var(--color-brand-green); }
.accord__title-wrap { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.accord__title {
  font-size: 18px;
  font-weight: 500;
  color: var(--color-charcoal);
  letter-spacing: -0.2px;
  line-height: 1.30;
}
.section--dark .accord__title { color: var(--color-white); }
.accord__chevron {
  width: 16px; height: 16px;
  color: var(--color-tungsten);
  transition: transform 0.2s ease;
  flex-shrink: 0;
  margin-top: 4px;
}
.accord__item.is-open .accord__chevron { transform: rotate(180deg); }

.accord__body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 20px;
}
.accord__item.is-open .accord__body {
  max-height: 280px;
  padding: 0 20px 20px 54px;
}
.accord__copy {
  font-size: 14px;
  line-height: 1.6;
  color: var(--color-iron);
}
.section--dark .accord__copy { color: rgba(255,255,255,0.62); }
.accord__copy strong { color: var(--color-charcoal); font-weight: 500; }
.section--dark .accord__copy strong { color: var(--color-white); }

/* Utility */
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; } .mt-40 { margin-top: 40px; } .mt-48 { margin-top: 48px; }
.mt-56 { margin-top: 56px; } .mt-64 { margin-top: 64px; }
.text-center { text-align: center; }
.flex { display: flex; }
.gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-24 { gap: 24px; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.flex-wrap { flex-wrap: wrap; }
.col { display: flex; flex-direction: column; }

/* Responsive — v8 */
@media (max-width: 880px) {
  .t-display { font-size: clamp(44px, 7vw, 56px); letter-spacing: -1.4px; }
  .t-h2 { font-size: clamp(32px, 5.5vw, 40px); letter-spacing: -0.5px; }
  .t-h3 { font-size: 22px; }
  :root {
    --section-pad: 80px;
    --section-pad-lg: 112px;
  }
}

/* ================ ICON SQUARES (v8) ================ */
/* Connor 2026-05-09: "icons should have square around them" + "subheadings should also be fully left
   (so that they begin beneath icon, not offset so they begin under heading)" */
.icon-sq {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--color-stone);
  background: var(--color-white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-charcoal);
}
.section--dark .icon-sq {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.10);
  color: var(--color-white);
}
.icon-sq svg { width: 18px; height: 18px; }

/* (icon-cell layout lives in index.html — gets overridden there) */

/* ================ PULL-QUOTE PROGRESSIVE REVEAL (v8) ================ */
/* Connor 2026-05-09: "animate pull quote" — Attio-style two-tone reveal on scroll */
.pq-fade {
  opacity: 0.35;
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.pq-fade.is-in {
  opacity: 1;
}
