.product-pay-modal {
    position: fixed;
    inset: 0;
    z-index: 8500;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 14px;
    background: rgba(45, 31, 61, 0.5);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}
.product-pay-modal.show {
    opacity: 1;
    visibility: visible;
}
.product-pay-modal[hidden] { display: none !important; }
.product-pay-modal.show[hidden] { display: flex !important; }
.product-pay-dialog {
    width: 100%;
    max-width: 520px;
    max-height: min(92vh, 720px);
    overflow-y: auto;
    background: rgba(255, 253, 255, 0.98);
    border-radius: 22px;
    border: 1px solid rgba(196, 181, 253, 0.55);
    box-shadow: 0 28px 64px rgba(91, 33, 182, 0.22);
    padding: 20px 18px 22px;
}
.product-pay-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}
.product-pay-head h2 {
    font-size: 1.1rem;
    font-weight: 800;
    margin: 0;
    color: #2d1f3d;
}
.product-pay-close {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: #ede9fe;
    color: #6b21a8;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}
.product-pay-price {
    text-align: center;
    font-size: 15px;
    color: #7c6b8a;
    margin-bottom: 6px;
}
.product-pay-price strong {
    font-size: 1.5rem;
    color: #9d174d;
}
.product-pay-hint {
    font-size: 12px;
    color: #7c6b8a;
    text-align: center;
    line-height: 1.55;
    margin-bottom: 14px;
}
.product-pay-qr-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}
@media (max-width: 480px) {
    .product-pay-qr-grid { grid-template-columns: 1fr; }
}
.product-pay-qr {
    text-align: center;
    padding: 10px;
    border-radius: 14px;
    border: 1px solid rgba(196, 181, 253, 0.55);
    background: #fff;
}
.product-pay-qr-label {
    display: block;
    font-size: 12px;
    font-weight: 800;
    color: #6b21a8;
    margin-bottom: 8px;
}
.product-pay-qr img {
    width: 100%;
    max-width: 200px;
    height: auto;
    border-radius: 8px;
}
.product-pay-btn {
    width: 100%;
    margin-top: 4px;
    border: none;
    border-radius: 999px;
    padding: 12px 20px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    color: #fff;
    background: linear-gradient(135deg, #5b21b6, #7c3aed);
    box-shadow: 0 12px 28px rgba(91, 33, 182, 0.28);
    font-family: inherit;
}
.product-pay-btn:disabled { opacity: 0.65; cursor: not-allowed; }
.product-pay-back {
    width: 100%;
    margin-top: 8px;
    border: 2px solid rgba(196, 181, 253, 0.55);
    border-radius: 999px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 700;
    background: #fff;
    color: #6b21a8;
    cursor: pointer;
    font-family: inherit;
}
.product-pay-code-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #5b4d6e;
    margin-bottom: 6px;
}
.product-pay-code-hint {
    font-size: 12px;
    color: #7c6b8a;
    line-height: 1.5;
    margin-bottom: 10px;
}
.product-pay-code-input {
    width: 100%;
    padding: 12px 14px;
    border-radius: 12px;
    border: 2px solid rgba(196, 181, 253, 0.65);
    font-size: 16px;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.06em;
    margin-bottom: 10px;
    font-family: inherit;
}
.product-pay-code-input:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.18);
}
.product-pay-confirm-text {
    font-size: 14px;
    line-height: 1.65;
    color: #2d1f3d;
    margin-bottom: 14px;
    padding: 12px;
    border-radius: 12px;
    background: rgba(254, 243, 199, 0.55);
    border: 1px solid rgba(251, 191, 36, 0.45);
}
.product-pay-msg {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 13px;
    line-height: 1.5;
}
.product-pay-msg.err {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
}
.product-pay-msg.ok {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}
