/* ===================================================================
   Betty by OddsEven — shared public-web styles
   Palette, typography, nav, footer, animations, common utilities.
   Page-specific layout stays inline in each PHP page when we convert.
   =================================================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --black:        #0a0a0a;
  --green-deep:   #0d2418;
  --green-mid:    #163d28;
  --green-bright: #1f6b42;
  --green-light:  #2a8a56;
  --gold:         #c9a84c;
  --gold-light:   #e4c670;
  --cream:        #f5f0e8;
  --white:        #ffffff;
  --text-dim:     rgba(255,255,255,0.55);
  --text-mid:     rgba(255,255,255,0.75);
  /* Bright green = the user's own data (Betty V2). Gold stays brand + features. */
  --data:         #4ade80;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Barlow', sans-serif;
  background: var(--black);
  color: var(--white);
  overflow-x: hidden;
}

/* Subtle noise texture overlay — applied across every page. */
body::before {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1000;
  opacity: 0.4;
}

/* ===================================================================
   NAV
   Three variants chosen by _nav.php via $navVariant:
   - 'full'    — logo + menu links + CTA (secondary marketing pages)
   - 'minimal' — logo + CTA only (home)
   - 'back'    — logo + back link (signup / focused conversion pages)
   =================================================================== */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 20px 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(to bottom, rgba(10,10,10,0.95), transparent);
  border-bottom: 1px solid transparent;
  transition: background 0.2s ease, border-color 0.2s ease;
}
/* Solid bar once the page has scrolled (site.js adds .nav-scrolled) or the
   mobile menu is open. The fade-to-transparent gradient above only works
   over the hero — further down, page content showed through behind the
   links (e.g. a section heading visible next to ABOUT). */
nav.nav-scrolled,
nav.nav-open {
  background: rgba(10,10,10,0.97);
  border-bottom-color: rgba(255,255,255,0.06);
}
@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  nav.nav-scrolled:not(.nav-open) {
    background: rgba(10,10,10,0.9);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }
}
.nav-logo {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.5px;
  color: var(--white);
  text-decoration: none;
}
.nav-logo span { color: var(--gold); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}
.nav-link {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-link:hover { color: var(--gold); }
.nav-link.is-active { color: var(--gold); }

.nav-cta {
  background: var(--gold);
  color: var(--black);
  padding: 10px 24px;
  border-radius: 2px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-decoration: none;
  transition: background 0.2s;
}
.nav-cta:hover { background: var(--gold-light); }

/* Existing-user sign-in link. Sits next to .nav-cta but visually quieter —
   the primary CTA is conversion (Start Free Trial / Say Hello to Betty),
   sign-in is for users who already have an account. */
.nav-signin {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
  padding: 10px 4px;
}
.nav-signin:hover { color: var(--gold); }

.nav-back {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s;
}
.nav-back:hover { color: var(--gold); }

/* ===================================================================
   COMMON SECTION HELPERS
   =================================================================== */
.section-inner { max-width: 1200px; margin: 0 auto; }

.section-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}
.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 20px;
}
.section-title em { font-style: italic; color: var(--gold); }
/* Inline highlight for a phrase about the user's own numbers. */
.data-hl { color: var(--data); font-weight: 500; }

.section-sub {
  font-size: 17px;
  font-weight: 300;
  color: var(--text-mid);
  line-height: 1.7;
  max-width: 560px;
}

/* ===================================================================
   BUTTONS
   =================================================================== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--gold);
  color: var(--black);
  padding: 16px 32px;
  border-radius: 2px;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-decoration: none;
  transition: all 0.2s;
  border: 0;
  cursor: pointer;
}
.btn-primary:hover {
  background: var(--gold-light);
  transform: translateY(-1px);
}
.btn-primary svg { width: 20px; height: 20px; }

/* ===================================================================
   FOOTER
   =================================================================== */
footer {
  background: var(--green-deep);
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 40px 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}
.footer-logo {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  font-weight: 900;
  color: var(--white);
}
.footer-logo span { color: var(--gold); }
.footer-links {
  display: flex;
  gap: 32px;
  align-items: center;
  flex-wrap: wrap;
}
.footer-links a {
  font-size: 13px;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--white); }
.footer-copy {
  font-size: 12px;
  color: var(--text-dim);
  font-family: 'Barlow Condensed', sans-serif;
  letter-spacing: 1px;
}

/* The legally-required-ish business + regulatory strip under the main
   footer. Kept tiny and grey on grey on purpose. */
.footer-compliance {
  background: #050505;
  padding: 20px 60px;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.04);
}
.footer-compliance p {
  font-family: 'Barlow', sans-serif;
  font-size: 11px;
  color: rgba(255,255,255,0.2);
  line-height: 1.8;
}
.footer-compliance strong { color: rgba(255,255,255,0.35); }
.footer-u18 {
  margin-top: 16px;
  font-size: 12px;
  color: rgba(255,255,255,0.2);
  line-height: 1.7;
}

/* ===================================================================
   ANIMATIONS
   =================================================================== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* Scroll-reveal. JS in /assets/site.js adds .visible when in viewport. */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===================================================================
   MOBILE BURGER MENU
   The button itself is hidden on desktop. The mobile breakpoint below
   shows it, and turns .nav-links into a dropdown panel toggled by the
   .nav-open class (added by site.js when the burger is tapped).
   =================================================================== */
.nav-burger {
  display: none;
  background: transparent;
  border: 0;
  padding: 6px;
  cursor: pointer;
  width: 36px;
  height: 36px;
  position: relative;
}
.nav-burger span {
  display: block;
  position: absolute;
  left: 7px;
  width: 22px;
  height: 2px;
  background: var(--white);
  border-radius: 1px;
  transition: transform 0.25s ease, opacity 0.2s ease, top 0.25s ease;
}
.nav-burger span:nth-child(1) { top: 11px; }
.nav-burger span:nth-child(2) { top: 17px; }
.nav-burger span:nth-child(3) { top: 23px; }
nav.nav-open .nav-burger span:nth-child(1) {
  top: 17px; transform: rotate(45deg);
}
nav.nav-open .nav-burger span:nth-child(2) { opacity: 0; }
nav.nav-open .nav-burger span:nth-child(3) {
  top: 17px; transform: rotate(-45deg);
}

/* Mid-width desktops: with the longer "How Odds Work" label the full nav
   wrapped onto two lines between ~901px and ~990px. Tighten the spacing
   until the burger menu takes over at 900px. */
@media (min-width: 901px) and (max-width: 1100px) {
  nav { padding-left: 32px; padding-right: 32px; }
  .nav-links { gap: 20px; }
}

/* ===================================================================
   RESPONSIVE
   =================================================================== */
@media (max-width: 900px) {
  nav { padding: 16px 20px; }

  /* Burger visible, inline links collapsed into a dropdown. */
  .nav-burger { display: block; }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 20px 20px;
    /* Fully opaque — at 0.97 the hero headline ghosted through the menu. */
    background: var(--black);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }
  nav.nav-open .nav-links {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  /* Inside the dropdown, every link gets full width + tall tap target. */
  .nav-links .nav-link,
  .nav-links .nav-signin {
    padding: 14px 8px;
    font-size: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    text-align: left;
  }
  .nav-links .nav-link:last-of-type,
  .nav-links .nav-signin { border-bottom: 1px solid rgba(255, 255, 255, 0.05); }

  /* The conversion CTA sits at the bottom of the drawer as a full-width button. */
  .nav-links .nav-cta {
    margin-top: 14px;
    text-align: center;
    padding: 14px 20px;
  }

  /* Footer responsive (unchanged from before). */
  footer { flex-direction: column; gap: 20px; text-align: center; padding: 32px 24px; }
  .footer-links { flex-wrap: wrap; justify-content: center; }
  .footer-compliance { padding: 20px 24px; }
}