/* Base styles */
:root {
    --foundation-navy: #0b2443;
    --foundation-orange: #e66a00;
    --foundation-cream: #f7f9fc;
    --card-gradient-start: #f4f7fb;
    --card-gradient-end: #eef4ff;
    --text-body: #0b2443;
    --text-muted: rgba(11, 36, 67, 0.75);
    font-family: 'MADE TOMMY', 'Poppins', 'Helvetica Neue', Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    background-color: #ffffff;
    color: var(--text-body);
    font-family: 'MADE TOMMY', 'Poppins', 'Helvetica Neue', Arial, sans-serif;
}

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

a {
    color: inherit;
}

/* Navigation */
.navbar {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #ffffff;
    box-shadow: 0 4px 20px rgba(11, 36, 67, 0.08);
    z-index: 1000;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: min(1100px, 92%);
    margin: 0 auto;
    padding: 16px 0;
}

.logo img {
    max-width: 320px;
    height: auto;
}

.navbar__donate {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.paypal-button-image {
    max-width: 220px;
}

/* Content sections */
.content-section {
    background-color: var(--foundation-cream);
    padding: 60px 4%;
}

.content-section:nth-of-type(even) {
    background-color: #ffffff;
}

.content-card {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 48px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 48px;
    border-radius: 32px;
    background: linear-gradient(135deg, var(--card-gradient-start) 0%, var(--card-gradient-end) 100%);
    box-shadow: 0 20px 45px rgba(11, 36, 67, 0.12);
    color: var(--text-body);
}

.content-card--vertical {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
}

.content-card--vertical .content-card__body {
    margin-bottom: 8px;
    width: 100%;
    max-width: min(100%, 880px);
    margin-left: 0;
    margin-right: 0;
    text-align: left;
    align-self: stretch;
}

.content-card--vertical .content-card__text {
    margin-bottom: 12px;
}

.content-card--vertical .content-card__media {
    margin-top: 0;
}

.content-card--video {
    align-items: stretch;
}

.content-card__body {
    flex: 1 1 320px;
    max-width: 540px;
}

.content-card__media {
    flex: 1 1 260px;
    max-width: 440px;
}

.content-card__media img,
.content-card__media picture {
    border-radius: 16px;
    box-shadow: 0 20px 45px rgba(11, 36, 67, 0.18);
    overflow: hidden;
}

.content-card__media picture img {
    border-radius: 16px;
    box-shadow: none;
}

.content-card__media--slider {
    width: 100%;
    max-width: none;
}

.content-card__media--video {
    max-width: 560px;
    width: 100%;
}

.video-frame {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 24px 48px rgba(11, 36, 67, 0.22);
}

.video-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.content-card__eyebrow {
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--foundation-orange);
}

.content-card__title {
    font-size: 2.25rem;
    line-height: 1.2;
    margin-top: 0;         /* ensure headings never add unexpected top space */
    margin-bottom: 16px;
}

.content-card__meta {
    font-weight: 600;
    margin-bottom: 18px;
}

.content-card__text {
    line-height: 1.65;
    margin-bottom: 16px;
    color: var(--text-muted);
}

.content-card__text:last-of-type {
    margin-bottom: 0;
}

.content-card--book .content-card__text:last-of-type {
    margin-bottom: 32px;
}

.content-card__cta-group {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 24px;
}

/* =================== Support section (two rows, images align with each row) =================== */
.support-section .content-card {
    display: grid;
    grid-template-columns: minmax(0,1fr) minmax(300px,520px); /* left text, right images */
    grid-template-rows: auto auto;                             /* row 1: patron, row 2: fundraise */
    column-gap: clamp(32px,6vw,56px);
    row-gap: clamp(24px,3vw,32px);
    align-items: start;
}

/* LEFT column blocks (each occupies its own row)
   Use margins (like Mission section) instead of flex gap so spacing matches exactly */
.support-section .content-card > .content-card__body {
    grid-column: 1;
    grid-row: 1;
    max-width: 640px;
    display: flex;
    flex-direction: column;
    gap: 0;  /* 🔧 remove inter-element gap; use the same margins as Mission */
}
.support-section .content-card > .support-fundraise {
    grid-column: 1;
    grid-row: 2;
    max-width: 640px;
    display: flex;
    flex-direction: column;
    gap: 0;  /* 🔧 match Mission spacing by relying on margins */
}

/* 🔧 Ensure Support section uses the same margin rhythm as Mission */
.support-section .content-card__eyebrow { margin-bottom: 12px; }
.support-section .content-card__title   { margin-top: 0; margin-bottom: 16px; }
.support-section .content-card__text    { margin-top: 0; margin-bottom: 16px; }
.support-section .content-card__text:last-of-type { margin-bottom: 0; }

/* RIGHT column: make each figure a grid child so we can map them to rows */
.support-section .support-media { display: contents; } /* flattens children into the grid */
.support-section .support-media__item:nth-child(1) { grid-column: 2; grid-row: 1; align-self: start; }
.support-section .support-media__item:nth-child(2) { grid-column: 2; grid-row: 2; align-self: start; }

/* Image sizing: keep neat, no ballooning */
.support-section .support-media__item {
    margin: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 45px rgba(11,36,67,.18);
    width: 100%;
    max-width: 520px;                /* prevents oversizing on huge screens */
    aspect-ratio: 16 / 9;            /* consistent height so row 1 & 2 line up cleanly */
}
.support-section .support-media__item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* --- Support Section: align images with their H2s, and match CTA spacing --- */

/* Buttons under “Help us Fundraise” — same spacing as Patreon CTA */
.support-section .support-fundraise__buttons{
    margin-top: 24px;   /* matches .content-card__cta-group */
    gap: 16px;
  }
  
  /* Desktop-only image offsets so tops line up with the H2s */
  @media (min-width: 901px){
    /* Image beside “Become a Patron” */
    .support-section .support-media__item:nth-child(1){
      margin-top: 84px !important;  /* align with Become a Patron H2 */
    }
    /* Image beside “Help us Fundraise” */
    .support-section .support-media__item:nth-child(2){
      margin-top: 24px !important;  /* align with Help us Fundraise H2 */
    }
  }
  /* place this AFTER any previous .support-media__item margin rules */
@media (min-width: 901px){
    .support-section .content-card .support-media__item:nth-child(1){
      margin-top: 54px !important;   /* aligns with “Become a Patron” */
    }
    .support-section .content-card .support-media__item:nth-child(2){
      margin-top: 10px !important;   /* aligns with “Help us Fundraise” */
    }
  }
  
  
/* Button parity (same size as Patreon) */
.support-section .pill-button { min-width: 220px; padding: 14px 32px; }
.support-section .support-fundraise__buttons { display: flex; flex-wrap: wrap; gap: 16px; }
.support-section .support-fundraise__buttons .pill-button { flex: 0 0 auto; min-width: 220px; padding: 14px 32px; }

/* Mobile: stack in reading order */
@media (max-width: 900px) {
    .support-section .content-card {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto auto;
    }
    .support-section .content-card > .content-card__body { grid-row: 1; }
    .support-section .support-media__item:nth-child(1) { grid-column: 1; grid-row: 2; max-width: none; }
    .support-section .content-card > .support-fundraise { grid-row: 3; }
    .support-section .support-media__item:nth-child(2) { grid-column: 1; grid-row: 4; max-width: none; }
    .support-section .support-fundraise__buttons .pill-button { width: 100%; min-width: 0; }
}



/* Buttons */
.pill-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    border-radius: 999px;
    background-color: var(--foundation-orange);
    color: #ffffff;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
    border: none;
    cursor: pointer;
}

.pill-button:hover,
.pill-button:focus {
    background-color: #c45600;
    box-shadow: 0 12px 24px rgba(230, 106, 0, 0.35);
    transform: translateY(-2px);
}

.pill-button--ghost {
    background-color: transparent;
    color: var(--foundation-navy);
    border: 2px solid rgba(11, 36, 67, 0.15);
    box-shadow: none;
}

.pill-button--ghost:hover,
.pill-button--ghost:focus {
    background-color: rgba(11, 36, 67, 0.08);
    color: var(--foundation-navy);
    box-shadow: 0 10px 18px rgba(11, 36, 67, 0.12);
}

/* Slider */
.image-slider {
    width: 100%;
}

.slider-container {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 20px 45px rgba(11, 36, 67, 0.18);
}

.slider-container[data-slider-expandable] {
    cursor: zoom-in;
}

.slider-expand-btn {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background-color: rgba(11, 36, 67, 0.7);
    color: #ffffff;
    font-size: 1.35rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 3;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.slider-expand-btn:hover,
.slider-expand-btn:focus {
    background-color: rgba(230, 106, 0, 0.85);
    transform: translateY(-2px);
    outline: none;
}

.slider-expand-btn:focus-visible {
    box-shadow: 0 0 0 4px rgba(230, 106, 0, 0.35);
}

.slider {
    display: flex;
    transition: transform 1s ease-in-out;
    width: 100%;
}

.slide {
    flex: 0 0 100%;
}

.slide img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.control-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    background-color: rgba(11, 36, 67, 0.6);
    color: #ffffff;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
    z-index: 2;
}

.control-btn:hover {
    background-color: rgba(11, 36, 67, 0.85);
}

.prev-btn { left: 16px; }
.next-btn { right: 16px; }

.pause-play-btn {
    bottom: 16px;
    top: auto;
    left: 50%;
    transform: translate(-50%, 0);
    width: 56px;
    height: 56px;
}

/* Slider lightbox */
.slider-lightbox {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: clamp(24px, 6vw, 72px);
    background-color: rgba(11, 36, 67, 0.9);
    z-index: 4000;
}

.slider-lightbox.is-visible { display: flex; }

.slider-lightbox__content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-lightbox__body {
    width: 100%;
    height: 100%;
    margin: 0 auto;
}

.slider-viewport {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    touch-action: none;
    cursor: grab;
}

.slider-viewport:active { cursor: grabbing; }

.slider-zoom-content {
    width: 100%;
    height: 100%;
    transform-origin: 0 0;
}

.slider-lightbox .slider-container {
    width: 100%;
    height: 100%;
    max-width: 100%;
    border-radius: 32px;
    box-shadow: 0 32px 70px rgba(0, 0, 0, 0.45);
    background-color: #000000;
}

.slider-lightbox .image-slider { height: 100%; }
.slider-lightbox .slider { height: 100%; }

.slider-lightbox .slide {
    height: 100%;
    display: flex;
}

.slider-lightbox .slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background-color: #000000;
}

.slider-lightbox .control-btn {
    width: 60px;
    height: 60px;
    background-color: rgba(0, 0, 0, 0.6);
}

.slider-lightbox .control-btn:hover,
.slider-lightbox .control-btn:focus {
    background-color: rgba(0, 0, 0, 0.85);
}

.slider-lightbox .pause-play-btn {
    bottom: clamp(24px, 5vw, 60px);
    width: 64px;
    height: 64px;
    background-color: rgba(0, 0, 0, 0.65);
}

.slider-lightbox .pause-play-btn:hover,
.slider-lightbox .pause-play-btn:focus {
    background-color: rgba(0, 0, 0, 0.85);
}

.slider-lightbox .slider-expand-btn { display: none; }

.slider-lightbox__reset {
    position: absolute;
    top: clamp(16px, 3vw, 36px);
    left: clamp(16px, 3vw, 36px);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    background-color: rgba(0, 0, 0, 0.55);
    color: #ffffff;
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    z-index: 5;
}

.slider-lightbox__reset:hover,
.slider-lightbox__reset:focus {
    background-color: rgba(230, 106, 0, 0.8);
    transform: translateY(-2px);
    outline: none;
}

.slider-lightbox__reset:focus-visible {
    box-shadow: 0 0 0 4px rgba(230, 106, 0, 0.35);
}

.slider-lightbox__close {
    position: absolute;
    top: clamp(16px, 3vw, 36px);
    right: clamp(16px, 3vw, 36px);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: none;
    background-color: rgba(0, 0, 0, 0.65);
    color: #ffffff;
    font-size: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    z-index: 5;
}

.slider-lightbox__close:hover,
.slider-lightbox__close:focus {
    background-color: rgba(230, 106, 0, 0.85);
    transform: translateY(-2px);
    outline: none;
}

body.no-scroll { overflow: hidden; }

/* Contact and social */
.content-grid {
    display: grid;
    gap: 32px;
    max-width: 1100px;
    margin: 0 auto;
    align-items: stretch;
}

@media (min-width: 900px) {
    .content-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.content-grid .content-card { height: 100%; }

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 0;
}

.contact-form__label {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--foundation-navy);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid rgba(11, 36, 67, 0.16);
    background-color: #ffffff;
    color: var(--foundation-navy);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form textarea {
    min-height: 160px;
    resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: rgba(230, 106, 0, 0.6);
    box-shadow: 0 0 0 4px rgba(230, 106, 0, 0.15);
    outline: none;
}

.contact-form button {
    align-self: flex-start;
    margin-top: 12px;
}

.social-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.social-links li { margin: 0; }

.social-links__button {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 999px;
    background-color: rgba(11, 36, 67, 0.08);
    text-decoration: none;
    font-weight: 600;
    color: var(--foundation-navy);
    transition: transform 0.2s ease, background-color 0.2s ease;
    width: 100%;
}

.social-links__button img {
    width: 36px;
    height: auto;
}

.social-links__button:hover,
.social-links__button:focus {
    background-color: rgba(11, 36, 67, 0.16);
    transform: translateY(-2px);
}

/* ===== Contact & Social: force same top alignment (kept) ===== */
.content-section.contact-and-support .content-grid {
    align-items: start; /* top-align the two cards in the grid */
}
.content-section.contact-and-support .content-card {
    align-items: flex-start; /* override the global 'center' for this section only */
}
.content-section.contact-and-support .content-card__eyebrow,
.content-section.contact-and-support .content-card__title,
.content-section.contact-and-support .content-card__text {
    margin-top: 0;
}
.content-section.contact-and-support .content-card__body { padding-top: 0; }
.content-section.contact-and-support .content-card__body > :first-child { margin-top: 0 !important; }
.content-section.contact-and-support .social-links { margin-top: 0; }

/* Footer */
.site-footer {
    background-color: #ffffff;
    color: var(--foundation-navy);
    font-family: inherit;
    padding: 24px 4%;
    border-top: 1px solid rgba(11, 36, 67, 0.08);
}

.site-footer .container {
    width: min(1100px, 92%);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    text-align: center;
}

.site-footer ul {
    list-style: none;
    display: flex;
    gap: 16px;
    padding: 0;
    margin: 12px 0 0;
}

.site-footer a {
    text-decoration: none;
    font-weight: 600;
    color: var(--foundation-navy);
}

.site-footer a:hover,
.site-footer a:focus {
    text-decoration: underline;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(11, 36, 67, 0.6);
    z-index: 2000;
    padding: 60px 20px;
    overflow-y: auto;
}

.modal-content {
    background-color: #ffffff;
    margin: 0 auto;
    padding: 32px;
    border-radius: 24px;
    max-width: 720px;
    position: relative;
    box-shadow: 0 20px 40px rgba(11, 36, 67, 0.25);
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background-color: rgba(11, 36, 67, 0.08);
    color: var(--foundation-navy);
    font-size: 1.8rem;
    line-height: 1;
    cursor: pointer;
}

.close-btn:hover,
.close-btn:focus {
    background-color: rgba(230, 106, 0, 0.15);
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .logo img { max-width: 260px; }
    .pill-button { padding: 12px 26px; }
}

@media (max-width: 900px) {
    .navbar .container { padding: 12px 0; }
    .logo img { max-width: 200px; }
    .paypal-button-image { max-width: 160px; }

    .content-section { padding: 48px 5%; }
    .content-card { padding: 36px; gap: 32px; }
    .content-card--vertical .content-card__body { max-width: 100%; }
    .content-card__title { font-size: 1.8rem; }
    .content-card__media { max-width: none; }

    .pill-button { width: 100%; justify-content: center; }
    .content-card__cta-group { width: 100%; }

    .support-section .content-card { grid-template-columns: 1fr; }

    .support-section .support-media { justify-self: stretch; max-width: none; align-items: stretch; }

    .support-section .support-fundraise__buttons { flex-direction: column; }
    .support-section .support-fundraise__buttons .pill-button { width: 100%; min-width: 0; }
}

@media (max-width: 540px) {
    .content-card { padding: 28px; }
    .content-card__title { font-size: 1.6rem; }
    .content-card__eyebrow { font-size: 0.75rem; }
    .pill-button { padding: 12px 20px; }
    .control-btn { width: 44px; height: 44px; }
    .pause-play-btn { width: 50px; height: 50px; }
}

/* Contact & Social: increase gap above the social buttons (kept) */
.content-section.contact-and-support .content-card--social .social-links { margin-top: 16px; }
@media (min-width: 900px) {
    .content-section.contact-and-support .content-card--social .social-links {
        margin-top: clamp(40px, 5vw, 20px);
    }
}
