/* ============================================================================
   Donation — amount chips, payee selector, UPI app pay buttons, PDF receipt.
   Palette matches the ID card: Maroon #6e0d0d · Gold #c9a24a · Cream #fffdf6
   ============================================================================ */

/* Quick-amount chips */
.amount-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.amount-chip {
    border: 1.5px solid #c9a24a;
    background: #fffdf6;
    color: #7f2626;
    border-radius: 999px;
    padding: 6px 16px;
    font-weight: 700;
    font-size: 0.88rem;
    cursor: pointer;
    transition: background 0.12s ease, color 0.12s ease;
}

.amount-chip:hover { background: #faf1dd; }

.amount-chip.is-active {
    background: #7f2626;
    color: #fff;
    border-color: #7f2626;
}

/* Payee radio cards */
.payee-options {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 6px;
}

.payee-option {
    flex: 1 1 200px;
    border: 1.5px solid #e7c878;
    border-radius: 12px;
    padding: 10px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 9px;
    background: #fffdf6;
    transition: background 0.12s ease, border-color 0.12s ease;
}

.payee-option:hover { background: #faf1dd; }

.payee-option.is-active {
    border-color: #7f2626;
    background: #fdf3e7;
    box-shadow: 0 2px 8px -4px rgba(110, 13, 13, 0.4);
}

.payee-option input {
    accent-color: #7f2626;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.payee-option span {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.payee-option strong { color: #7f2626; font-size: 0.9rem; }
.payee-option small { color: #5c4b3f; font-size: 0.78rem; }

/* Two-step pay flow with numbered badges */
.pay-step {
    margin-top: 1.3rem;
    padding-top: 1.2rem;
    border-top: 1px dashed rgba(201, 162, 74, 0.55);
}

.pay-step-head {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #7f2626;
    font-weight: 800;
    font-size: 1rem;
    margin-bottom: 0.75rem;
}

.step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 27px;
    height: 27px;
    border-radius: 50%;
    background: linear-gradient(180deg, #8a1414, #6e0d0d);
    color: #ffe7c2;
    font-size: 0.9rem;
    font-weight: 800;
    flex-shrink: 0;
    box-shadow: 0 2px 6px -2px rgba(110, 13, 13, 0.6);
}

/* Prominent amount input with a rupee prefix */
.amount-input { position: relative; }

.amount-cur {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-weight: 800;
    color: #7f2626;
    font-size: 1.3rem;
    pointer-events: none;
}

.amount-input .field-control {
    padding-left: 42px;
    font-size: 1.35rem;
    font-weight: 700;
    color: #6e0d0d;
}

.amount-input .field-control::placeholder {
    font-size: 0.95rem;
    font-weight: 500;
}

/* Prominent full-width primary CTA on the donation form */
#donationForm .summary-actions {
    margin-top: 1.1rem;
}

#donationForm .summary-actions .btn-mandir {
    width: 100%;
    justify-content: center;
    font-size: 1rem;
    padding: 14px 18px;
}

/* UPI app pay buttons */
.pay-apps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
}

.pay-app {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 10px;
    border: 1px solid #e6dcc4;
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #fbf6ec 100%);
    color: #33291f;
    font-weight: 800;
    font-size: 0.85rem;
    cursor: pointer;
    text-decoration: none;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.85),
        0 5px 13px -7px rgba(74, 26, 10, 0.3);
    transition: transform 0.14s ease, box-shadow 0.2s ease;
}

.pay-app:hover {
    transform: translateY(-2px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.85),
        0 11px 20px -8px rgba(74, 26, 10, 0.35);
}

.pay-app:active { transform: translateY(0); }

/* Brand logo badge */
.pay-ico {
    width: 25px;
    height: 25px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1;
}

.pay-ico svg { width: 23px; height: 23px; display: block; }
.pay-ico.pp { background: #5f259f; }
.pay-ico.bhim { background: #17457f; }
.pay-ico.upi { background: linear-gradient(135deg, #f26522, #0f9d58); font-size: 0.72rem; }

/* Brand-coloured wordmarks */
.pay-name.pp { color: #5f259f; }
.pay-name.bhim { color: #17457f; }
.pay-paytm-a { color: #002970; }
.pay-paytm-b { color: #00b9f1; }

/* ── Receipt template (rendered off-screen -> PDF) ── */
.receipt-stage {
    position: fixed;
    left: -10000px;
    top: 0;
    width: 620px;
    z-index: -1;
    pointer-events: none;
}

.receipt {
    width: 620px;
    box-sizing: border-box;
    background: #fffdf6;
    color: #2c1a12;
    font-family: 'Noto Sans Devanagari', 'Montserrat', sans-serif;
    border: 3px solid #c9a24a;
    -webkit-font-smoothing: antialiased;
}

.rcp-header {
    background: linear-gradient(155deg, #8a1414, #6e0d0d 60%, #4f0707);
    color: #fff;
    text-align: center;
    padding: 22px 20px 16px;
    border-bottom: 3px solid #c9a24a;
}

.rcp-logo {
    width: 70px;
    height: 70px;
    object-fit: contain;
    border-radius: 50%;
    background: #fffdf6;
    border: 2px solid #c9a24a;
    margin-bottom: 8px;
}

.rcp-jai { color: #f0cd80; font-size: 13px; font-weight: 700; letter-spacing: 1px; }
.rcp-trust-hi { font-size: 22px; font-weight: 800; margin-top: 4px; }
.rcp-trust-en { color: #f0cd80; font-size: 12px; letter-spacing: 1.5px; margin-top: 2px; }
.rcp-addr { color: #e9c98f; font-size: 11px; margin-top: 5px; }

.rcp-badge {
    display: inline-block;
    margin-top: 12px;
    background: linear-gradient(180deg, #f6dd9c, #d9b252 55%, #b88f30);
    color: #571010;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 1px;
    padding: 6px 22px;
    border-radius: 999px;
    border: 1.5px solid #fff0c8;
}

.rcp-body { padding: 22px 26px 8px; }

.rcp-meta {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}

.rcp-meta > div { display: flex; flex-direction: column; }
.rcp-meta span { color: #9a7424; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.4px; }
.rcp-meta strong { color: #2c1a12; font-size: 14px; }

.rcp-ack { color: #5c4b3f; font-size: 13px; margin-bottom: 12px; }

.rcp-line {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding: 7px 0;
    border-bottom: 1px dashed rgba(201, 162, 74, 0.5);
}

.rcp-line span { color: #9a7424; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.3px; flex-shrink: 0; }
.rcp-line strong { color: #2c1a12; font-size: 14px; text-align: right; word-break: break-word; }

.rcp-amount {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 14px 0;
    padding: 14px 18px;
    background: linear-gradient(180deg, #fff5e8, #fdf0dd);
    border: 1.5px solid #c9a24a;
    border-radius: 12px;
}

.rcp-amount span { color: #7f2626; font-size: 13px; font-weight: 800; }
.rcp-amount strong { color: #6e0d0d; font-size: 26px; font-weight: 800; }

.rcp-note {
    margin-top: 16px;
    padding: 11px 14px;
    background: rgba(201, 162, 74, 0.08);
    border: 1px solid rgba(201, 162, 74, 0.4);
    border-radius: 10px;
    color: #5c4b3f;
    font-size: 11px;
    line-height: 1.5;
}

.rcp-sign { display: flex; justify-content: flex-end; margin-top: 18px; }
.rcp-sign-box { text-align: center; }
.rcp-sign-box img { width: 120px; max-height: 86px; object-fit: contain; display: block; margin: 0 auto; }
.rcp-sign-box span { color: #2c1a12; font-size: 10px; font-weight: 700; }

.rcp-footer {
    margin-top: 14px;
    background: linear-gradient(155deg, #8a1414, #6e0d0d 60%, #4f0707);
    border-top: 3px solid #c9a24a;
    color: #ffe7c2;
    text-align: center;
    font-size: 11px;
    padding: 11px 14px;
    line-height: 1.7;
}

/* ============================================================================
   PREMIUM PASS (donate page only — this stylesheet loads only on donate.html)
   Layered shadows, fine gold hairlines, subtle gradients, refined type.
   ============================================================================ */

/* ── Elevated QR cards with a gold crown line ── */
.qr-card {
    position: relative;
    overflow: hidden;
    padding: 1.9rem 1.5rem 1.6rem;
    background:
        radial-gradient(130% 60% at 50% -12%, rgba(201, 162, 74, 0.13), transparent 60%),
        linear-gradient(180deg, #fffefb 0%, #fdf5e7 100%);
    border: 1px solid #e6cd90;
    border-radius: 22px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.85),
        0 22px 46px -26px rgba(74, 26, 10, 0.55),
        0 6px 16px -10px rgba(74, 26, 10, 0.28);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.qr-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #c9a24a 18%, #f3d488 50%, #c9a24a 82%, transparent);
}

.qr-card:hover {
    transform: translateY(-5px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.85),
        0 32px 58px -26px rgba(74, 26, 10, 0.6),
        0 10px 22px -10px rgba(74, 26, 10, 0.34);
}

.qr-card h3 {
    font-size: 1.16rem;
    letter-spacing: 0.2px;
    margin-bottom: 0.45rem;
}

/* Role → elegant gold pill (resets the chunky 46px icon badge) */
.qr-role {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 0.9rem;
    padding: 4px 13px 4px 11px;
    background: linear-gradient(180deg, rgba(201, 162, 74, 0.18), rgba(201, 162, 74, 0.08));
    border: 1px solid rgba(201, 162, 74, 0.45);
    border-radius: 999px;
    color: #8a5a1a;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.2px;
}

.qr-card .qr-role i {
    display: inline;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0;
    background: none;
    border-radius: 0;
    color: #b8892f;
    font-size: 0.82em;
}

/* UPI id → refined monospace chip */
.qr-upi {
    display: inline-block;
    margin-bottom: 1rem;
    padding: 7px 14px;
    background: #fffaf0;
    border: 1px dashed rgba(201, 162, 74, 0.6);
    border-radius: 9px;
    font-size: 0.85rem;
    color: #5c4b3f;
}

.qr-upi strong {
    color: #6e0d0d;
    font-family: 'Consolas', 'Courier New', monospace;
    letter-spacing: 0.3px;
}

/* QR image → clean white frame with a fine gold edge */
.qr-card .qr-image-wrap {
    max-width: 238px;
    margin: 0 auto 1.15rem;
    padding: 8px;
    background: #ffffff;
    border: 1px solid #e6cd90;
    border-radius: 16px;
    box-shadow:
        inset 0 0 0 3px #fffdf6,
        0 14px 28px -16px rgba(74, 26, 10, 0.5);
}

.qr-card .qr-image-wrap img {
    border-radius: 10px;
}

/* Premium "Pay via UPI" — embossed maroon with a gold hairline */
.qr-actions .btn-mandir {
    background: linear-gradient(180deg, #9a1b1b 0%, #7a1010 48%, #5c0808 100%);
    border: 1px solid #caa457;
    color: #fff2df;
    letter-spacing: 0.3px;
    box-shadow:
        inset 0 1px 0 rgba(255, 224, 168, 0.38),
        inset 0 -1px 0 rgba(0, 0, 0, 0.22),
        0 10px 22px -12px rgba(110, 13, 13, 0.85);
    transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.15s ease;
}

.qr-actions .btn-mandir:hover {
    transform: translateY(-2px);
    filter: brightness(1.05);
    box-shadow:
        inset 0 1px 0 rgba(255, 224, 168, 0.42),
        0 16px 30px -12px rgba(110, 13, 13, 0.9);
}

/* Premium secondary buttons */
.qr-actions .copy-btn {
    background: linear-gradient(180deg, #fffdf7 0%, #fbf1db 100%);
    border: 1px solid #d9bd7e;
    color: #7a1a1a;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.85),
        0 3px 8px -4px rgba(74, 26, 10, 0.3);
    transition: transform 0.14s ease, background 0.14s ease;
}

.qr-actions .copy-btn:hover {
    background: linear-gradient(180deg, #fffdf7 0%, #f6e8c8 100%);
    transform: translateY(-1px);
}

/* ── Elevated form panel with the same gold crown line ── */
.summary-panel {
    position: relative;
    overflow: hidden;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.7),
        0 26px 52px -30px rgba(74, 26, 10, 0.5),
        0 6px 16px -10px rgba(74, 26, 10, 0.24);
}

.summary-panel::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #c9a24a 18%, #f3d488 50%, #c9a24a 82%, transparent);
}

/* Refined amount input, chips, pay apps, notice */
.amount-input .field-control {
    box-shadow: inset 0 2px 5px -3px rgba(74, 26, 10, 0.25);
}

.amount-chip {
    box-shadow: 0 2px 5px -3px rgba(74, 26, 10, 0.35);
}

.donate-note {
    background: linear-gradient(180deg, rgba(201, 162, 74, 0.13), rgba(201, 162, 74, 0.05));
    border: 1px solid rgba(201, 162, 74, 0.45);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

/* Optional payment-screenshot preview */
.shot-preview {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 8px 0 0;
    padding: 8px 10px;
    background: #fffaf0;
    border: 1px solid #e6cd90;
    border-radius: 10px;
}

.shot-preview[hidden] { display: none; }

.shot-preview img {
    width: 54px;
    height: 54px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #d9bd7e;
    flex-shrink: 0;
}

.shot-ok {
    color: #2e7d32;
    font-size: 0.82rem;
    font-weight: 700;
}

.shot-remove {
    margin-left: auto;
    background: #fff;
    border: 1px solid #d9bd7e;
    color: #7f2626;
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}

.shot-remove:hover { background: #f6ecd6; }

/* ── Payment QR box (generated, fixed-amount) ── */
.pay-qr-box {
    margin-top: 1.3rem;
    padding: 1.4rem 1rem 1.1rem;
    text-align: center;
    background: linear-gradient(180deg, #fffefb, #fdf5e7);
    border: 1px solid #e6cd90;
    border-radius: 16px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8), 0 12px 30px -18px rgba(74, 26, 10, 0.5);
}

.pay-qr-box[hidden] { display: none; }

.pay-qr-head {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    color: #7f2626;
    font-weight: 800;
    font-size: 0.95rem;
    margin-bottom: 0.4rem;
}

.pay-qr-amount {
    color: #6e0d0d;
    font-size: 1.9rem;
    font-weight: 800;
    margin-bottom: 0.9rem;
}

.pay-qr-render {
    display: inline-block;
    padding: 12px;
    background: #fff;
    border: 1px solid #e6cd90;
    border-radius: 14px;
    box-shadow: 0 12px 26px -16px rgba(74, 26, 10, 0.5);
    line-height: 0;
}

.pay-qr-render img,
.pay-qr-render canvas { display: block; }

.pay-qr-payee {
    margin: 0.9rem auto 0;
    font-size: 0.82rem;
    color: #5c4b3f;
    font-weight: 700;
    word-break: break-word;
}

.pay-qr-payee i { color: #b8892f; margin-right: 5px; }

.pay-qr-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin: 1rem auto 0.5rem;
    max-width: 430px;
}

.pay-qr-actions .btn-mandir {
    flex-basis: 100%;
    justify-content: center;
    min-height: 0;
    padding: 12px 18px;
    border-radius: 12px;
}

.pay-qr-actions .copy-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex: 1 1 40%;
    margin: 0;
    padding: 10px 12px;
    border: 1px solid #d9bd7e;
    border-radius: 10px;
    background: linear-gradient(180deg, #fffdf7, #fbf1db);
    color: #7a1a1a;
    font-weight: 700;
    font-size: 0.82rem;
    cursor: pointer;
    transition: background 0.12s ease;
}

.pay-qr-actions .copy-btn:hover { background: linear-gradient(180deg, #fffdf7, #f6e8c8); }

.pay-qr-box .field-hint { justify-content: center; text-align: center; }
.pay-qr-box .field-hint i { color: #b8892f; margin-right: 4px; }

/* ── Donation acknowledgement letter (rendered off-screen -> PDF) ── */
.letter-stage {
    position: fixed;
    left: -10000px;
    top: 0;
    width: 760px;
    z-index: -1;
    pointer-events: none;
}

.letter {
    width: 760px;
    box-sizing: border-box;
    background: #fffdf6;
    color: #2c1a12;
    font-family: 'Noto Sans Devanagari', 'Montserrat', sans-serif;
    padding: 44px 50px;
    border: 6px double #c9a24a;
    -webkit-font-smoothing: antialiased;
}

.lp-head { display: flex; align-items: center; gap: 18px; }
.lp-logo { width: 88px; height: 88px; object-fit: contain; flex-shrink: 0; }
.lp-org { text-align: center; flex: 1; }
.lp-name { color: #6e0d0d; font-family: 'Cormorant Garamond', serif; font-size: 30px; font-weight: 700; letter-spacing: 0.5px; line-height: 1.05; }
.lp-name-hi { color: #7f2626; font-size: 18px; font-weight: 700; margin-top: 2px; }
.lp-addr { color: #5c4b3f; font-size: 12.5px; margin-top: 6px; }
.lp-contact { color: #8a5a1a; font-size: 12px; margin-top: 3px; font-weight: 600; }

.lp-rule { height: 3px; background: linear-gradient(90deg, transparent, #c9a24a 15%, #f0cd80 50%, #c9a24a 85%, transparent); margin: 16px 0 14px; }

.lp-titlebar { text-align: center; background: #7f2626; color: #f0cd80; font-weight: 800; letter-spacing: 1px; font-size: 14px; padding: 8px; border-radius: 6px; }

.lp-meta { display: flex; justify-content: space-between; font-size: 13px; color: #2c1a12; margin: 18px 2px 8px; }

.lp-body { font-size: 14.5px; line-height: 1.75; color: #2c1a12; }
.lp-body p { margin: 0 0 11px; }
.lp-jai { text-align: center; color: #7f2626; font-weight: 700; }

.lp-table { width: 100%; border-collapse: collapse; margin: 8px 0 4px; }
.lp-table td { border: 1px solid #e0cfa0; padding: 8px 12px; font-size: 13.5px; }
.lp-table td:first-child { background: #fff5e8; color: #8a5a1a; font-weight: 700; width: 38%; }
.lp-table td:last-child { color: #2c1a12; font-weight: 600; }

.lp-sign { display: flex; justify-content: flex-end; margin-top: 26px; }
.lp-sign-box { text-align: center; }
.lp-sign-box img { width: 120px; max-height: 90px; object-fit: contain; display: block; margin: 0 auto 2px; }
.lp-sign-txt { font-size: 13px; color: #2c1a12; }
.lp-sign-txt span { color: #5c4b3f; font-size: 12px; }

.lp-foot { margin-top: 24px; border-top: 1px solid #e0cfa0; padding-top: 10px; text-align: center; }
.lp-tagline { color: #9f3434; font-weight: 700; letter-spacing: 1px; font-size: 13px; }
.lp-foot > div:last-child { color: #8a7866; font-size: 11px; margin-top: 4px; }
