/* =========================================================
   theme-donate — /donate page (views/pages/donate.blade.php,
   views/components/paypal-wallets.blade.php)
   ========================================================= */

/* ---------- Page frame ---------- */
.other-bg:has(+ .page-hero + .donate-page)::before {
    background: radial-gradient(90% 70% at 50% 0%, rgba(14, 11, 9, .55), rgba(14, 11, 9, .94) 75%);
}
#other.donate-page { position: relative; padding: 8px 0 110px; }

.donate-page .price_donate {
    display: flex; align-items: center; justify-content: center; gap: 12px;
    width: fit-content; margin: 0 auto 36px; padding: 9px 22px;
    border: 1px solid var(--panel-border); border-radius: 999px;
    background: rgba(10, 8, 6, .6);
    color: var(--text-muted); font-size: 14px; letter-spacing: .02em; line-height: 1.4;
}
.donate-page .price_col { color: var(--gold); font-family: var(--font-bold), sans-serif; }
.price_donate__gem {
    flex: none; width: 8px; height: 8px; transform: rotate(45deg);
    background: linear-gradient(135deg, #fff1cc, var(--gold-soft));
    box-shadow: 0 0 10px rgba(230, 194, 122, .6);
}

.donate-page #payment-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 380px;
    gap: 28px;
    align-items: start;
}

/* ---------- Main panel / steps ---------- */
.donate-page .payment-pay.panel { padding: 34px 36px; }
.donate-page .payment-pay.panel::before {
    content: ""; position: absolute; left: 24px; right: 24px; top: -1px; height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent); opacity: .7;
}

.donate-step { min-width: 0; }
.donate-step + .donate-step {
    margin-top: 30px; padding-top: 30px;
    border-top: 1px solid rgba(201, 164, 99, .14);
}
.donate-step__head {
    display: flex; align-items: center; gap: 14px;
    margin: 0 0 20px; padding: 0;
    font: inherit; line-height: 1.2; color: inherit; text-transform: none;
}
.donate-step__head::after {
    content: ""; flex: 1; height: 1px;
    background: linear-gradient(90deg, rgba(201, 164, 99, .35), transparent);
}
.donate-step__num {
    position: relative; flex: none;
    display: grid; place-items: center;
    width: 34px; height: 34px;
    color: var(--gold); font-family: var(--font-accent-bold), serif; font-size: 11px; letter-spacing: .04em;
}
.donate-step__num::before {
    content: ""; position: absolute; inset: 5px; transform: rotate(45deg);
    border: 1px solid var(--gold);
    background: linear-gradient(135deg, rgba(230, 194, 122, .22), rgba(14, 11, 9, .9));
    box-shadow: 0 0 14px rgba(230, 194, 122, .25), inset 0 0 0 2px rgba(0, 0, 0, .5);
    z-index: -1;
}
.donate-step__num { z-index: 0; }
.donate-step__title {
    font-family: var(--font-accent-bold), serif; font-size: 15px;
    letter-spacing: .14em; text-transform: uppercase; color: #f1e2bf;
}

.donate-page .payment-pay .form-group { margin-bottom: 18px; }
.donate-page .payment-pay .form-group:last-child { margin-bottom: 0; }
.donate-label {
    display: block; margin-bottom: 8px;
    color: var(--text-muted); font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
}

/* ---------- Inputs ---------- */
.donate-page .form-control {
    height: 50px; padding: 0 16px;
    background: linear-gradient(180deg, rgba(6, 5, 4, .75), rgba(18, 14, 11, .75));
    border: 1px solid rgba(201, 164, 99, .26);
    border-radius: 4px;
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, .55);
    color: var(--text); font-size: 15px;
    transition: border-color .2s, box-shadow .2s;
}
.donate-page .form-control::placeholder { color: #7d7365; font-size: 14px; }
.donate-page .form-control:hover { border-color: rgba(230, 194, 122, .45); }
.donate-page .form-control:focus {
    outline: none; border-color: var(--gold);
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, .55), 0 0 0 3px rgba(230, 194, 122, .14);
}
.donate-page select.form-control {
    padding-right: 40px;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg width='10' height='6' viewBox='0 0 10 6' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23e6c27a'/%3E%3C/svg%3E"),
                      linear-gradient(180deg, rgba(6, 5, 4, .75), rgba(18, 14, 11, .75));
    background-repeat: no-repeat; background-position: right 16px center, 0 0;
}
.donate-page select.form-control option { background: var(--ink-2); color: var(--text); }

.donate-page .payment__input { position: relative; display: block; }
.donate-page .payment__input .form-control {
    height: 58px; padding-right: 110px;
    font-family: var(--font-accent-bold), serif; font-size: 20px; letter-spacing: .04em; color: #fff4d6;
}
.donate-page .payment__input .form-control::placeholder { font-family: var(--font-regular), sans-serif; letter-spacing: 0; }
.donate-page .payment_bonus_price {
    position: absolute; top: 9px; right: 9px; bottom: 9px;
    height: auto; min-width: 64px; padding: 0 14px;
    border-radius: 3px;
    background: linear-gradient(180deg, #f3d895, #c69a52);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 0 14px rgba(230, 194, 122, .25);
    color: #1b130a; font-family: var(--font-accent-bold), serif; font-size: 14px; letter-spacing: .04em;
}

.donate-presets { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.donate-page .donate-preset { min-width: 64px; }
.donate-page .donate-preset.is-active {
    --ui-tex: url("../img/ui/UI_BtnSmall_Pressed.png");
    color: var(--gold);
    padding-top: 6px; padding-bottom: 2px;
}

.donate-page .text-danger { margin-top: 8px; color: #ff8b7a; font-size: 13px; }

/* noUiSlider (kept hidden by markup, themed for when it is shown) */
.donate-page .payment__range.noUi-target {
    background: rgba(6, 5, 4, .8); border: 1px solid rgba(201, 164, 99, .3); border-radius: 2px; box-shadow: none;
}
.donate-page .payment__range.noUi-horizontal .noUi-connect { background: linear-gradient(90deg, var(--gold-soft), var(--gold)); }
.donate-page .payment__range.noUi-horizontal .noUi-handle {
    width: 22px; height: 22px; top: -7px; right: -11px;
    transform: rotate(45deg); border-radius: 2px;
    background: linear-gradient(135deg, #fff1cc, var(--gold-soft)); border: 1px solid #5a4423;
    box-shadow: 0 0 12px rgba(230, 194, 122, .45);
}
.donate-page .payment__range .noUi-tooltip {
    background: var(--ink-2); border: 1px solid var(--panel-border); border-radius: 3px; color: var(--gold);
}
.donate-page .payment__range .noUi-value { color: var(--text-muted); }
.donate-page .payment__range .noUi-marker,
.donate-page .payment__range .noUi-marker-large { background: rgba(201, 164, 99, .3); }

/* ---------- Payment method cards (UI_IconBtn frame) ---------- */
.donate-page .payment_select {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(124px, 1fr));
    gap: 12px;
}
.donate-page .pay_method {
    position: relative;
    display: grid; place-items: center;
    padding: 4px;
    border: 4px solid transparent; border-radius: 0;
    border-image: url("../img/ui/UI_IconBtn_Normal.png") 8 fill / 4px stretch;
    cursor: pointer; opacity: 1;
    transition: transform .2s var(--ease), filter .2s, box-shadow .25s;
}
.donate-page .pay_method img {
    display: block; width: 100%; height: auto; aspect-ratio: 214 / 93; object-fit: contain;
    border-radius: 3px;
    filter: saturate(.8) brightness(.92);
    transition: filter .25s;
}
.donate-page .pay_method:hover {
    opacity: 1;
    border-image-source: url("../img/ui/UI_IconBtn_Hover.png");
    transform: translateY(-2px);
}
.donate-page .pay_method:hover img { filter: none; }
.donate-page .pay_method:active {
    border-image-source: url("../img/ui/UI_IconBtn_Pressed.png");
    transform: translateY(0);
}
.donate-page .pay_method:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.donate-page .pay_method.active {
    border: 4px solid transparent; border-radius: 0;
    border-image: url("../img/ui/UI_IconBtn_Pressed.png") 8 fill / 4px stretch;
    box-shadow: 0 0 0 1px var(--gold), 0 0 0 4px rgba(230, 194, 122, .14), 0 0 22px rgba(230, 194, 122, .35);
}
.donate-page .pay_method.active img { filter: none; }
.donate-page .pay_method.active::after {
    content: "";
    position: absolute; top: -9px; right: -9px;
    width: 14px; height: 14px; transform: rotate(45deg);
    border: 1px solid #5a4423;
    background: radial-gradient(circle at 50% 50%, #1b130a 0 2px, transparent 2.5px),
                linear-gradient(135deg, #fff1cc, var(--gold-soft));
    box-shadow: 0 0 10px rgba(230, 194, 122, .7);
}

/* ---------- Aside: summary ---------- */
.donate-aside {
    position: sticky; top: 96px;
    display: flex; flex-direction: column; gap: 24px;
}
.donate-summary { text-align: center; padding: 30px 28px; }
.donate-summary::before {
    content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
    background: radial-gradient(80% 50% at 50% 0%, rgba(230, 194, 122, .12), transparent 70%);
}
.donate-summary .panel-title { position: relative; margin-bottom: 6px; }
.donate-page .total_text {
    display: flex; align-items: baseline; justify-content: center; gap: 10px;
    margin: 0; color: var(--text);
}
.donate-page #payment-total {
    font-family: var(--font-accent-bold), serif; font-size: 52px; line-height: 1.1;
    background: linear-gradient(180deg, #fff6df 10%, #e2bd77 90%);
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 3px 14px rgba(0, 0, 0, .6));
    font-variant-numeric: tabular-nums;
}
.total_text__coin {
    font-family: var(--font-accent-bold), serif; font-size: 16px; letter-spacing: .1em; color: var(--gold);
}
.donate-summary__split { margin: 4px 0 0; font-size: 13px; color: var(--text-muted); }
.donate-summary__split #donate-base { color: var(--text); }
.donate-summary__bonus { color: var(--gold); }
.donate-summary .ornament { margin: 20px auto 18px; width: 70%; }
.donate-summary__label {
    margin-bottom: 10px;
    color: var(--text-muted); font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
}

.donate-page .pay-currency {
    display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px;
    text-align: left;
}
.donate-page .curr-item {
    display: flex; align-items: baseline; justify-content: space-between; gap: 8px;
    padding: 7px 2px;
    border-bottom: 1px dashed rgba(201, 164, 99, .16);
    min-width: 0;
}
.donate-page .curr-item p { margin: 0; line-height: 1.3; }
.donate-page .curr-item .curr_symbol {
    color: var(--gold-soft); font-family: var(--font-accent-bold), serif; font-size: 11px; letter-spacing: .06em;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.donate-page .curr-item .currency { color: var(--text); font-size: 14px; font-variant-numeric: tabular-nums; }

.donate-page .btn-wrapper.btn-full { margin: 24px 0 0; }
.donate-page .btn-full .ui-btn {
    width: 100%;
    border: 4px solid transparent;
    border-image: var(--ui-tex) 8 fill / 4px stretch;
    font-size: 16px; letter-spacing: .14em;
}

.paypal-wallets__message { margin: 12px 0 0; font-size: 13px; text-align: center; }
.paypal-wallets__message:empty { display: none; }
.paypal-wallets__message.error { color: #ff8b7a; }
.paypal-wallets__message.success { color: #8fd49a; }

/* ---------- Aside: bonus tiers ---------- */
.donate-bonuses { padding: 26px 24px; }
.donate-page .donate-title-block { margin-bottom: 14px; }
.donate-page .donate-title { margin-bottom: 4px; font-size: 15px; }
.donate-page .donate-title-block p { margin: 0; color: var(--text-muted); font-size: 13px; line-height: 1.5; }

.donate-page .payment-bonus { display: flex; flex-direction: column; gap: 6px; }
.donate-page .bonus-item {
    position: relative;
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    margin: 0; padding: 10px 14px 12px;
    border: 1px solid rgba(201, 164, 99, .12); border-radius: 3px;
    background: rgba(6, 5, 4, .35);
    font-size: 14px;
    overflow: hidden;
    transition: background .25s, border-color .25s, box-shadow .25s;
}
.donate-page .bonus-item p { margin: 0; color: var(--text); line-height: 1.3; }
.donate-page .bonus-item small { color: var(--text-muted); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.donate-page .bonus-item__value { white-space: nowrap; }
.donate-page .bonus-item__value span {
    color: var(--gold); font-family: var(--font-accent-bold), serif; font-size: 17px;
}
.bonus-item__bar {
    position: absolute; left: 0; bottom: 0; height: 2px;
    width: var(--bonus-fill, 0%);
    background: linear-gradient(90deg, rgba(201, 164, 99, .15), var(--gold));
    opacity: .55;
}
.donate-page .bonus-item.is-current {
    border-color: var(--gold);
    background: linear-gradient(90deg, rgba(230, 194, 122, .16), rgba(230, 194, 122, .04));
    box-shadow: 0 0 18px rgba(230, 194, 122, .18), inset 3px 0 0 var(--gold);
}
.donate-page .bonus-item.is-current .bonus-item__bar { opacity: 1; }
.donate-page .bonus-item.is-current .bonus-item__value span { color: #fff4d6; text-shadow: 0 0 12px rgba(230, 194, 122, .7); }

/* ---------- Alerts / popups (UI_Close) ---------- */
.donate-inline-alert {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    margin-top: 10px; padding: 10px 12px 10px 14px;
    border: 1px solid rgba(255, 120, 100, .4); border-left-width: 3px; border-radius: 3px;
    background: rgba(120, 30, 20, .25);
}
.donate-inline-alert p { margin: 0; color: #ffb3a6; font-size: 13px; line-height: 1.5; }
.donate-inline-alert .ui-close { flex: none; display: block; }

.donate-popup {
    position: fixed; inset: 0; z-index: 9999;
    display: none; align-items: center; justify-content: center;
    padding: 20px;
    background: rgba(5, 4, 3, .74);
    -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.donate-popup .popup-content {
    width: min(440px, 100%);
    padding: 44px 34px 34px;
    text-align: center;
    animation: donate-popup-in .35s var(--ease);
}
.donate-popup .popup-close { position: absolute; top: 14px; right: 14px; padding: 0; }
.donate-popup p { margin: 0; color: var(--text); font-size: 16px; line-height: 1.6; }
.donate-popup__emblem {
    position: relative;
    width: 56px; height: 56px; margin: 0 auto 22px;
    display: grid; place-items: center;
}
.donate-popup__emblem::before {
    content: ""; position: absolute; inset: 8px; transform: rotate(45deg);
    border: 1px solid var(--gold);
    background: linear-gradient(135deg, rgba(230, 194, 122, .3), rgba(14, 11, 9, .95));
    box-shadow: 0 0 22px rgba(230, 194, 122, .4);
}
.donate-popup__emblem::after {
    position: relative;
    font-family: var(--font-accent-bold), serif; font-size: 20px; line-height: 1; color: #fff4d6;
}
.donate-popup--success .donate-popup__emblem::after { content: "\2713"; }
.donate-popup--error .donate-popup__emblem::before {
    border-color: #e0806f;
    background: linear-gradient(135deg, rgba(224, 128, 111, .35), rgba(14, 11, 9, .95));
    box-shadow: 0 0 22px rgba(224, 128, 111, .4);
}
.donate-popup--error .donate-popup__emblem::after { content: "!"; color: #ffd6cc; }
@keyframes donate-popup-in {
    from { opacity: 0; transform: translateY(12px) scale(.98); }
    to { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
    .donate-page #payment-form { grid-template-columns: 1fr; gap: 24px; }
    .donate-aside {
        position: static;
        display: grid; grid-template-columns: 1fr 1fr; align-items: start;
    }
}
@media (max-width: 760px) {
    #other.donate-page { padding-bottom: 70px; }
    .donate-aside { display: flex; }
    .donate-page .payment-pay.panel { padding: 24px 18px; }
    .donate-summary, .donate-bonuses { padding: 24px 18px; }
    .donate-page .price_donate { margin-bottom: 24px; padding: 8px 16px; font-size: 13px; text-align: center; }
    .donate-page .payment_select { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
    .donate-step + .donate-step { margin-top: 24px; padding-top: 24px; }
    .donate-page #payment-total { font-size: 44px; }
}
@media (max-width: 520px) {
    .donate-presets { display: grid; grid-template-columns: repeat(3, 1fr); }
    .donate-page .donate-preset { min-width: 0; }
    .donate-page .pay-currency { gap: 0 12px; }
}
