/* ============================================================
   Gift Donation Flow — Mawaddah
   ============================================================ */

.gift-shell-page {
    background: #f7f8fa;
}

.gift-shell-page .dashboard-content {
    min-height: calc(100vh - 220px);
}

/* Two-column layout: preview | options */
.gift-layout {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    gap: 1rem;
    align-items: start;
}

/* Preview panel (left / start) */
.gift-preview-panel {
    background: #eef1f4;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1rem;
    display: flex;
    justify-content: center;
}

/* The card itself */
.gift-card-preview {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 1.2rem;
    width: min(100%, 380px);
    height: 675px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    padding-bottom: 205px;
}

.gift-card-preview::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("../images/pattern.svg");
    background-repeat: no-repeat;
    background-position: top 12px left 12px;
    background-size: 220px auto;
    opacity: 0.1;
    pointer-events: none;
}

.gift-card-preview::after {
    content: "";
    position: absolute;
    top: 18px;
    right: 10px;
    width: 185px;
    height: 185px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(246, 137, 98, 0.24) 0%, rgba(246, 137, 98, 0.12) 36%, rgba(246, 137, 98, 0) 72%);
    filter: blur(12px);
    opacity: 0.95;
    pointer-events: none;
}

/* Card inner elements */
.gift-preview-logo {
    width: 180px;
    max-width: 100%;
    margin-inline: auto;
    display: block;
    position: relative;
    z-index: 1;
}

.gift-preview-copy {
    text-align: center;
    position: relative;
    z-index: 1;
}

.gift-preview-copy h3 {
    margin: 0.7rem 0 0.35rem;
    font-size: 2.05rem;
    line-height: 1.25;
    color: var(--gift-accent, #0f8a75);
    font-weight: 800;
}

.gift-preview-copy p {
    margin: 0;
    color: #4b5563;
    font-size: 0.9rem;
}

.gift-preview-to,
.gift-preview-from {
    position: relative;
    z-index: 1;
    font-size: 0.92rem;
    color: #4b5563;
}

.gift-preview-message {
    position: relative;
    z-index: 1;
    background: var(--gift-accent, #0f8a75);
    color: #fff;
    border-radius: 10px;
    padding: 0.65rem 0.85rem;
    text-align: center;
    font-weight: 700;
    font-size: 0.92rem;
}

/* Footer image layer */
.gift-card-occasion-footer {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 0;
    height: 178px;
    overflow: hidden;
    border-radius: 0 0 16px 16px;
}

.gift-card-occasion-footer::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(to bottom, #ffffff 0%, rgba(255, 255, 255, 0.82) 25%, rgba(255, 255, 255, 0) 58%);
}

.gift-card-occasion-footer img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* QR placeholder */
.gift-preview-qr-wrap {
    position: absolute;
    left: 12px;
    bottom: 10px;
    z-index: 1;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
}

.gift-preview-qr-wrap p {
    margin: 0;
    font-size: 0.74rem;
    color: #374151;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 999px;
    padding: 0.05rem 0.35rem;
}

.gift-preview-qr {
    width: 84px;
    height: 84px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background-color: #fff;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
}

.gift-preview-qr::after {
    content: "QR";
    font-size: 0.7rem;
    font-weight: 700;
    color: #9ca3af;
    letter-spacing: 1px;
}

/* Options panel */
.gift-options-panel .meet-panel + .meet-panel {
    margin-top: 1rem;
}

/* Template grid */
.gift-template-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.55rem;
}

.gift-template-btn {
    border: 1px solid rgba(246, 137, 98, 0.45);
    background: #fff;
    border-radius: 10px;
    padding: 0.45rem;
    text-align: right;
    cursor: pointer;
    transition: all 0.2s ease;
}

[dir="ltr"] .gift-template-btn {
    text-align: left;
}

.gift-template-btn:hover {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(246, 137, 98, 0.12);
}

.gift-template-btn.is-active {
    border-color: var(--color-primary);
    background: rgba(246, 137, 98, 0.08);
}

.gift-template-thumb {
    border-radius: 8px;
    min-height: 92px;
    margin-bottom: 0.4rem;
    border: 1px solid #f1d5c9;
    background-color: #fff7f2;
    background-size: cover;
    background-position: center;
    position: relative;
}

.gift-template-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(to top, rgba(17, 24, 39, 0.06), rgba(255, 255, 255, 0.22));
}

.gift-template-btn strong {
    display: block;
    font-size: 0.86rem;
    color: #1f2937;
}

/* Color swatches */
.gift-color-swatches {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.gift-color-btn {
    width: 36px;
    height: 36px;
    border-radius: 999px;
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.12);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gift-color-btn:hover {
    transform: scale(1.06);
}

.gift-color-btn.is-active {
    box-shadow: 0 0 0 3px rgba(246, 137, 98, 0.35);
}

/* Amount grid */
.gift-amount-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.6rem;
}

.gift-amount-btn {
    border: 1px solid rgba(246, 137, 98, 0.55);
    background: #fff;
    color: #2f3846;
    border-radius: 9px;
    min-height: 45px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}

.gift-amount-btn.is-active {
    background: rgba(246, 137, 98, 0.12);
    color: #a64724;
    border-color: var(--color-primary);
}

/* Summary list (step 3) */
.gift-summary-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.45rem;
}

.gift-summary-list li {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    border: 1px solid #eceff3;
    border-radius: 10px;
    padding: 0.6rem 0.75rem;
    font-size: 0.88rem;
}

/* Payment methods (step 3) */
.gift-payment-methods {
    display: grid;
    gap: 0.5rem;
}

.gift-pay-option {
    border: 1px solid #eceff3;
    border-radius: 10px;
    padding: 0.65rem 0.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    cursor: pointer;
    transition: border-color 0.15s ease;
}

.gift-pay-option:hover {
    border-color: rgba(246, 137, 98, 0.4);
}

.gift-pay-option input {
    accent-color: var(--color-primary);
}

.gift-pay-meta {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    color: #1f2937;
    font-size: 0.88rem;
    font-weight: 700;
}

.gift-pay-meta img {
    width: 34px;
    height: 22px;
    object-fit: contain;
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 992px) {
    .gift-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .gift-template-grid,
    .gift-amount-grid {
        grid-template-columns: 1fr 1fr;
    }

    .gift-card-preview {
        width: min(100%, 320px);
        height: 568px;
        padding-bottom: 175px;
    }
}
