/* ============================================================
   NS Payment Cards — Elessi Theme
   Generado automáticamente. No editar manualmente.
   ============================================================ */

/* Heading */
.ns-payment-heading {
    font-size: 22px;
    font-weight: 700;
    color: #222;
    margin: 0 0 20px 0;
    line-height: 1.3;
}

/* Reset de la lista contenedora */
.checkout-modern-wrap #payment .wc_payment_methods,
#payment .wc_payment_methods {
    border: none !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    margin: 0 !important;
}

/* ── Cada tarjeta ── */
.wc_payment_method {
    border: 1.5px solid #d5d5d5 !important;
    border-radius: 10px !important;
    padding: 0 !important;
    margin-bottom: 12px !important;
    list-style: none !important;
    display: block !important;
    background: #fff;
    transition: border-color 0.2s ease, background-color 0.2s ease;
    overflow: hidden;
}

/* Ocultar el radio nativo */
.wc_payment_method .input-radio {
    position: absolute !important;
    opacity: 0 !important;
    width: 1px !important;
    height: 1px !important;
    pointer-events: none;
}

/* ── Label = toda la tarjeta ── */
.wc_payment_method .ns-payment-card {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    padding: 16px 18px !important;
    cursor: pointer !important;
    width: 100% !important;
    font-weight: normal !important;
    margin-bottom: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

/* ── Radio personalizado ── */
.ns-payment-radio-dot {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid #aaa;
    position: relative;
    transition: border-color 0.2s;
}

.ns-payment-radio-dot::after {
    content: '';
    display: block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #1a73e8;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.2s;
}

/* ── Ícono del gateway ── */
.ns-payment-icon {
    flex-shrink: 0;
    width: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ns-payment-icon img {
    max-height: 38px !important;
    max-width: 52px !important;
    width: auto !important;
    object-fit: contain;
}

/* ── Info: título + descripción ── */
.ns-payment-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.ns-payment-title {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #1a1a1a;
    line-height: 1.3;
}

.ns-payment-desc {
    font-size: 13px !important;
    color: #666;
    font-weight: 400 !important;
    line-height: 1.4;
}

/* ── Monto a la derecha ── */
.ns-payment-amount {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    flex-shrink: 0;
    gap: 1px;
}

.ns-paga-label {
    font-size: 12px;
    color: #777;
    font-weight: 400;
    line-height: 1;
}

.ns-paga-price {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #1a1a1a;
    white-space: nowrap;
    line-height: 1.3;
}

/* Strip WooCommerce currency span */
.ns-paga-price .woocommerce-Price-amount,
.ns-paga-price bdi {
    font-size: inherit !important;
    font-weight: inherit !important;
    color: inherit !important;
}

.ns-paga-price .woocommerce-Price-currencySymbol {
    display: none;
}

/* ══════════════════════════════════════════════
   Estado SELECCIONADO — CSS :has() + clase JS
   ══════════════════════════════════════════════ */
.wc_payment_method:has(input:checked),
.wc_payment_method.ns-pay-selected {
    border-color: #1a73e8 !important;
    background-color: #eef4ff !important;
}

.wc_payment_method:has(input:checked) .ns-payment-radio-dot,
.wc_payment_method.ns-pay-selected .ns-payment-radio-dot {
    border-color: #1a73e8;
}

.wc_payment_method:has(input:checked) .ns-payment-radio-dot::after,
.wc_payment_method.ns-pay-selected .ns-payment-radio-dot::after {
    transform: translate(-50%, -50%) scale(1);
}

.wc_payment_method:has(input:checked) .ns-paga-label,
.wc_payment_method.ns-pay-selected .ns-paga-label {
    color: #d42d8b;
}

.wc_payment_method:has(input:checked) .ns-paga-price,
.wc_payment_method.ns-pay-selected .ns-paga-price {
    color: #d42d8b;
}

/* ── Payment box (campos extra, ej. tarjeta de crédito) ── */
.wc_payment_method .payment_box {
    padding: 0 18px 16px 54px !important;
    background: transparent !important;
    border-top: 1px solid #d8e8ff;
    margin: 0 !important;
}

/* ── Botón Realizar pago ── */
#payment .place-order #place_order {
    width: 100%;
    text-align: center;
    margin-top: 20px;
    padding: 16px !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    border-radius: 8px !important;
    letter-spacing: 0.02em;
}

/* Responsive mobile */
@media (max-width: 640px) {
    .ns-payment-card {
        gap: 10px !important;
        padding: 14px 14px !important;
    }
    .ns-payment-icon { width: 40px; }
    .ns-payment-icon img { max-width: 40px !important; }
    .ns-payment-amount { display: none !important; }
}


    .ns-promo-icon { display: none; }
}

/* ============================================================
   NS Coupon Promos — Banner con input siempre visible
   ============================================================ */

.ns-coupon-promos { margin: 0 0 20px; }

.ns-coupon-promo-item {
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f3fd 100%);
    border: 1px solid #c3ddf8;
    border-left: 4px solid #1a73e8;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 10px;
    font-size: 14px;
    color: #333;
}

.ns-coupon-promo-item:last-child { margin-bottom: 0; }

/* Fila informativa */
.ns-promo-main-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.ns-promo-icon {
    flex-shrink: 0;
    color: #1a73e8;
    display: flex;
    align-items: center;
}

.ns-promo-text { flex: 1; line-height: 1.5; }

.ns-promo-brand {
    color: #1a73e8 !important;
    font-weight: 700 !important;
}

.ns-promo-price {
    color: #d42d8b !important;
    font-weight: 700 !important;
}

.ns-promo-price .woocommerce-Price-amount,
.ns-promo-price bdi {
    font-size: inherit !important;
    font-weight: inherit !important;
    color: inherit !important;
}

.ns-promo-price .woocommerce-Price-currencySymbol {
    font-size: 11px;
    vertical-align: super;
    margin-right: 1px;
}

/* Fila del input */
.ns-promo-input-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 10px;
    border-top: 1px solid #c3ddf8;
}

.ns-promo-coupon-input {
    flex: 1;
    min-width: 140px;
    height: 38px;
    border: 1.5px solid #b3cff5 !important;
    border-radius: 6px !important;
    padding: 0 12px !important;
    font-size: 14px !important;
    background: #fff !important;
    color: #222 !important;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-shadow: none !important;
}

.ns-promo-coupon-input:focus {
    border-color: #1a73e8 !important;
    box-shadow: 0 0 0 3px rgba(26,115,232,0.15) !important;
}

.ns-promo-submit-btn {
    flex-shrink: 0;
    height: 38px;
    background: #1a73e8;
    color: #fff !important;
    border: none;
    border-radius: 6px;
    padding: 0 18px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, opacity 0.2s;
    white-space: nowrap;
}

.ns-promo-submit-btn:hover              { background: #1557b0; }
.ns-promo-submit-btn.ns-loading,
.ns-promo-submit-btn:disabled           { opacity: 0.65; cursor: not-allowed; }

.ns-promo-feedback {
    width: 100%;
    margin: 2px 0 0;
    font-size: 13px;
    color: #c0392b;
    line-height: 1.4;
}

/* Dark mode */
.nasa-dark .ns-coupon-promo-item   { background: linear-gradient(135deg,#1a2a3a,#1e2e40); border-color:#2a4a6a; border-left-color:#4a9eff; color:#ddd; }
.nasa-dark .ns-promo-brand         { color: #4a9eff !important; }
.nasa-dark .ns-promo-price         { color: #ff69b4 !important; }
.nasa-dark .ns-promo-icon          { color: #4a9eff; }
.nasa-dark .ns-promo-submit-btn    { background: #2563eb; }
.nasa-dark .ns-promo-coupon-input  { background: #111 !important; border-color: #2a4a6a !important; color: #eee !important; }
.nasa-dark .ns-promo-input-row     { border-top-color: #2a4a6a; }

/* Responsive */
@media (max-width: 520px) {
    .ns-promo-icon          { display: none; }
    .ns-promo-coupon-input  { min-width: 0; }
    .ns-promo-submit-btn    { width: 100%; }
}