/* ==========================================================================
   Compra de tarjetas regalo — capa Liquid Glass (client_gift_buy.php)
   Se carga después de client_gift_buy.css y solo afecta a .gb-page y a los
   modales de la página. No cambia datos ni lógica: solo presentación.
   ========================================================================== */

:root {
    --background: #F7F5F2;
    --surface: #FFFFFF;
    --champagne: #E8D9CE;
    --rose: #A98277;
    --burgundy: #481C20;
    --burgundy-light: #69383B;
    --text-primary: #252326;
    --text-secondary: #85818A;
    --border: rgba(255, 255, 255, 0.75);

    /* Derivados con contraste AA sobre blanco/cristal */
    --gb-text-soft: #68646D;      /* texto secundario (5,8:1); #85818A solo en iconos */
    --gb-rose-ink: #7F5D54;       /* rosa legible para texto (5,8:1) */
    --gb-champagne-soft: #F3EAE3;
    --gb-gold: #C29A3F;
    --gb-gold-light: #E2C78A;
    --gb-line: rgba(72, 28, 32, 0.10);

    --gb-glass: rgba(255, 255, 255, 0.72);
    --gb-glass-strong: rgba(255, 255, 255, 0.86);
    --gb-blur: blur(24px) saturate(180%);
    --gb-glass-border: 1px solid rgba(255, 255, 255, 0.8);
    --gb-shadow: 0 12px 36px rgba(40, 25, 25, 0.055);
    --gb-shadow-hover: 0 22px 48px rgba(40, 25, 25, 0.10), 0 4px 12px rgba(40, 25, 25, 0.04);
    --gb-radius: 24px;
    --gb-radius-md: 18px;
    --gb-radius-sm: 14px;
    --gb-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --gb-fast: 200ms;
    --gb-font: 'Montserrat', sans-serif;
}

/* ---------- Fondo ambiental ---------- */
body:has(.gb-page) {
    background:
        radial-gradient(1100px 520px at 88% -8%, rgba(232, 217, 206, 0.75), transparent 62%),
        radial-gradient(900px 480px at 8% 102%, rgba(169, 130, 119, 0.16), transparent 60%),
        var(--background) fixed;
}

body:has(.gb-page) .content-wrapper,
body:has(.gb-page) .layout-page {
    background: transparent;
}

.gb-page {
    max-width: 1180px;
    margin: 0 auto;
    font-family: var(--gb-font);
    color: var(--text-primary);
    container-type: inline-size;
    container-name: gb;
}

.gb-page :where(h1, h2, h3, h4, h5, p, span, a, button, label, input, textarea, select, li, small, strong) {
    font-family: var(--gb-font);
}

/* core.css da 10px de padding a todos los <p>: aquí descuadra la alineación */
.gb-page p {
    padding-left: 0;
    padding-right: 0;
}

.gb-ico {
    flex-shrink: 0;
    vertical-align: middle;
}

/* Entrada progresiva del contenido de cada paso */
.gb-page > * {
    animation: gbRise 520ms var(--gb-ease) backwards;
}

.gb-page > *:nth-child(2) { animation-delay: 60ms; }
.gb-page > *:nth-child(3) { animation-delay: 120ms; }
.gb-page > *:nth-child(n+4) { animation-delay: 160ms; }

@keyframes gbRise {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: none; }
}

/* ---------- Cabecera y breadcrumb ---------- */
.gb-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 0.5rem 0 1.25rem;
}

.gb-crumbs {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 0;
    font-size: 1.5rem;
    line-height: 1.25;
    letter-spacing: -0.01em;
}

.gb-crumbs__parent {
    font-weight: 400;
    color: var(--text-secondary); /* texto grande: 3,8:1 cumple AA para ≥24px */
}

.gb-crumbs__sep {
    font-weight: 300;
    color: rgba(37, 35, 38, 0.22);
}

.gb-crumbs__current {
    font-weight: 600;
    color: var(--text-primary);
}

.gb-head__biz {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin: 0.4rem 0 0;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--gb-text-soft);
}

.gb-head__biz .gb-ico {
    color: var(--rose);
}

.gb-back {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 42px;
    padding: 0 1.1rem;
    border-radius: 999px;
    background: var(--gb-glass);
    -webkit-backdrop-filter: var(--gb-blur);
    backdrop-filter: var(--gb-blur);
    border: var(--gb-glass-border);
    box-shadow: var(--gb-shadow);
    color: var(--burgundy);
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
    transition: transform var(--gb-fast) var(--gb-ease), box-shadow var(--gb-fast) var(--gb-ease), background-color var(--gb-fast) ease;
}

.gb-back:hover {
    color: var(--burgundy);
    background: var(--gb-glass-strong);
    transform: translateY(-1px);
    box-shadow: var(--gb-shadow-hover);
}

.gb-back:active {
    transform: scale(0.97);
}

/* ---------- Superficies de cristal comunes ---------- */
.gb-page .card,
.gb-stepper,
.gb-product,
.gb-page .gift-card-showcase,
.gb-page .buyer-info-card,
.gb-page .gift-option-payment,
.gb-page .success-card {
    position: relative;
    background: var(--gb-glass);
    -webkit-backdrop-filter: var(--gb-blur);
    backdrop-filter: var(--gb-blur);
    border: var(--gb-glass-border);
    box-shadow: var(--gb-shadow);
}

/* Reflejo superior sutil */
.gb-stepper::before,
.gb-product::before,
.gb-page .gift-card-showcase::before,
.gb-page .success-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.65) 0%, rgba(255, 255, 255, 0) 42%);
    pointer-events: none;
    z-index: 0;
}

.gb-page .card {
    border-radius: var(--gb-radius);
}

.gb-page .alert {
    border-radius: var(--gb-radius-sm);
    border: 0;
    font-weight: 500;
}

.gb-page .alert-warning { background: #FBF1DE; color: #6B4A12; }
.gb-page .alert-info { background: var(--gb-champagne-soft); color: var(--burgundy); }
.gb-page .alert-danger { background: #F9E6E4; color: #7A2422; }

.gb-page .form-select,
.gb-page .form-control {
    border-radius: var(--gb-radius-sm);
    border: 1px solid var(--gb-line);
    background-color: rgba(255, 255, 255, 0.9);
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: border-color var(--gb-fast) ease, box-shadow var(--gb-fast) ease;
}

.gb-page .form-select:focus,
.gb-page .form-control:focus {
    border-color: var(--rose);
    box-shadow: 0 0 0 4px rgba(232, 217, 206, 0.9);
}

.gb-page .form-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
}

.gb-page .text-muted {
    color: var(--gb-text-soft) !important;
}

/* ---------- Stepper ---------- */
.gb-stepper {
    --pad: 1.25rem;
    --dot: 36px;
    max-width: 540px;
    margin: 0 auto 1.75rem;
    padding: 0.85rem var(--pad) 0.75rem;
    border-radius: var(--gb-radius);
}

.gb-stepper__track {
    position: absolute;
    z-index: 1;
    top: calc(0.85rem + var(--dot) / 2 - 1px);
    left: calc(var(--pad) + (100% - 2 * var(--pad)) / 6);
    right: calc(var(--pad) + (100% - 2 * var(--pad)) / 6);
    height: 2px;
    border-radius: 2px;
    background: var(--gb-line);
    overflow: hidden;
}

.gb-stepper__fill {
    display: block;
    height: 100%;
    width: var(--progress);
    border-radius: inherit;
    background: linear-gradient(90deg, var(--burgundy-light), var(--burgundy));
    animation: gbProgress 700ms var(--gb-ease) 180ms both;
}

@keyframes gbProgress {
    from { width: var(--progress-from); }
    to { width: var(--progress); }
}

.gb-stepper__list {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin: 0;
    padding: 0;
    list-style: none;
}

.gb-step__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    color: inherit;
    text-decoration: none;
    border-radius: var(--gb-radius-sm);
}

a.gb-step__inner {
    cursor: pointer;
}

.gb-step__dot {
    display: grid;
    place-items: center;
    width: var(--dot);
    height: var(--dot);
    border-radius: 50%;
    font-size: 0.85rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    transition: transform var(--gb-fast) var(--gb-ease), box-shadow var(--gb-fast) ease, background-color var(--gb-fast) ease;
}

.gb-step__label {
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--gb-text-soft);
    letter-spacing: 0.01em;
    transition: color var(--gb-fast) ease;
}

.gb-step.is-pending .gb-step__dot {
    background: rgba(255, 255, 255, 0.92);
    color: var(--gb-text-soft);
    box-shadow: inset 0 0 0 1.5px var(--gb-line);
}

.gb-step.is-active .gb-step__dot {
    background: linear-gradient(160deg, var(--burgundy-light), var(--burgundy));
    color: #fff;
    box-shadow: 0 0 0 5px rgba(232, 217, 206, 0.95), 0 6px 18px rgba(72, 28, 32, 0.28);
    animation: gbHalo 600ms var(--gb-ease) 300ms both;
}

.gb-step.is-active .gb-step__label {
    color: var(--text-primary);
    font-weight: 600;
}

.gb-step.is-completed .gb-step__dot {
    background: var(--burgundy);
    color: #fff;
    box-shadow: 0 0 0 3px rgba(232, 217, 206, 0.7);
}

.gb-step.is-completed .gb-step__label {
    color: var(--burgundy);
}

.gb-step__check {
    animation: gbPop 360ms var(--gb-ease) both;
}

a.gb-step__inner:hover .gb-step__dot {
    transform: scale(1.08);
}

a.gb-step__inner:hover .gb-step__label {
    text-decoration: underline;
    text-underline-offset: 3px;
}

@keyframes gbHalo {
    from { box-shadow: 0 0 0 0 rgba(232, 217, 206, 0), 0 6px 18px rgba(72, 28, 32, 0.0); transform: scale(0.9); }
    to { box-shadow: 0 0 0 5px rgba(232, 217, 206, 0.95), 0 6px 18px rgba(72, 28, 32, 0.28); transform: none; }
}

@keyframes gbPop {
    from { transform: scale(0.4); opacity: 0; }
    to { transform: none; opacity: 1; }
}

/* ---------- Escaparate de tarjetas ---------- */
.gb-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@container gb (min-width: 560px) {
    .gb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@container gb (min-width: 1000px) {
    .gb-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.1rem; }
}

.gb-product {
    border-radius: var(--gb-radius);
    transition: transform 260ms var(--gb-ease), box-shadow 260ms var(--gb-ease), opacity var(--gb-fast) ease;
    animation: gbRise 560ms var(--gb-ease) backwards;
    animation-delay: calc(140ms + var(--i, 0) * 70ms);
}

.gb-product form {
    display: none;
}

.gb-product__inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 10px;
    cursor: pointer;
}

.gb-product:hover {
    transform: translateY(-4px);
    box-shadow: var(--gb-shadow-hover);
}

/* Arte de la tarjeta: la tarjeta real del negocio sobre un fondo con identidad propia */
.gb-art {
    --art-bg: linear-gradient(150deg, #FCF8F4 0%, var(--champagne) 100%);
    --art-ink: var(--gb-rose-ink);
    --art-value: var(--burgundy);
    --art-chip: rgba(255, 255, 255, 0.7);
    --art-card-ring: rgba(255, 255, 255, 0.9);
    position: relative;
    display: grid;
    place-items: center;
    height: 190px;
    border-radius: var(--gb-radius-md);
    background: var(--art-bg);
    overflow: hidden;
    isolation: isolate;
}

/* Brillo ambiental y barrido de luz */
.gb-art::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(120% 80% at 20% 0%, rgba(255, 255, 255, 0.55), transparent 55%);
    z-index: -1;
}

.gb-art::after {
    content: '';
    position: absolute;
    inset: -40% auto -40% -60%;
    width: 45%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
    transform: rotate(12deg) translateX(0);
    transition: transform 900ms var(--gb-ease);
    pointer-events: none;
}

.gb-product:hover .gb-art::after {
    transform: rotate(12deg) translateX(520%);
}

.gb-art__card {
    height: 60%;
    max-width: 72%;
    aspect-ratio: 1.586;
    border-radius: 12px;
    overflow: hidden;
    display: grid;
    place-items: center;
    background: #fff;
    box-shadow:
        0 0 0 1px var(--art-card-ring),
        0 18px 30px -12px rgba(40, 20, 20, 0.35),
        0 4px 10px rgba(40, 20, 20, 0.08);
    transform: translateY(-4px) rotate(-2deg);
    transition: transform 420ms var(--gb-ease), box-shadow 420ms var(--gb-ease);
}

.gb-art__card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.gb-art__fallback {
    color: rgba(255, 255, 255, 0.9);
}

.gb-product:hover .gb-art__card {
    transform: translateY(-9px) rotate(0deg) scale(1.03);
    box-shadow:
        0 0 0 1px var(--art-card-ring),
        0 26px 40px -14px rgba(40, 20, 20, 0.42),
        0 6px 14px rgba(40, 20, 20, 0.1);
}

.gb-art__eyebrow {
    position: absolute;
    top: 12px;
    left: 14px;
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--art-ink);
}

.gb-art__value {
    position: absolute;
    right: 12px;
    bottom: 11px;
    padding: 0.28rem 0.7rem;
    border-radius: 999px;
    background: var(--art-chip);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--art-value);
    font-variant-numeric: tabular-nums;
}

/* Identidades */
.gb-product--rose .gb-art {
    --art-bg: linear-gradient(150deg, #F6E9E3 0%, #E2C4B9 55%, #CFA89C 100%);
    --art-ink: #5E3E37;
    --art-chip: rgba(255, 255, 255, 0.62);
}

.gb-product--burgundy .gb-art {
    --art-bg:
        radial-gradient(90% 70% at 85% 110%, rgba(194, 154, 63, 0.22), transparent 60%),
        linear-gradient(150deg, var(--burgundy-light) 0%, var(--burgundy) 55%, #2C0F12 100%);
    --art-ink: var(--gb-gold-light);
    --art-value: var(--gb-gold-light);
    --art-chip: rgba(255, 255, 255, 0.08);
    --art-card-ring: rgba(226, 199, 138, 0.85);
}

.gb-product--noir .gb-art {
    --art-bg:
        radial-gradient(90% 70% at 15% 110%, rgba(232, 217, 206, 0.16), transparent 60%),
        linear-gradient(150deg, #34302F 0%, #1A1718 55%, #0E0C0D 100%);
    --art-ink: var(--champagne);
    --art-value: var(--gb-gold-light);
    --art-chip: rgba(255, 255, 255, 0.08);
    --art-card-ring: rgba(232, 217, 206, 0.55);
}

.gb-product--burgundy .gb-art::before,
.gb-product--noir .gb-art::before {
    background: radial-gradient(120% 80% at 20% 0%, rgba(255, 255, 255, 0.14), transparent 55%);
}

.gb-product--burgundy .gb-art__value,
.gb-product--noir .gb-art__value {
    border: 1px solid rgba(226, 199, 138, 0.45);
}

.gb-product--burgundy .gb-art::after,
.gb-product--noir .gb-art::after {
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.12), transparent);
}

/* Información */
.gb-product__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 1rem 0.5rem 0.4rem;
}

.gb-product__name {
    margin: 0 0 0.4rem;
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: -0.005em;
    color: var(--text-primary);
}

.gb-product__desc {
    flex: 1;
    margin: 0 0 0.9rem;
    padding: 0;
    font-size: 0.84rem;
    font-weight: 400;
    line-height: 1.55;
    color: var(--gb-text-soft);
}

.gb-price {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.35rem 0.55rem;
    margin-bottom: 0.85rem;
}

.gb-price__now {
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--burgundy);
    font-variant-numeric: tabular-nums;
}

.gb-price__was {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--gb-text-soft);
    text-decoration-thickness: 1px;
    font-variant-numeric: tabular-nums;
}

.gb-badge {
    align-self: center;
    padding: 0.22rem 0.6rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #F6ECE4, var(--champagne));
    box-shadow: inset 0 0 0 1px rgba(169, 130, 119, 0.28);
    color: #5E3E37;
    font-size: 0.74rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.gb-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
    margin: 0 0 1rem;
    padding: 0;
    list-style: none;
}

.gb-meta__item {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    column-gap: 0.5rem;
    align-items: center;
    padding: 0.55rem 0.65rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.6);
    box-shadow: inset 0 0 0 1px var(--gb-line);
    min-width: 0;
}

.gb-meta__item .gb-ico {
    grid-row: 1 / 3;
    color: var(--text-secondary);
}

.gb-meta__label {
    font-size: 0.68rem;
    font-weight: 500;
    color: var(--gb-text-soft);
    line-height: 1.2;
}

.gb-meta__value {
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Tooltip de usos: legible y sin provocar scroll horizontal */
.gb-meta [data-tooltip]::before,
.gb-meta[data-tooltip]::before,
.gb-meta__item[data-tooltip]::before {
    left: auto;
    right: 0;
    transform: none;
    width: max-content;
    max-width: 220px;
    white-space: normal;
    text-align: left;
    padding: 0.5rem 0.7rem;
    border-radius: 10px;
    background: rgba(37, 35, 38, 0.92);
    font-family: var(--gb-font);
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.4;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

/* ---------- Botón principal ---------- */
.gb-buy,
.gb-page .express-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    width: 100%;
    min-height: 50px;
    padding: 0 1.25rem;
    border: 0;
    border-radius: var(--gb-radius-sm);
    background: linear-gradient(180deg, var(--burgundy-light) -40%, var(--burgundy) 70%);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.18) inset, 0 8px 18px -6px rgba(72, 28, 32, 0.45);
    cursor: pointer;
    overflow: hidden;
    transition: transform var(--gb-fast) var(--gb-ease), box-shadow var(--gb-fast) var(--gb-ease), background-color var(--gb-fast) ease, filter var(--gb-fast) ease;
}

.gb-buy {
    margin-top: auto;
}

.gb-buy__icon {
    display: inline-flex;
    transition: transform var(--gb-fast) var(--gb-ease);
}

.gb-product__inner:hover .gb-buy,
.gb-buy:hover,
.gb-page .express-button:hover:not(:disabled) {
    transform: translateY(-1px);
    background: linear-gradient(180deg, #7A4447 -40%, var(--burgundy-light) 80%);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.2) inset, 0 14px 26px -8px rgba(72, 28, 32, 0.5);
    color: #fff;
}

.gb-product__inner:hover .gb-buy__icon {
    transform: translateY(-1px) rotate(-6deg);
}

.gb-product__inner:active .gb-buy,
.gb-buy:active,
.gb-page .express-button:active:not(:disabled) {
    transform: translateY(0) scale(0.98);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12) inset, 0 4px 10px -4px rgba(72, 28, 32, 0.45);
}

.gb-buy:focus-visible,
.gb-page .express-button:focus-visible,
.gb-back:focus-visible,
a.gb-step__inner:focus-visible,
.gb-page .btn-outline-primary:focus-visible,
.gb-page .btn-copy-code:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--burgundy);
}

.gb-buy:disabled,
.gb-page .express-button:disabled {
    cursor: progress;
    opacity: 1;
    transform: none;
}

.gb-buy.is-loading,
.gb-buy[aria-busy="true"],
.gb-page .express-button.is-loading {
    background: var(--burgundy-light);
}

.gb-spinner {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    animation: gbSpin 700ms linear infinite;
    flex-shrink: 0;
}

@keyframes gbSpin {
    to { transform: rotate(360deg); }
}

/* Compra en curso: la tarjeta elegida queda destacada y el resto se atenúa */
.gb-grid.is-busy .gb-product:not(.is-loading) {
    opacity: 0.5;
    pointer-events: none;
    filter: saturate(0.7);
}

.gb-grid.is-busy .gb-product__inner {
    cursor: progress;
}

.gb-product.is-loading {
    box-shadow: 0 0 0 2px rgba(169, 130, 119, 0.55), var(--gb-shadow-hover);
}

/* ---------- Paso 2: pago ---------- */
.gb-page .gift-card-showcase {
    border-radius: var(--gb-radius);
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.gb-page .gift-card-showcase > * {
    position: relative;
    z-index: 1;
}

.gb-page .gift-card-preview-large {
    max-width: 360px;
    height: auto;
    aspect-ratio: 1.586;
    margin: 0.25rem auto 1.5rem;
    border-radius: 16px;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.9), 0 26px 44px -18px rgba(40, 20, 20, 0.45), 0 6px 14px rgba(40, 20, 20, 0.08);
    animation: gbCardIn 700ms var(--gb-ease) 150ms both;
}

.gb-page .preview-content-large::before {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0) 45%);
}

@keyframes gbCardIn {
    from { opacity: 0; transform: translateY(14px) rotate(-3deg) scale(0.96); }
    to { opacity: 1; transform: none; }
}

.gb-page .product-details-card {
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
}

.gb-page .product-details-card h3,
.gb-page .product-details-card h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.gb-page .product-details-card .border-top {
    border-color: var(--gb-line) !important;
    font-size: 0.9rem;
    line-height: 1.6;
}

.gb-page .price-tag {
    font-size: 1.9rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--burgundy);
    font-variant-numeric: tabular-nums;
}

.gb-page .price-original {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--gb-text-soft);
    margin-right: 0;
}

.gb-page .buyer-info-card {
    border-radius: var(--gb-radius-md);
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
}

.gb-page .buyer-info-card small {
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    font-weight: 500 !important;
}

.gb-page .buyer-info-card .fs-5 {
    font-size: 1rem !important;
    font-weight: 600 !important;
}

.gb-page .user-avatar-large,
.gb-page .user-avatar-img {
    width: 52px;
    height: 52px;
    font-size: 1.1rem;
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px var(--champagne), 0 6px 14px rgba(40, 25, 25, 0.12);
}

.gb-page .user-avatar-large {
    background: linear-gradient(160deg, var(--burgundy-light), var(--burgundy));
}

.gb-page .payment-section {
    margin-top: 0;
    border-top: 0;
    padding-top: 0;
}

.gb-page .gift-option-payment {
    border-radius: var(--gb-radius-md);
    padding: 1.1rem 1.25rem;
    margin-bottom: 1rem;
}

.gb-page .custom-checkbox {
    gap: 0.75rem;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.gb-page .custom-checkbox .fw-semibold {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-weight: 500 !important;
}

.gb-page .custom-checkbox .gb-ico {
    color: var(--rose);
}

.gb-page .custom-checkbox input {
    accent-color: var(--burgundy);
}

.gb-page #giftFieldsPayment {
    padding-top: 1rem;
    animation: gbRise 320ms var(--gb-ease) both;
}

.gb-page .payment-section .card {
    padding: 1.25rem !important;
}

.gb-page .payment-section .card h5 {
    font-size: 1rem;
    font-weight: 600;
}

.gb-page .express-button {
    min-height: 56px;
    font-size: 1rem;
}

.gb-page #payment-error:empty {
    display: none;
}

/* ---------- Paso 3: resumen ---------- */
.gb-page .success-card {
    max-width: 640px;
    border-radius: var(--gb-radius);
    padding: 2rem 1.75rem;
}

.gb-page .success-card > * {
    position: relative;
    z-index: 1;
}

.gb-page .success-card > h2 {
    font-size: 1.5rem;
    font-weight: 600 !important;
    letter-spacing: -0.01em;
}

.gb-success-mark {
    display: grid;
    place-items: center;
    width: 72px;
    height: 72px;
    margin: 0 auto 1.25rem;
    border-radius: 50%;
    background: linear-gradient(160deg, var(--burgundy-light), var(--burgundy));
    color: #fff;
    box-shadow: 0 0 0 8px rgba(232, 217, 206, 0.8), 0 14px 30px -8px rgba(72, 28, 32, 0.45);
    animation: gbPop 520ms var(--gb-ease) 120ms both;
}

.gb-page .success-card .gift-card-showcase {
    background: transparent;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    border: 0;
    box-shadow: none;
    padding: 0;
}

.gb-page .success-card .gift-card-showcase::before {
    display: none;
}

.gb-page .gift-code-card {
    background:
        radial-gradient(90% 70% at 85% 120%, rgba(194, 154, 63, 0.22), transparent 60%),
        linear-gradient(150deg, var(--burgundy-light) 0%, var(--burgundy) 60%, #2C0F12 100%);
    border-radius: var(--gb-radius-md);
    padding: 1.1rem;
    box-shadow: 0 14px 30px -12px rgba(72, 28, 32, 0.5);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
}

.gb-page .gift-code-card .gift-code-label {
    flex-basis: 100%;
    margin-bottom: 0;
}

.gb-page .gift-code-card .gift-code-value {
    margin-bottom: 0;
}

.gb-page .gift-code-label {
    color: var(--gb-gold-light);
    font-weight: 600;
    letter-spacing: 0.16em;
}

.gb-page .gift-code-value {
    font-family: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
    color: var(--burgundy);
    border-radius: 10px;
    box-shadow: 0 0 0 1px rgba(226, 199, 138, 0.6);
}

.gb-page .btn-copy-code {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 34px;
    padding: 0 0.9rem;
    border-radius: 999px;
    border: 1px solid rgba(226, 199, 138, 0.55);
    background: rgba(255, 255, 255, 0.1);
    font-weight: 500;
    transition: background-color var(--gb-fast) ease, color var(--gb-fast) ease, transform var(--gb-fast) var(--gb-ease);
}

.gb-page .btn-copy-code:hover {
    background: #fff;
    color: var(--burgundy);
}

.gb-page .btn-copy-code:active {
    transform: scale(0.97);
}

.gb-page .gift-instructions {
    background: rgba(255, 255, 255, 0.66);
    border-left: 0;
    box-shadow: inset 3px 0 0 var(--rose), inset 0 0 0 1px var(--gb-line);
    border-radius: var(--gb-radius-md);
}

.gb-page .gift-instructions h4 {
    display: flex;
    align-items: center;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
}

.gb-page .gift-instructions h4 .bx {
    color: var(--rose);
}

.gb-page .gift-instructions p,
.gb-page .gift-instructions li {
    font-size: 0.9rem;
    color: var(--gb-text-soft);
}

.gb-page .gift-instructions strong {
    color: var(--burgundy);
    font-weight: 600;
}

.gb-page .gift-instructions .gift-booking-btn,
.gb-page .action-buttons .btn-outline-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-height: 46px;
    border-radius: var(--gb-radius-sm);
    font-weight: 600;
    font-size: 0.92rem;
    transition: transform var(--gb-fast) var(--gb-ease), box-shadow var(--gb-fast) var(--gb-ease), background-color var(--gb-fast) ease, color var(--gb-fast) ease;
}

.gb-page .gift-instructions .gift-booking-btn {
    background: linear-gradient(180deg, var(--burgundy-light) -40%, var(--burgundy) 70%);
    box-shadow: 0 8px 18px -6px rgba(72, 28, 32, 0.45);
}

.gb-page .gift-instructions .gift-booking-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 26px -8px rgba(72, 28, 32, 0.5);
}

.gb-page .action-buttons .btn-outline-primary {
    padding: 0 1.4rem;
    border: 1.5px solid var(--burgundy);
    color: var(--burgundy);
    background: rgba(255, 255, 255, 0.7);
}

.gb-page .action-buttons .btn-outline-primary:hover {
    background: var(--burgundy);
    color: #fff;
    transform: translateY(-1px);
}

.gb-page .action-buttons .btn-outline-primary:active,
.gb-page .gift-instructions .gift-booking-btn:active {
    transform: scale(0.98);
}

/* ---------- Modal de inicio de sesión ---------- */
#loginModal .modal-content {
    border-radius: var(--gb-radius);
    background: rgba(255, 255, 255, 0.9);
    -webkit-backdrop-filter: var(--gb-blur);
    backdrop-filter: var(--gb-blur);
    border: var(--gb-glass-border);
    font-family: var(--gb-font);
}

#loginModal .modal-title {
    font-weight: 600;
    color: var(--text-primary);
}

#loginModal .btn {
    min-height: 48px;
    border-radius: var(--gb-radius-sm);
    font-weight: 600;
    transition: transform var(--gb-fast) var(--gb-ease), box-shadow var(--gb-fast) var(--gb-ease), background-color var(--gb-fast) ease;
}

#loginModal .btn-primary {
    background: var(--burgundy);
    border-color: var(--burgundy);
}

#loginModal .btn-primary:hover {
    background: var(--burgundy-light);
    transform: translateY(-1px);
    box-shadow: 0 10px 20px -8px rgba(72, 28, 32, 0.5);
}

#loginModal .btn-outline-primary {
    border: 1px solid var(--gb-line);
    color: var(--text-primary);
    background: #fff;
}

#loginModal .btn-outline-primary:hover {
    background: var(--gb-champagne-soft);
    color: var(--text-primary);
}

#loginModal .btn:active {
    transform: scale(0.98);
}

/* ---------- Responsive ---------- */
@media (max-width: 767.98px) {
    .gb-head {
        padding-bottom: 1rem;
    }

    .gb-crumbs {
        font-size: 1.25rem;
    }

    .gb-crumbs__parent {
        font-weight: 500; /* <24px: el gris necesita peso para seguir legible */
        color: var(--gb-text-soft);
    }

    .gb-stepper {
        --pad: 0.75rem;
        --dot: 32px;
        margin-bottom: 1.25rem;
        padding-top: 0.7rem;
    }

    .gb-stepper__track {
        top: calc(0.7rem + var(--dot) / 2 - 1px);
    }

    .gb-step__label {
        font-size: 0.72rem;
    }

    .gb-art {
        height: 180px;
    }

    .gb-price__now {
        font-size: 1.75rem;
    }

    .gb-buy {
        min-height: 52px;
    }

    .gb-page .gift-card-showcase,
    .gb-page .success-card {
        padding: 1.1rem;
    }

    .gb-page .price-tag {
        font-size: 1.6rem;
    }

    .gb-page .action-buttons .btn-outline-primary {
        width: 100%;
        justify-content: center;
    }
}

@media (hover: none) {
    .gb-product:hover {
        transform: none;
        box-shadow: var(--gb-shadow);
    }

    .gb-product:hover .gb-art__card {
        transform: translateY(-4px) rotate(-2deg);
    }
}

/* ---------- Accesibilidad y compatibilidad ---------- */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .gb-page .card,
    .gb-stepper,
    .gb-product,
    .gb-page .gift-card-showcase,
    .gb-page .buyer-info-card,
    .gb-page .gift-option-payment,
    .gb-page .success-card,
    .gb-back {
        background: rgba(255, 255, 255, 0.96);
    }
}

@media (prefers-reduced-transparency: reduce) {
    .gb-page .card,
    .gb-stepper,
    .gb-product,
    .gb-page .gift-card-showcase,
    .gb-page .buyer-info-card,
    .gb-page .gift-option-payment,
    .gb-page .success-card,
    .gb-back,
    #loginModal .modal-content {
        background: #fff;
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .gb-page *,
    .gb-page *::before,
    .gb-page *::after {
        animation-duration: 1ms !important;
        animation-delay: 0ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 1ms !important;
    }

    .gb-spinner {
        animation: gbSpin 1.4s linear infinite !important;
    }

    .gb-product:hover,
    .gb-product:hover .gb-art__card,
    .gb-buy:hover,
    .gb-product__inner:hover .gb-buy {
        transform: none;
    }
}
