/* ==========================================================================
   Deep Bleeps — Vow2Vulnerability
   Design tokens extracted from official book/brand artwork:
   background #322b1b, gold #eac926, rust #d65830
   ========================================================================== */

:root{
  /* Brand surfaces */
  --bg-0: #14110a;        /* deepest layer (footer, preloader) */
  --bg-1: #1c170f;        /* section alt background */
  --bg-2: #221d13;        /* base page background */
  --bg-3: #322b1b;        /* brand espresso — card / raised surface */
  --bg-4: #423823;        /* hover / elevated surface */

  /* Brand accents */
  --gold: #eac926;
  --gold-dim: #b9a021;
  --rust: #d65830;
  --rust-dim: #a8431f;

  /* Text */
  --ink-0: #f6f0df;       /* primary text on dark */
  --ink-1: #cdc2a4;       /* secondary text on dark */
  --ink-2: #8c8168;       /* muted / tertiary text on dark */
  --ink-on-gold: #221d13; /* text on gold surfaces */

  /* Borders */
  --line-0: rgba(246,240,223,0.12);
  --line-1: rgba(246,240,223,0.22);

  /* Type */
  --font-display: "Fraunces", "Playfair Display", "Iowan Old Style", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-label: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  /* Scale */
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2.5rem;
  --space-5: 4rem;
  --space-6: 6rem;
  --space-7: 9rem;

  --radius-sm: 6px;
  --radius-md: 14px;
  --radius-pill: 999px;

  --container: 1180px;

  --ease-out: cubic-bezier(.16,.8,.28,1);
  --dur-fast: 220ms;
  --dur-med: 420ms;
}

/* ---------------------------------- Reset --------------------------------- */
*, *::before, *::after{ box-sizing: border-box; }
html{ -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
body{
  margin: 0;
  background: var(--bg-2);
  color: var(--ink-0);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, video{ max-width: 100%; display: block; }
a{ color: inherit; text-decoration: none; }
ul{ margin: 0; padding: 0; list-style: none; }
h1,h2,h3,h4,p,figure{ margin: 0; }
button{ font: inherit; color: inherit; background: none; border: 0; }
button, .btn, .nav-toggle, a{ cursor: pointer; }
input, textarea, select{ font: inherit; color: inherit; }

/* Skip link */
.skip-link{
  position: fixed;
  top: -100%;
  left: var(--space-2);
  z-index: 1000;
  background: var(--gold);
  color: var(--ink-on-gold);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: top var(--dur-fast) var(--ease-out);
}
.skip-link:focus{ top: var(--space-2); }

:focus-visible{
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

.container{
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-3);
}
@media (min-width: 768px){ .container{ padding-inline: var(--space-4); } }

section{ position: relative; }

/* ------------------------------- Typography -------------------------------- */
.eyebrow{
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-weight: 500;
}
.eyebrow::before{
  content: "";
  width: 1.4em;
  height: 1px;
  background: var(--gold);
  display: inline-block;
}

h1, h2, h3, .font-display{ font-family: var(--font-display); font-weight: 600; letter-spacing: -0.01em; }

h2{
  font-size: clamp(2rem, 4.4vw, 3.4rem);
  line-height: 1.08;
  color: var(--ink-0);
  margin-top: 0.6em;
}
h3{ font-size: clamp(1.15rem, 2vw, 1.5rem); line-height: 1.25; }

.lede{
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  line-height: 1.65;
  color: var(--ink-1);
  max-width: 46ch;
}

.pull-quote{
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.5rem, 3.4vw, 2.5rem);
  line-height: 1.35;
  color: var(--ink-0);
}
.pull-quote em{ color: var(--gold); font-style: italic; }

/* --------------------------------- Buttons --------------------------------- */
.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  padding: 0.95rem 1.7rem;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
  white-space: nowrap;
  min-height: 44px;
}
.btn:active{ transform: scale(0.97); }
.btn-gold{ background: var(--gold); color: var(--ink-on-gold); }
.btn-gold:hover{ background: #ffe14d; }
.btn-outline{ background: transparent; color: var(--ink-0); border: 1px solid var(--line-1); }
.btn-outline:hover{ border-color: var(--gold); color: var(--gold); }
.btn-sm{ padding: 0.7rem 1.3rem; font-size: 0.85rem; }
.btn svg{ width: 1.05em; height: 1.05em; flex: none; }

/* ---------------------------------- Preloader ------------------------------- */
#preloader{
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: var(--bg-0);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: var(--space-3);
}
#preloader .pre-logo{
  width: 46px;
  height: 46px;
  color: var(--gold);
  opacity: 0.9;
}
#preloader .pre-count{
  font-family: var(--font-label);
  font-size: 1.05rem;
  letter-spacing: 0.15em;
  color: var(--ink-1);
  font-variant-numeric: tabular-nums;
}
#preloader .pre-bar{
  width: min(220px, 60vw);
  height: 1px;
  background: var(--line-0);
  position: relative;
  overflow: hidden;
}
#preloader .pre-bar-fill{
  position: absolute;
  inset: 0;
  width: 0%;
  background: var(--gold);
}
#preloader.is-done{
  pointer-events: none;
}

body.is-loading{ overflow: hidden; }

/* ----------------------------------- Nav ------------------------------------ */
.site-header{
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  padding: var(--space-2) 0;
  background: linear-gradient(to bottom, rgba(20,17,10,0.75), rgba(20,17,10,0));
  transition: background var(--dur-med) var(--ease-out), padding var(--dur-med) var(--ease-out), backdrop-filter var(--dur-med) var(--ease-out);
}
.site-header.is-scrolled{
  background: rgba(20,17,10,0.86);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--line-0);
}
.nav-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}
.brand{
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--ink-0);
}
.brand .logo-mark{ width: 30px; height: 30px; color: var(--gold); flex: none; }
.brand small{
  display: block;
  font-family: var(--font-label);
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-2);
  font-weight: 500;
  margin-top: 0.15em;
}

.nav-links{
  display: none;
  align-items: center;
  gap: var(--space-4);
}
.nav-links a{
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-1);
  position: relative;
  padding: 0.3rem 0;
}
.nav-links a::after{
  content: "";
  position: absolute;
  left: 0; right: 100%;
  bottom: -2px;
  height: 1px;
  background: var(--gold);
  transition: right var(--dur-fast) var(--ease-out);
}
.nav-links a:hover, .nav-links a.is-active{ color: var(--ink-0); }
.nav-links a:hover::after, .nav-links a.is-active::after{ right: 0; }

.nav-cta{ display: none; }
.nav-actions{ display: flex; align-items: center; gap: var(--space-2); }

@media (min-width: 900px){
  .nav-links{ display: flex; }
  .nav-cta{ display: inline-flex; }
  .nav-toggle{ display: none; }
}

.nav-toggle{
  width: 44px; height: 44px;
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--ink-0);
}
.nav-toggle svg{ width: 22px; height: 22px; }
.nav-toggle svg line{ transition: transform var(--dur-fast) var(--ease-out), opacity var(--dur-fast) var(--ease-out); transform-origin: center; }
.nav-toggle[aria-expanded="true"] svg line:nth-child(1){ transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] svg line:nth-child(2){ opacity: 0; }
.nav-toggle[aria-expanded="true"] svg line:nth-child(3){ transform: translateY(-6px) rotate(-45deg); }

/* Mobile menu */
.mobile-menu{
  position: fixed;
  inset: 0;
  z-index: 480;
  background: var(--bg-0);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--space-4);
  padding: var(--space-4);
  transform: translateY(-100%);
  transition: transform var(--dur-med) var(--ease-out);
}
.mobile-menu.is-open{ transform: translateY(0); }
.mobile-menu a{
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--ink-0);
}
.mobile-menu a:hover{ color: var(--gold); }
.mobile-menu .btn{ align-self: flex-start; }

/* ----------------------------------- Hero ------------------------------------ */
.hero{
  min-height: 100dvh;
  display: flex;
  align-items: flex-end;
  padding-top: 7rem;
  padding-bottom: var(--space-5);
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(214,88,48,0.20), transparent 60%),
    radial-gradient(ellipse 60% 50% at 85% 15%, rgba(234,201,38,0.10), transparent 60%),
    linear-gradient(180deg, var(--bg-0) 0%, var(--bg-2) 55%, var(--bg-2) 100%);
  overflow: hidden;
}
.hero-stars{
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.hero-stars svg{
  position: absolute;
  color: var(--gold);
  opacity: 0.5;
}
.hero-inner{
  position: relative;
  z-index: 1;
  display: grid;
  gap: var(--space-3);
}
.hero-eyebrow{ margin-bottom: var(--space-2); }
.hero h1{
  font-size: clamp(2.6rem, 7.2vw, 5.6rem);
  line-height: 1.02;
  color: var(--ink-0);
  max-width: 16ch;
}
.hero h1 em{
  font-style: italic;
  color: var(--gold);
}
.hero-sub{
  margin-top: var(--space-3);
  font-size: clamp(1.05rem, 1.7vw, 1.3rem);
  color: var(--ink-1);
  max-width: 58ch;
  line-height: 1.6;
}
.hero-actions{
  margin-top: var(--space-4);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}
.hero-scroll{
  position: absolute;
  right: var(--space-3);
  bottom: var(--space-4);
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink-2);
  font-family: var(--font-label);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.hero-scroll .line{
  width: 1px; height: 46px;
  background: linear-gradient(var(--ink-2), transparent);
}
@media (min-width: 900px){ .hero-scroll{ display: flex; } }

/* ------------------------------- Section shell -------------------------------- */
.section{ padding-block: var(--space-6); }
.section-alt{ background: var(--bg-1); }
.section-head{
  max-width: 62ch;
  margin-bottom: var(--space-5);
}

/* ------------------------------- Mission section -------------------------------- */
.mission-quote-wrap{
  border-left: 2px solid var(--rust);
  padding-left: var(--space-4);
  margin-block: var(--space-4);
}
.mission-grid{
  display: grid;
  gap: var(--space-4);
  margin-top: var(--space-5);
}
@media (min-width: 800px){
  .mission-grid{ grid-template-columns: repeat(3, 1fr); }
}
.stat{
  border-top: 1px solid var(--line-0);
  padding-top: var(--space-2);
}
.stat .num{
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: var(--gold);
  display: block;
}
.stat .label{
  color: var(--ink-1);
  font-size: 0.95rem;
  margin-top: 0.3rem;
}

.about-founder{
  margin-top: var(--space-6);
  display: grid;
  gap: var(--space-3);
  max-width: 68ch;
}
.about-founder p{ color: var(--ink-1); line-height: 1.75; }
.about-founder .signature{
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-0);
  font-size: 1.2rem;
}

/* ------------------------------- Book section -------------------------------- */
.book-grid{
  display: grid;
  gap: var(--space-5);
  align-items: center;
}
@media (min-width: 900px){
  .book-grid{ grid-template-columns: 0.85fr 1.15fr; gap: var(--space-6); }
}
.book-cover-frame{
  position: relative;
  isolation: isolate;
}
.book-cover-frame::before{
  content: "";
  position: absolute;
  inset: var(--space-2) calc(var(--space-2) * -1) calc(var(--space-2) * -1) var(--space-2);
  border: 1px solid var(--line-1);
  border-radius: var(--radius-md);
  z-index: -1;
}
.book-cover-frame img{
  width: 100%;
  height: auto;
  max-width: 380px;
  aspect-ratio: 1294 / 2000;
  margin-inline: auto;
  border-radius: var(--radius-md);
  box-shadow: 0 40px 80px -30px rgba(0,0,0,0.6);
}
.book-kicker{ color: var(--ink-2); font-size: 0.95rem; margin-top: 0.75rem; }
.book-title{ font-size: clamp(2rem, 3.6vw, 2.9rem); margin-top: 0.4em; }
.book-byline{
  font-family: var(--font-label);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-top: 0.6rem;
}
.book-blurb{
  margin-top: var(--space-3);
  color: var(--ink-1);
  line-height: 1.75;
  max-width: 52ch;
}
.book-list{
  margin-top: var(--space-3);
  display: grid;
  gap: 0.85rem;
}
.book-list li{
  display: flex;
  gap: 0.75rem;
  color: var(--ink-1);
  font-size: 0.98rem;
}
.book-list svg{
  width: 1.1rem; height: 1.1rem;
  color: var(--rust);
  flex: none;
  margin-top: 0.2rem;
}
.book-actions{
  margin-top: var(--space-4);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}
.book-actions .fineprint{
  color: var(--ink-2);
  font-size: 0.85rem;
}

/* ------------------------------- Programs section -------------------------------- */
.programs-grid{
  display: grid;
  gap: var(--space-3);
}
@media (min-width: 760px){
  .programs-grid{ grid-template-columns: repeat(3, 1fr); }
}
.program-card{
  background: var(--bg-3);
  border: 1px solid var(--line-0);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  transition: transform var(--dur-med) var(--ease-out), border-color var(--dur-med) var(--ease-out);
}
.program-card:hover{ transform: translateY(-4px); border-color: var(--line-1); }
.program-card .icon{
  width: 42px; height: 42px;
  border-radius: 50%;
  background: rgba(234,201,38,0.12);
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
}
.program-card .icon svg{ width: 20px; height: 20px; }
.program-card h3{ color: var(--ink-0); }
.program-card p{ color: var(--ink-1); font-size: 0.95rem; line-height: 1.65; }

/* ------------------------------- Get involved -------------------------------- */
.involved-grid{
  display: grid;
  gap: var(--space-5);
}
@media (min-width: 900px){
  .involved-grid{ grid-template-columns: 0.9fr 1.1fr; gap: var(--space-6); }
}
.connect-list{
  display: grid;
  gap: var(--space-2);
  margin-top: var(--space-4);
}
.connect-card{
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  background: var(--bg-3);
  border: 1px solid var(--line-0);
  border-radius: var(--radius-md);
  transition: border-color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
}
a.connect-card:hover{ border-color: var(--gold); background: var(--bg-4); }
.connect-card .icon{
  width: 44px; height: 44px; flex: none;
  border-radius: 50%;
  background: rgba(214,88,48,0.15);
  color: var(--rust);
  display: flex; align-items: center; justify-content: center;
}
.connect-card .icon svg{ width: 20px; height: 20px; }
.connect-card .title{ color: var(--ink-0); font-weight: 600; font-size: 0.98rem; }
.connect-card .desc{ color: var(--ink-2); font-size: 0.85rem; margin-top: 0.1rem; }

.form-card{
  background: var(--bg-3);
  border: 1px solid var(--line-0);
  border-radius: var(--radius-md);
  padding: var(--space-4);
}
.field{ margin-bottom: var(--space-3); }
.field label{
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-0);
  margin-bottom: 0.5rem;
}
.field .req{ color: var(--rust); }
.field input, .field textarea, .field select{
  width: 100%;
  background: var(--bg-1);
  border: 1px solid var(--line-1);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  color: var(--ink-0);
  min-height: 44px;
  transition: border-color var(--dur-fast) var(--ease-out);
}
.field textarea{ min-height: 120px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus{
  border-color: var(--gold);
  outline: none;
}
.field-help{ font-size: 0.8rem; color: var(--ink-2); margin-top: 0.4rem; }
.form-status{
  margin-top: var(--space-2);
  font-size: 0.9rem;
  color: var(--gold);
  min-height: 1.2em;
}
.form-status[data-state="error"]{ color: var(--rust); }

/* ----------------------------------- Footer ------------------------------------ */
.site-footer{
  background: var(--bg-0);
  padding-block: var(--space-5) var(--space-3);
  border-top: 1px solid var(--line-0);
}
.footer-top{
  display: grid;
  gap: var(--space-4);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--line-0);
}
@media (min-width: 800px){
  .footer-top{ grid-template-columns: 1.3fr 1fr 1fr; }
}
.footer-brand .brand{ margin-bottom: var(--space-2); }
.footer-brand p{ color: var(--ink-2); max-width: 40ch; line-height: 1.65; font-size: 0.92rem; }
.footer-col h4{
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: var(--space-2);
}
.footer-col ul{ display: grid; gap: 0.65rem; }
.footer-col a{ color: var(--ink-1); font-size: 0.95rem; }
.footer-col a:hover{ color: var(--gold); }
.footer-bottom{
  padding-top: var(--space-3);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  justify-content: space-between;
  color: var(--ink-2);
  font-size: 0.82rem;
}
.footer-socials{ display: flex; gap: var(--space-2); }
.footer-socials a{
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line-1);
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-1);
}
.footer-socials a:hover{ color: var(--gold); border-color: var(--gold); }
.footer-socials svg{ width: 16px; height: 16px; }

/* ---------------------------------- Utilities ------------------------------------ */
.visually-hidden{
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
[data-reveal]{ opacity: 1; }
