/* ============================================================
   GYST AI - 90-Day HVAC Lead Engine funnel
   Design system: Atelier light mode (serif + warm cream + burnt orange)
   Tokens derived from ads/funnels/hvac-vsl/slides/atelier-vsl.css (light mode)
   ============================================================ */

/* 1. Fonts ------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Newsreader:ital,opsz,wght@0,6..72,300;0,6..72,400;0,6..72,500;0,6..72,600;1,6..72,400;1,6..72,500&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap');

/* 2. Reset ------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
img, svg, video { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
a { color: inherit; text-decoration: none; }
body { line-height: 1.6; }

/* 3. Tokens ------------------------------------------------ */
:root {
  /* colour - Atelier light */
  --primary: #C2410C;          /* burnt orange */
  --primary-dark: #9A3412;
  --secondary: #1F1A12;        /* near-black ink, used for headings */
  --accent: #C2410C;           /* stars, highlight */
  --bg: #F5F0E6;               /* warm cream page */
  --bg-light: #FBF7EF;         /* section-alt */
  --elevated: #F8F3E8;
  --card: #FFFFFF;
  --text: #1F1A12;
  --text-muted: #6A6258;
  --faint: #9A917E;
  --border: #D9D2BF;
  --border-strong: #BCB39B;
  --success: #15803D;

  /* fonts */
  --serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', monospace;

  /* type scale - 1.25 modular */
  --text-xs: 0.8rem;
  --text-sm: 0.9rem;
  --text-base: 1rem;
  --text-lg: 1.25rem;
  --text-xl: 1.563rem;
  --text-2xl: 1.953rem;
  --text-3xl: 2.441rem;
  --text-4xl: 3.052rem;
  --text-5xl: 3.815rem;
  --text-6xl: 4.768rem;

  /* spacing - 4px scale */
  --space-1: 0.25rem;  --space-2: 0.5rem;  --space-3: 0.75rem;
  --space-4: 1rem;     --space-6: 1.5rem;  --space-8: 2rem;
  --space-12: 3rem;    --space-16: 4rem;   --space-20: 5rem;
  --space-24: 6rem;

  /* radii */
  --radius-sm: 4px; --radius-md: 8px; --radius-lg: 12px; --radius-full: 999px;

  /* shadows - soft, warm */
  --shadow-sm: 0 1px 2px rgba(31,26,18,0.05);
  --shadow-md: 0 4px 14px rgba(31,26,18,0.08);
  --shadow-lg: 0 16px 40px rgba(31,26,18,0.12);

  /* transitions */
  --t-fast: 150ms ease;
  --t-base: 250ms ease;

  /* layout widths */
  --container-max: 1200px;
  --container-narrow: 800px;
}

/* 4. Base -------------------------------------------------- */
body {
  font-family: var(--sans);
  font-size: var(--text-base);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 400;
  color: var(--secondary);
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.5rem, 5vw + 1rem, 4.25rem); line-height: 1.08; }
h2 { font-size: clamp(2rem, 3vw + 1rem, 3.05rem); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h1 .it, h2 .it { font-style: italic; color: var(--primary); }
p { line-height: 1.6; max-width: 68ch; }
strong, b { font-weight: 600; color: var(--text); }
a:hover { color: var(--primary); }

/* 5. Layout ------------------------------------------------ */
.container { width: 100%; max-width: var(--container-max); margin-inline: auto; padding-inline: var(--space-6); }
.container-narrow { width: 100%; max-width: var(--container-narrow); margin-inline: auto; padding-inline: var(--space-6); }
.hero-headline { width: 100%; max-width: 1080px; margin-inline: auto; }
.section { padding-block: var(--space-24); }
.section-alt { background: var(--bg-light); }
@media (max-width: 768px) { .section { padding-block: var(--space-16); } }

/* 6. Buttons ----------------------------------------------- */
.btn-primary, .btn-secondary {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  font-family: var(--sans); font-weight: 600; font-size: var(--text-lg);
  padding: var(--space-4) var(--space-8); border-radius: var(--radius-md);
  transition: transform var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
}
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-md); }
.btn-primary:hover { background: var(--primary-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.btn-secondary { background: transparent; color: var(--text); border: 1.5px solid var(--border-strong); }
.btn-secondary:hover { border-color: var(--primary); color: var(--primary); }
.btn-large { font-size: var(--text-xl); padding: var(--space-6) var(--space-12); }
.nav .btn-primary { font-size: var(--text-base); padding: var(--space-3) var(--space-6); box-shadow: var(--shadow-sm); }

/* 7. Card -------------------------------------------------- */
.card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-8); box-shadow: var(--shadow-sm);
  transition: transform var(--t-base), box-shadow var(--t-base);
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }

/* 8. Trust strip ------------------------------------------- */
.trust-strip {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: var(--space-8); color: var(--text-muted); font-size: var(--text-sm);
}
.trust-strip .stars { color: var(--accent); letter-spacing: 2px; }
.trust-strip .trust-item { display: inline-flex; align-items: center; gap: var(--space-2); }

/* 9. Section heading set ----------------------------------- */
.section-eyebrow {
  font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.12em;
  font-size: var(--text-sm); color: var(--primary); font-weight: 500;
  display: block; margin-bottom: var(--space-4);
}
.section-title { margin-bottom: var(--space-4); }
.section-subtitle { color: var(--text-muted); max-width: 600px; font-size: var(--text-lg); }

/* 10. Modal (Pattern A funnel has no modal; kept for completeness) */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(31,26,18,0.55); backdrop-filter: blur(2px);
  display: flex; align-items: center; justify-content: center; padding: var(--space-4);
  opacity: 0; visibility: hidden; transition: opacity var(--t-base), visibility var(--t-base); z-index: 1000;
}
.modal-overlay.active { opacity: 1; visibility: visible; }
.modal-content {
  background: var(--card); border-radius: var(--radius-lg); max-width: 800px; width: 90%;
  max-height: 90vh; overflow-y: auto; padding: var(--space-12); position: relative; box-shadow: var(--shadow-lg);
}
.modal-close { position: absolute; top: var(--space-4); right: var(--space-4); color: var(--text-muted); }
body.modal-open { overflow: hidden; }

/* 11. FAQ accordion ---------------------------------------- */
.faq-item { border-bottom: 1px solid var(--border); }
.faq-item summary {
  list-style: none; cursor: pointer; padding: var(--space-6) 0;
  font-family: var(--serif); font-size: var(--text-xl); color: var(--secondary);
  display: flex; justify-content: space-between; align-items: center; gap: var(--space-4);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; color: var(--primary); font-family: var(--sans); font-weight: 400; transition: transform var(--t-fast); }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-body { padding-bottom: var(--space-6); color: var(--text-muted); }

/* 12. Nav + placeholders ----------------------------------- */
.nav { position: sticky; top: 0; z-index: 100; background: rgba(245,240,230,0.85); backdrop-filter: blur(10px); transition: box-shadow var(--t-base); }
.nav-scrolled { box-shadow: var(--shadow-md); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; padding-block: var(--space-4); }
.wordmark { display: inline-flex; align-items: baseline; gap: var(--space-2); text-decoration: none; }
.wordmark .wm-main { font-family: var(--serif); font-weight: 600; font-size: 1.35rem; color: var(--secondary); letter-spacing: -0.01em; }
.wordmark .wm-sub { font-family: var(--mono); font-size: 0.68rem; color: var(--text-muted); letter-spacing: 0.04em; }
.wordmark:hover .wm-main { color: var(--primary); }
footer .wordmark .wm-main { font-size: 1.1rem; }
.video-placeholder, .image-placeholder {
  display: flex; align-items: center; justify-content: center; text-align: center;
  border: 2px dashed var(--border-strong); border-radius: var(--radius-lg);
  color: var(--faint); font-family: var(--mono); font-size: var(--text-sm);
  background: var(--elevated); padding: var(--space-8);
}
.video-placeholder { aspect-ratio: 16 / 9; }
.image-placeholder { aspect-ratio: 3 / 2; }
.video-frame { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-lg); }
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* 13. Responsive grids ------------------------------------- */
.grid-2 { display: grid; grid-template-columns: 1fr; gap: var(--space-8); }
.grid-3 { display: grid; grid-template-columns: 1fr; gap: var(--space-8); }
@media (min-width: 768px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

/* 14. Utilities -------------------------------------------- */
.text-muted { color: var(--text-muted); }
.text-center { text-align: center; }
.mb-4 { margin-bottom: var(--space-4); } .mb-8 { margin-bottom: var(--space-8); } .mb-12 { margin-bottom: var(--space-12); }
.mt-8 { margin-top: var(--space-8); } .mt-12 { margin-top: var(--space-12); }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.highlight {
  color: var(--primary);
  background-image: linear-gradient(transparent 62%, rgba(194,65,12,0.16) 0);
  font-style: italic;
}
.eyebrow-center { text-align: center; }
