/* Support uses the current homepage palette and neutral card treatment. */
.support-page {
  --ink: var(--navy);
  --muted: color-mix(in srgb, var(--navy) 72%, white);
  --line: color-mix(in srgb, var(--navy) 18%, white);
  --focus: var(--red);
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}
.support-page > .hd,
.support-page > .site-footer { flex-shrink: 0; }
.support-page .give-page { flex: 1 0 auto; padding: 28px 0 72px; }
.support-page .back-link { margin-bottom: 32px; min-height: 32px; }
.support-page .give-grid {
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, 0.9fr);
  gap: clamp(32px, 5vw, 68px);
}
.support-page .give-copy { padding-top: 12px; }
.support-page .give-copy h1 {
  font-size: clamp(42px, 5vw, 64px);
  line-height: 1.03;
  margin: 0 0 24px;
}
.support-page .give-copy h1 span { color: var(--red); }
.support-page .give-copy .lead { font-size: 22px; line-height: 1.5; }
.support-page .give-copy > p { max-width: 520px; }
.support-work { list-style: none; padding: 0; margin: 28px 0; }
.support-work li { padding: 12px 0; border-top: 1px solid var(--line); font-size: 15px; line-height: 1.6; }
.support-work strong { color: var(--navy); }
.support-page .support-contact { margin: 30px 0 0; font-size: 14px; line-height: 1.7; }
.support-contact a { overflow-wrap: anywhere; }
.support-page .donation-card {
  padding: 32px;
  border-radius: 8px;
  box-shadow: 0 8px 28px rgb(20 38 74 / 6%);
}
.support-page .donation-card > h2 { font-size: 30px; line-height: 1.1; margin: 0 0 12px; }
.support-preview-note {
  margin: 0 0 26px;
  padding: 12px 14px;
  background: var(--cream);
  border-radius: 4px;
  font-size: 13px;
  color: var(--muted);
}
.support-page legend { font-size: 14px; margin-bottom: 12px; }
.support-page .frequency-options span,
.support-page .amount-options span {
  min-height: 50px;
  border-radius: 4px;
  border-color: color-mix(in srgb, var(--navy) 40%, white);
  font-size: 16px;
}
.support-page .frequency-options input:checked + span,
.support-page .amount-options input:checked + span { border-color: var(--navy); }
.support-page .money-input input { min-height: 50px; border-color: color-mix(in srgb, var(--navy) 55%, white); }
.support-page .money-input input[aria-invalid="true"] { border-color: var(--red); }
.support-page .hint { margin-top: 8px; font-size: 12px; }
.support-page .err { color: var(--red); }
.support-page .err:empty { display: none; }
.support-page .gift-summary { gap: 8px; font-size: 14px; margin: 24px 0; }
.support-page .gift-summary strong { font-size: 17px; }
.support-page .btn {
  box-shadow: none;
  background: var(--red);
  min-height: 50px;
  border-radius: 4px;
}
.support-page .btn:hover { background: color-mix(in srgb, var(--red) 88%, var(--navy)); }
.support-page .gift-preview { padding: 0; }
.support-page .gift-preview h3 { font-size: 36px; line-height: 1.15; margin: 0 0 12px; overflow-wrap: anywhere; }
.support-page .preview-explanation { background: var(--cream); padding: 16px; font-size: 14px; }
.support-page .contribution-disclosure { border-top: 1px solid var(--line); margin: 24px 0 0; padding-top: 20px; font-size: 12px; line-height: 1.65; color: var(--muted); }
.support-page .contribution-disclosure a { white-space: nowrap; }
.support-page .site-footer { background: var(--navy); color: var(--cream); }
.support-page .site-footer .footer-columns h2,
.support-page .footer-legal p { color: color-mix(in srgb, var(--cream) 78%, var(--navy)); }
.support-page .hd,
.support-page .site-footer { --focus: #ff4d5e; }
/* Brand checkbox, same as the homepage's Text me box (directions/brand-colors.css): navy outline, red when ticked,
   white tick. The real checkbox stays in place for keyboards and screen readers; .check-box draws it. */
.check-option {
  position: relative;
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 12px;
  align-items: start;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--navy);
  cursor: pointer;
}
.check-option input {
  position: absolute;
  opacity: 0;
  width: 22px;
  height: 22px;
  margin: 0;
}
.check-box {
  box-sizing: border-box;
  width: 22px;
  height: 22px;
  border: 1.5px solid var(--navy);
  border-radius: 4px;
  background: white;
}
.check-option input:checked + .check-box {
  border-color: var(--red);
  background: var(--red) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.6 2.6L12 5.5' fill='none' stroke='white' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 15px no-repeat;
}
.check-option input:focus-visible + .check-box {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}
.check-hint {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--muted);
}
.fee-option { margin: 18px 0 14px; }
/* "Add a note or give anonymously": closed by default; opens to the note and the anonymity box. */
.gift-more { margin: 0 0 20px; }
.gift-more summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
  list-style: none;
}
.gift-more summary::-webkit-details-marker { display: none; }
/* Plus (closed) / minus (open), drawn so it lines up with the text and isn't underlined. */
.gift-more summary::before {
  content: "";
  flex: none;
  width: 10px;
  height: 10px;
  background:
    linear-gradient(currentColor, currentColor) center / 10px 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 2px 10px no-repeat;
}
.gift-more[open] summary::before { background: linear-gradient(currentColor, currentColor) center / 10px 2px no-repeat; }
.gift-more-text {
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--navy) 35%, white);
  text-underline-offset: 3px;
}
.gift-more summary:hover .gift-more-text { text-decoration-color: var(--navy); }
.gift-more summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.gift-more-body { display: grid; gap: 14px; padding-top: 10px; }
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.note-field { margin: 0; }
.note-field label { font-size: 14px; margin-bottom: 10px; }
.note-field textarea {
  display: block;
  width: 100%;
  min-height: 64px;
  padding: 10px 12px;
  border: 1px solid color-mix(in srgb, var(--navy) 55%, white);
  border-radius: 4px;
  background: white;
  color: var(--navy);
  font: inherit;
  font-size: 16px;
  line-height: 1.5;
  resize: vertical;
}
.note-field textarea:hover { border-color: var(--navy); }
.note-field textarea:focus {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-color: var(--navy);
}
/* "Secure checkout powered by Stripe": the card's last line. */
.secure-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 18px -32px -32px;
  padding: 12px 16px;
  border-top: 1px solid var(--line);
  border-radius: 0 0 8px 8px;
  background: var(--cream);
  font-size: 12px;
  color: var(--muted);
}
.secure-lock { width: 13px; height: 13px; flex: none; color: var(--navy); }
.stripe-mark {
  font-weight: 800;
  font-size: 14px;
  letter-spacing: -0.02em;
  color: #635bff;
}
/* Step-by-step giving: 1 Amount → 2 Your details → 3 Payment. */
.give-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.give-steps li {
  counter-increment: step;
  padding-top: 8px;
  border-top: 3px solid var(--line);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.give-steps button {
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  text-align: left;
}
.give-steps button::before { content: counter(step) ". "; }
.give-steps button:disabled { cursor: default; }
/* A finished step is a way back to it. */
.give-steps button:not(:disabled) { cursor: pointer; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, var(--navy) 35%, white); }
.give-steps button:not(:disabled):hover { text-decoration-color: var(--navy); }
.give-steps button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.give-steps li.done { border-top-color: color-mix(in srgb, var(--navy) 45%, white); color: var(--navy); }
.give-steps li[aria-current="step"] { border-top-color: var(--red); color: var(--navy); }
.give-step .step-title {
  margin: 0 0 16px;
  font-size: 20px;
  line-height: 1.2;
  outline: none;
}
.step-field { margin-bottom: 18px; }
.step-field label { font-size: 14px; margin-bottom: 8px; }
.step-field input {
  min-height: 50px;
  border-radius: 4px;
  border-color: color-mix(in srgb, var(--navy) 55%, white);
}
.step-field input[aria-invalid="true"] { border-color: var(--red); }
.step-label { margin: 0 0 8px; font-size: 14px; font-weight: 600; color: var(--navy); }
.stripe-element { min-height: 60px; margin-bottom: 8px; }
.give-step .btn { margin-top: 12px; }
.give-step .err:empty { display: none; }
.pay-summary {
  display: flex;
  align-items: center;
  margin: 0 0 16px;
  padding: 12px 14px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 15px;
  font-weight: 700;
  color: var(--navy);
}
.link-button {
  padding: 4px 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  text-decoration: underline;
  cursor: pointer;
}
.link-button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.change-gift {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  margin: 0 0 8px;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
}
.change-gift:hover { text-decoration: underline; }
.change-gift:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
/* ─────────────────────────────────────────────────────────
 * SUBMISSION STORYBOARD – the CSS half. Timers are in give.js (TIMING); card[data-stage] drives it.
 *   working     fields dim, band sweeps the Give button (1.1s loop)
 *   confirmed   band stops, arrow → check
 *   leaving     payment step fades out, lifts 8px (200ms)
 *   thanks      ring draws (450ms), tick draws (+250ms), title (+150ms), lines (+250ms, 90ms apart)
 *   failed      button nudges sideways twice (320ms)
 * ───────────────────────────────────────────────────────── */
.donation-card {
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --sweep: 1100ms;
  --step-out: 200ms;
  --ring: 450ms;
  --tick-delay: 250ms;
  --title-delay: 150ms;
  --lines-delay: 250ms;
  --line-stagger: 90ms;
}
.pay-button { position: relative; overflow: hidden; }
.pay-button:disabled { opacity: 1; }
.pay-button .pay-icon { display: inline-block; min-width: 1em; text-align: right; }
.donation-card[data-stage="working"] .pay-button::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 40%;
  background: linear-gradient(90deg, transparent, rgb(255 255 255 / 0.28), transparent);
  animation: pay-sweep var(--sweep) linear infinite;
}
@keyframes pay-sweep { from { transform: translateX(-100%); } to { transform: translateX(250%); } }
.donation-card[data-stage="working"] .pay-text::after { content: "…"; }
.donation-card[data-stage="working"] #step-payment > :not(.pay-button) {
  opacity: 0.55;
  pointer-events: none;
  transition: opacity 200ms var(--ease-out);
}
.donation-card[data-stage="working"] .give-steps,
.donation-card[data-stage="confirmed"] .give-steps { pointer-events: none; }
.donation-card[data-stage="confirmed"] .pay-icon,
.donation-card[data-stage="leaving"] .pay-icon { font-size: 0; }
.donation-card[data-stage="confirmed"] .pay-icon::before,
.donation-card[data-stage="leaving"] .pay-icon::before { content: "✓"; font-size: 16px; }
.donation-card[data-stage="leaving"] #step-payment {
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity var(--step-out) var(--ease-out), transform var(--step-out) var(--ease-out);
}
.donation-card[data-stage="failed"] .pay-button { animation: pay-nudge 320ms var(--ease-out); }
@keyframes pay-nudge {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  50% { transform: translateX(5px); }
  75% { transform: translateX(-3px); }
}
/* Thank-you panel */
.give-done { padding: 8px 0 4px; }
.done-check { width: 56px; height: 56px; margin-bottom: 14px; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.done-check circle { stroke: var(--red); stroke-width: 3; stroke-dasharray: 139; stroke-dashoffset: 0; transform: rotate(-90deg); transform-origin: center; }
.done-check path { stroke: var(--navy); stroke-width: 3.5; stroke-dasharray: 32; stroke-dashoffset: 0; }
.done-title { margin: 0 0 10px; font-size: 28px; line-height: 1.1; outline: none; }
.done-line { margin: 0 0 8px; font-size: 15px; line-height: 1.55; color: var(--ink, var(--navy)); }
.done-help { margin-top: 14px; font-size: 13px; color: var(--muted); }
.donation-card[data-stage="thanks"] .done-check circle { animation: draw-ring var(--ring) var(--ease-out) both; }
.donation-card[data-stage="thanks"] .done-check path { animation: draw-tick 300ms var(--ease-out) var(--tick-delay) both; }
.donation-card[data-stage="thanks"] .done-title { animation: rise 350ms var(--ease-out) var(--title-delay) both; }
.donation-card[data-stage="thanks"] .done-line { animation: rise 350ms var(--ease-out) both; }
.donation-card[data-stage="thanks"] .done-line:nth-of-type(1) { animation-delay: var(--lines-delay); }
.donation-card[data-stage="thanks"] .done-line:nth-of-type(2) { animation-delay: calc(var(--lines-delay) + var(--line-stagger)); }
.donation-card[data-stage="thanks"] .done-line:nth-of-type(3) { animation-delay: calc(var(--lines-delay) + 2 * var(--line-stagger)); }
.donation-card[data-stage="thanks"] .done-line:nth-of-type(4) { animation-delay: calc(var(--lines-delay) + 3 * var(--line-stagger)); }
@keyframes draw-ring { from { stroke-dashoffset: 139; } }
@keyframes draw-tick { from { stroke-dashoffset: 32; } }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) {
  .donation-card *, .donation-card *::before, .donation-card *::after { animation: none !important; transition: none !important; }
  .donation-card[data-stage="leaving"] #step-payment { transform: none; }
}
@media (max-width: 800px) {
  .support-page .give-grid { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .support-page .give-copy { padding: 0; }
  .support-page .donation-card { width: 100%; max-width: 560px; justify-self: center; }
  .support-page .give-page { padding-bottom: 48px; }
}
@media (max-width: 440px) {
  .support-page .donation-card { padding: 24px 20px; }
  .secure-strip { margin: 18px -20px -24px; }
  .support-page .amount-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .support-page .give-copy h1 { font-size: 42px; }
  .support-page .give-copy .lead { font-size: 20px; }
  .support-page .gift-summary { display: flex; }
}
@media (forced-colors: active) {
  .support-page .frequency-options input:checked + span,
  .support-page .amount-options input:checked + span { outline: 3px solid Highlight; outline-offset: -3px; }
}
