/* ==========================================================================
   CHV Fall Match landing page — page-scoped styles
   Figma: "2026 Fall Campaign Landing Page" › DRAFT 3
   --------------------------------------------------------------------------
   - Loaded ONLY on pages whose content contains "chvm-" (see enqueue PHP).
   - Every rule is scoped under .chvm (set on each section of this page), so
     nothing here can reach the header, footer, other blocks or other pages.
   - No !important: ".chvm .chvm-x" (0,2,0) outranks theme rules such as
     ".entry-content h2" / ".content p" (0,1,1).
   ========================================================================== */

/* ---------- 1. Design tokens (from Figma) ---------- */
.chvm {
  --chvm-blue: #0067ff;
  --chvm-blue-dark: #0052cc;
  --chvm-yellow: #ffe653;
  --chvm-yellow-tint: #fffadd;       /* #ffe653 at 20% on white */
  --chvm-ink: #000000;
  --chvm-white: #ffffff;
  --chvm-polaroid: #f1f1f1;

  --chvm-serif: 'P22 Mackinac Pro', Georgia, serif;
  --chvm-sans: 'GT America', Helvetica, Arial, sans-serif;
  /* Site only loads GT America / Mono / Mackinac. If "GT America Condensed" is
     added later it is picked up automatically; until then GT America is used. */
  --chvm-cond: 'GT America Condensed', 'GT America', 'Arial Narrow', sans-serif;
  --chvm-mono: 'GT America Mono', 'GT America', monospace;

  /* H1 — Mackinac Extra Bold 72 / 74 */
  --chvm-h1-size: clamp(42px, 31.4px + 2.82vw, 72px);
  --chvm-h1-lh: 1.03;
  /* H2 — Mackinac Medium 28 / 36 */
  --chvm-h2-size: clamp(20px, 17.2px + 0.75vw, 28px);
  --chvm-h2-lh: 1.286;
  /* Body — GT America Regular 20 / 30 */
  --chvm-body-size: clamp(17px, 15.97px + 0.28vw, 20px);
  --chvm-body-lh: 1.5;

  --chvm-max: 1062px;                /* Figma content width (x 189 → 1251) */
  --chvm-pad-y: clamp(64px, 8vw, 120px);
  --chvm-pad-x: 24px;

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

/* Theme guards — sections butt together (no block-gap strips) and theme
   image styles (borders, shadows, radius) can't reach this page's images */
section.chvm,
div.chvm { margin-top: 0; margin-bottom: 0; }
.chvm img,
.chvm-stories .chvst-image { border: 0; box-shadow: none; }

/* ---------- Full-width backgrounds ----------
   The theme keeps page content inside its content box. Content stays that
   width; each section's BACKGROUND is painted edge to edge by a 100vw layer
   behind it. --chvm-sbw (scrollbar width, set by chv-match.js) keeps the
   layer exactly viewport-wide, and overflow-x: clip (this page only) stops
   any sideways scroll. */
html:has(.chvm),
html:has(.chvm) body { overflow-x: clip; }

/* The theme wraps every block in e.g.
   <div class="container core-html p-xs-2 p-md-0 mt-4 mb-4">. Its mt-4 / mb-4 /
   p-* utilities are !important, so they need !important to undo — limited to
   block wrappers that hold this page's sections. */
[class*="core-"]:has(.chvm),
[class*="core-"]:has(.chvst) {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}
.core-html:has(> .chvm),
.core-html:has(> .chvst),
[class*="core-"]:has(> .chvst) {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.wp-block-group:has(.chvm),
.wp-block-group:has(.chvst) {     /* theme/WP padding on the wrapper groups */
  padding: 0;
  margin-top: 0;
  margin-bottom: 0;
}

.chvm.chvm-intro,
.chvm.chvm-impact,
.chvm.chvm-why,
.chvm.chvm-supporters,
.chvm.chvm-cta {
  position: relative;
  isolation: isolate;
  background: transparent;
}
.chvm.chvm-intro::before,
.chvm.chvm-impact::before,
.chvm.chvm-why::before,
.chvm.chvm-why::after,
.chvm.chvm-supporters::before,
.chvm.chvm-cta::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 0;
  bottom: 0;
  left: 50%;
  width: calc(100vw - var(--chvm-sbw, 0px));
  transform: translateX(-50%);
  pointer-events: none;
}
.chvm.chvm-intro::before      { background: var(--chvm-white); }
.chvm.chvm-impact::before     { background: var(--chvm-yellow-tint); }
.chvm.chvm-supporters::before { background: var(--chvm-yellow-tint); }
.chvm.chvm-cta::before        { background: var(--chvm-yellow); }
/* Why we care: yellow block with rounded bottom corners sitting on cream */
.chvm.chvm-why::before        { background: var(--chvm-yellow-tint); }
.chvm.chvm-why::after         { background: var(--chvm-yellow); border-radius: 0 0 30px 30px; }

/* Smooth anchor scrolling — this page only */
html:has(.chvm) { scroll-behavior: smooth; }
#donatesection,
#chv-give { scroll-margin-top: 120px; }

/* ---------- 2. Type styles ---------- */
.chvm .chvm-h1 {
  font-family: var(--chvm-serif);
  font-weight: 800;
  font-style: normal;
  font-size: var(--chvm-h1-size);
  line-height: var(--chvm-h1-lh);
  letter-spacing: 0;
  text-transform: none;
  color: var(--chvm-blue);
  margin: 0 0 40px;
  padding: 0;
}

.chvm .chvm-h2 {
  font-family: var(--chvm-serif);
  font-weight: 500;
  font-style: normal;
  font-size: var(--chvm-h2-size);
  line-height: var(--chvm-h2-lh);
  letter-spacing: 0;
  text-transform: none;
  color: var(--chvm-ink);
  margin: 0 0 20px;
  padding: 0;
}
.chvm .chvm-h2:last-child { margin-bottom: 0; }
.chvm .chvm-h2--blue { color: var(--chvm-blue); }

.chvm .chvm-body {
  font-family: var(--chvm-sans);
  font-weight: 400;
  font-style: normal;
  font-size: var(--chvm-body-size);
  line-height: var(--chvm-body-lh);
  color: var(--chvm-ink);
  margin: 0 0 20px;
  padding: 0;
}

.chvm .chvm-hl {
  color: var(--chvm-blue);
  font-weight: 700;
}

/* ---------- 3. Button (Figma "donate button - blue") ---------- */
.chvm .chvm-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 51px;
  padding: 0 28px;
  background: var(--chvm-blue);
  color: var(--chvm-yellow);
  font-family: var(--chvm-mono);
  font-weight: 500;
  font-size: 20px;
  line-height: 1;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  border: 0;
  border-radius: 100px;
  box-shadow: none;
  cursor: pointer;
  transition: background-color .2s ease, transform .2s ease;
}
.chvm .chvm-btn:hover,
.chvm .chvm-btn:focus-visible {
  background: var(--chvm-blue-dark);
  color: var(--chvm-yellow);
  text-decoration: none;
  transform: translateY(-2px);
}
.chvm .chvm-btn:focus-visible {
  outline: 3px solid var(--chvm-ink);
  outline-offset: 3px;
}

/* ==========================================================================
   SECTION: Intro — "We take care of each other." + rolling images
   ========================================================================== */
.chvm.chvm-intro {
  padding: var(--chvm-pad-y) var(--chvm-pad-x);
}
.chvm .chvm-intro__inner {
  max-width: var(--chvm-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 628px) 410px;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
}
.chvm .chvm-intro__content .chvm-btn-row { margin-top: 36px; }

/* Rolling gallery — bleeds to the top and bottom edge of the section, like Figma.
   JS clones the set for a seamless loop and adds .is-looping. */
.chvm .chvm-gallery {
  position: relative;
  align-self: stretch;
  contain: size;             /* the column follows the text height instead of the image stack */
  margin: calc(var(--chvm-pad-y) * -1) 0;
}
.chvm .chvm-gallery__viewport {
  height: 100%;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, transparent 6%, #000 24%, #000 76%, transparent 94%, transparent 100%);
          mask-image: linear-gradient(to bottom, transparent 0, transparent 6%, #000 24%, #000 76%, transparent 94%, transparent 100%);
}
.chvm .chvm-gallery__track {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
}
.chvm .chvm-gallery.is-looping .chvm-gallery__track {
  animation: chvm-scroll var(--chvm-loop-duration, 8s) linear infinite;
  will-change: transform;
}
.chvm .chvm-gallery.is-looping:hover .chvm-gallery__track,
.chvm .chvm-gallery.is-paused .chvm-gallery__track { animation-play-state: paused; }

.chvm .chvm-gallery__item {
  margin: 0 0 24px;
  padding: 0;
  border-radius: 15px;
  overflow: hidden;
  aspect-ratio: 410 / 323;
  background: var(--chvm-yellow);
}
.chvm .chvm-gallery__item img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  margin: 0;
  border-radius: 0;
}

/* Pause / play control (WCAG 2.2.2 — auto-moving content must be pausable) */
.chvm .chvm-gallery__toggle {
  position: absolute;
  right: 10px;
  bottom: calc(var(--chvm-pad-y) * 0.35);
  z-index: 2;
  width: 36px;
  height: 36px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: var(--chvm-blue);
  color: var(--chvm-yellow);
  cursor: pointer;
  opacity: 0;                 /* appears on hover or keyboard focus */
  transition: opacity .2s ease;
}
.chvm .chvm-gallery:hover .chvm-gallery__toggle,
.chvm .chvm-gallery.is-paused .chvm-gallery__toggle,
.chvm .chvm-gallery__toggle:focus-visible { opacity: 1; }
.chvm .chvm-gallery__toggle:focus-visible { outline: 3px solid var(--chvm-ink); outline-offset: 2px; }
.chvm .chvm-gallery__toggle svg { width: 14px; height: 14px; display: block; fill: currentColor; }
.chvm .chvm-gallery__toggle .chvm-icon-play { display: none; }
.chvm .chvm-gallery.is-paused .chvm-gallery__toggle .chvm-icon-play { display: block; }
.chvm .chvm-gallery.is-paused .chvm-gallery__toggle .chvm-icon-pause { display: none; }

@keyframes chvm-scroll {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(0, -50%, 0); }
}

/* ==========================================================================
   SECTION: Campaign video (item 6) — poster + Figma play ring, YouTube on click
   ========================================================================== */
.chvm.chvm-video {
  position: relative;
  width: calc(100vw - var(--chvm-sbw, 0px));      /* full width, out of the theme content box */
  max-width: none;
  margin: 0 0 0 calc(50% - (100vw - var(--chvm-sbw, 0px)) / 2);
  aspect-ratio: 16 / 9;            /* Figma 1440 × 810 */
  background: #000;
  overflow: hidden;
}
.chvm .chvm-video__link,
.chvm.chvm-video iframe {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  margin: 0;
}
.chvm .chvm-video__link { color: var(--chvm-white); cursor: pointer; }
.chvm .chvm-video__poster {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  margin: 0;
  border-radius: 0;
}
.chvm .chvm-video__play {
  position: absolute;
  top: 50%;
  left: 50%;
  width: clamp(88px, 15.35vw, 221px);   /* 221px at 1440 */
  height: clamp(88px, 15.35vw, 221px);
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 2px 12px rgba(0, 0, 0, .25));
  transition: transform .2s ease;
}
.chvm .chvm-video__play svg { display: block; width: 100%; height: 100%; }
.chvm .chvm-video__link:hover .chvm-video__play { transform: translate(-50%, -50%) scale(1.06); }
.chvm .chvm-video__link:focus-visible { outline: 4px solid var(--chvm-yellow); outline-offset: -8px; }

/* Visually hidden, still read by screen readers */
.chvm .chvm-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   SECTION: Impact — "Because you choose to care…" + 3 cards
   ========================================================================== */
.chvm.chvm-impact {
  padding: var(--chvm-pad-y) var(--chvm-pad-x);
}
.chvm .chvm-impact__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 48px;
  max-width: var(--chvm-max);
  margin: 0 auto 64px;
}
.chvm .chvm-impact__copy {
  flex: 1 1 auto;
  max-width: 628px;
}
.chvm .chvm-impact__copy .chvm-h1 { margin-bottom: 32px; }
.chvm .chvm-impact__copy .chvm-h2 { max-width: 563px; }
.chvm .chvm-impact__form {
  flex: 0 0 356px;
  max-width: 356px;
}

/* Cards rise up out of a clipped band (Figma "gom stats" states 0 → $8 → $68 → $130) */
.chvm .chvm-impact__cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 411px));
  justify-content: center;
  gap: 24px;
  max-width: 1281px;
  margin: 0 auto;
  padding-top: 12px;         /* room for the hover lift inside the clip */
  overflow: hidden;
}
.chvm .chvm-card-wrap { display: flex; }

.chvm .chvm-card {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: transform .25s ease;
}
.chvm .chvm-card__top {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  border-radius: 15px;
  padding: 36px 26px 24px;
  transition: box-shadow .25s ease;
}
.chvm .chvm-card--blue .chvm-card__top   { background: var(--chvm-blue); }
.chvm .chvm-card--yellow .chvm-card__top { background: var(--chvm-yellow); }

.chvm .chvm-card__amount {
  display: block;
  font-family: var(--chvm-cond);
  font-stretch: condensed;
  font-weight: 900;
  font-synthesis: weight;
  font-size: 52px;
  line-height: 1;
  color: var(--chvm-yellow);
  margin: 0 0 10px;
}
.chvm .chvm-card--yellow .chvm-card__amount { color: var(--chvm-blue); }

.chvm .chvm-card__label {
  font-family: var(--chvm-cond);
  font-stretch: condensed;
  font-weight: 900;
  font-synthesis: weight;
  font-size: 28px;
  line-height: 30px;
  color: var(--chvm-white);
  margin: 0 0 24px;
  max-width: 311px;
}
.chvm .chvm-card--yellow .chvm-card__label { color: var(--chvm-ink); }

.chvm .chvm-card__img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  aspect-ratio: 360 / 318;
  object-fit: cover;
  border-radius: 10px;
  margin: auto 0 0;
}
.chvm .chvm-card__caption {
  font-family: var(--chvm-sans);
  font-weight: 400;
  font-size: var(--chvm-body-size);
  line-height: var(--chvm-body-lh);
  color: var(--chvm-ink);
  text-align: center;
  margin: 18px 0 0;
}

.chvm a.chvm-card:hover,
.chvm a.chvm-card:focus-visible {
  transform: translateY(-6px);
  text-decoration: none;
  color: inherit;
}
.chvm a.chvm-card:hover .chvm-card__top,
.chvm a.chvm-card:focus-visible .chvm-card__top { box-shadow: 0 14px 30px rgba(0, 0, 0, .16); }
.chvm a.chvm-card:focus-visible {
  outline: 3px solid var(--chvm-blue);
  outline-offset: 4px;
}

/* Scroll-in animation (item 11). Only hidden once JS is running (.chvm-js),
   so the cards can never disappear if the script fails to load. */
.chvm-js .chvm .chvm-reveal {
  transform: translate3d(0, calc(100% + 24px), 0);
  transition: transform .9s cubic-bezier(.16, 1, .3, 1);
}
.chvm-js .chvm .chvm-reveal:nth-child(2) { transition-delay: .35s; }
.chvm-js .chvm .chvm-reveal:nth-child(3) { transition-delay: .7s; }
.chvm-js .chvm .chvm-reveal.is-in { transform: none; }

/* ==========================================================================
   SECTION: Why we care — testimonials with stacked photos
   ========================================================================== */
.chvm.chvm-why {
  padding: var(--chvm-pad-y) var(--chvm-pad-x);
}
.chvm .chvm-why__inner { max-width: var(--chvm-max); margin: 0 auto; }
.chvm .chvm-why__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
  margin-bottom: 72px;
}
.chvm .chvm-why__header .chvm-h1 { margin: 42px 0 0; flex: 0 1 auto; }
.chvm .chvm-why__intro { flex: 0 0 409px; max-width: 409px; margin: 0; }

.chvm .chvm-why__item {
  display: grid;
  grid-template-columns: minmax(0, 626px) 300px;
  justify-content: space-between;
  align-items: center;
  gap: 40px;
}
.chvm .chvm-why__item + .chvm-why__item { margin-top: 110px; }
.chvm .chvm-why__item--right { grid-template-columns: 300px minmax(0, 626px); }
.chvm .chvm-why__item--right .chvm-why__photos { order: -1; }

.chvm .chvm-why__text {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font-style: normal;
  quotes: none;
}
.chvm .chvm-why__text::before,
.chvm .chvm-why__text::after { content: none; display: none; }

.chvm .chvm-why__quote-text {
  font-family: var(--chvm-cond);
  font-stretch: condensed;
  font-weight: 900;
  font-synthesis: weight;
  font-size: clamp(22px, 18px + 1vw, 32px);
  line-height: 1.44;            /* 46 / 32 */
  color: var(--chvm-blue);
  margin: 0 0 20px;
}
.chvm .chvm-why__attribution {
  font-family: var(--chvm-cond);
  font-stretch: condensed;
  font-weight: 500;
  font-size: clamp(16px, 14.6px + 0.37vw, 20px);
  line-height: 1.8;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--chvm-blue);
  margin: 0;
}

/* Two overlapping "polaroid" photos */
.chvm .chvm-why__photos {
  position: relative;
  width: 300px;
  height: 480px;
}
.chvm .chvm-polaroid {
  position: absolute;
  margin: 0;
  padding: 12px;
  background: var(--chvm-polaroid);
  box-shadow: 0 4px 4px rgba(0, 0, 0, .25);
}
.chvm .chvm-polaroid img {
  display: block;
  width: 208px;
  height: 208px;
  max-width: none;
  object-fit: cover;
  margin: 0;
  border-radius: 0;
}
.chvm .chvm-polaroid--a { top: 0; right: 0; transform: rotate(-3.74deg); }
.chvm .chvm-polaroid--b { top: 222px; left: 0; transform: rotate(6.83deg); z-index: 1; }
.chvm .chvm-polaroid--b img { width: 216px; height: 216px; }
.chvm .chvm-why__item--right .chvm-polaroid--a { right: auto; left: 22px; transform: rotate(3.57deg); }
.chvm .chvm-why__item--right .chvm-polaroid--b { top: 216px; transform: rotate(-5.12deg); }

/* Optional video above a testimonial (not in DRAFT 3 — kept for re-use) */
.chvm .chvm-why__video {
  grid-column: 1 / -1;
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 15px;
  overflow: hidden;
  background: #d9d9d9;
  cursor: pointer;
}
.chvm .chvm-why__video video { display: block; width: 100%; height: 100%; object-fit: cover; margin: 0; }
.chvm .chvm-why__play {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 162px; height: 162px; padding: 0;
  border: 0; border-radius: 50%; background: transparent;
  color: var(--chvm-white); cursor: pointer;
  transition: opacity .2s ease;
}
.chvm .chvm-why__play svg { width: 100%; height: 100%; display: block; }
.chvm .chvm-why__play:focus-visible { outline: 3px solid var(--chvm-white); outline-offset: 4px; }
.chvm .chvm-why__video.has-controls .chvm-why__play { opacity: 0; pointer-events: none; }

/* ==========================================================================
   SECTION: Supporter count — "You can change a young person's life."
   ========================================================================== */
.chvm.chvm-supporters {
  padding: var(--chvm-pad-y) var(--chvm-pad-x);
  text-align: center;
}
.chvm .chvm-supporters__inner { max-width: var(--chvm-max); margin: 0 auto; }
.chvm .chvm-supporters__inner > .chvm-h1 { max-width: 894px; margin: 0 auto 60px; }

.chvm .chvm-counter {
  max-width: 1064px;
  margin: 0 auto;
  background: var(--chvm-yellow);
  border-radius: 15px;
  padding: 60px 45px 30px;
}
.chvm .chvm-counter__digits {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 225px));
  justify-content: center;
  gap: 24px;
}
.chvm .chvm-counter__digit {
  font-synthesis: weight;            /* heavy digits even if only regular GT America is loaded */
  position: relative;
  container-type: inline-size;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--chvm-white);
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--chvm-cond);
  font-stretch: condensed;
  font-weight: 700;
  font-size: clamp(48px, 13.9vw, 200px);   /* 200px in a 225px tile */
  line-height: 1;
  color: var(--chvm-ink);
  font-variant-numeric: tabular-nums;
}
/* Slot-machine strip built by JS when data-count is set */
.chvm .chvm-counter__strip {
  position: absolute;
  inset: 0 0 auto;
  display: flex;
  flex-direction: column;
  transition: transform 1.1s cubic-bezier(.3, 1.15, .45, 1);   /* slight overshoot, like a flip counter */
}
.chvm .chvm-counter__strip span {
  flex: 0 0 auto;
  height: 100cqw;                 /* one tile tall */
  font-size: 88cqw;               /* scales with the tile, not the viewport */
  display: flex;
  align-items: center;
  justify-content: center;
}
.chvm .chvm-counter__label {
  font-family: var(--chvm-serif);
  font-weight: 800;
  font-size: clamp(22px, 17.6px + 1.2vw, 36px);
  line-height: 1.4;
  color: var(--chvm-blue);
  margin: 24px 0 0;
}
.chvm .chvm-supporters__text { max-width: 904px; margin: 0 auto; }
.chvm .chvm-supporters__text:first-of-type { margin-top: 50px; }
.chvm .chvm-supporters__text + .chvm-supporters__text { margin-top: 20px; }
/* Button rows — spacing lives on the wrapper, so it still works when the
   FundraiseUp button code replaces the <a> inside it */
.chvm .chvm-btn-row { margin: 40px 0 0; padding: 0; }
.chvm.chvm-supporters .chvm-btn-row,
.chvm.chvm-cta .chvm-btn-row { display: flex; justify-content: center; }
.chvm.chvm-cta .chvm-btn-row { margin-top: 32px; }
.chvm .chvm-btn-row .chvm-btn { margin: 0; }

/* ==========================================================================
   SECTION: Stories slider ([chv_stories] plugin) — restyled to Figma
   "What is the story you want to tell?" + "testimonial carousel container v2".
   Scoped to the .chvm-stories group on this page only; the plugin itself is
   untouched and keeps its own look anywhere else it is used.
   ========================================================================== */
.chvm-stories {
  --chvm-blue: #0067ff;
  --chvm-yellow: #ffe653;
  position: relative;
  z-index: 1;
  padding: 0;
}
/* Figma: the white stories block rounds over the yellow CTA below it */
.chvm-stories .chvst {
  padding: clamp(64px, 8.3vw, 120px) 0 clamp(48px, 5vw, 72px);
  background: var(--chvm-white, #fff);
  border-radius: 0 0 30px 30px;
}
.chvm-stories + .wp-block-group > .chvm.chvm-cta {
  margin-top: -30px;
  padding-top: calc(clamp(96px, 14vw, 200px) + 30px);
}
.chvm-stories .chvst-head {
  max-width: 1062px;
  margin: 0 auto clamp(40px, 5vw, 72px);
  padding: 0 24px;
  box-sizing: content-box;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
}
.chvm-stories .chvst-heading,
.chvm-stories .chvst-intro,
.chvm-stories .chvst-name,
.chvm-stories .chvst-subtitle,
.chvm-stories .chvst-quote,
.chvm-stories .chvst-quote p {
  font-style: normal;
  text-transform: none;
  letter-spacing: 0;
  padding: 0;
}
.chvm-stories .chvst-heading {
  font-family: 'P22 Mackinac Pro', Georgia, serif;
  font-weight: 800;
  font-style: normal;
  font-size: clamp(42px, 31.4px + 2.82vw, 72px);
  line-height: 1.03;
  letter-spacing: 0;
  color: var(--chvm-blue);
  max-width: 560px;
  margin: 0;
}
.chvm-stories .chvst-intro {
  font-family: 'P22 Mackinac Pro', Georgia, serif;
  font-weight: 500;
  font-size: clamp(20px, 17.2px + 0.75vw, 28px);
  line-height: 1.286;
  color: #000;
  max-width: 409px;
  margin: 0;
}

.chvm-stories .chvst-track { gap: 24px; }
.chvm-stories .chvst-slide {
  flex-basis: min(1060px, 74%);
  border-radius: 15px;
  padding: 48px;
  gap: 48px;
  grid-template-columns: minmax(0, 1fr) minmax(0, 500px);
}
.chvm-stories .chvst-slide--blue { background: var(--chvm-blue); }
.chvm-stories .chvst-slide-text { display: flex; flex-direction: column; }
.chvm-stories .chvst-subtitle {
  order: -1;                          /* Figma: role label sits above the name */
  font-family: 'GT America Condensed', 'GT America', 'Arial Narrow', sans-serif;
  font-stretch: condensed;
  font-weight: 500;
  font-size: 20px;
  line-height: 1.4;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #fff;
  margin: 0 0 12px;
}
.chvm-stories .chvst-name {
  font-family: 'P22 Mackinac Pro', Georgia, serif;
  font-weight: 500;
  font-size: clamp(40px, 30px + 2.3vw, 64px);
  line-height: 1.1;
  color: #fff;
  margin: 0 0 36px;
}
.chvm-stories .chvst-quote p { margin: 0 0 12px; color: inherit; font: inherit; }
.chvm-stories .chvst-quote p:last-child { margin-bottom: 0; }
.chvm-stories .chvst-quote {
  font-family: 'GT America Condensed', 'GT America', 'Arial Narrow', sans-serif;
  font-stretch: condensed;
  font-weight: 900;
  font-synthesis: weight;
  font-size: clamp(22px, 18px + 1vw, 32px);
  line-height: 1.25;
  color: var(--chvm-yellow);
}
.chvm-stories .chvst-image {
  min-height: 0;
  max-height: none;
  aspect-ratio: 500 / 518;
  border-radius: 10px;
}

/* Figma prev / next arrows (added by chv-match.js; dots hide once arrows exist) */
.chvm-stories .chvm-stories__nav {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
}
.chvm-stories .chvm-stories__arrow {
  width: 50px;
  height: 50px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: #d9d9d9;
  color: #7a7a7a;
  cursor: pointer;
  transition: background-color .2s ease, color .2s ease;
}
.chvm-stories .chvm-stories__arrow:hover { background: #c4c4c4; color: #4a4a4a; }
.chvm-stories .chvm-stories__arrow:focus-visible { outline: 3px solid var(--chvm-blue); outline-offset: 2px; }
.chvm-stories .chvm-stories__arrow svg { width: 24px; height: 24px; display: block; }
.chvm-stories.has-arrows .chvst-dots { display: none; }

/* ==========================================================================
   SECTION: Closing CTA — "You can change a young person's future."
   ========================================================================== */
.chvm.chvm-cta {
  padding: clamp(96px, 14vw, 200px) var(--chvm-pad-x);
  text-align: center;
}
.chvm .chvm-cta__inner { max-width: 894px; margin: 0 auto; }


/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1100px) {
  .chvm .chvm-intro__inner { grid-template-columns: minmax(0, 1fr) 340px; gap: 40px; }
  .chvm .chvm-impact__cards { gap: 16px; }
  .chvm .chvm-card__top { padding: 28px 20px 20px; }
  .chvm .chvm-card__amount { font-size: 44px; }
  .chvm .chvm-card__label { font-size: 24px; line-height: 27px; }
  .chvm .chvm-why__item { grid-template-columns: minmax(0, 1fr) 270px; }
  .chvm .chvm-why__item--right { grid-template-columns: 270px minmax(0, 1fr); }
  .chvm .chvm-why__photos { transform: scale(.9); transform-origin: center; }
}

@media (max-width: 767px) {
  .chvm { --chvm-pad-x: 20px; --chvm-pad-y: 64px; }
  .chvm .chvm-h1 { margin-bottom: 24px; }
  .chvm .chvm-btn { font-size: 18px; min-height: 48px; }

  .chvm .chvm-intro__inner { grid-template-columns: 1fr; gap: 40px; }
  .chvm .chvm-gallery { margin: 0; contain: none; }
  .chvm .chvm-gallery__viewport { height: 460px; }
  .chvm .chvm-gallery__toggle { bottom: 10px; }

  .chvm .chvm-impact__top { flex-direction: column; gap: 32px; margin-bottom: 40px; }
  .chvm .chvm-impact__form { flex-basis: auto; width: 100%; max-width: 100%; }
  .chvm .chvm-impact__cards { grid-template-columns: minmax(0, 411px); gap: 32px; overflow: visible; }
  .chvm-js .chvm .chvm-reveal { transform: translate3d(0, 60px, 0); opacity: 0; transition: transform .8s cubic-bezier(.16, 1, .3, 1), opacity .6s ease; }
  .chvm-js .chvm .chvm-reveal:nth-child(n) { transition-delay: 0s; }
  .chvm-js .chvm .chvm-reveal.is-in { opacity: 1; }

  .chvm .chvm-why__header { flex-direction: column; gap: 16px; margin-bottom: 48px; }
  .chvm .chvm-why__header .chvm-h1 { margin-top: 0; }
  .chvm .chvm-why__intro { flex-basis: auto; max-width: none; }
  .chvm .chvm-why__item,
  .chvm .chvm-why__item--right { grid-template-columns: 1fr; gap: 32px; justify-items: center; }
  .chvm .chvm-why__item--right .chvm-why__photos { order: 0; }
  .chvm .chvm-why__item + .chvm-why__item { margin-top: 72px; }
  .chvm .chvm-why__photos { width: 250px; height: 380px; transform: none; }
  .chvm .chvm-polaroid { padding: 10px; }
  .chvm .chvm-polaroid img,
  .chvm .chvm-polaroid--b img { width: 170px; height: 170px; }
  .chvm .chvm-polaroid--b,
  .chvm .chvm-why__item--right .chvm-polaroid--b { top: 178px; }
  .chvm .chvm-why__play { width: 88px; height: 88px; }

  .chvm .chvm-supporters__inner > .chvm-h1 { margin-bottom: 36px; }
  .chvm .chvm-counter { padding: 24px 16px 20px; }
  .chvm .chvm-counter__digits { gap: 10px; }
  .chvm .chvm-counter__digit { border-radius: 10px; }
  .chvm .chvm-supporters__text:first-of-type { margin-top: 36px; }

  .chvm-stories .chvst-head { flex-direction: column; align-items: flex-start; gap: 16px; padding: 0 20px; }
  .chvm-stories .chvst-slide { flex-basis: 86%; grid-template-columns: 1fr; padding: 24px; gap: 20px; }
  .chvm-stories .chvst-slide-media { order: -1; }
  .chvm-stories .chvst-image { aspect-ratio: 4 / 3; }
  .chvm-stories .chvst-subtitle { font-size: 16px; letter-spacing: 2px; }
  .chvm-stories .chvst-name { margin-bottom: 20px; }
}

/* Touch screens have no hover: keep the pause button visible */
@media (hover: none) {
  .chvm .chvm-gallery__toggle { opacity: .85; }
}

@media (prefers-reduced-motion: reduce) {
  html:has(.chvm) { scroll-behavior: auto; }
  .chvm .chvm-gallery.is-looping .chvm-gallery__track { animation: none; }
  .chvm-js .chvm .chvm-reveal { opacity: 1; transform: none; transition: none; }
  .chvm .chvm-counter__strip { transition: none; }
  .chvm .chvm-btn,
  .chvm .chvm-card,
  .chvm .chvm-video__play { transition: none; }
}