/* ============================================================
   Kids Rise with Books
   ------------------------------------------------------------
   Version A — minimal, with three changes:
     1. The multi-color ribbon is now a BORDER (top + bottom
        bands, and a full frame on the intro card). Hard color
        stops, so no color gets swallowed by its neighbour.
     2. Numbered info cards with a hand-drawn stroke on top.
     3. A two-slide intro title card on the home page.
   ============================================================ */

:root {
  /* Color — drawn from the KRWB mark: navy child, phoenix flame,
     book-page strips of green / gold / red. */
  --paper: #F6F7FB;
  --paper-cool: #EEF1F9;
  --paper-warm: #FDFCFA;
  --ink: #1B2D5E;
  --ink-soft: #51598A;
  --ink-faint: #8B92B8;
  --phoenix: #E8622F;
  --phoenix-deep: #C94F20;
  --ember: #C62828;
  --leaf: #2D7D32;
  --leaf-soft: #E8F3E9;
  --gold: #F0A93A;
  --gold-deep: #D4A017;
  --line: #DDE1EF;
  --white: #FFFFFF;

  --font-display: 'Lora', Georgia, serif;
  --font-body: 'Karla', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-bubble: 'Baloo 2', 'Karla', sans-serif;

  --container: 1140px;
  --radius: 14px;

  /* Border band thickness */
  --band: 7px;

  /* The band itself — five equal, hard-edged segments. Nothing
     blends, nothing fades into a neighbouring field. */
  --band-fill: linear-gradient(
    90deg,
    var(--leaf)    0%,  var(--leaf)    20%,
    var(--ink)     20%, var(--ink)     40%,
    var(--gold)    40%, var(--gold)    60%,
    var(--phoenix) 60%, var(--phoenix) 80%,
    var(--ember)   80%, var(--ember)   100%
  );
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

body {
  margin: 0;
  padding-top: var(--band);
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Scroll is locked while the intro card is on screen */
body.intro-active { overflow: hidden; }

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 0.5em;
  font-weight: 600;
}

h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; color: var(--ink-soft); }

a {
  color: var(--phoenix-deep);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}
a:hover { color: var(--ember); }

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

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--gold-deep);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ============================================================
   1. THE BORDER
   The ribbon that used to sit behind the logo now frames the
   page: a fixed band at the top, a matching band closing the
   footer. Five clean segments, equal weight, no blending.
   ============================================================ */
.page-band {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--band);
  background: var(--band-fill);
  z-index: 90;
}

.footer-band {
  height: var(--band);
  background: var(--band-fill);
}

/* ============================================================
   Eyebrow labels
   ============================================================ */
.eyebrow {
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--phoenix-deep);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--phoenix);
  display: inline-block;
}

/* ============================================================
   Navigation
   ============================================================ */
.site-header {
  position: sticky;
  top: var(--band);
  z-index: 50;
  background: rgba(246, 247, 251, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
}

.nav-brand img { height: 42px; width: auto; }

.nav-brand-text {
  font-family: var(--font-bubble);
  font-weight: 700;
  font-size: 1.28rem;
  line-height: 1.05;
  letter-spacing: 0.005em;
  color: var(--ink);
}

.nav-brand-text span {
  display: block;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  color: var(--leaf);
  text-transform: uppercase;
  margin-top: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 34px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  position: relative;
  padding: 6px 0;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: var(--phoenix);
  transition: width 0.2s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

.nav-links a.active { color: var(--phoenix-deep); }

.nav-links a.nav-cta {
  background: var(--ink);
  color: var(--white) !important;
  padding: 14px 34px;
  border-radius: 999px;
  font-weight: 700 !important;
  white-space: nowrap;
}

.nav-links a.nav-cta::after { display: none; }
.nav-links a.nav-cta:hover { background: var(--phoenix-deep); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--ink);
  margin: 5px 0;
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--paper-warm);
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 24px 28px 30px;
    border-bottom: 1px solid var(--line);
  }
  .nav-links.open { display: flex; }
  .nav-links a { width: 100%; padding: 10px 0; }
  .nav-links a.nav-cta { width: 100%; text-align: center; margin-top: 6px; }
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.98rem;
  padding: 14px 28px;
  border-radius: 999px;
  text-decoration: none;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary { background: var(--ink); color: var(--white); }
.btn-primary:hover { background: var(--phoenix-deep); color: var(--white); }

.btn-outline { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--white); }

/* ============================================================
   Hero — nothing sits behind the logo now. Plain paper.
   ============================================================ */
.hero { padding: 72px 0 44px; }

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

.hero-copy p.lede {
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 46ch;
}

.hero-actions {
  display: flex;
  gap: 16px;
  margin-top: 28px;
  flex-wrap: wrap;
}

.hero-art { display: flex; justify-content: center; }
.hero-art img { width: 100%; max-width: 370px; }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { order: -1; }
  .hero-art img { max-width: 210px; }
}

/* ============================================================
   Page-turn divider
   ============================================================ */
.page-turn {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
}

/* ============================================================
   Section scaffolding
   ============================================================ */
.section { padding: 76px 0; }
.section-cool { background: var(--paper-cool); }
.section-flush-top { padding-top: 0; }

.section-head {
  max-width: 640px;
  margin: 0 0 44px;
}

/* ============================================================
   2. NUMBERED INFO CARDS
   Warm paper card on the cool section, a hand-drawn colored
   stroke laid across the top edge, number in the display face.
   ============================================================ */
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  align-items: start;
}

.info-card {
  position: relative;
  background: var(--paper-warm);
  border: 1px solid var(--line);
  border-radius: 16px 13px 17px 14px;
  padding: 38px 30px 32px;
  box-shadow: 0 10px 26px -22px rgba(27, 45, 94, 0.5);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.info-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 34px -22px rgba(27, 45, 94, 0.45);
}

/* The stroke sits on the top edge and overhangs a touch, the way
   a marker line would if you'd drawn it by hand across the card. */
.info-card .card-stroke {
  position: absolute;
  top: -5px;
  left: -3px;
  width: calc(100% + 6px);
  height: 11px;
  overflow: visible;
}

.info-card .card-stroke path {
  fill: none;
  stroke: currentColor;
  stroke-width: 5.5;
  stroke-linecap: round;
}

.info-card:nth-child(1) .card-stroke { color: var(--leaf);        transform: rotate(-0.4deg); }
.info-card:nth-child(2) .card-stroke { color: var(--phoenix);     transform: rotate(0.45deg); }
.info-card:nth-child(3) .card-stroke { color: var(--gold-deep);   transform: rotate(-0.25deg); }

.info-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2.4rem;
  line-height: 1;
  letter-spacing: -0.02em;
  display: block;
  margin-bottom: 14px;
}

.info-card:nth-child(1) .info-num { color: var(--leaf); }
.info-card:nth-child(2) .info-num { color: var(--phoenix-deep); }
.info-card:nth-child(3) .info-num { color: var(--gold-deep); }

.info-card h3 { margin: 0 0 12px; font-size: 1.3rem; }
.info-card p { margin: 0; font-size: 0.98rem; }

/* Subtle stagger, the way three loose cards would land on a desk */
@media (min-width: 901px) {
  .info-card:nth-child(2) { margin-top: 28px; }
  .info-card:nth-child(3) { margin-top: 12px; }
}

@media (max-width: 900px) {
  .info-grid { grid-template-columns: 1fr; gap: 24px; }
}

/* ============================================================
   Mission quote
   ============================================================ */
.mission-block {
  background: var(--ink);
  color: var(--white);
  border-radius: 24px;
  padding: 64px 56px;
  position: relative;
  overflow: hidden;
}

.mission-block::before {
  content: "\201C";
  position: absolute;
  top: -10px;
  left: 32px;
  font-family: var(--font-display);
  font-size: 9rem;
  color: var(--gold);
  opacity: 0.35;
  line-height: 1;
}

.mission-block blockquote {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  line-height: 1.5;
  max-width: 60ch;
  position: relative;
  z-index: 1;
}

.mission-block cite {
  display: block;
  margin-top: 24px;
  font-style: normal;
  font-family: var(--font-body);
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold);
}

@media (max-width: 700px) {
  .mission-block { padding: 44px 28px; border-radius: 18px; }
}

/* ============================================================
   Service area
   ============================================================ */
.service-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 48px;
  align-items: center;
}

@media (max-width: 900px) {
  .service-grid { grid-template-columns: 1fr; }
}

.place-list { list-style: none; margin: 24px 0 0; padding: 0; }

.place-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.place-list li:last-child { border-bottom: none; }

.place-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--phoenix);
  margin-top: 7px;
  flex-shrink: 0;
}

.place-list strong { color: var(--ink); display: block; }
.place-list span { color: var(--ink-soft); font-size: 0.94rem; }

/* ============================================================
   Final CTA band
   ============================================================ */
.cta-band {
  background: var(--leaf-soft);
  border-radius: 24px;
  padding: 56px;
  text-align: center;
}

.cta-band h2 { margin-bottom: 12px; }
.cta-band p { max-width: 52ch; margin-left: auto; margin-right: auto; }

@media (max-width: 700px) {
  .cta-band { padding: 40px 24px; border-radius: 18px; }
}

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 52px 0 0;
  margin-top: 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 36px;
}

@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.footer-brand img { height: 36px; }

.footer-brand-text {
  font-family: var(--font-bubble);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--ink);
}

.footer-col h4 {
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  color: var(--ink-soft);
  margin: 0 0 14px;
}

.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 10px; }

.footer-col a {
  color: var(--ink);
  text-decoration: none;
  font-size: 0.95rem;
}

.footer-col a:hover { color: var(--phoenix-deep); }

.footer-bottom {
  border-top: 1px solid var(--line);
  padding: 24px 0 34px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.85rem;
  color: var(--ink-faint);
}

/* ============================================================
   Interior page headers
   ============================================================ */
.page-header { padding: 64px 0 20px; }
.page-header .lede { font-size: 1.1rem; max-width: 60ch; }

/* ============================================================
   About page
   ============================================================ */
.story-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

@media (max-width: 900px) {
  .story-grid { grid-template-columns: 1fr; }
}

.board-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

@media (max-width: 900px) { .board-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .board-grid { grid-template-columns: 1fr; } }

.board-card {
  background: var(--paper-warm);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 20px;
  text-align: center;
}

.board-avatar-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  margin: 0 auto 16px;
  border: 2px solid var(--white);
  box-shadow: 0 0 0 2px var(--line);
}

.board-card h3 { font-size: 1.05rem; margin-bottom: 4px; }

.board-card p {
  font-size: 0.85rem;
  color: var(--leaf);
  font-weight: 700;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.status-note {
  background: #FDF1DC;
  border: 1px solid #F0D9A8;
  border-radius: var(--radius);
  padding: 22px 26px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.status-note svg { flex-shrink: 0; margin-top: 3px; }
.status-note p { margin: 0; color: var(--ink); font-size: 0.95rem; }
.status-note strong { color: var(--ink); }

/* ============================================================
   Contact
   ============================================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 56px;
  align-items: start;
}

@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; }
}

.contact-info p { margin-bottom: 28px; max-width: 42ch; }

.info-block {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 22px;
}

.info-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--leaf-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.info-icon svg { width: 22px; height: 22px; }

.info-block strong {
  display: block;
  color: var(--ink);
  font-size: 1rem;
  margin-bottom: 2px;
}

.info-block span { color: var(--ink-soft); font-size: 0.95rem; }

.contact-form {
  background: var(--paper-warm);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 40px;
}

@media (max-width: 560px) { .contact-form { padding: 28px 22px; } }

.form-row { margin-bottom: 20px; }
.form-row:last-of-type { margin-bottom: 26px; }

.form-row label {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ink);
  margin-bottom: 8px;
}

.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.98rem;
  color: var(--ink);
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
}

.form-row textarea { min-height: 120px; resize: vertical; }

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--phoenix);
}

.form-submit {
  width: 100%;
  justify-content: center;
  border: none;
  font-family: var(--font-body);
}

/* ============================================================
   3. INTRO TITLE CARD  (home page only)
   Slide 1: logo drops in, wordmark fades in beneath it.
   Slide 2: the line.
   Then the whole card lifts away and the site is there.
   The border becomes a full frame here, like a book cover.
   ============================================================ */
.intro {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: intro-exit 0.55s ease-in 4.2s forwards;
}

/* Full four-sided frame, same five colors, same hard stops */
.intro::before,
.intro::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: var(--band);
  background: var(--band-fill);
}

.intro::before { top: 0; }
.intro::after  { bottom: 0; }

.intro-edge-l,
.intro-edge-r {
  position: absolute;
  top: 0;
  bottom: 0;
  width: var(--band);
  background: linear-gradient(
    180deg,
    var(--leaf)    0%,  var(--leaf)    20%,
    var(--ink)     20%, var(--ink)     40%,
    var(--gold)    40%, var(--gold)    60%,
    var(--phoenix) 60%, var(--phoenix) 80%,
    var(--ember)   80%, var(--ember)   100%
  );
}

.intro-edge-l { left: 0; }
.intro-edge-r { right: 0; }

/* Both slides share one grid cell, so they are centred without a
   translate that the fade-rise animation would have to fight. */
.intro-stage {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  max-width: 640px;
  padding: 0 32px;
  text-align: center;
}

.intro-slide {
  grid-area: 1 / 1;
  width: 100%;
}

/* --- Slide 1 --------------------------------------------- */
.intro-slide-1 {
  animation: intro-slide-out 0.4s ease-in 2s forwards;
}

.intro-logo {
  width: 150px;
  margin: 0 auto 22px;
  opacity: 0;
  animation: logo-drop 0.85s cubic-bezier(0.22, 1.4, 0.4, 1) 0.15s forwards;
}

.intro-wordmark {
  font-family: var(--font-bubble);
  font-weight: 700;
  font-size: clamp(2rem, 6.4vw, 3.1rem);
  line-height: 1.05;
  color: var(--ink);
  margin: 0;
  opacity: 0;
  animation: fade-rise 0.7s ease-out 0.72s forwards;
}

/* --- Slide 2 --------------------------------------------- */
.intro-slide-2 {
  opacity: 0;
  animation: fade-rise 0.6s ease-out 2.42s forwards,
             intro-slide-out 0.4s ease-in 3.8s forwards;
}

.intro-line {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.5rem, 4.4vw, 2.4rem);
  line-height: 1.35;
  color: var(--ink);
  margin: 0;
  max-width: 22ch;
  margin-left: auto;
  margin-right: auto;
}

.intro-line em {
  font-style: normal;
  color: var(--phoenix-deep);
}

/* --- Skip ------------------------------------------------ */
/* The Skip button is the only way out of the card, so it reads as
   a button rather than a faint label. */
.intro-skip {
  position: absolute;
  bottom: calc(var(--band) + 26px);
  right: 28px;
  background: rgba(255, 255, 255, 0.7);
  border: 1.5px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding: 9px 20px;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.intro-skip:hover {
  color: var(--ink);
  border-color: var(--ink);
  background: var(--white);
}

/* --- Keyframes ------------------------------------------- */
@keyframes logo-drop {
  0%   { opacity: 0; transform: translateY(-70px) scale(0.94); }
  60%  { opacity: 1; }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes fade-rise {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes intro-slide-out {
  from { opacity: 1; }
  to   { opacity: 0; }
}

@keyframes intro-exit {
  from { opacity: 1; visibility: visible; }
  to   { opacity: 0; visibility: hidden; }
}

/* Anyone who has asked their system to reduce motion, or who has
   JS off, never sees the card at all. */
@media (prefers-reduced-motion: reduce) {
  .intro { display: none; }
}

.no-js .intro { display: none; }

@media (max-width: 560px) {
  .intro-logo { width: 112px; }
  .intro-skip { right: 16px; }
}

/* ============================================================
   DONATE MODAL
   Zeffy's embed strips out the description, logo, and org name,
   so we supply all of that ourselves and let the iframe handle
   only what it's good at: the money. Two columns on desktop —
   our story on the left, their form on the right — stacking on
   mobile.
   ============================================================ */
.donate-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 28px;
  background: rgba(15, 25, 55, 0.62);
  backdrop-filter: blur(3px);
}

.donate-overlay.is-open { display: flex; }

body.donate-locked { overflow: hidden; }

.donate-panel {
  position: relative;
  width: 100%;
  max-width: 1040px;
  max-height: calc(100vh - 56px);
  background: var(--paper);
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 40px 80px -30px rgba(15, 25, 55, 0.6);
  animation: donateIn 0.28s cubic-bezier(0.16, 0.9, 0.3, 1.05) both;
}

@keyframes donateIn {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* The same five-color band, so the window is unmistakably ours */
.donate-band {
  display: block;
  flex-shrink: 0;
  width: 100%;
  height: var(--band);
  background: var(--band-fill);
}

.donate-body {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  overflow: hidden;
  flex: 1;
  min-height: 0;
}

.donate-story {
  padding: 38px 34px;
  overflow-y: auto;
  border-right: 1px solid var(--line);
}

.donate-story-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}

.donate-story-brand img { height: 42px; width: auto; }

.donate-story-brand span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.2;
  color: var(--ink);
}

.donate-story h2 {
  font-size: 1.85rem;
  margin-bottom: 16px;
}

.donate-story p {
  font-size: 0.97rem;
  margin-bottom: 14px;
}

.donate-goal {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.donate-goal-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 8px;
}

.donate-goal-label span:last-child { color: var(--leaf); }

.donate-goal-track {
  height: 8px;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
}

.donate-goal-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(to right, var(--leaf), var(--gold));
}

.donate-tiers {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
}

.donate-tiers li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.88rem;
  color: var(--ink-soft);
  padding: 7px 0;
}

.donate-tiers b { color: var(--ink); white-space: nowrap; }

/* Form side */
.donate-form-side {
  background: var(--white);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.donate-form-side iframe {
  border: 0;
  width: 100%;
  flex: 1;
  min-height: 620px;
}

.donate-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 620px;
  font-size: 0.9rem;
  color: var(--ink-faint);
}

.donate-close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease;
}

.donate-close:hover { background: var(--ink); color: var(--white); }

.donate-fallback {
  padding: 14px 34px 20px;
  font-size: 0.82rem;
  color: var(--ink-faint);
  border-top: 1px solid var(--line);
  background: var(--paper);
}

.donate-fallback a { color: var(--phoenix-deep); }

@media (max-width: 900px) {
  .donate-overlay { padding: 0; }
  .donate-panel {
    max-width: none;
    max-height: 100vh;
    height: 100vh;
    border-radius: 0;
    overflow-y: auto;
  }
  .donate-body {
    grid-template-columns: 1fr;
    overflow: visible;
  }
  .donate-story {
    border-right: none;
    border-bottom: 1px solid var(--line);
    padding: 30px 24px 26px;
    overflow: visible;
  }
  .donate-story h2 { font-size: 1.5rem; }
  .donate-tiers { display: none; }
  .donate-form-side { overflow: visible; }
  .donate-form-side iframe,
  .donate-loading { min-height: 780px; }
  .donate-fallback { padding: 14px 24px 22px; font-size: 0.78rem; }
}
