/* ================================================================
   BUILT TO RISE FOUNDATION
   Global Design System · Navigation · Footer
   ================================================================ */

/* === TOKENS ===================================================== */
:root {
  --purple:       #3D1A5E;
  --purple-dark:  #27103D;
  --gold:         #C9922A;
  --gold-warm:    #D9A840;
  --gold-light:   #E4B456;
  --gold-pale:    #F5E5C0;
  --cream:        #FAF7F2;
  --cream-warm:   #FDF8EE;
  --white:        #FFFFFF;

  --text-head:    #1E0A35;
  --text-body:    #3D2E50;
  --text-muted:   #7A6888;

  --serif:        'Playfair Display', Georgia, serif;
  --sans:         'DM Sans', 'Helvetica Neue', Arial, sans-serif;

  --nav-h:        124px;
  --max-w:        1300px;
  --pad-x:        clamp(1.25rem, 5vw, 3.5rem);

  --ease-fast:    0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --ease-base:    0.32s cubic-bezier(0.4, 0, 0.2, 1);

  --shadow-nav:   0 1px 0 rgba(61,26,94,0.07), 0 6px 24px rgba(61,26,94,0.06);
  --shadow-card:  0 4px 28px rgba(61,26,94,0.10);
  --shadow-lift:  0 14px 48px rgba(61,26,94,0.18);

  --radius-sm:    4px;
  --radius-pill:  999px;
}

/* === RESET ====================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.68;
  color: var(--text-body);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: var(--sans); cursor: pointer; border: none; background: none; }
input, textarea, select { font-family: var(--sans); }

/* === TYPOGRAPHY ================================================= */
h1,h2,h3,h4,h5,h6 {
  font-family: var(--serif);
  font-weight: 700;
  line-height: 1.13;
  color: var(--text-head);
  letter-spacing: -0.025em;
}
h1 { font-size: clamp(2.75rem, 6.5vw, 5.75rem); }
h2 { font-size: clamp(2rem,   4vw,   3.5rem);   }
h3 { font-size: clamp(1.4rem, 2.5vw, 2.125rem); }
h4 { font-size: 1.1875rem; }
p  { max-width: 68ch; }

.eyebrow {
  display: block;
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.875rem;
}

/* === LAYOUT ===================================================== */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

/* === BUTTONS ==================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  font-family: var(--sans);
  font-size: 0.9125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 0.875rem 2.25rem;
  border-radius: var(--radius-pill);
  border: 2px solid transparent;
  transition: all var(--ease-base);
  cursor: pointer;
  white-space: nowrap;
}
.btn-gold {
  background: var(--gold);
  color: var(--white);
  border-color: var(--gold);
}
.btn-gold:hover {
  background: #B5811E;
  border-color: #B5811E;
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(201,146,42,0.38);
}
.btn-outline-white {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,0.6);
}
.btn-outline-white:hover {
  border-color: var(--gold-light);
  color: var(--gold-light);
  transform: translateY(-2px);
}

/* === ACCESSIBILITY ============================================== */
.skip-link {
  position: absolute;
  top: -120%;
  left: 1.5rem;
  z-index: 9999;
  background: var(--gold);
  color: var(--white);
  font-weight: 700;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-sm);
  transition: top var(--ease-fast);
}
.skip-link:focus { top: 1.25rem; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

/* ================================================================
   NAVIGATION
   ================================================================ */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 900;
  height: var(--nav-h);
  transition: background var(--ease-base), box-shadow var(--ease-base);
}

/* — Transparent state (over hero) — */
.site-nav.nav-transparent {
  background: transparent;
}
.site-nav.nav-transparent .nav-link {
  color: rgba(255,255,255,0.90);
}
.site-nav.nav-transparent .nav-link:hover,
.site-nav.nav-transparent .nav-link.active {
  color: var(--gold-light);
}
.site-nav.nav-transparent .nav-toggle span {
  background: rgba(255,255,255,0.90);
}

/* — Solid state (on scroll) — */
.site-nav.nav-solid {
  background: var(--cream);
  box-shadow: var(--shadow-nav);
}
.site-nav.nav-solid .nav-link {
  color: var(--text-head);
}
.site-nav.nav-solid .nav-link:hover,
.site-nav.nav-solid .nav-link.active {
  color: var(--gold);
}
.site-nav.nav-solid .nav-toggle span {
  background: var(--purple);
}

/* — Nav inner layout — */
.nav-inner {
  display: flex;
  align-items: center;
  height: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

/* — Logo — */
.nav-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-right: 2rem;
}
.nav-logo img {
  height: 168px;
  width: auto;
  /* Pull up & left to offset the whitespace baked into the PNG */
  margin-top: -16px;
  margin-left: -18px;
  transition: opacity var(--ease-fast);
}
.nav-logo:hover img { opacity: 0.82; }

/* — Desktop links — */
.nav-links {
  display: flex;
  align-items: center;
  gap: 0;
  margin-left: auto;
  margin-right: 1.5rem;
}
.nav-link {
  position: relative;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  padding: 0.5rem 0.875rem;
  border-radius: var(--radius-sm);
  transition: color var(--ease-fast);
  white-space: nowrap;
}
/* Slide-in underline on hover/active */
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 0.875rem;
  right: 0.875rem;
  height: 1.5px;
  border-radius: 2px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--ease-fast);
}
.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

/* — Donate button — */
.nav-donate {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 0.6rem 1.625rem;
  border-radius: var(--radius-pill);
  background: var(--gold);
  color: var(--white);
  transition: all var(--ease-base);
}
.nav-donate:hover {
  background: #B5811E;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(201,146,42,0.42);
}

/* — Hamburger toggle — */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 8px;
  border-radius: var(--radius-sm);
  margin-left: auto;
  transition: opacity var(--ease-fast);
  flex-shrink: 0;
}
.nav-toggle:hover { opacity: 0.65; }
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 2px;
  transition: all var(--ease-base);
  transform-origin: center;
}
/* Bars → X animation */
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ================================================================
   MOBILE OVERLAY
   ================================================================ */
.nav-overlay {
  position: fixed;
  inset: 0;
  z-index: 890;
  background: var(--purple-dark);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--ease-base), visibility var(--ease-base);
}
.nav-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

/* Header row inside overlay */
.overlay-header {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-inline: var(--pad-x);
}
.overlay-logo img {
  height: 46px;
  width: auto;
  background: rgba(255,255,255,0.06);
  padding: 6px 10px;
  border-radius: 6px;
}
.overlay-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 1.125rem;
  color: rgba(255,255,255,0.5);
  transition: all var(--ease-fast);
}
.overlay-close:hover {
  color: var(--gold-light);
  background: rgba(255,255,255,0.07);
}

/* Overlay links */
.overlay-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  text-align: center;
  width: 100%;
}
.overlay-link {
  font-family: var(--serif);
  font-size: clamp(2rem, 7vw, 3rem);
  font-weight: 600;
  color: rgba(255,255,255,0.78);
  padding: 0.4rem 2rem;
  display: block;
  letter-spacing: -0.02em;
  transition: color var(--ease-fast);
}
.overlay-link:hover { color: var(--gold-light); }
.overlay-donate {
  display: inline-flex;
  align-items: center;
  margin-top: 1.75rem;
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.875rem 2.75rem;
  border-radius: var(--radius-pill);
  background: var(--gold);
  color: var(--white);
  transition: background var(--ease-fast);
}
.overlay-donate:hover { background: var(--gold-warm); }

/* ================================================================
   FOOTER
   ================================================================ */
.site-footer {
  background: var(--purple-dark);
  color: rgba(255,255,255,0.88);
}

/* Three-column grid */
.footer-body {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--pad-x);
  padding-top: 5rem;
  padding-bottom: 4.5rem;
  display: grid;
  grid-template-columns: 1.55fr 1fr 1fr;
  gap: 3rem 5rem;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

/* — Brand column — */
.footer-logo {
  height: 120px;
  width: auto;
  /* Frosted white pill so logo reads clearly on dark purple */
  background: rgba(255,255,255,0.96);
  border-radius: 14px;
  padding: 6px 18px;
  margin-bottom: 1.5rem;
  /* Offset PNG whitespace so logo mark sits snug in the pill */
  margin-left: -8px;
  box-shadow: 0 2px 16px rgba(0,0,0,0.18);
}
.footer-desc {
  font-size: 0.9375rem;
  line-height: 1.78;
  color: rgba(255,255,255,0.42);
  max-width: 30ch;
  margin-bottom: 2rem;
}
/* Scripture — the centrepiece of the footer */
.footer-scripture {
  font-family: var(--serif);
  font-size: 1.05rem;
  font-style: italic;
  color: var(--gold-light);
  line-height: 1.65;
  max-width: 33ch;
  padding-left: 1.125rem;
  border-left: 3px solid var(--gold);
  margin: 0;
}
.footer-scripture cite {
  display: block;
  margin-top: 0.75rem;
  font-family: var(--sans);
  font-style: normal;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.30);
}

/* — Link columns — */
.footer-col-heading {
  font-family: var(--sans);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.30);
  margin-bottom: 1.5rem;
}
.footer-col a {
  display: block;
  font-size: 0.9375rem;
  color: rgba(255,255,255,0.60);
  padding: 0.3rem 0;
  transition: color var(--ease-fast);
}
.footer-col a:hover { color: var(--gold-light); }
.footer-col address {
  font-style: normal;
  font-size: 0.9375rem;
  line-height: 1.85;
  color: rgba(255,255,255,0.38);
  margin-top: 0.25rem;
}

/* — Copyright bar — */
.footer-bottom {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--pad-x);
  padding-block: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer-bottom p,
.footer-bottom a {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.22);
  max-width: none;
}
.footer-bottom a:hover { color: rgba(255,255,255,0.5); }

/* ================================================================
   CARD HOVER (global pattern)
   ================================================================ */
.card-hover {
  transition: transform var(--ease-base), box-shadow var(--ease-base);
}
.card-hover:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lift);
}

/* ================================================================
   RESPONSIVE — Nav
   ================================================================ */
@media (max-width: 960px) {
  .nav-links  { display: none; }
  .nav-donate { display: none; }
  .nav-toggle { display: flex; margin-left: auto; }
  .nav-logo   { margin-right: 0; }
}

/* ================================================================
   RESPONSIVE — Footer
   ================================================================ */
@media (max-width: 860px) {
  .footer-body {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem 3rem;
  }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 540px) {
  .footer-body { grid-template-columns: 1fr; }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }
}

/* AOS pointer-events fix */
[data-aos] { pointer-events: none; }
[data-aos].aos-animate { pointer-events: auto; }
