/* =========================================================
   Miss Amazing Missouri — landing page
   Palette and type are defined once here; swap the tokens in
   :root to re-skin the whole page.
   ========================================================= */

:root {
  color-scheme: light;

  /* Brand — sampled from assets/favicon.ico.
     The logo is a gradient running violet (#482E7F) to magenta (#C01B77). */
  --violet:        #482E7F;
  --violet-deep:   #2E1C53;
  --magenta:       #C01B77;
  --magenta-deep:  #8E1458;
  --gold:          #E8A33D;
  --header:        #423A4E;

  /* Neutrals */
  --ink:          #171320;
  --ink-soft:     #4A4458;
  --ink-faint:    #726B82;
  --rule:         #E4DFEC;
  --surface:      #FFFFFF;
  --cream:        #FAF7FC;

  /* Type */
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body:    "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* Layout */
  --wrap:    1120px;
  --gutter:  clamp(1rem, 4vw, 2.5rem);
  --radius:  14px;
}

/* ───────── Reset ───────── */

*, *::before, *::after { box-sizing: border-box; }

body, h1, h2, h3, h4, p, ul, ol, dl, dd, figure {
  margin: 0;
  padding: 0;
}

ul, ol { list-style: none; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  background: var(--surface);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ───────── Shared ───────── */

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

a { color: var(--magenta); }

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

.hero :focus-visible,
.site-footer :focus-visible {
  outline-color: #FFF;
}

/* Announces new-tab links to screen readers without showing the text. */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translate(-50%, -120%);
  z-index: 100;
  background: var(--ink);
  color: #FFF;
  padding: 0.75rem 1.25rem;
  border-radius: 0 0 var(--radius) var(--radius);
  font-weight: 600;
  text-decoration: none;
}
.skip-link:focus { transform: translate(-50%, 0); }

.eyebrow {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.eyebrow-dark { color: var(--magenta); }

.section-title {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.9rem, 4.2vw, 2.9rem);
  line-height: 1.15;
  letter-spacing: -0.015em;
  max-width: 22ch;
}

.section-lede {
  margin-top: 1.25rem;
  max-width: 62ch;
  font-size: 1.125rem;
  color: var(--ink-soft);
}

.sub-h {
  font-family: var(--body);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-top: 3rem;
  margin-bottom: 0.75rem;
}

.section-outro { margin-top: 2.75rem; }

.link-out {
  font-weight: 600;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}
.link-out .arrow {
  display: inline-block;
  margin-left: 0.4em;
  transition: transform 0.18s ease;
}
.link-out:hover .arrow { transform: translateX(4px); }

/* ───────── Buttons ───────── */

.btn {
  display: inline-block;
  font-family: var(--body);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: 0.95rem 1.6rem;
  border-radius: 999px;
  text-decoration: none;
  border: 2px solid transparent;
  transition: background-color 0.18s ease, color 0.18s ease,
              border-color 0.18s ease, transform 0.18s ease;
}
.btn:hover { transform: translateY(-2px); }

.btn-sm { padding: 0.65rem 1.2rem; font-size: 0.9375rem; }

.btn-solid  { background: var(--gold); color: var(--violet-deep); }
.btn-solid:hover { background: #F3B65C; }

.btn-ghost  { background: transparent; color: #FFF; border-color: rgba(255,255,255,0.5); }
.btn-ghost:hover { background: rgba(255,255,255,0.12); border-color: #FFF; }

.btn-outline { background: transparent; color: var(--magenta); border-color: var(--magenta); }
.btn-outline:hover { background: var(--magenta); color: #FFF; }

/* Filled magenta — used on the light header, where gold reads too soft. */
.btn-magenta { background: var(--magenta); color: #FFF; }
.btn-magenta:hover { background: var(--magenta-deep); }

/* ───────── Header ───────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--header);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: 84px;
}

/* The logo is a white wordmark, so it needs the dark band to sit on. */
.brand {
  display: block;
  margin-right: auto;
  line-height: 0;
}

.brand-logo {
  width: auto;
  height: 52px;
}

.site-nav ul { display: flex; gap: 1.75rem; }
.site-nav a {
  color: rgba(255,255,255,0.86);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 500;
  padding-block: 0.5rem;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: #FFF; border-bottom-color: var(--gold); }

@media (max-width: 840px) {
  .site-nav { display: none; }
}
@media (max-width: 420px) {
  .header-cta { display: none; }
}

/* ───────── Hero ───────── */

.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(120% 120% at 15% 0%, #8A1A53 0%, transparent 60%),
    linear-gradient(145deg, var(--violet) 0%, var(--violet-deep) 100%);
  color: #FFF;
  padding-block: clamp(4rem, 11vw, 7.5rem);
}

/* Photo sits on the right and dissolves into the gradient. It paints over
   the hero's background and under the copy, which is lifted to z-index 1.
   The radial mask feathers every edge so there is no visible seam. */
.hero-photo {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 52%;
  height: 100%;
  z-index: 0;
  object-fit: cover;
  object-position: 50% 30%;
  /* Desaturating pulls the photo's stage-blue closer to the brand violet. */
  filter: saturate(0.62) brightness(0.97);
  -webkit-mask-image: radial-gradient(ellipse 72% 80% at 62% 44%, #000 30%, transparent 76%);
  mask-image: radial-gradient(ellipse 72% 80% at 62% 44%, #000 30%, transparent 76%);
}

/* Violet veil over the photo half only — the left stays fully transparent so
   the magenta bloom in the hero gradient is untouched. */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(100deg,
      rgba(46, 28, 83, 0) 34%,
      rgba(72, 46, 127, 0.42) 56%,
      rgba(58, 30, 96, 0.58) 100%);
}

.hero-inner { position: relative; z-index: 1; }

/* No width cap here — the hero block must share the .wrap grid so the
   headline aligns with the logo above it. Line length is capped on the
   children instead. */
.hero h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(2.3rem, 6.2vw, 4.1rem);
  line-height: 1.07;
  letter-spacing: -0.025em;
  text-wrap: balance;
  max-width: 34rem;
}

.lede {
  margin-top: 1.5rem;
  max-width: 34rem;
  font-size: clamp(1.0625rem, 2vw, 1.25rem);
  color: rgba(255,255,255,0.86);
}

.hero-actions {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
}

/* Narrow screens: there is no room for a side-by-side photo, so it drops
   behind the copy as a texture with a scrim to protect contrast. */
@media (max-width: 1024px) {
  .hero-photo {
    width: 100%;
    opacity: 0.38;
    object-position: 58% 22%;
    -webkit-mask-image: radial-gradient(ellipse 95% 85% at 65% 38%, #000 22%, transparent 82%);
    mask-image: radial-gradient(ellipse 95% 85% at 65% 38%, #000 22%, transparent 82%);
  }

  .hero::after {
    background: linear-gradient(180deg, rgba(46, 28, 83, 0.42), rgba(46, 28, 83, 0.68));
  }
}

/* ───────── Stats ───────── */

.stats {
  background: var(--ink);
  color: #FFF;
  padding-block: 3rem;
}

.stats-title {
  font-family: var(--body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 2rem;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem 2.5rem;
}

.stat dd {
  font-family: var(--display);
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.02em;
  order: -1;
  margin-bottom: 0.6rem;
}
.stat .plus { color: var(--gold); }

.stat { display: flex; flex-direction: column; }

.stat dt {
  font-size: 0.9375rem;
  line-height: 1.4;
  color: rgba(255,255,255,0.7);
  max-width: 24ch;
}

/* ───────── Sections ───────── */

.section { padding-block: clamp(3.5rem, 9vw, 6.5rem); }
.section-alt { background: var(--cream); }

/* Pillars */

.pillars {
  margin-top: 3.25rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2.5rem;
}

.pillar { border-top: 3px solid var(--magenta); padding-top: 1.5rem; }

.pillar-num {
  display: block;
  font-family: var(--display);
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--magenta);
  letter-spacing: 0.06em;
  margin-bottom: 0.6rem;
}

.pillar h3 {
  font-family: var(--display);
  font-size: 1.4rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 0.6rem;
}

.pillar p { color: var(--ink-soft); }

/* Cards */

.cards {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.25rem;
}
.cards-3 { margin-top: 3rem; }

.card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 1.75rem;
}

.card h3, .card h4 {
  font-family: var(--display);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.card p { color: var(--ink-soft); font-size: 1rem; }

.card-action {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
}
.card-action p { flex: 1; }
.card-action .btn { margin-top: 0.5rem; }

/* Split columns */

.split {
  margin-top: 3.5rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 3rem;
}

.split-col .sub-h { margin-top: 2rem; }
.split-col .sub-h:first-child { margin-top: 0; }
.split-col p { color: var(--ink-soft); }
.split-col strong { color: var(--ink); font-weight: 600; }

.timeline { counter-reset: step; }

.timeline li {
  counter-increment: step;
  position: relative;
  padding-left: 2.75rem;
  padding-bottom: 1.1rem;
  color: var(--ink-soft);
}

.timeline li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0.05rem;
  width: 1.75rem;
  height: 1.75rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--violet);
  color: #FFF;
  font-size: 0.8125rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.timeline li::after {
  content: "";
  position: absolute;
  left: 0.8125rem;
  top: 2rem;
  bottom: 0.15rem;
  width: 2px;
  background: var(--rule);
}
.timeline li:last-child { padding-bottom: 0; }
.timeline li:last-child::after { display: none; }

/* Callout */

.callout {
  margin-top: 3.5rem;
  background: var(--surface);
  border-left: 5px solid var(--gold);
  border-radius: 6px;
  padding: 1.75rem 2rem;
  box-shadow: 0 1px 3px rgba(23, 19, 32, 0.06);
}

.callout h3 {
  font-family: var(--display);
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.callout p { color: var(--ink-soft); }

/* ───────── Events ───────── */

.events {
  margin-top: 3rem;
  display: grid;
  gap: 1.25rem;
}

.event {
  display: flex;
  gap: 1.75rem;
  align-items: flex-start;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 1.75rem;
}

.event-date {
  flex: none;
  width: 5rem;
  text-align: center;
  background: var(--violet);
  color: #FFF;
  border-radius: 10px;
  padding: 0.75rem 0.5rem;
}

.event-month {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

.event-day {
  display: block;
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 600;
  line-height: 1.1;
}

.event-body h3 {
  font-family: var(--display);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.event-meta {
  color: var(--magenta);
  font-size: 0.9375rem;
  font-weight: 600;
  margin: 0.2rem 0 0.6rem;
}

.event-body > p:last-child { color: var(--ink-soft); font-size: 1rem; }

@media (max-width: 480px) {
  .event { flex-direction: column; gap: 1.1rem; }
  .event-date { width: auto; display: inline-flex; gap: 0.6rem; align-items: baseline; padding: 0.5rem 1rem; }
  .event-day { font-size: 1.4rem; }
}

/* ───────── Team ───────── */

.team {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1.5rem 2rem;
}

.member {
  border-top: 1px solid var(--rule);
  padding-top: 1rem;
}

.member-name {
  font-family: var(--display);
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: -0.005em;
}

.member-role {
  font-size: 0.9375rem;
  color: var(--ink-faint);
  margin-top: 0.1rem;
}

/* ───────── Get involved ───────── */

.involve { border-top: 1px solid var(--rule); }
.involve .section-title { max-width: none; }

/* ───────── Footer ───────── */

.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.72);
  padding-top: clamp(3rem, 7vw, 4.5rem);
  font-size: 0.9375rem;
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 2fr;
  gap: 3rem;
  padding-bottom: 3rem;
}

.footer-logo {
  width: auto;
  height: 62px;
  margin-bottom: 1.25rem;
}

.footer-note { max-width: 34ch; line-height: 1.6; }

/* Registered address and EIN — required for nonprofit verification.
   The lines are block-level elements so they stack correctly even if the
   stylesheet fails or is served stale from cache. */
.footer-org {
  margin-top: 1.5rem;
  font-style: normal;
  font-size: 0.875rem;
  line-height: 1.6;
  color: rgba(255,255,255,0.58);
}

.footer-org-line { display: block; margin: 0; }

.footer-ein {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 2rem;
}

.footer-col h2 {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  margin-bottom: 0.9rem;
}

.footer-col li { margin-bottom: 0.55rem; }

.footer-col a {
  color: rgba(255,255,255,0.82);
  text-decoration: none;
}
.footer-col a:hover { color: #FFF; text-decoration: underline; text-underline-offset: 3px; }

.footer-base {
  border-top: 1px solid rgba(255,255,255,0.14);
  padding-block: 1.5rem;
  font-size: 0.875rem;
  color: rgba(255,255,255,0.55);
}

@media (max-width: 760px) {
  .footer-inner { grid-template-columns: 1fr; gap: 2.5rem; }
}
