.payment_method_etogo_gateway .etogo-method-card {
    background: linear-gradient(145deg, #0f172a, #111827);
    border: 1px solid #25324a;
    border-radius: 12px;
    padding: 14px;
    color: #e5e7eb;
}

.payment_method_etogo_gateway .etogo-method-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.payment_method_etogo_gateway .etogo-logo {
    width: auto;
    height: 28px;
    max-width: 220px;
    object-fit: contain;
}

.payment_method_etogo_gateway .etogo-secure-label {
    display: inline-block;
    background: rgba(34, 211, 238, 0.12);
    color: #67e8f9;
    border: 1px solid rgba(34, 211, 238, 0.3);
    font-size: 12px;
    border-radius: 999px;
    padding: 3px 10px;
    white-space: nowrap;
}

.payment_method_etogo_gateway .etogo-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.payment_method_etogo_gateway .etogo-badge {
    display: inline-flex;
    align-items: center;
    border: 1px solid #334155;
    border-radius: 6px;
    padding: 5px 10px;
    font-size: 12px;
    line-height: 1;
    color: #e2e8f0;
    background: #111827;
}

.payment_method_etogo_gateway .etogo-note {
    margin: 12px 0 0;
    color: #cbd5e1;
    font-size: 13px;
}

.payment_method_etogo_gateway .wc-etogo-inline-embed {
    margin-top: 12px;
}

.payment_method_etogo_gateway .wc-etogo-inline-status {
    padding: 10px 12px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.35;
    border: 1px solid rgba(148, 163, 184, 0.25);
    background: rgba(15, 23, 42, 0.6);
    color: #e2e8f0;
    margin-bottom: 10px;
}

.payment_method_etogo_gateway .wc-etogo-inline-status.is-error {
    border-color: rgba(244, 63, 94, 0.35);
    background: rgba(136, 19, 55, 0.18);
    color: #fecdd3;
}

.payment_method_etogo_gateway .wc-etogo-inline-frame-wrap {
    border-radius: 14px;
    overflow: hidden;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.06),
        0 20px 50px -12px rgba(0, 0, 0, 0.45);
    background: #0b1022;
}

.payment_method_etogo_gateway .wc-etogo-inline-frame-wrap iframe {
    display: block;
    width: 100%;
    height: 720px;
    border: 0;
    background: #111528;
}

.payment_method_etogo_gateway .wc-etogo-inline-new-attempt {
    margin-top: 10px;
    border-radius: 10px;
    padding: 10px 14px;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(148, 163, 184, 0.25);
    color: #e2e8f0;
    font-weight: 600;
}

.payment_method_etogo_gateway .wc-etogo-inline-new-attempt:hover {
    background: rgba(30, 41, 59, 0.9);
    border-color: rgba(203, 213, 225, 0.35);
}

/* Shipment line is shown on the Etogo payment page; hide it on checkout when Etogo is selected. */
body.wc-etogo-checkout-hide-shipping.woocommerce-checkout .woocommerce-checkout-review-order-table tr.woocommerce-shipping-totals,
body.wc-etogo-checkout-hide-shipping.woocommerce-checkout .woocommerce-checkout-review-order-table tr.shipping {
    display: none !important;
}

@media (max-width: 640px) {
    .payment_method_etogo_gateway .etogo-method-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .payment_method_etogo_gateway .etogo-logo {
        height: 24px;
        max-width: 180px;
    }
}

/* =====================================================================
   ETOGO POPUP MODAL
   ===================================================================== */

/* Lock scroll when modal is open */
body.wc-etogo-modal-open {
    overflow: hidden;
}

/* Fullscreen overlay + box wrapper */
#wc-etogo-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

#wc-etogo-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(6, 8, 20, 0.82);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

#wc-etogo-modal-box {
    position: relative;
    z-index: 1;
    width: min(96vw, 680px);
    height: 80vh;
    max-height: 80vh;
    background: #0b1022;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 18px;
    box-shadow: 0 30px 80px -10px rgba(0,0,0,0.7), 0 0 0 1px rgba(255,255,255,0.04);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

#wc-etogo-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    z-index: 2;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    color: #94a3b8;
    font-size: 20px;
    line-height: 1;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s, color 0.15s;
}

#wc-etogo-modal-close:hover {
    background: rgba(255,255,255,0.16);
    color: #e2e8f0;
}

#wc-etogo-modal-status {
    margin: 14px 14px 0;
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.4;
    color: #e2e8f0;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(148,163,184,0.2);
}

#wc-etogo-modal-status.is-error {
    background: rgba(136,19,55,0.2);
    border-color: rgba(244,63,94,0.35);
    color: #fecdd3;
}

#wc-etogo-modal-frame-wrap {
    flex: none;
    margin: 14px;
    border-radius: 12px;
    overflow: visible;
    background: #111528;
}

#wc-etogo-modal-iframe {
    display: block;
    width: 100%;
    height: 520px;
    border: 0;
    background: #111528;
}

/* "Continue to Secure Payment" button */
.wc-etogo-pay-now-btn {
    display: block;
    width: 100%;
    margin-top: 10px;
    padding: 14px 20px;
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: #fff !important;
    font-size: 15px;
    font-weight: 700;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    letter-spacing: 0.02em;
    transition: opacity 0.15s, transform 0.1s;
}

.wc-etogo-pay-now-btn:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

/* Remove the old inline embed area from display */
.payment_method_etogo_gateway .wc-etogo-inline-embed {
    display: none !important;
}

@media (max-width: 768px) {
    #wc-etogo-modal-box {
        height: 78vh;
        max-height: 78vh;
        width: 96vw;
        border-radius: 14px;
    }
    #wc-etogo-modal-iframe {
        height: 620px;
    }
}
