/* ==========================================================================
   donation.css — styles for direct-donation pages on act.electrepublicans.org
   Loaded only by base_donation.html (not base.html).
   Scoped under body.donation-page to guarantee zero interaction with main.css.
   ========================================================================== */

/* -- CRITICAL START -- */
/* Above-the-fold donation styles inlined in <head> for first paint.
 * Covers: reset, headline/body/ask copy, amount grid, monthly toggle, CTA
 * buttons. CRO Phase 1 Task 9.
 */

/* Reset + base */
body.donation-page {
    margin: 0;
    padding: 0;
    background: #ffffff;
    color: #1f2937;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.donation-page * {
    box-sizing: border-box;
}

body.donation-page a {
    color: inherit;
}

body.donation-page .container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Logo header — no border, generous vertical padding */
body.donation-page .donation-logo-header {
    padding: 32px 0 12px;
}

body.donation-page .donation-logo {
    display: block;
    height: 10em;
    width: auto;
    margin: 0 auto;
}

/* Main content wrapper */
body.donation-page .donation-main {
    padding: 36px 0 48px;
    min-height: 60vh;
}

/* Shared donation-root scoping */
body.donation-page #donationRoot {
    display: block;
}

/* Shared copy styles */
body.donation-page .donation-copy {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

body.donation-page .donation-headline {
    margin: 0;
    font-size: 26px;
    font-weight: 800;
    color: #d0021a;
    line-height: 1.15;
}

body.donation-page .donation-subheadline {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
    color: #374151;
    line-height: 1.4;
}

body.donation-page .donation-body {
    font-size: 16px;
    line-height: 1.6;
    color: #374151;
}

body.donation-page .donation-body p {
    margin: 0 0 10px;
}

body.donation-page .donation-body strong {
    color: #1f2937;
}

body.donation-page .donation-pullquote {
    margin: 4px 0;
    padding: 12px 16px;
    border-left: 3px solid #f59e0b;
    background: #fef3c7;
    font-style: italic;
    font-size: 14px;
    color: #78350f;
}

body.donation-page .donation-ask {
    margin: 6px 0 0;
    font-size: 16px;
    font-weight: 700;
    color: #1f2937;
}

/* Amount block */
body.donation-page .donation-amounts {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

body.donation-page .amounts-label {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #1f2937;
}

body.donation-page .amounts-subtitle {
    margin: -4px 0 4px;
    font-size: 14px;
    color: #6b7280;
}

body.donation-page .amount-grid {
    display: grid;
    gap: 8px;
    /* grid-template-columns set per layout below */
}

body.donation-page .amount-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 8px;
    background: #f3f4f6;
    color: #1f2937;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: background-color 0.15s, border-color 0.15s, transform 0.1s;
    cursor: pointer;
}

body.donation-page .amount-button:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
}

body.donation-page .amount-button:active {
    transform: scale(0.98);
}

body.donation-page .amount-button {
    position: relative;  /* anchor for the upper-left checkmark */
}

body.donation-page .amount-button.selected {
    background: #d0021a;
    color: #ffffff;
    border-color: #991b1b;
    box-shadow: 0 2px 4px rgba(185, 28, 28, 0.3);
}

/* SVG checkmark, upper-left corner of selected button (not inline with text) */
body.donation-page .amount-button.selected::before {
    content: "";
    position: absolute;
    top: 6px;
    left: 6px;
    width: 14px;
    height: 14px;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'><polyline points='20 6 9 17 4 12'/></svg>");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    pointer-events: none;
}

body.donation-page .amount-button.selected:hover {
    background: #991b1b;
    border-color: #7f1d1d;
}

/* "Other" amount — button-shaped slot containing a $ prefix + visible text input.
   The inner <input> has its own white background and border so it clearly reads
   as an interactive text field, not just text that's part of a button. */
body.donation-page .amount-button.amount-other {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 6px;
    padding: 6px 10px;
    cursor: text;
}

body.donation-page .amount-other-prefix {
    flex-shrink: 0;
    font-weight: 700;
    font-size: 16px;
    color: #6b7280;
    pointer-events: none;
    line-height: 1;
}

body.donation-page .amount-other-input {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    background: #ffffff;
    border: 1.5px solid #d1d5db;
    border-radius: 3px;
    padding: 8px 8px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    color: #1f2937;
    outline: none;
    transition: border-color 0.15s, box-shadow 0.15s;
    -moz-appearance: textfield;
    -webkit-appearance: none;
    appearance: none;
}

body.donation-page .amount-other-input::-webkit-outer-spin-button,
body.donation-page .amount-other-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

body.donation-page .amount-other-input::placeholder {
    color: #9ca3af;
}

body.donation-page .amount-other-input:focus {
    border-color: #d0021a;
    box-shadow: 0 0 0 2px rgba(185, 28, 28, 0.2);
}

/* Selected state: outer slot turns red like other buttons, but the input
   stays white so it's still obviously a typeable text field. */
body.donation-page .amount-button.amount-other.selected {
    background: #d0021a;
    border-color: #991b1b;
}

body.donation-page .amount-button.amount-other.selected .amount-other-prefix {
    color: #ffffff;
}

body.donation-page .amount-button.amount-other.selected .amount-other-input {
    background: #ffffff;
    color: #1f2937;
    border-color: #ffffff;
}

/* ==========================================================================
   Checkout section (shared across all layouts)
   Contains: "Checkout" label, help line, primary "Pay with card" button,
   "or" divider, and Apple Pay + Google Pay secondary buttons.
   ========================================================================== */

body.donation-page .checkout-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    flex-direction: column;
}

body.donation-page .checkout-label {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 800;
    color: #1f2937;
    display: flex;
    align-items: center;
    gap: 8px;
}

body.donation-page .checkout-icon {
    flex-shrink: 0;
    display: block;
}

body.donation-page .checkout-help {
    margin: 0 0 14px;
    font-size: 13px;
    color: #6b7280;
    line-height: 1.5;
}

/* NextAfter: social proof at the CTA. Replaces the generic gray trust
   copy that used to live here — specific donor counts outperform
   generic reassurance in every A/B test they've run. */
body.donation-page .checkout-social-proof {
    margin: 0 0 14px;
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
    line-height: 1.4;
}

/* Destination-clarity hint rendered below the card CTA. Tells the donor
   what to expect post-click (one-click for returning WinRed donors). */
body.donation-page .checkout-hint {
    margin: 10px 0 4px;
    font-size: 12px;
    color: #6b7280;
    line-height: 1.45;
    text-align: center;
}

/* Wallet button (Apple Pay OR Google Pay) is the SECONDARY CTA — black,
   below the card primary. JS picks one based on browser and removes the
   other so only one ever renders. Slightly smaller padding + font than
   the card button so the visual hierarchy reads primary → secondary. */
body.donation-page .pay-with-wallet-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 14px 16px;
    background: #000000;
    color: #ffffff;
    border: 1px solid #000000;
    border-radius: 4px;
    font-family: inherit;
    font-size: 17px;
    font-weight: 800;
    letter-spacing: 0.2px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.22);
    transition: background-color 0.15s, transform 0.1s;
}
body.donation-page .pay-with-wallet-btn:hover { background: #1f2937; }
body.donation-page .pay-with-wallet-btn:active { transform: scale(0.98); }
body.donation-page .pay-wallet-icon { flex-shrink: 0; pointer-events: none; }

/* Card button is PRIMARY (CRO spec §7, updated 2026-04-20: card carries
   oc=true for one-click returning-donor flow; wallet buttons can't). Size
   tuned to match visual weight of the black wallet button. */
body.donation-page .pay-with-card-btn {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    width: 100%;
    padding: 16px 16px;
    background: #d0021a;
    color: #ffffff;
    border: 1px solid #991b1b;
    border-radius: 4px;
    font-family: inherit;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: 0.2px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(185, 28, 28, 0.3);
    transition: background-color 0.15s, transform 0.1s;
}

body.donation-page .pay-with-card-btn:hover {
    background: #991b1b;
}

body.donation-page .pay-with-card-btn:active {
    transform: scale(0.98);
}

body.donation-page .pay-card-icons {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    pointer-events: none;
}

body.donation-page .pay-card-icon {
    display: block;
    border-radius: 2px;
    overflow: hidden;
}

body.donation-page .pay-btn-text {
    flex: 1 1 auto;
    text-align: center;
    pointer-events: none;
}

body.donation-page .pay-with-or {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 14px 0;
    color: #9ca3af;
    font-size: 11px;
    font-weight: 600;
}

body.donation-page .pay-with-or::before,
body.donation-page .pay-with-or::after {
    content: "";
    flex: 1 1 auto;
    height: 1px;
    background: #e5e7eb;
}

body.donation-page .pay-with-or span {
    padding: 0 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

body.donation-page .payment-alt-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

/* When JS has removed one of the two alt payment buttons (Safari -> Apple Pay
   only, non-Safari -> Google Pay only), collapse to a single full-width button. */
body.donation-page .payment-alt-grid.single {
    grid-template-columns: 1fr;
}

body.donation-page .payment-alt-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 12px;
    background: #000000;
    color: #ffffff;
    border: 1px solid #000000;
    border-radius: 4px;
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.15s, transform 0.1s;
}

body.donation-page .payment-alt-btn:hover {
    background: #1f2937;
}

body.donation-page .payment-alt-btn:active {
    transform: scale(0.98);
}
/* -- CRITICAL END -- */

body.donation-page .payment-alt-icon {
    flex-shrink: 0;
    display: block;
    pointer-events: none;
}

/* Google Pay button gets a white background for the multi-color G */
body.donation-page #googlePayBtn {
    background: #ffffff;
    color: #1f2937;
    border-color: #d1d5db;
}

body.donation-page #googlePayBtn:hover {
    background: #f3f4f6;
    border-color: #9ca3af;
}

body.donation-page .payment-alt-label {
    pointer-events: none;
}

/* ==========================================================================
   Monthly toggle — checkbox variant (default)
   Outer element is a <label> so clicking anywhere in the box toggles
   the checkbox via native browser label behavior (no JS required).
   ========================================================================== */

body.donation-page .monthly-toggle-checkbox {
    margin-top: 6px;
    padding: 12px 14px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    cursor: pointer;  /* entire label is clickable */
}

body.donation-page .monthly-toggle-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #d0021a;
    cursor: pointer;
    flex-shrink: 0;
}

body.donation-page .monthly-toggle-label {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

body.donation-page .monthly-toggle-checkbox .monthly-explanation {
    margin: 0;
    font-size: 14px;
    color: #6b7280;
    flex: 1 1 100%;
    padding-left: 28px;
}

/* ==========================================================================
   Monthly toggle — switch variant (AOC-style)
   Big uppercase label + hint arrow SVG + italic hint line + two buttons.
   A hidden checkbox tracks the binary state for JS/URL compatibility.
   ========================================================================== */

body.donation-page .monthly-toggle-switch {
    margin-top: 6px;
    padding: 20px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
}

body.donation-page .monthly-toggle-switch .monthly-hidden-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

body.donation-page .monthly-switch-title {
    margin: 0;
    font-size: 20px;
    font-weight: 900;
    color: #1f2937;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1;
}

body.donation-page .monthly-switch-hint {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    color: #4b5563;
    font-style: italic;
}

body.donation-page .monthly-switch-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 4px;
}

body.donation-page .monthly-switch-btn {
    padding: 13px 14px;
    background: #f3f4f6;
    color: #1f2937;
    border: 1.5px solid #d1d5db;
    border-radius: 4px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s, transform 0.1s;
}

body.donation-page .monthly-switch-btn:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
}

body.donation-page .monthly-switch-btn:active {
    transform: scale(0.98);
}

body.donation-page .monthly-switch-btn.selected {
    background: #d0021a;
    color: #ffffff;
    border-color: #991b1b;
    box-shadow: 0 2px 4px rgba(185, 28, 28, 0.3);
}

body.donation-page .monthly-switch-btn.selected:hover {
    background: #991b1b;
    border-color: #7f1d1d;
}

/* Footer — precisely mirrors main.css .site-footer rules (survey parity).
   Hardcoded values replace main.css's CSS variables since donation.css
   doesn't import the :root variable block. */

body.donation-page .site-footer {
    background: #ffffff;
    border-top: 1px solid #e5e7eb;
    padding: 2rem 0;
    margin-top: auto;
}

body.donation-page .footer-content {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.6;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

body.donation-page .footer-content p {
    margin-bottom: 1rem;
}

body.donation-page .footer-disclaimer {
    font-weight: 500;
    color: #111827;
}

body.donation-page .footer-address {
    display: inline-block;
    margin-top: 0.25rem;
    font-style: normal;
}

/* FECA Compliance - Paid For Disclaimer */
body.donation-page .footer-paid-for {
    font-weight: 600;
    color: #111827;
    font-size: 12px;
    line-height: 1.4;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    padding: 1rem;
    border-radius: 6px;
    margin: 1.5rem 0;
    text-align: center;
}

body.donation-page .footer-photo-credit {
    font-size: 14px;
    color: #6b7280;
    text-align: center;
    margin-top: 1rem;
    font-style: italic;
}

body.donation-page .footer-links {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
    text-align: center;
}

body.donation-page .footer-links a {
    color: #D0021A;
    text-decoration: none;
    font-weight: 500;
}

body.donation-page .footer-links a:hover {
    text-decoration: underline;
}

body.donation-page .footer-links .separator {
    margin: 0 1rem;
    color: #e5e7eb;
}

/* ==========================================================================
   Layout A — two_column
   ========================================================================== */

body.donation-page.layout-two_column #donationRoot {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 56px;
    padding: 16px 0;
    align-items: start;
}

/* Ladder two_column step scaffold: single centered column (no persuasion
   copy). The donation shell inside #ladderDonationShell keeps its own
   #donationRoot 2-col grid via the rule above. */
body.donation-page.layout-two_column #ladderStepGrid {
    display: block;
    max-width: 560px;
    margin: 0 auto;
    padding: 16px 0;
}

body.donation-page.layout-two_column .donation-copy {
    gap: 16px;
}

body.donation-page.layout-two_column .donation-headline {
    font-size: 32px;
    line-height: 1.12;
}

body.donation-page.layout-two_column .donation-subheadline {
    font-size: 17px;
    font-weight: 500;
    color: #374151;
}

body.donation-page.layout-two_column .donation-body {
    font-size: 16px;
    line-height: 1.65;
}

body.donation-page.layout-two_column .donation-ask {
    font-size: 17px;
}

body.donation-page.layout-two_column .amounts-label {
    font-size: 17px;
    font-weight: 800;
}

body.donation-page.layout-two_column .amount-grid {
    grid-template-columns: repeat(4, 1fr);
}

/* ==========================================================================
   Layout C — floating_form (600px positioned container over a bg image)
   The survey-container IS donationRoot (direct donation) OR wraps donationRoot
   (ladder donation shell). Both paths resolve to the same internal styling.
   ========================================================================== */

body.donation-page.layout-floating_form .donation-logo-header {
    display: none;  /* logo moves inside the floating form */
}

body.donation-page.layout-floating_form .donation-main {
    padding: 48px 0 48px;
    /* Force the main area to fill at least the viewport height so the
       footer/compliance block sits below the fold — donors should never
       see it without deliberately scrolling past the form. */
    min-height: 100vh;
}

body.donation-page.layout-floating_form #donationRoot {
    padding: 28px 28px 32px;
    display: block;
}

body.donation-page.layout-floating_form .donation-logo-floating {
    display: block;
    height: 7em;
    width: auto;
    margin: 0 auto 16px;
}

body.donation-page.layout-floating_form .donation-copy {
    gap: 12px;
    margin-bottom: 20px;
}

body.donation-page.layout-floating_form .donation-headline {
    font-size: 26px;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.01em;
    color: #d0021a;
    text-align: left;
    margin: 0;
}

body.donation-page.layout-floating_form .donation-subheadline {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.35;
    color: #4b5563;
    text-align: left;
    margin: 0;
}

body.donation-page.layout-floating_form .donation-body {
    font-size: 16px;
    line-height: 1.6;
}

body.donation-page.layout-floating_form .amounts-label {
    font-size: 16px;
    font-weight: 800;
}

body.donation-page.layout-floating_form .amount-grid {
    grid-template-columns: repeat(4, 1fr);
}

/* ==========================================================================
   Layout D — photo_split (AOC-style, hero photo right + copy/amounts left)
   Full-bleed: no container, no top logo header. Logo lives inside the
   content column. Photo fills the right column edge-to-edge.
   ========================================================================== */

body.donation-page.layout-photo_split .donation-main {
    padding: 0;
    min-height: 0;
}

body.donation-page.layout-photo_split #donationRoot,
body.donation-page.layout-photo_split #ladderStepGrid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 0;
    width: 100%;
    align-items: start;  /* let content flow naturally, hero stays sticky */
}

body.donation-page.layout-photo_split .donation-content-col {
    padding: 56px 48px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    background: #ffffff;
}

body.donation-page.layout-photo_split .donation-logo-inline {
    display: block;
    height: 10em;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    align-self: center;  /* center within flex-column, prevent stretching */
    margin: 0 0 8px;
}

body.donation-page.layout-photo_split .donation-copy {
    gap: 16px;
}

body.donation-page.layout-photo_split .donation-headline {
    font-size: 30px;
    line-height: 1.12;
}

body.donation-page.layout-photo_split .donation-subheadline {
    font-size: 17px;
    font-weight: 500;
    color: #374151;
}

body.donation-page.layout-photo_split .donation-body {
    font-size: 16px;
    line-height: 1.65;
}

body.donation-page.layout-photo_split .donation-ask {
    font-size: 17px;
}

body.donation-page.layout-photo_split .amounts-label {
    font-size: 17px;
    font-weight: 800;
}

/* Right panel: sticky to viewport, never scrolls past. Photo fills the
   panel edge-to-edge via background-size: cover (will crop to fit). */
body.donation-page.layout-photo_split .donation-hero-image {
    position: sticky;
    top: 0;
    align-self: start;
    height: 100vh;
    width: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: #0f172a;  /* fallback while image loads */
}

body.donation-page.layout-photo_split .amount-grid {
    grid-template-columns: repeat(4, 1fr);
}

/* ==========================================================================
   Mobile breakpoint — 768px and below
   two_column and photo_split collapse to stacked single column.
   All layouts use a 2-column amount grid on mobile for easier tapping.
   ========================================================================== */

@media (max-width: 768px) {
    body.donation-page .container {
        padding: 0 16px;
    }

    body.donation-page .donation-main {
        padding: 24px 0 36px;
    }

    body.donation-page .donation-headline {
        font-size: 22px;
    }

    /* Layout A: two_column → stack */
    body.donation-page.layout-two_column #donationRoot {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    body.donation-page.layout-two_column .amount-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Layout D: photo_split → stack, HIDE the hero image entirely on mobile.
       On narrow viewports the photo loses its full-bleed impact and just
       eats vertical space that mobile donors need for the form. */
    body.donation-page.layout-photo_split #donationRoot {
        grid-template-columns: 1fr;
    }

    body.donation-page.layout-photo_split .donation-hero-image {
        display: none;
    }

    body.donation-page.layout-photo_split .donation-content-col {
        padding: 28px 20px;
    }

    body.donation-page.layout-photo_split .amount-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Layout C: floating_form → hide the mobile header image (keep just the
       inline logo inside the form) and drop the amount grid to 2-col so the
       grid reads as 2x4 instead of 4x2 on narrow viewports. Also collapse
       the inner #donationRoot horizontal padding — it stacks with the
       .container gutters on narrow screens and eats usable form width. */
    body.donation-page.layout-floating_form .mobile-header-image {
        display: none;
    }

    body.donation-page.layout-floating_form #donationRoot {
        padding: 24px 16px 28px;
    }

    body.donation-page.layout-floating_form .amount-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ==========================================================================
   Ladder persuasion column — shown in two_column / photo_split layouts
   for ladder pages. Visually mirrors .donation-copy so authors migrating
   between donation and ladder pages get the same look on static copy.
   ========================================================================== */

body.ladder-page .ladder-persuasion {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

body.ladder-page .ladder-persuasion-headline {
    margin: 0;
    font-size: 32px;
    font-weight: 800;
    color: #d0021a;
    line-height: 1.12;
}

body.ladder-page .ladder-persuasion-subheadline {
    margin: 0;
    font-size: 17px;
    font-weight: 500;
    color: #374151;
    line-height: 1.4;
}

body.ladder-page .ladder-persuasion-body {
    font-size: 16px;
    line-height: 1.65;
    color: #374151;
}

body.ladder-page .ladder-persuasion-body p {
    margin: 0 0 10px;
}

body.ladder-page .ladder-persuasion-body strong {
    color: #1f2937;
}

body.ladder-page .ladder-persuasion-pullquote {
    margin: 4px 0;
    padding: 12px 16px;
    border-left: 3px solid #f59e0b;
    background: #fef3c7;
    font-style: italic;
    font-size: 14px;
    color: #78350f;
}

/* ==========================================================================
   Ladder intro step — lead-capture form visual well and intro-active
   persuasion suppression. On the intro step the persuasion column is hidden
   (step title/subtitle carry the hook copy); once the user advances past
   intro, the persuasion column re-appears as static context for the ladder.
   ========================================================================== */

/* Ladder photo_split / two_column: the persuasion column duplicates the
   step-content framing and creates competing hierarchy on every step, not
   just intro. Hide it across the board. The hero photo (photo_split) and
   the step itself carry the messaging. two_column's step scaffold
   (#ladderStepGrid) collapses to a single centered column; the donation
   shell keeps its own 2-col grid. */
body.ladder-page.layout-two_column .ladder-persuasion,
body.ladder-page.layout-photo_split .ladder-persuasion {
    display: none;
}

/* Ladder donation shell — hidden until the final donation step is reached.
   renderLadderDonationStep toggles display inline + adds body class
   ladder-donation-active. Survey container is hidden symmetrically. */
body.ladder-page .ladder-donation-shell {
    display: none;
}

body.ladder-page.ladder-donation-active #ladderStepGrid,
body.ladder-page.ladder-donation-active #surveyContainer {
    display: none !important;
}

body.ladder-page.ladder-donation-active #ladderDonationShell {
    display: block;
}

/* Intro form well — subtle border + rounded + padding so the lead-capture
   form has visual shape in two_column and photo_split. Applied only on the
   intro step (primer steps don't need it — yes/no buttons carry their own
   structure). floating_form's intro opts out — the survey container already
   has its own surface treatment. Donation pages don't use this selector. */
body.ladder-page.ladder-intro-active .survey-content .form-step {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 32px 32px 28px;
    background: #ffffff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

body.ladder-page.ladder-intro-active.layout-floating_form .survey-content .form-step {
    border: none;
    padding: 0;
    background: transparent;
    box-shadow: none;
}

/* ─────────────────────────────────────────────────────────────── *
 * Featured amount (CRO Phase 1, Task 7): donation.featured_amount
 * renders a "Recommended" badge above the button and pre-selects
 * it on page load. Donors see a committed state without tapping.
 * See docs/superpowers/specs/2026-04-18-cro-overhaul-design.md §5.3
 * ─────────────────────────────────────────────────────────────── */
.amount-button.featured {
    position: relative;
    overflow: visible;
    border-width: 2px;
}
.amount-button.featured .amount-value {
    display: block;
}
.amount-badge {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--er-navy, #0b2a5b);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 3px;
    letter-spacing: 0.04em;
    white-space: nowrap;
    z-index: 2;
    pointer-events: none;
}

/* Hero image in photo_split layout — <picture> replaces CSS background */
body.donation-page.layout-photo_split .donation-hero-image picture,
body.donation-page.layout-photo_split .donation-hero-image .hero-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}
body.donation-page.layout-photo_split .donation-hero-image {
    position: sticky;
    /* existing rules still apply; the picture fills via absolute positioning */
}

/* ─────────────────────────────────────────────────────────────── *
 * Phase 2 donation fields: value_prop, goal_progress, urgency,
 * social_proof. CRO Phase 2 Task 3.
 * ─────────────────────────────────────────────────────────────── */
/* value_prop callout — floating label pattern, matches "Recommended"
   badge treatment on the amount grid. Label half-overlaps the top edge
   so the callout reads as an intentional design element, not a tacked-
   on copy block. */
body.donation-page .donation-value-prop {
    position: relative;
    margin: 18px 0 14px;
    padding: 18px 16px 14px;
    background: #f9fafb;
    border-left: 4px solid var(--er-navy, #0b2a5b);
    border-radius: 4px;
    font-size: 14px;
    line-height: 1.5;
    color: #2d3338;
}
body.donation-page .value-prop-label {
    position: absolute;
    top: -10px;
    left: 12px;
    padding: 3px 10px;
    background: var(--er-navy, #0b2a5b);
    color: #ffffff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.2px;
    line-height: 1.4;
    border-radius: 3px;
    text-transform: uppercase;
}

body.donation-page .donation-goal-progress {
    margin: 12px 0;
    padding: 12px 14px;
    background: #ffffff;
    border: 1px solid #e6ebf0;
    border-radius: 6px;
}
body.donation-page .goal-thermo-label {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 14px;
    font-weight: 500;
    color: #1f2937;
    margin-bottom: 10px;
}
body.donation-page .goal-thermo-amounts strong {
    color: #0b2a5b;
    font-size: 15px;
}
body.donation-page .goal-thermo-track {
    height: 14px;
    background: #e6ebf0;
    border-radius: 7px;
    overflow: hidden;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.06);
}
body.donation-page .goal-thermo-fill {
    height: 100%;
    background: linear-gradient(to right, #0b2a5b, #c8102e);
    border-radius: 7px;
    transition: width 600ms ease-out;
}

body.donation-page .donation-urgency {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin: 8px 0 12px;
    padding: 10px 14px;
    background: #fff7ed;
    border-left: 4px solid #ea580c;
    border-top: 1px solid #fed7aa;
    border-right: 1px solid #fed7aa;
    border-bottom: 1px solid #fed7aa;
    border-radius: 6px;
    font-size: 13px;
    color: #7c2d12;
}
body.donation-page .urgency-lockup {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
body.donation-page .urgency-icon {
    flex-shrink: 0;
}
body.donation-page .urgency-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
body.donation-page .urgency-reason {
    font-weight: 700;
    line-height: 1.2;
}
body.donation-page .urgency-deadline {
    font-weight: 600;
    font-size: 12px;
    color: #9a3412;
    line-height: 1.3;
    margin-top: 1px;
}
body.donation-page .urgency-countdown {
    font-variant-numeric: tabular-nums;
    font-weight: 800;
    font-size: 14px;
    color: #9a3412;
    flex-shrink: 0;
    white-space: nowrap;
}
body.donation-page .urgency-countdown:empty {
    display: none;
}

body.donation-page .donation-social-proof {
    margin: 8px 0 0;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--er-navy, #0b2a5b);
    letter-spacing: 0.02em;
}
body.donation-page .social-proof-count {
    font-weight: 900;
}
