/* ==========================================================================
   coodu-home.css  —  HOME PAGE section-level layout ONLY
   --------------------------------------------------------------------------
   Owns: hero composition, impact overlap, section grids/spacing, the
   get-involved + planet dark bands, and the home-only sub-components
   (hero/story dots & arrows, gi-card, planet chip). Shared components
   (.btn, .card, .stat, .eyebrow, .icon-chip, .img-slot, .section, .section-head,
   header / drawer / mega / footer) are owned by coodu-components.css — never
   restyled here except for the few scoped colour overrides the dark bands
   require (white headings / amber eyebrow on dark), which are page composition.

   Mobile-first. Enhance up with min-width only. Breakpoints: 600 / 900 / 1200.
   All motion is gated behind prefers-reduced-motion inside coodu-motion.css.
   ========================================================================== */

/* ==========================================================================
   1. HERO A — dark field-photo banner
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  min-height: clamp(440px, 78vh, 566px);
  color: var(--surface);
  /* photo-banner composition colours (not part of the shared token set) */
  --hero-from: #2c5a3c;
  --hero-to: #10271a;
  background: linear-gradient(160deg, var(--hero-from), var(--hero-to));
}

.hero__layers {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* faint diagonal weave — placeholder for the rotating field photo */
.hero__texture {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.035) 0 14px,
    rgba(0, 0, 0, 0.05) 14px 28px
  );
}

/* legibility scrim — vertical on mobile, horizontal (left-weighted) on desktop */
.hero__scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 26, 15, 0.5), rgba(8, 26, 15, 0.82));
}

.hero__note {
  position: absolute;
  top: 14px;
  right: 16px;
  font-family: var(--font-display);
  font-size: 0.625rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.hero .container {
  position: relative;
  z-index: 2;
}

.hero__content {
  max-width: 616px;
  padding-block: clamp(40px, 9vw, 72px);
}

/* amber eyebrow on the dark hero (component is green on light by default) */
.hero .eyebrow {
  color: var(--color-amber-light);
  margin-bottom: var(--s2);
}

.hero__title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-h1);
  line-height: 1.08;
  color: var(--surface);
}

.hero__sub {
  max-width: 540px;
  margin: var(--s3) 0 0;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.hero__actions {
  display: flex;
  flex-direction: column;
  gap: 11px;
  margin-top: var(--s4);
}
.hero__actions .btn {
  width: 100%;
  justify-content: center;
}

/* Hero secondary (Donate): solid accent on mobile to match the mobile render */
.hero .btn--outline {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--surface);
}

.hero__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: var(--s4) 0 0;
  font-size: var(--fs-small);
  color: rgba(255, 255, 255, 0.78);
}
.hero__meta i { width: 16px; height: 16px; }
.hero__meta-dot {
  width: 4px;
  height: 4px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.6);
}

.hero__dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 20px;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: 8px;
}
.hero__dot {
  width: 6px;
  height: 6px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
}
.hero__dot.is-active {
  width: 26px;
  background: var(--color-amber);
}

@media (min-width: 600px) {
  .hero__actions {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 14px;
  }
  .hero__actions .btn { width: auto; }
  /* restore the ghost-on-dark treatment for the secondary at tablet+ */
  .hero .btn--outline {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.6);
    color: var(--surface);
  }
  .hero .btn--outline:hover {
    background: var(--surface);
    color: var(--hero-to);
    border-color: var(--surface);
  }
}

@media (min-width: 900px) {
  .hero {
    background: linear-gradient(135deg, #2c5a3c, #12301e);
  }
  .hero__scrim {
    background: linear-gradient(
      90deg,
      rgba(8, 26, 15, 0.9) 0%,
      rgba(8, 26, 15, 0.62) 46%,
      rgba(8, 26, 15, 0.18) 100%
    );
  }
}

/* ==========================================================================
   2. IMPACT STAT BAND — floating card that overlaps the hero on desktop
   ========================================================================== */
.impact {
  position: relative;
  z-index: 3;
  background: transparent;
  padding-block: clamp(28px, 7vw, 40px);
}

.impact__eyebrow {
  display: block;
  text-align: center;
  margin: 0 0 var(--s3);
}

.impact__card {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s2);
}

.impact .stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 18px 14px;
  text-align: center;
  background: rgba(255, 255, 255, 0.62);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: var(--radius-card);
}

.impact__caption {
  margin: var(--s3) 0 0;
  text-align: center;
  font-size: var(--fs-small);
  color: var(--text-muted);
}

@media (min-width: 900px) {
  .impact__card { grid-template-columns: repeat(4, 1fr); }
}

@media (min-width: 1200px) {
  .impact { padding-top: 0; }
  .impact__eyebrow { display: none; }
  /* four cells become one divided slab, lifted up over the hero */
  .impact__card {
    gap: 0;
    margin-top: -54px;
    background: rgba(255, 255, 255, 0.62);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 14px;
    box-shadow: var(--shadow-2);
  }
  /* stats sit directly on the frosted slab — no per-cell fill */
  .impact .stat { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
  .impact .stat {
    border: 0;
    border-right: 1px solid var(--border);
    border-radius: 0;
    padding: 28px 24px;
  }
  .impact .stat:last-child { border-right: 0; }
}

/* ==========================================================================
   3. WHO WE ARE + VIDEO
   ========================================================================== */
.about-intro__grid {
  display: grid;
  gap: var(--s4);
  align-items: center;
}

.about-intro__media {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-2);
  background: #0f1f15;
}
.about-intro__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.about-intro__play {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--color-primary);
  box-shadow: var(--shadow-2);
  cursor: pointer;
}
.about-intro__play i { width: 26px; height: 26px; }

.about-intro__content .eyebrow { margin-bottom: var(--s2); }

.about-intro__title {
  margin: 0 0 var(--s2);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-h2);
  line-height: 1.16;
  color: var(--color-primary);
}
.about-intro__amber { color: var(--color-amber-text); }

.about-intro__text {
  max-width: 560px;
  margin: 0 0 var(--s3);
  color: var(--text-body);
}

@media (min-width: 900px) {
  .about-intro__grid {
    grid-template-columns: 1.04fr 1fr;
    gap: clamp(32px, 5vw, 54px);
  }
  .about-intro__play { width: 74px; height: 74px; }
  .about-intro__play i { width: 30px; height: 30px; }
}

/* ==========================================================================
   4. CORE PROGRAMS — fluid auto-fit card grid (1 -> 2 -> 3)
   ========================================================================== */
/* Transparent so the leaf background shows through (cards stay solid + readable). */
.programs.section--alt { background: transparent; border-block: 0; }

.programs__grid {
  display: grid;
  gap: clamp(16px, 2.4vw, 26px);
  margin-top: clamp(28px, 4vw, 44px);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}

.programs__more {
  display: flex;
  justify-content: center;
  margin-top: clamp(28px, 4vw, 40px);
}

/* ==========================================================================
   5. STORIES OF TRANSFORMATION — testimonial carousel
   ========================================================================== */
.stories__carousel { margin-top: clamp(24px, 4vw, 40px); }

.stories__slides { position: relative; }

.story {
  display: grid;
  grid-template-columns: 1fr;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-2);
}
.story[hidden] { display: none; }

.story__media {
  position: relative;
  min-height: 220px;
}
.story__cat {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: var(--color-primary);
  color: var(--surface);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.story__panel {
  display: flex;
  flex-direction: column;
  gap: var(--s2);
  padding: clamp(22px, 4vw, 42px);
}
.story__mark {
  font-family: var(--font-display);
  font-size: clamp(40px, 6vw, 64px);
  line-height: 0.5;
  color: var(--color-amber);
}
.story__quote {
  margin: 0;
  font-size: clamp(1.0625rem, 1.6vw, 1.3125rem);
  line-height: 1.5;
  font-weight: 500;
  color: var(--text-strong);
}
.story__author {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: var(--s1);
}
.story__avatar {
  flex: none;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-pill);
  background: var(--surface-tint);
  color: var(--color-primary);
  font-family: var(--font-display);
  font-weight: 600;
}
.story__name {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text-strong);
}
.story__meta {
  display: block;
  font-size: var(--fs-small);
  color: var(--text-muted);
}

.stories__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--s3);
  margin-top: var(--s3);
}
.stories__dots { display: flex; gap: 8px; }
.stories__dot {
  width: 6px;
  height: 6px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-pill);
  background: #cdd6cd;
  cursor: pointer;
}
.stories__dot.is-active {
  width: 20px;
  background: var(--color-primary);
}
.stories__arrows {
  display: none;
  gap: 10px;
}
.stories__arrow {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text-muted);
  cursor: pointer;
}
.stories__arrow--next {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--surface);
}

@media (min-width: 900px) {
  .story {
    grid-template-columns: 0.92fr 1.08fr;
  }
  .story__media { min-height: 340px; }
  .stories__controls { justify-content: space-between; }
  .stories__dot.is-active { width: 22px; }
  .stories__arrows { display: flex; }
}

/* ==========================================================================
   6. DUAL "GET INVOLVED" CTA BAND (green)
   ========================================================================== */
.get-involved {
  /* Warm sand band — the brand's amber partner to green. Breaks the green wall:
     trio becomes WARM get-involved -> GREEN planet -> DEEP-GREEN footer. */
  background: linear-gradient(135deg, #fbf1de 0%, #f6e7c8 100%);
  color: var(--text-body);
  border-block: 1px solid #efe2c4;
  padding-block: clamp(48px, 8vw, 84px);
}
.get-involved .eyebrow { color: var(--color-amber-text); }
.get-involved .section-head__title { color: var(--text-strong); }
.get-involved .section-head__sub { color: var(--text-body); }

.gi-grid {
  display: grid;
  gap: clamp(16px, 2.4vw, 24px);
  margin-top: clamp(26px, 4vw, 40px);
}

.gi-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s2);
  padding: clamp(26px, 3.4vw, 38px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  color: var(--text-body);
  box-shadow: var(--shadow-1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.gi-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-2);
}
.gi-card__title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-h3);
  color: var(--text-strong);
}
.gi-card__text {
  margin: 0;
  line-height: 1.6;
  color: var(--text-body);
}
.gi-card .btn { margin-top: var(--s1); }

@media (min-width: 900px) {
  .gi-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--s3);
    align-items: stretch;
  }
  .gi-card { gap: var(--s3); }
  /* Equal-height cards: pin the button to the foot so the two CTAs line up. */
  .gi-card .btn { margin-top: auto; }
}

/* ==========================================================================
   7. "WE HAVE ONLY ONE PLANET" DARK COUNTER BAND
   ========================================================================== */
.planet {
  /* BRIGHT layer (2 of 3) — the hero of the trio. Fresh mid-emerald, lighter than
     the deep get-involved band above and the footer below so all three read as
     distinct. A crisp top highlight lifts the bright band off the deep one. */
  position: relative;
  background: linear-gradient(160deg, #1f8442 0%, #135c31 100%);
  color: var(--surface);
  overflow: hidden;
  /* Tallest band of the three so it commands the eye as the section hero. */
  padding-block: clamp(60px, 10vw, 112px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14);
}
.planet__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(28px, 6vw, 44px);
  align-items: center;
}
.planet__visual {
  position: relative;
  display: grid;
  place-items: center;
}
/* Soft halo behind the globe so it reads as a focal object on the bright band. */
.planet__visual::before {
  content: "";
  position: absolute;
  width: 116%;
  max-width: 560px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0) 72%);
  pointer-events: none;
}
.planet__globe {
  position: relative;
  width: min(330px, 76vw);
  height: min(330px, 76vw);
  display: block;
  filter: drop-shadow(0 22px 36px rgba(0, 0, 0, 0.32));
}
.planet__body { min-width: 0; }

.planet .section-head--left {
  text-align: left;
  max-width: none;
  margin: 0 0 clamp(20px, 3vw, 26px);
  align-items: flex-start;
}
.planet .section-head--left::after { margin-left: 0; margin-right: auto; }
.planet .section-head__title { color: var(--surface); }
.planet .section-head__sub { color: rgba(255, 255, 255, 0.74); margin: 0; }

.planet__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(12px, 2vw, 18px);
  margin-top: 0;
}
.planet .stat {
  padding: clamp(18px, 2.2vw, 24px) clamp(16px, 2vw, 22px);
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  transition: background 0.25s ease, border-color 0.25s ease;
}
.planet .stat:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.24);
}
.planet .stat__num {
  color: var(--color-amber);
  font-weight: 700;
}
.planet .stat__label {
  color: rgba(255, 255, 255, 0.74);
  letter-spacing: 0.01em;
}

.planet__caption {
  margin: clamp(20px, 3vw, 28px) 0 0;
  text-align: left;
  font-size: var(--fs-small);
  color: rgba(255, 255, 255, 0.52);
}

/* Tablet: stacked but composed — cap the globe so it does not dominate. */
@media (min-width: 600px) {
  .planet__globe { width: min(380px, 52vw); height: min(380px, 52vw); }
}

/* Desktop: globe left / content right, the band's defining two-column balance. */
@media (min-width: 900px) {
  .planet__inner { grid-template-columns: 0.92fr 1.32fr; gap: clamp(40px, 5vw, 72px); }
  .planet__globe { width: min(440px, 36vw); height: min(440px, 36vw); }
}
