/* Prismatic, attempt 2 */

:root {
  --black: #0B0B0C;
  --charcoal: #1C1C1F;
  --grey: #4A4A50;
  --paper: #F6F3EE;
  --ink: #111113;
  --on-dark: #F6F3EE;
  --on-dark-muted: rgba(246, 243, 238, 0.78);
  --line-dark: rgba(246, 243, 238, 0.14);
  --line-light: rgba(17, 17, 19, 0.12);

  --pearl: linear-gradient(120deg, #E9BCD6, #C9BBF0, #A8DDCB, #A9CBEF);
  --pearl-solid: #C9BBF0;
  /* Deeper pearl for text on light backgrounds (each stop at least 4.5:1 on #F6F3EE) */
  --pearl-deep: linear-gradient(120deg, #8E3F6B, #5B47A8, #2D6F5A, #2F5F96);
  --pearl-deep-solid: #5B47A8;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --header-h: 64px;
  --radius: 0;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

img,
video { display: block; max-width: 100%; }

h1, h2, h3 {
  margin: 0 0 0.6em;
  line-height: 1.12;
  letter-spacing: -0.02em;
  font-weight: 700;
}

h1 { font-size: clamp(2.25rem, 7vw, 4.25rem); max-width: 16ch; }
h2 { font-size: clamp(1.85rem, 5vw, 3rem); max-width: 20ch; }
h3 { font-size: 1.2rem; letter-spacing: -0.01em; }

p { margin: 0 0 1em; max-width: 60ch; text-wrap: pretty; }

a { color: inherit; text-underline-offset: 0.2em; }

:focus-visible {
  outline: 3px solid var(--pearl-deep-solid);
  outline-offset: 3px;
  border-radius: 4px;
}
.theme-dark :focus-visible,
.site-header[data-header-theme="dark"] :focus-visible,
.mobile-cta :focus-visible { outline-color: var(--pearl-solid); }

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
.narrow { max-width: 820px; }

.skip-link {
  position: absolute;
  left: 12px;
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--paper);
  color: var(--ink);
  border-radius: 8px;
  font-weight: 600;
}
.skip-link:focus { top: 12px; }

/* Themes */
.theme-dark { background: var(--black); color: var(--on-dark); }
.theme-light { background: var(--paper); color: var(--ink); }

/* Highlighted phrase: solid pearl, never gradient text */
.hl { color: var(--pearl-deep-solid); }
.theme-dark .hl { color: var(--pearl-solid); }

/* Thin pearl divider */
.divider {
  width: 56px;
  height: 2px;
  margin: 0 0 40px;
  border: 0;
  background: var(--pearl-solid);
  border-radius: 0;
}
.divider-wide { width: 100%; height: 1px; margin-bottom: 64px; opacity: 0.9; }

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 14px 28px;
  border: 0;
  border-radius: 0;
  background: var(--pearl-solid);
  color: var(--ink);
  font: inherit;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
  transition: transform 140ms var(--ease-out), background-color 180ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .button:hover { background-color: #D8CEF5; }
}
.button:active { transform: scale(0.97); }
.button-block { width: 100%; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: var(--black);
  color: var(--on-dark);
  border-bottom: 1px solid var(--line-dark);
  transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}
.site-header[data-header-theme="light"] {
  background: var(--paper);
  color: var(--ink);
  border-bottom-color: var(--line-light);
}
.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand { position: relative; display: block; height: 38px; flex-shrink: 0; }
.brand-logo { height: 38px; width: auto; }
.brand-shimmer {
  position: absolute;
  top: 0;
  left: 0;
  height: 38px;
  width: auto;
  display: none;
}
.brand-logo-light { display: none; }
.site-header[data-header-theme="light"] .brand-logo-light { display: block; }
.site-header[data-header-theme="light"] .brand-logo-dark { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .site-header[data-header-theme="dark"] .brand-shimmer { display: block; }
}

.menu-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 8px 14px;
  border: 1px solid currentColor;
  border-radius: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}
.menu-toggle-bars,
.menu-toggle-bars::before,
.menu-toggle-bars::after {
  display: block;
  width: 16px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.2s, opacity 0.2s;
}
.menu-toggle-bars { position: relative; }
.menu-toggle-bars::before,
.menu-toggle-bars::after { content: ""; position: absolute; left: 0; }
.menu-toggle-bars::before { top: -5px; }
.menu-toggle-bars::after { top: 5px; }
.menu-toggle[aria-expanded="true"] .menu-toggle-bars { background: transparent; }
.menu-toggle[aria-expanded="true"] .menu-toggle-bars::before { transform: translateY(5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle-bars::after { transform: translateY(-5px) rotate(-45deg); }

.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav a { text-decoration: none; font-weight: 550; }
.site-nav a:not(.pill):hover { text-decoration: underline; }

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 18px;
  border: 1px solid currentColor;
  border-radius: 0;
  background: transparent;
  color: inherit;
  font-weight: 650;
}

/* Mobile nav: hidden until toggled (only when JS is running) */
.js .site-nav {
  position: absolute;
  top: var(--header-h);
  left: 0;
  right: 0;
  display: none;
  background: var(--black);
  border-bottom: 1px solid var(--line-dark);
}
.js .site-header[data-header-theme="light"] .site-nav { background: var(--paper); border-bottom-color: var(--line-light); }
.js .site-nav.is-open { display: block; }
.site-nav ul { display: flex; flex-direction: column; gap: 4px; padding: 12px 20px 20px; }
.site-nav li a:not(.pill) { display: block; padding: 10px 0; }
.site-nav li:last-child { margin-top: 8px; }

html:not(.js) .menu-toggle { display: none; }
html:not(.js) .site-header { height: auto; }
html:not(.js) .header-inner { flex-wrap: wrap; padding-top: 12px; padding-bottom: 4px; }
html:not(.js) .site-nav ul { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 16px; padding: 8px 0; }
html:not(.js) .site-nav li:last-child { margin-top: 0; }

@media (min-width: 860px) {
  .menu-toggle { display: none; }
  .js .site-nav,
  .site-nav {
    position: static;
    display: block;
    border: 0;
    background: none;
  }
  .site-nav ul,
  html:not(.js) .site-nav ul { flex-direction: row; align-items: center; gap: 28px; padding: 0; }
  .site-nav li a:not(.pill) { padding: 6px 0; }
  .site-nav li:last-child { margin-top: 0; margin-left: 4px; }
  /* The light-theme dropdown background is for phones only */
  .js .site-header[data-header-theme="light"] .site-nav { background: none; border: 0; }
}

/* Sections */
section[id] { scroll-margin-top: var(--header-h); }

.section { padding: 88px 0; }
.section-tight-bottom { padding-bottom: 56px; }
.section-tight-top { padding-top: 0; }
@media (min-width: 860px) {
  .section { padding: 128px 0; }
  .section-tight-bottom { padding-bottom: 72px; }
  .section-tight-top { padding-top: 0; }
}

.lead { font-size: clamp(1.1rem, 2.4vw, 1.3rem); line-height: 1.55; }
.theme-dark p,
.theme-dark li { color: var(--on-dark-muted); }
.theme-dark strong,
.theme-dark h3 { color: var(--on-dark); }
.theme-light p,
.theme-light li { color: var(--grey); }
.theme-light strong,
.theme-light h3 { color: var(--ink); }

.eyebrow {
  margin-bottom: 14px;
  font-size: 0.85rem;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* Hero: the trailer is the first thing visitors see, centred under the header,
   with the headline and audit button directly below it.
   script.js scales and fades .trailer on scroll. */
.hero {
  position: relative;
  overflow: hidden;
  padding: 32px 0 80px;
  background: var(--black);
  text-align: center;
}
.hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.trailer {
  position: relative;
  width: 100%;
  max-width: 1040px;
  aspect-ratio: 16 / 9;
  margin: 0 auto 44px;
  border-radius: 0;
  overflow: hidden;
  background: var(--charcoal) url("assets/video/trailer-poster.jpg") center / cover no-repeat;
  border: 1px solid var(--line-dark);
  transform-origin: 50% 0;
  will-change: transform, opacity;
}
.trailer-video { width: 100%; height: 100%; object-fit: cover; }
.trailer-sound {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border: 1px solid rgba(246, 243, 238, 0.28);
  border-radius: 0;
  background: var(--black);
  color: var(--on-dark);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition: border-color 180ms ease, transform 140ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .trailer-sound:hover { border-color: var(--pearl-solid); }
}
.trailer-sound:active { transform: scale(0.97); }
.trailer-sound:focus-visible { outline-color: var(--pearl-solid); }
.trailer-sound svg { width: 18px; height: 18px; flex: none; }
.trailer-sound .icon-on { display: none; }
.trailer-sound[aria-pressed="true"] .icon-on { display: block; }
.trailer-sound[aria-pressed="true"] .icon-off { display: none; }
.trailer-note {
  position: absolute;
  left: 14px;
  bottom: 14px;
  margin: 0;
  padding: 5px 10px;
  border-radius: 0;
  background: var(--black);
  font-size: 0.75rem;
  line-height: 1.2;
  color: var(--on-dark-muted);
}
.hero h1 { color: var(--on-dark); margin-left: auto; margin-right: auto; }
.hero .lead { max-width: 46ch; margin-left: auto; margin-right: auto; color: rgba(246, 243, 238, 0.86); }
.hero-cta { margin-top: 28px; }
.hero-note { margin: 14px auto 0; font-size: 0.92rem; color: rgba(246, 243, 238, 0.78); }

@media (max-width: 599px) {
  .hero { padding: 16px 0 56px; }
  .trailer { margin-bottom: 28px; }
  .trailer-sound { right: 10px; bottom: 10px; padding: 9px; }
  .trailer-sound-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .trailer-note { left: 10px; bottom: 10px; font-size: 0.7rem; }
}

/* Cards */
.card-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 16px;
}
.card {
  padding: 28px 24px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line-light);
}
.card h3 { margin-bottom: 0.5em; }
.card p { margin: 0; }
.card-compact { padding: 24px 22px; }

.tag {
  display: inline-block;
  margin: 0 0 12px !important;
  padding: 3px 10px;
  border: 1px solid var(--line-light);
  border-radius: 0;
  font-size: 0.8rem;
  font-weight: 650;
  color: var(--ink) !important;
}

@media (min-width: 700px) {
  .card-grid-3 { grid-template-columns: repeat(3, 1fr); }
  .card-grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1040px) {
  .card-grid-4 { grid-template-columns: repeat(4, 1fr); }
}

/* How it works: scroll-scrub */
.how { position: relative; padding-bottom: 88px; }
.how-sticky { padding: 72px 0 24px; }
.how-inner {
  display: grid;
  gap: 32px;
  align-items: center;
}
.how-media {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--black);
  border: 1px solid var(--line-dark);
}
.scrub-video,
.scrub-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.scrub-poster { display: none; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; }
.step {
  padding-left: 16px;
  border-left: 2px solid rgba(246, 243, 238, 0.25);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.step p { margin: 6px 0 0; font-size: 1.08rem; }
.step.is-current { border-left-color: var(--pearl-solid); }

.how-cta { padding-top: 24px; }

/* Scrub layout only when JS is running and motion is allowed */
@media (prefers-reduced-motion: no-preference) {
  .js .how-track { height: 320vh; }
  .js .how-sticky {
    position: sticky;
    top: var(--header-h);
    height: calc(100vh - var(--header-h));
    height: calc(100svh - var(--header-h));
    display: flex;
    align-items: center;
    align-items: safe center;
    padding: 20px 0;
  }
  .js .how.scrub-ready .step:not(.is-on) { opacity: 0; transform: translateY(16px); }
  .js .how.scrub-ready .step.is-on:not(.is-current) { opacity: 0.75; }
}

/* Mobile: video stacked above steps, kept compact so all fits in the viewport */
@media (max-width: 859px) {
  .how-inner { gap: 16px; }
  .how-media { aspect-ratio: auto; height: 22vh; height: 22svh; }
  .how h2 { font-size: 1.65rem; margin-bottom: 0.4em; }
  .steps { gap: 12px; }
  .step { padding-left: 14px; }
  .step p { margin: 0; font-size: 0.98rem; line-height: 1.5; }
}
@media (max-width: 859px) and (prefers-reduced-motion: no-preference) {
  /* Leave room for the sticky CTA bar at the bottom */
  .js .how-sticky {
    height: calc(100vh - var(--header-h) - 76px);
    height: calc(100svh - var(--header-h) - 76px);
  }
}
@media (max-width: 859px) and (max-height: 600px) {
  /* Very short screens: drop the sticky panel, keep the scrub */
  .js .how-track { height: auto !important; }
  .js .how-sticky { position: static !important; height: auto !important; }
  .js .how.scrub-ready .step:not(.is-on) { opacity: 1 !important; transform: none !important; }
}

@media (min-width: 860px) {
  .how-inner { grid-template-columns: 1.15fr 1fr; gap: 64px; }
  .how-media { aspect-ratio: 16 / 10; }
  .how-cta { padding-top: 40px; }
}

/* Packages */
.founding {
  margin: 0 0 40px;
  padding: 24px;
  border-radius: var(--radius);
  background: var(--charcoal);
  border: 1px solid var(--line-dark);
}
.founding h3 { font-size: clamp(1.2rem, 3vw, 1.5rem); margin-bottom: 0.4em; }
.founding p { margin: 0 0 12px; }
.spots {
  display: inline-block;
  margin: 4px 0 0 !important;
  padding: 6px 14px;
  border: 1px solid rgba(246, 243, 238, 0.3);
  border-radius: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--on-dark) !important;
}
@media (min-width: 860px) {
  .founding { display: grid; grid-template-columns: 1fr auto; column-gap: 32px; align-items: center; padding: 28px 32px; }
  .founding h3,
  .founding p:not(.spots) { grid-column: 1; }
  .founding .spots { grid-column: 2; grid-row: 1 / span 2; }
}

.package-grid { display: grid; gap: 20px; }
@media (min-width: 960px) {
  .package-grid { grid-template-columns: repeat(3, 1fr); align-items: start; }
}
.package {
  position: relative;
  padding: 32px 26px 28px;
  border-radius: var(--radius);
  background: var(--charcoal);
  border: 1px solid var(--line-dark);
  transition: translate 0.25s var(--ease), border-color 180ms ease;
}
.package:hover,
.package:focus-within {
  translate: 0 -4px;
}
.package-featured {
  border: 2px solid var(--pearl-solid);
  background: var(--charcoal);
}
.badge {
  position: absolute;
  top: -13px;
  left: 24px;
  margin: 0;
  padding: 3px 12px;
  border-radius: 0;
  background: var(--pearl-solid);
  color: var(--ink) !important;
  font-size: 0.8rem;
  font-weight: 700;
}
.package h3 { font-size: 1.4rem; margin-bottom: 0.25em; }
.price {
  margin: 0 0 10px;
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--on-dark) !important;
}
.package-intro { margin-bottom: 18px; }

.ticks { list-style: none; margin: 0; padding: 0; }
.ticks li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 10px;
}
.ticks li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.5em;
  width: 12px;
  height: 7px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
  opacity: 0.8;
}

.annual {
  margin: 36px 0 12px;
  font-size: 1.08rem;
  font-weight: 600;
  color: var(--on-dark) !important;
}
.small-print { font-size: 0.92rem; }

/* Small print and form note: plain solid text, never the pearl tint */
.small-print,
.small-print *,
.form-note,
.form-note * {
  background: none !important;
  -webkit-background-clip: border-box !important;
  background-clip: border-box !important;
  -webkit-text-fill-color: currentColor !important;
}
.theme-dark .small-print,
.theme-dark .small-print *,
.theme-dark .form-note,
.theme-dark .form-note * { color: #9A9AA0 !important; }
.theme-light .small-print,
.theme-light .small-print *,
.theme-light .form-note,
.theme-light .form-note * { color: #4A4A50 !important; }

/* Guarantee */
.guarantee .lead { color: var(--ink); max-width: 44ch; }

/* FAQ */
.faq-list { border-top: 1px solid var(--line-light); padding-top: 12px; }
.faq { border-bottom: 1px solid var(--line-light); }
.faq summary {
  position: relative;
  display: block;
  padding: 20px 40px 20px 0;
  font-weight: 650;
  font-size: 1.08rem;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  position: absolute;
  right: 6px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-70%) rotate(45deg);
  transition: transform 0.2s;
}
.faq[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq p { margin: 0 0 22px; }

/* About */
.about-columns { display: grid; gap: 32px; margin-bottom: 32px; }
@media (min-width: 760px) {
  .about-columns { grid-template-columns: 1.4fr 1fr; gap: 56px; }
}
.about-close a { color: var(--on-dark); font-weight: 600; }

/* Audit */
.audit-inner { display: grid; gap: 48px; }
@media (min-width: 960px) {
  .audit-inner { grid-template-columns: 1.1fr 1fr; gap: 72px; align-items: start; }
}
.audit-text h3 { margin-top: 1.4em; }
.ticks-dark li { color: var(--grey); }

.audit-form {
  padding: 28px 22px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line-light);
}
@media (min-width: 600px) { .audit-form { padding: 36px 32px; } }
.field { margin-bottom: 18px; }
.field label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
}
.field input {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border: 1px solid #8A8A90;
  border-radius: 0;
  background: #fff;
  color: var(--ink);
  font: inherit;
}
.field input:focus-visible {
  outline: 3px solid var(--pearl-deep-solid);
  outline-offset: 1px;
  border-color: var(--ink);
}
.audit-form .button { margin-top: 8px; }
.form-note { margin: 14px 0 0; font-size: 0.9rem; }

/* Footer */
.site-footer { padding: 56px 0; border-top: 1px solid var(--line-dark); }
.footer-inner p { margin: 0 0 8px; color: var(--on-dark-muted); }
.footer-logo { height: 40px; width: auto; margin-bottom: 20px; }
.copyright { font-size: 0.9rem; }

/* Mobile sticky CTA */
.mobile-cta { display: none; }
@media (max-width: 859px) {
  .mobile-cta {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    display: block;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    background: rgba(11, 11, 12, 0.94);
    border-top: 1px solid var(--line-dark);
    transition: transform 0.3s var(--ease), visibility 0.3s;
  }
  .mobile-cta.is-hidden { transform: translateY(110%); visibility: hidden; }
  .site-footer { padding-bottom: 132px; }
}

/* Reveal on scroll (only hidden when JS has run) */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .js .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
    transition-delay: var(--reveal-delay, 0ms);
  }
  .js .reveal.is-visible { opacity: 1; transform: none; }
  /* Hover lift uses `translate`, so it never fights the reveal `transform` */
  .js .package.reveal {
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease), translate 0.25s var(--ease), border-color 180ms ease;
    transition-delay: var(--reveal-delay, 0ms), var(--reveal-delay, 0ms), 0ms, 0ms;
  }
}

/* Reduced motion: everything static and visible, posters instead of video */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .scrub-video { display: none; }
  .scrub-poster { display: block; }
  .package:hover,
  .package:focus-within { translate: none; }
  .button:active,
  .trailer-sound:active { transform: none; }
}
