/* Shared components. Load tokens.css before this stylesheet. */
* { box-sizing: border-box; }
body { margin: 0; }
body.dialog-open { overflow: hidden; }
html { scroll-behavior: smooth; scroll-padding-top: 16px; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; }
button:disabled { cursor: wait; opacity: .65; }
img, svg { display: block; }
img { max-width: 100%; }
p, h1, h2, h3 { margin-top: 0; }
p { margin-bottom: 1rem; }
h1, h2, h3 { color: var(--ink); line-height: var(--line-height-heading); letter-spacing: -.035em; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 1rem; top: .6rem; z-index: 100; padding: .5rem 1rem; background: var(--paper); transform: translateY(-200%); }
.skip-link:focus { transform: none; }
.site-header { position: relative; z-index: 40; background: var(--header-background); border-bottom: 1px solid var(--line); }
.header-inner { width: min(100% - 48px, var(--content-width)); min-height: 72px; margin-inline: auto; display: flex; align-items: center; gap: var(--space-4); }
.brand { display: inline-flex; align-items: center; gap: 7px; text-decoration: none; color: var(--brand); font-size: 1.65rem; font-weight: var(--font-weight-bold); letter-spacing: -.065em; white-space: nowrap; }
.brand svg { width: 37px; height: 35px; color: var(--green); }
.main-nav { display: flex; align-items: center; gap: var(--space-6); flex: 1; }
.main-nav a { font-size: .8rem; text-decoration: none; color: var(--muted); font-weight: var(--font-weight-medium); }
.main-nav a:hover, .footer-links a:hover { text-decoration: underline; text-underline-offset: 4px; }
.header-donate { margin-left: auto; flex-shrink: 0; white-space: nowrap; }
.currency-note { margin: var(--space-3) 0; color: var(--muted); font-size: .68rem; line-height: 1.6; overflow-wrap: anywhere; }
.menu-toggle { display: none; border: 1px solid var(--line); border-radius: 50%; background: var(--paper); width: 44px; height: 44px; align-items: center; justify-content: center; color: var(--ink); }
.menu-toggle svg { width: 21px; height: 21px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 46px; padding: 11px 22px; border: 1px solid transparent; border-radius: var(--radius-pill); background: var(--green); color: var(--ink); font-size: var(--font-size-small); font-weight: var(--font-weight-bold); text-align: center; text-decoration: none; transition: background .18s, border-color .18s, filter .18s; }
.button:hover { background: var(--green); filter: brightness(.94); }
.button svg { width: 18px; height: 18px; }
.button-dark { background: var(--green); color: var(--ink); }
.button-dark:hover { background: var(--green-hover); }
.button-outline { border-color: var(--outline); background: var(--paper); color: var(--ink); }
.button-outline:hover { background: var(--outline-hover); filter: none; }
.button-small { min-height: 42px; font-size: .78rem; padding: var(--space-2) 17px; }
.button-full { width: 100%; }
.page-shell { width: min(100% - 48px, var(--content-width)); margin: var(--space-8) auto 0; }
.content-split { display: grid; grid-template-columns: minmax(0, 1fr) 350px; gap: var(--space-7); align-items: start; }
.campaign-main { min-width: 0; }
.campaign-layout { max-width: var(--reading-width); margin-inline: auto; }
.hero { margin: 0; border-radius: var(--radius-panel); overflow: hidden; background: var(--image-placeholder); }
.hero img { width: 100%; height: auto; }
.campaign-layout .hero { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.hero figcaption { padding: 6px var(--space-3); font-size: .61rem; color: var(--muted); background: var(--surface-tint); }
.campaign-title { padding: 22px 0 0; }
.eyebrow { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-bottom: var(--space-2); color: var(--muted); font-size: .68rem; font-weight: var(--font-weight-semibold); }
.eyebrow .dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; }
h1 { font-size: clamp(1.35rem, 2.4vw, 1.72rem); font-weight: var(--font-weight-heavy); margin-bottom: 9px; }
.organizer-line { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; color: var(--muted); font-size: .73rem; margin-bottom: 0; }
.organizer-line strong { font-weight: var(--font-weight-bold); color: var(--ink); }
.organizer-byline { display: inline-flex; align-items: center; gap: 8px; min-width: 0; max-width: 100%; }
.organizer-byline .avatar { width: 32px; height: 32px; font-size: .6rem; }
.campaign-status { display: inline-flex; align-items: center; gap: 7px; padding: 5px 10px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--paper); color: var(--ink); font-size: .68rem; font-weight: var(--font-weight-semibold); line-height: 1.4; white-space: nowrap; }
.campaign-status-dot { width: 7px; height: 7px; flex-shrink: 0; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 2px var(--surface-tint); }
.surface { margin-top: 22px; padding: var(--space-7); border-radius: var(--radius-panel); background: var(--paper); box-shadow: var(--shadow-surface); }
.surface h2 { margin-bottom: 17px; font-size: var(--font-size-heading); font-weight: var(--font-weight-heavy); }
.story { font-size: clamp(1rem, 1.3vw, 1.1rem); line-height: 1.85; }
.campaign-story > h2, .campaign-story .campaign-funds > h2, .campaign-story .campaign-questions > h2 { margin-bottom: 22px; font-size: clamp(1.3rem, 2.2vw, 1.6rem); font-weight: var(--font-weight-heavy); letter-spacing: -.035em; line-height: 1.3; }
.campaign-story > h2::before { content: ""; display: block; width: 38px; height: 5px; margin-bottom: 14px; border-radius: var(--radius-pill); background: var(--green); }
.campaign-story .story-intro { margin-bottom: 28px; color: var(--ink); font-size: clamp(1.08rem, 1.6vw, 1.2rem); font-weight: var(--font-weight-semibold); line-height: 1.7; }
.campaign-story .story-remainder > p { margin-bottom: 22px; }
.story .story-heading { margin: 32px 0 12px; color: var(--ink); font-size: clamp(1.1rem, 1.8vw, 1.3rem); font-weight: var(--font-weight-heavy); line-height: 1.4; }
.story .story-heading:first-child { margin-top: 0; }
.story .story-heading + .story-heading { margin-top: 9px; margin-bottom: 20px; font-size: 1.03em; font-weight: var(--font-weight-semibold); letter-spacing: -.02em; }
.story .story-quote { margin: 28px 0; padding: 19px 22px; border-left: 4px solid var(--green); border-radius: 0 var(--radius-small) var(--radius-small) 0; background: var(--surface-tint); color: var(--ink); font-size: 1.06em; font-weight: var(--font-weight-semibold); line-height: 1.7; }
.story .story-closing { display: block; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line); font-size: 1.04em; font-weight: var(--font-weight-bold); line-height: 1.7; }
.campaign-story .story [data-money-usd] { color: var(--ink); font-weight: var(--font-weight-heavy); font-variant-numeric: tabular-nums; }
.story p:last-child { margin-bottom: 0; }
.policy-links { display: flex; gap: 10px 24px; flex-wrap: wrap; padding-left: 20px; margin: 16px 0 0; line-height: 1.7; }
.policy-links a { overflow-wrap: anywhere; }
.story strong { color: var(--ink); }
.story-image { width: 100%; margin: var(--space-6) 0; overflow: hidden; border-radius: var(--radius-panel); background: var(--image-placeholder); }
.story-image img { width: 100%; height: auto; }
.story-disclosure { margin-top: 14px; overflow-anchor: none; }
.story-toggle { position: relative; min-height: 180px; list-style: none; cursor: pointer; }
.story-toggle::-webkit-details-marker { display: none; }
.story-toggle::marker { content: ""; }
.story-toggle::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgb(255 255 255 / 14%), rgb(255 255 255 / 76%) 48%, var(--paper)); pointer-events: none; }
.story-preview { position: absolute; inset: 0; overflow: hidden; border-radius: var(--radius-panel); pointer-events: none; user-select: none; }
.story-preview-text { display: block; max-height: 62px; overflow: hidden; color: var(--muted); font-size: var(--font-size-body); line-height: 1.8; filter: blur(4px); }
.story-preview img { width: 100%; height: 160px; margin-top: 12px; object-fit: cover; object-position: center 30%; opacity: .7; filter: blur(5px); }
.story-toggle-label { position: absolute; top: 50%; left: 50%; z-index: 2; transform: translate(-50%, -50%); white-space: nowrap; }
.story-toggle:focus-visible { outline: 0; }
.story-toggle:focus-visible .story-toggle-label { outline: 3px solid var(--focus); outline-offset: 4px; }
.story-disclosure[open] > .story-toggle { display: none; }
body:has(.story-disclosure:not([open])) > .footer { display: none; }
body:has(.story-disclosure:not([open])) > .sticky-donation { display: none; }
.story-expanded .campaign-gallery { margin-top: 28px; padding: 0; border-radius: 0; background: transparent; box-shadow: none; }
.story-actions { margin-top: 23px; padding-top: 18px; display: flex; gap: 10px; flex-wrap: wrap; }
.campaign-funds, .campaign-questions { margin-top: 36px; padding-top: 30px; border-top: 1px solid var(--line); }
.campaign-fund-list { display: grid; gap: 14px; }
.campaign-fund-list > p { margin-bottom: 4px; }
.campaign-fund-item { min-width: 0; padding: 21px; border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--surface-tint); }
.campaign-fund-title { margin: 0 0 13px; color: var(--ink); font-size: clamp(1.05rem, 1.7vw, 1.18rem); font-weight: var(--font-weight-heavy); line-height: 1.5; letter-spacing: -.025em; }
.campaign-fund-title-numbered { display: grid; grid-template-columns: 30px minmax(0, 1fr); align-items: start; column-gap: 10px; }
.campaign-fund-number { display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; margin-top: 1px; border-radius: 50%; background: var(--green); color: var(--ink); font-size: .83rem; font-weight: var(--font-weight-heavy); line-height: 1; letter-spacing: 0; }
.campaign-fund-budget { display: block; margin-top: 5px; font-size: 1.08em; font-weight: var(--font-weight-heavy); letter-spacing: -.025em; }
.campaign-fund-title [data-money-usd] { display: inline; padding: 1px 3px; border-radius: 4px; background: var(--green); box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.campaign-funds p { white-space: pre-line; font-size: .94em; line-height: 1.8; }
.campaign-fund-item p:last-child { margin-bottom: 0; }
.campaign-question { border-bottom: 1px solid var(--line); padding: 19px 0; }
.campaign-question summary { cursor: pointer; color: var(--ink); font-size: 1rem; font-weight: var(--font-weight-bold); line-height: 1.5; }
.campaign-question summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
.campaign-question p { margin: 12px 0 0; color: var(--muted); line-height: 1.8; }
.campaign-gallery-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); align-items: start; }
.campaign-gallery-item { margin: 0; overflow: hidden; border-radius: var(--radius-control); background: var(--image-placeholder); }
.campaign-gallery-item:last-child:nth-child(odd) { grid-column: 1 / -1; }
.campaign-gallery-item img { width: 100%; height: auto; }
.support-button[aria-pressed="true"] { background: var(--support-selected); border-color: var(--support-border); color: var(--ink); }
.support-button[aria-pressed="true"] svg { fill: currentColor; }
.status { font-size: var(--font-size-caption); color: var(--muted); overflow-wrap: anywhere; margin: 10px 0 0; }
.status:empty { display: none; }
.avatar { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--avatar-background); }
.avatar-emblem { display: block; border-radius: 0; background: transparent; color: var(--ink); }
.organizer-emblem-seal { fill: var(--green); }
.campaign-aside { position: sticky; top: 96px; }
.donation-summary { padding: 25px; border-radius: var(--radius-panel); background: var(--paper); box-shadow: var(--shadow-summary); }
.raised { font-size: 2.05rem; font-weight: var(--font-weight-heavy); line-height: 1.15; letter-spacing: -.045em; color: var(--ink); margin: 0 0 5px; }
.funding-counter { display: inline-grid; vertical-align: baseline; white-space: nowrap; }
.funding-counter > span { grid-area: 1 / 1; }
.funding-counter-reserve { visibility: hidden; }
.funding-counter, [data-funding-amount], [data-funding-percent-text] { font-variant-numeric: tabular-nums; }
.goal { margin: 0; font-size: .78rem; color: var(--muted); }
.funding-progress { width: 100%; height: 8px; border: 0; border-radius: 99px; overflow: hidden; background: var(--progress-track); color: var(--green); accent-color: var(--green); display: block; margin: 17px 0 6px; }
.funding-progress::-webkit-progress-bar { background: var(--progress-track); }
.funding-progress::-webkit-progress-value { background: var(--green); border-radius: 99px; }
.funding-progress::-moz-progress-bar { background: var(--green); border-radius: 99px; }
.progress-description { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px; margin: 0 0 22px; color: var(--muted); font-size: .66rem; }
.giving-note { text-align: center; font-size: .71rem; color: var(--muted); margin: var(--space-3) 0 17px; }
.checkout-note { display: flex; align-items: flex-start; gap: 9px; padding: 14px var(--space-3); margin: 17px 0; border: 1px solid var(--line); border-radius: var(--radius-small); background: var(--surface-soft); }
.checkout-note > svg { width: 23px; height: 23px; flex-shrink: 0; color: var(--ink); }
.checkout-note p { font-size: .71rem; line-height: 1.7; margin: 0; color: var(--muted); }
.checkout-note strong { display: block; color: var(--ink); font-weight: var(--font-weight-bold); margin-bottom: 2px; }
.organizer { display: flex; align-items: center; gap: 11px; padding-top: 17px; }
.organizer p { margin: 0; font-size: .76rem; color: var(--ink); font-weight: var(--font-weight-bold); }
.organizer span { display: block; font-size: .67rem; color: var(--muted); }
.campaign-summary { --summary-curve-rise: clamp(16px, 3.5vw, 28px); position: relative; z-index: 1; padding: 24px 28px 18px; border: 1px solid var(--line); border-top: 0; border-radius: 0 0 24px 24px; background: var(--paper); }
.campaign-summary::before { content: ""; position: absolute; top: calc(-1 * var(--summary-curve-rise)); left: -1px; right: -1px; height: var(--summary-curve-rise); border-radius: 50% 50% 0 0 / 100% 100% 0 0; background: var(--paper); pointer-events: none; }
.hero-has-caption + .campaign-summary::before { display: none; }
.campaign-summary, .sticky-donation { --progress-track: var(--line); }
.campaign-funding { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.campaign-funding .progress-ring { width: 80px; height: 80px; }
.campaign-funding .progress-ring > span { font-size: .82rem; }
.summary-funding-copy { min-width: 0; flex: 1; }
.summary-amount-line { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 .3em; margin: 0; color: var(--ink); font-size: clamp(1.05rem, 2.4vw, 1.35rem); line-height: 1.45; }
.summary-amount-line strong { font-weight: var(--font-weight-bold); }
.summary-goal { color: var(--muted); }
.summary-goal-value { text-decoration: underline; text-underline-offset: 3px; }
.summary-funding-status { margin: 5px 0 0; color: var(--muted); font-size: .82rem; line-height: 1.5; }
.mobile-funding { display: flex; align-items: center; gap: 20px; margin-bottom: 22px; }
.mobile-funding > div:last-child { min-width: 0; flex: 1; }
.progress-ring { position: relative; width: 94px; height: 94px; flex-shrink: 0; }
.progress-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.progress-ring circle { stroke-width: 6; }
.progress-ring > span { position: absolute; inset: 0; display: grid; place-items: center; color: var(--ink); font-size: .86rem; font-weight: var(--font-weight-bold); }
.mobile-funding .raised { font-size: 2rem; }
.mobile-funding .goal { font-size: .83rem; line-height: 1.6; }
.summary-donate { min-height: 50px; font-size: 1rem; font-weight: var(--font-weight-semibold); box-shadow: 0 2px 5px rgb(34 34 34 / 10%); }
.summary-donate svg { width: 21px; height: 21px; }
.summary-share { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 44px; margin-top: 8px; padding: 8px 16px; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--muted); font-size: .84rem; font-weight: var(--font-weight-regular); }
.summary-share:hover { background: var(--surface-tint); }
.summary-share svg { width: 18px; height: 18px; }
#icon-heart path { fill: var(--donation-heart-fill, none); stroke: var(--donation-heart-stroke, currentColor); }
[data-open-donation] .donation-heart { transform-origin: center; animation: donation-heart-pulse 2.4s ease-in-out infinite; }
@keyframes donation-heart-pulse { 0%, 48%, 100% { transform: scale(1); } 12% { transform: scale(1.14); } 24% { transform: scale(1); } 36% { transform: scale(1.08); } }
.sticky-donation-trigger { height: 1px; }
.sticky-donation { position: fixed; inset-inline: 0; bottom: 0; z-index: 30; width: 100%; padding: 18px 20px calc(18px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); border-radius: 30px 30px 0 0; background: var(--paper); box-shadow: 0 -8px 32px rgb(34 34 34 / 14%); }
.sticky-donation-inner { display: grid; width: min(760px, 100%); margin-inline: auto; gap: 14px; }
.sticky-donation:not([hidden]) { animation: sticky-donation-enter .28s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes sticky-donation-enter { from { transform: translateY(100%); } to { transform: translateY(0); } }
.sticky-funding .mobile-funding { gap: 16px; margin: 0; }
.sticky-funding .progress-ring { width: 80px; height: 80px; }
.sticky-funding .progress-ring > span { font-size: .72rem; }
.sticky-funding .raised { font-size: 1.7rem; margin-bottom: 3px; }
.sticky-funding .goal { font-size: .76rem; }
.sticky-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.sticky-actions .button { min-height: 48px; padding: 11px 14px; font-size: .86rem; }
.sticky-share { background: var(--ink); color: var(--green); }
.sticky-share:hover { background: var(--ink); filter: brightness(1.15); }
.sticky-donation .status { margin-top: 0; }
body.dialog-open .sticky-donation { display: none; }
.has-donation-bar .footer { padding-bottom: calc(var(--sticky-donation-height, 240px) + 32px + env(safe-area-inset-bottom)); }
.footer { background: var(--paper); border-top: 1px solid var(--line); margin-top: var(--space-12); }
.footer-inner { width: min(100% - 48px, var(--content-width)); margin-inline: auto; padding: 36px 0; }
.footer-trust { min-width: 0; }
.footer-overview { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1.5fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.footer-brand { min-width: 0; }
.footer-brand p { max-width: 32ch; margin: 14px 0 0; color: var(--muted); font-size: .78rem; line-height: 1.75; }
.footer-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; min-width: 0; }
.footer-nav-group h2, .footer-contact h2, .footer-faq h2 { margin: 0 0 12px; color: var(--ink); font-size: .78rem; font-weight: var(--font-weight-bold); line-height: 1.5; letter-spacing: 0; }
.footer-nav-group ul { list-style: none; margin: 0; padding: 0; }
.footer-links a { display: inline-flex; align-items: center; min-height: 32px; padding-block: 5px; color: var(--muted); font-size: .74rem; line-height: 1.5; text-decoration: none; overflow-wrap: anywhere; }
.footer-contact { min-width: 0; }
.footer-email { display: inline-flex; align-items: center; min-height: 44px; max-width: 100%; color: var(--ink); font-size: clamp(.8rem, 1.3vw, 1rem); font-weight: var(--font-weight-semibold); line-height: 1.6; overflow-wrap: anywhere; text-decoration-color: var(--green); text-decoration-thickness: 2px; text-underline-offset: 5px; }
.footer-email:hover { text-decoration-color: var(--ink); }
.footer-support { display: grid; grid-template-columns: minmax(0, 1fr); gap: 36px; align-items: start; margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--line); }
.footer-support:has(> .footer-badges-preview), .footer-support:has(> .footer-badges) { grid-template-columns: minmax(0, 1.4fr) minmax(260px, .8fr); }
.footer-faq { min-width: 0; }
.footer-faq h2 { margin-bottom: 8px; }
.footer-donor-info { margin: 0; border-top: 1px solid var(--line); }
.footer-donor-info details { border-bottom: 1px solid var(--line); }
.footer-donor-info summary { min-height: 44px; padding-block: 12px; cursor: pointer; font-size: .78rem; font-weight: var(--font-weight-semibold); color: var(--ink); line-height: 1.6; }
.footer-donor-info details > p { max-width: 85ch; margin: 0 0 14px; font-size: .76rem; line-height: 1.75; color: var(--muted); }
.footer-donor-info a { color: var(--ink); text-decoration-thickness: 1px; text-underline-offset: 4px; font-weight: var(--font-weight-semibold); }
.footer-donor-info details > a { display: inline-block; margin-bottom: 14px; font-size: .76rem; }
.footer-badges-preview { min-width: 0; }
.footer-badges { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; width: 100%; max-width: 360px; margin: 0 auto; }
.badge-review-context { margin: 0 0 18px; padding: 0; color: var(--muted); font-size: .7rem; line-height: 1.6; text-align: center; }
.footer-badge { min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; padding: 0; border-radius: 8px; color: var(--ink); text-decoration: none; }
.footer-badge img { display: block; width: 84px; height: 84px; object-fit: contain; }
.footer-badge h3, .footer-badge strong { font-size: .73rem; margin: 0; }
.footer-badge p, .footer-badge span { font-size: .65rem; color: var(--muted); margin: 4px 0 0; line-height: 1.5; }
a.footer-badge:hover { text-decoration: underline; text-underline-offset: 3px; }
.footer-bottom { padding-block: 16px; border-top: 1px solid var(--line); }
.copyright { width: min(100% - 48px, var(--content-width)); margin: 0 auto; color: var(--muted); font-size: .68rem; line-height: 1.6; }
.donation-dialog { position: fixed; inset: auto 0 0; width: min(100%, 800px); max-width: 100%; height: min(820px, 96vh); height: min(820px, 96dvh); max-height: 96vh; max-height: 96dvh; padding: 0; margin: 0 auto; border: 1px solid var(--line); border-bottom: 0; border-radius: 28px 28px 0 0; background: var(--paper); color: var(--text); box-shadow: 0 -12px 60px rgb(0 0 0 / 16%); overflow: hidden; overscroll-behavior: contain; }
.donation-dialog[open] { display: flex; flex-direction: column; animation: donation-tray-enter .28s cubic-bezier(.2, .8, .2, 1) both; }
.donation-dialog::backdrop { background: var(--backdrop); }
.donation-dialog[open]::backdrop { animation: donation-backdrop-enter .2s ease-out both; }
.dialog-header { position: relative; flex: 0 0 56px; background: var(--paper); }
.dialog-handle { display: block; width: 44px; height: 5px; margin: 12px auto 0; border-radius: 99px; background: var(--line); }
.dialog-close { position: absolute; top: 8px; right: 16px; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--ink); cursor: pointer; }
.dialog-close:hover { background: var(--surface-soft); }
.dialog-close:focus-visible { outline: 3px solid var(--focus); outline-offset: -3px; }
.dialog-close svg { width: 22px; height: 22px; }
.donation-tray-form { display: flex; flex: 1 1 auto; flex-direction: column; min-height: 0; overflow: hidden; }
.dialog-content { flex: 1 1 auto; min-height: 0; padding: 0 28px 24px; overflow-y: auto; overscroll-behavior: contain; }
.dialog-checkout { flex: 0 0 auto; padding: 16px 28px max(20px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--paper); }
.dialog-checkout .currency-note, .dialog-checkout .status { margin-bottom: 0; }
.donation-dialog .dialog-checkout #checkout-button { animation: none; }
@keyframes donation-tray-enter { from { transform: translateY(100%); opacity: .75; } to { transform: translateY(0); opacity: 1; } }
@keyframes donation-backdrop-enter { from { opacity: 0; } to { opacity: 1; } }
.dialog-kicker { color: var(--muted); text-transform: uppercase; font-size: .65rem; font-weight: var(--font-weight-bold); letter-spacing: .1em; margin-bottom: 12px; }
.dialog-content h2 { font-size: clamp(1.35rem, 4vw, 1.8rem); line-height: 1.25; letter-spacing: -.045em; margin-bottom: 12px; }
.dialog-intro { color: var(--muted); font-size: .88rem; line-height: 1.65; margin-bottom: 24px; }
.donation-dialog .tier-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 0; }
.donation-dialog .tier { min-height: 72px; padding: 16px 8px; font-size: .87rem; }
.donation-dialog .tier-described { flex-direction: column; gap: 8px; min-height: 120px; padding: 18px 10px 16px; text-align: center; }
.tier-amount { font-size: clamp(1.25rem, 4vw, 1.4rem); font-weight: var(--font-weight-bold); line-height: 1.25; white-space: nowrap; }
.tier-description { font-size: .74rem; font-weight: 400; line-height: 1.4; }
.tier-recommended { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); padding: 3px 8px; border-radius: 99px; background: var(--ink); color: var(--paper); font-size: .56rem; font-weight: var(--font-weight-bold); line-height: 1.3; white-space: nowrap; }
.donation-tiers { border: 0; padding: 0; margin: 0; min-width: 0; }
.donation-tiers legend { padding: 0; margin-bottom: 10px; font-size: .78rem; font-weight: var(--font-weight-semibold); }
.tier-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); margin-bottom: 22px; }
.tier { position: relative; display: flex; align-items: center; justify-content: center; gap: 9px; min-height: 62px; padding: 15px; border: 2px solid var(--line); border-radius: var(--radius-control); font-size: .95rem; font-weight: var(--font-weight-semibold); color: var(--ink); cursor: pointer; transition: border-color .15s, background .15s; }
.tier:hover { border-color: var(--tier-border-hover); background: var(--tier-background-hover); }
.tier:has(input:checked) { background: var(--green); border-color: var(--ink); color: var(--ink); }
.tier:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 3px; }
.tier input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.checkout-button { min-height: 54px; font-size: .96rem; }
#checkout-button { box-shadow: 0 6px 18px color-mix(in srgb, var(--green) 40%, transparent); transform-origin: center; }
#checkout-button:disabled { box-shadow: none; }
@keyframes checkout-button-pulse {
  0%, 100% { transform: scale(1); box-shadow: 0 6px 18px color-mix(in srgb, var(--green) 40%, transparent), 0 0 0 0 transparent; }
  50% { transform: scale(1.018); box-shadow: 0 8px 28px color-mix(in srgb, var(--green) 70%, transparent), 0 0 0 7px color-mix(in srgb, var(--green) 15%, transparent); }
}
@media (prefers-reduced-motion: no-preference) {
  #checkout-button:not(:disabled) { animation: checkout-button-pulse 2.4s ease-in-out infinite; }
  #checkout-button:is(:hover, :focus-visible) { animation-play-state: paused; }
}
.dialog-content .checkout-note { margin-top: var(--space-6); }
.dialog-content .checkout-note p { font-size: .76rem; }
.dialog-content .checkout-note > svg { width: 27px; height: 27px; }
.no-script { padding: var(--space-3) var(--space-6); background: var(--notice-background); color: var(--notice-text); font-size: .8rem; text-align: center; }
/* --breakpoint-sidebar */
@media (max-width: 1023px) {
  .content-split { display: block; }
  .campaign-aside { display: none; }
  .page-shell { max-width: var(--reading-width); }
}
/* --breakpoint-navigation */
@media (max-width: 1100px) {
  .header-inner { width: calc(100% - 32px); min-height: 64px; gap: var(--space-3); }
  .header-inner > .brand { font-size: 1.45rem; }
  .header-inner > .brand svg { width: 31px; height: 31px; }
  .header-donate { padding: var(--space-2) 14px; font-size: .73rem; min-height: 42px; }
  .menu-toggle { display: inline-flex; flex-shrink: 0; }
  .main-nav { display: none; position: absolute; left: 0; top: 100%; right: 0; padding: 14px var(--space-5); background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-menu); }
  .main-nav[data-open="true"] { display: flex; flex-direction: column; align-items: stretch; gap: 0; }
  .main-nav a { display: block; padding: 10px 0; min-height: 44px; font-size: .82rem; }
}
/* --breakpoint-mobile */
@media (max-width: 680px) {
  .page-shell { width: 100%; margin-top: 0; }
  .hero { border-radius: 0; }
  .campaign-title { padding: var(--space-5) var(--space-5) 0; }
  h1 { font-size: 1.3rem; }
  .eyebrow { font-size: .64rem; }
  .organizer-line { font-size: .7rem; }
  .campaign-summary { padding: 20px 18px 14px; border-radius: 0 0 22px 22px; }
  .campaign-funding { gap: 14px; margin-bottom: 17px; }
  .campaign-funding .progress-ring { width: 72px; height: 72px; }
  .campaign-funding .progress-ring > span { font-size: .75rem; }
  .summary-amount-line { font-size: 1.05rem; }
  .summary-funding-status { margin-top: 4px; font-size: .76rem; }
  .mobile-funding { gap: 16px; margin-bottom: 20px; }
  .progress-ring { width: 84px; height: 84px; }
  .progress-ring > span { font-size: .76rem; }
  .mobile-funding .raised { font-size: clamp(1.55rem, 7.2vw, 1.9rem); }
  .mobile-funding .goal { font-size: .73rem; }
  .sticky-donation { padding: 16px 20px calc(16px + env(safe-area-inset-bottom)); border-radius: 28px 28px 0 0; }
  .sticky-donation-inner { gap: 12px; }
  .sticky-funding .mobile-funding { gap: 14px; }
  .sticky-funding .progress-ring { width: 72px; height: 72px; }
  .sticky-funding .progress-ring > span { font-size: .65rem; }
  .sticky-funding .raised { font-size: clamp(1.3rem, 6.3vw, 1.6rem); }
  .sticky-funding .goal { font-size: .68rem; }
  .sticky-actions { gap: 10px; }
  .sticky-actions .button { min-height: 46px; padding: 10px; font-size: .76rem; }
  .surface { margin-top: var(--space-3); padding: 23px var(--space-5); border-radius: 0; box-shadow: none; }
  .surface h2 { font-size: 1.12rem; }
  .story { font-size: 1rem; }
  .story-actions .button { flex: 1; padding-inline: 14px; font-size: var(--font-size-caption); }
  .campaign-gallery-grid { grid-template-columns: 1fr; }
  .dialog-content { padding-inline: 20px; padding-bottom: 20px; }
  .dialog-checkout { padding-inline: 20px; }
  .donation-dialog .tier-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .donation-dialog .tier-described { min-height: 104px; padding: 16px 8px; }
  .dialog-content h2 { font-size: 1.35rem; }
  .dialog-intro { font-size: .8rem; margin-bottom: 23px; }
  .tier { min-height: 57px; padding: 13px; font-size: .88rem; }
}
/* --breakpoint-compact */
@media (max-width: 350px) {
  .header-inner { width: calc(100% - 24px); gap: var(--space-2); }
  .header-inner > .brand { font-size: 1.3rem; gap: var(--space-1); }
  .header-donate { padding-inline: 9px; gap: 6px; }
  .header-donate .donation-heart { width: 16px; height: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Home, campaign discovery, and institutional pages share the same surfaces. */
body { min-width: 280px; }
main { min-height: 50vh; }
input, select, textarea { font: inherit; }
.main-nav a[aria-current="page"] { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.site-main { margin-top: var(--space-8); }
.section { margin-block: var(--space-12); scroll-margin-top: 88px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; flex-wrap: wrap; gap: var(--space-4); margin-bottom: var(--space-6); }
.section-heading h1, .section-heading h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: var(--space-2); }
.section-heading p { color: var(--muted); font-size: var(--font-size-small); max-width: 65ch; margin: 0; }
.home-main { width: 100%; margin: 0; }
.home-hero { position: relative; isolation: isolate; display: flex; align-items: flex-end; width: 100%; min-height: clamp(700px, 56.28vw, 940px); overflow: hidden; background: #222222; }
.home-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(180deg, rgba(34, 34, 34, .02) 0%, rgba(34, 34, 34, .08) 36%, rgba(34, 34, 34, .68) 61%, rgba(34, 34, 34, .96) 100%); }
.home-hero-inner { width: min(100% - 48px, var(--content-width)); margin-inline: auto; padding: clamp(300px, 31vw, 520px) 0 48px; }
.hero-copy { min-width: 0; max-width: 920px; }
.kicker { color: var(--ink); font-size: .68rem; font-weight: var(--font-weight-bold); text-transform: uppercase; letter-spacing: .12em; margin-bottom: var(--space-4); }
.hero-copy h1 { color: #fff; font-size: clamp(2.3rem, 4.15vw, 3.75rem); line-height: 1.1; margin-bottom: var(--space-5); text-wrap: balance; }
.hero-copy .kicker { color: #fff; margin-bottom: var(--space-3); }
.hero-copy .lead { color: rgba(255, 255, 255, .92); max-width: 75ch; margin-bottom: 0; line-height: 1.65; }
.home-hero .actions { margin-top: var(--space-6); }
.home-hero .button-outline { color: #fff; border-color: rgba(255, 255, 255, .75); background: rgba(255, 255, 255, .08); }
.home-hero .button-outline:hover { background: rgba(255, 255, 255, .18); }
.lead { color: var(--muted); font-size: 1rem; line-height: 1.8; max-width: 62ch; }
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-7); }
.home-photo { position: absolute; inset: 0; z-index: -2; margin: 0; overflow: hidden; }
.home-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.home-photo figcaption { padding: 6px var(--space-3); color: var(--muted); background: var(--surface-tint); font-size: .61rem; }
.filters { display: flex; align-items: end; justify-content: space-between; gap: var(--space-6); margin-bottom: var(--space-6); }
.chips { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.chip { min-height: 44px; border: 1px solid var(--outline); border-radius: var(--radius-pill); background: var(--paper); color: var(--ink); padding: var(--space-2) var(--space-4); font-size: var(--font-size-caption); font-weight: var(--font-weight-semibold); }
.chip:hover { background: var(--outline-hover); }
.chip[aria-pressed="true"] { color: var(--ink); background: var(--green); border-color: var(--ink); }
.search-field { display: grid; gap: 6px; min-width: 220px; font-size: var(--font-size-caption); font-weight: var(--font-weight-semibold); }
.search-field input, input#search { width: 100%; min-height: 44px; border: 1px solid var(--outline); border-radius: var(--radius-control); padding: 10px var(--space-3); background: var(--paper); color: var(--ink); font-size: var(--font-size-small); }
.campaign-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-6); }
.campaign-card { min-width: 0; overflow: hidden; display: flex; flex-direction: column; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-panel); box-shadow: var(--shadow-surface); }
.campaign-card-image { display: block; margin: 0; background: var(--image-placeholder); }
img.campaign-card-image, .campaign-card-image img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; }
.campaign-card-body { display: flex; flex: 1; flex-direction: column; padding: var(--space-6); }
.campaign-card-meta { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-2); color: var(--muted); font-size: .67rem; margin-bottom: var(--space-3); }
.card-title { font-size: 1.05rem; line-height: 1.45; margin-bottom: var(--space-3); }
.card-title a { text-decoration: none; }
.card-title a:hover { text-decoration: underline; text-underline-offset: 3px; }
.campaign-card-summary { font-size: .8rem; color: var(--muted); line-height: 1.8; margin-bottom: var(--space-5); }
.card-funding { margin-top: auto; }
.card-funding > p { font-size: .71rem; color: var(--muted); margin-bottom: var(--space-2); }
.card-funding > p > strong { font-size: 1.4rem; color: var(--ink); font-weight: var(--font-weight-heavy); }
.card-funding .raised { font-size: 1.4rem; }
.card-funding .goal { font-size: .71rem; }
.card-funding .progress-description { margin-bottom: var(--space-4); }
.campaign-card-footer { margin-top: var(--space-5); }
.campaign-card-footer .button { width: 100%; }
.demo-badge { display: inline-flex; align-items: center; padding: 3px 9px; border-radius: var(--radius-pill); background: var(--notice-background); color: var(--notice-text); font-size: .65rem; font-weight: var(--font-weight-semibold); }
.empty-results { background: var(--paper); color: var(--muted); border: 1px dashed var(--outline); border-radius: var(--radius-panel); padding: var(--space-7); text-align: center; }
.give-section { display: block; width: 100%; max-width: var(--reading-width); margin: var(--space-12) auto; }
.give-copy { width: 100%; min-width: 0; }
.give-copy h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
.give-copy p { color: var(--muted); font-size: var(--font-size-body); }
.give-copy > h2, .give-copy > p { text-align: center; }
.callout { text-align: center; margin-block: var(--space-12); padding: var(--space-12) var(--space-7); }
.callout h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
.callout p { max-width: 65ch; margin-inline: auto; color: var(--muted); font-size: var(--font-size-body); }
.content-page { width: min(100% - 48px, var(--reading-width)); margin-top: var(--space-12); }
.content-page > .section-heading { display: block; text-align: left; }
.content-page > h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin-bottom: var(--space-5); }
.content-page > p { color: var(--muted); line-height: 1.85; }
.content-section { margin-top: var(--space-6); }
.content-section p { font-size: var(--font-size-body); line-height: 1.85; }
.content-section p:last-child { margin-bottom: 0; }
.checkout-unavailable { color: var(--muted); font-size: .8rem; line-height: 1.8; }
.campaign-notice { color: var(--muted); font-size: .75rem; line-height: 1.8; margin-top: var(--space-4); }
.donation-panel { min-width: 0; margin-top: var(--space-6); }
.donation-panel .tier-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-3); }
.donation-panel .tier { min-height: 52px; padding: var(--space-3) var(--space-2); font-size: var(--font-size-small); }
.contact-card { margin-top: var(--space-7); }
.contact-form { display: grid; gap: var(--space-6); }
.contact-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); }
.form-field { display: grid; gap: var(--space-2); min-width: 0; }
.form-field label { color: var(--ink); font-weight: var(--font-weight-semibold); font-size: var(--font-size-small); }
.form-field input, .form-field textarea { width: 100%; border: 1px solid var(--outline); border-radius: var(--radius-control); background: var(--paper); color: var(--ink); padding: 13px 14px; font: inherit; font-size: 16px; }
.form-field textarea { min-height: 160px; resize: vertical; }
.contact-note { margin: 0; color: var(--muted); font-size: .75rem; line-height: 1.7; }
.contact-form .button { justify-self: start; }
.contact-success { text-align: center; padding-block: var(--space-6); }
.contact-success h2 { margin-bottom: var(--space-3); }
.contact-success p { color: var(--muted); font-size: var(--font-size-body); }
.success-icon { display: grid; place-items: center; width: 60px; height: 60px; margin: 0 auto var(--space-5); background: var(--green); color: var(--ink); border-radius: 50%; font-size: 28px; }
.success-icon svg { width: 28px; height: 28px; }

/* --breakpoint-sidebar */
@media (max-width: 1023px) {
  .campaign-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-copy h1 { font-size: clamp(2.2rem, 4.7vw, 3rem); }
  .filters { flex-direction: column; align-items: stretch; gap: var(--space-4); }
  .search-field { min-width: 0; }
}
/* --breakpoint-mobile */
@media (max-width: 680px) {
  .site-main, .content-page { width: calc(100% - 40px); margin-top: var(--space-7); }
  .section { margin-block: var(--space-8); }
  .home-hero { min-height: 0; }
  .home-hero::after { background: linear-gradient(180deg, rgba(34, 34, 34, 0) 0%, rgba(34, 34, 34, .05) 19%, rgba(34, 34, 34, .78) 31%, #222222 47%); }
  .home-hero-inner { width: calc(100% - 40px); padding: clamp(148px, 43vw, 280px) 0 28px; }
  .hero-copy h1 { font-size: clamp(1.75rem, 7.4vw, 2.45rem); line-height: 1.14; margin-bottom: 14px; }
  .hero-copy .kicker { font-size: .6rem; letter-spacing: .1em; margin-bottom: 12px; }
  .hero-copy .lead { font-size: .82rem; line-height: 1.7; }
  .home-hero .actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: stretch; gap: 10px; margin-top: 22px; }
  .home-hero .button { width: 100%; min-height: 44px; padding: 10px 12px; font-size: .74rem; }
  .lead { font-size: var(--font-size-body); }
  .home-photo img { height: auto; aspect-ratio: auto; }
  .campaign-grid { grid-template-columns: 1fr; gap: var(--space-5); }
  .campaign-card-body { padding: var(--space-5); }
  .give-section { padding: var(--space-5); border-radius: var(--radius-panel); margin-block: var(--space-8); }
  .donation-panel .tier-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .callout, .content-section { padding: var(--space-6) var(--space-5); border-radius: var(--radius-panel); }
  .callout { margin-block: var(--space-8); }
  .section-heading h1, .section-heading h2 { font-size: 1.5rem; }
  .content-page > h1 { font-size: 1.8rem; }
  .contact-fields { grid-template-columns: 1fr; }
  .contact-card { padding: var(--space-6) var(--space-5); border-radius: var(--radius-panel); }
  .contact-form .button { width: 100%; }
}

/* Institutional footer: compact columns and readable mobile links. */
@media (max-width: 1023px) {
  .footer-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
  .footer-brand { grid-column: 1; grid-row: 1; }
  .footer-contact { grid-column: 2; grid-row: 1; }
  .footer-links { grid-column: 1 / -1; grid-row: 2; }
}
@media (max-width: 820px) {
  .footer-support:has(> .footer-badges-preview), .footer-support:has(> .footer-badges) { grid-template-columns: minmax(0, 1fr); }
  .footer-badges { max-width: 320px; }
}
@media (max-width: 680px) {
  .footer { margin-top: var(--space-6); }
  .footer-inner { width: calc(100% - 40px); padding-block: 28px; }
  .footer-overview { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .footer-brand, .footer-links, .footer-contact { grid-column: 1; }
  .footer-contact { grid-row: 3; }
  .footer-links { gap: 16px; }
  .footer-links a { min-height: 44px; font-size: .73rem; }
  .footer-email { font-size: 1rem; }
  .footer-support { gap: 28px; margin-top: 28px; padding-top: 24px; }
  .footer-badge img { width: 76px; height: 76px; }
  .copyright { width: calc(100% - 40px); }
}
@media (max-width: 350px) {
  .footer-inner, .copyright { width: calc(100% - 32px); }
}
