/**
 * vip-purchase.css — VIP 购买弹窗公共组件样式
 * 所有 class 使用 vp- 前缀，避免与页面样式冲突
 */

/* =============================================
 * 支付弹窗
 * ============================================= */
.vp-pay-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0; top: 0; width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.6);
    align-items: center; justify-content: center;
    backdrop-filter: blur(6px);
}
.vp-pay-modal-content {
    background-color: #ffffff;
    padding: 28px;
    border-radius: 20px;
    width: 420px;
    max-width: 90vw;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    position: relative;
    animation: vpModalFadeIn 0.3s ease;
    max-height: 90vh;
    overflow-y: auto;
}
.vp-pay-title {
    margin: 0 0 12px;
    font-size: 20px;
    font-weight: 700;
    color: #0f172a;
    letter-spacing: -0.3px;
    display: flex;
    align-items: center;
}
.vp-privilege-guide {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    padding: 10px;
    background: #eff6ff;
    border-radius: 8px;
    color: #2563eb;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
}
.vp-privilege-guide:hover {
    background: #dbeafe;
    color: #1d4ed8;
}
.vp-price-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    border: 2px solid #3b82f6;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 16px;
}
.vp-price-left {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.vp-price-panel .vp-label {
    color: #64748b;
    font-size: 12px;
    font-weight: 500;
}
.vp-price-detail {
    display: flex;
    align-items: baseline;
    gap: 8px;
}
.vp-price-panel .vp-price-value {
    color: #2563eb;
    font-weight: 800;
    font-size: 28px;
    letter-spacing: -0.5px;
}
.vp-price-original {
    font-size: 14px;
    color: #94a3b8;
    text-decoration: line-through;
}
.vp-price-badge {
    background: #ef4444;
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

/* 退款保障提示 */
.vp-guarantee-box {
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    border: 2px solid #16a34a;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 16px;
}
.vp-guarantee-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}
.vp-guarantee-title-text {
    font-size: 15px;
    font-weight: 700;
    color: #15803d;
}
.vp-guarantee-points {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.vp-guarantee-point {
    font-size: 12px;
    color: #16a34a;
    font-weight: 500;
    padding-left: 4px;
}

/* 二维码区域 */
.vp-qrcode-panel {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    padding: 20px;
    text-align: center;
    margin-bottom: 16px;
}
.vp-qrcode-wrapper {
    position: relative;
    display: inline-block;
    margin-bottom: 12px;
}
.vp-qrcode-img {
    width: 180px;
    height: 180px;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.vp-qrcode-status {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.vp-qrcode-tip {
    font-size: 13px;
    color: #64748b;
    margin: 0 0 8px 0;
    font-weight: 500;
}
.vp-qrcode-countdown {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-size: 11px;
    color: #94a3b8;
}
#vpQrCountdown {
    font-weight: 600;
    color: #64748b;
}

/* 安全提示 */
.vp-security-tips {
    display: flex;
    justify-content: center;
    gap: 16px;
    padding: 12px;
    background: #f8fafc;
    border-radius: 10px;
    margin-bottom: 12px;
}
.vp-security-item {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: #16a34a;
    font-weight: 500;
}
.vp-pay-footer-note {
    text-align: center;
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.5;
}
.vp-link-text {
    color: #2563eb;
    text-decoration: none;
}
.vp-link-text:hover {
    text-decoration: underline;
}

/* 关闭按钮 */
.vp-close-modal {
    position: absolute;
    right: 15px;
    top: 10px;
    font-size: 24px;
    cursor: pointer;
    color: #94a3b8;
    transition: color 0.2s;
    background: none;
    border: none;
    line-height: 1;
}
.vp-close-modal:hover {
    color: #0f172a;
}

/* 隐藏按钮 */
.vp-action-btn {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s;
    margin-bottom: 32px;
    border: none;
}
.vp-btn-outline {
    background: transparent;
    border: 2px solid #2563eb;
    color: #2563eb;
}
.vp-btn-outline:hover {
    background: #eff6ff;
}
.vp-btn-primary {
    background: linear-gradient(135deg, #6366f1, #2563eb);
    color: white;
    box-shadow: 0 4px 6px -1px rgba(99, 102, 241, 0.3);
}
.vp-btn-primary:hover {
    opacity: 0.92;
    box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.4);
}

/* =============================================
 * 成功视图
 * ============================================= */
.vp-success-view {
    display: none;
    text-align: center;
    padding: 20px 10px;
}
.vp-success-icon {
    width: 64px;
    height: 64px;
    background: #dcfce7;
    color: #16a34a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    margin: 0 auto 16px;
}
.vp-success-title {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}
.vp-success-desc {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 24px;
}
.vp-btn-full {
    width: 100%;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.2s;
    cursor: pointer;
    border: none;
}

/* =============================================
 * 支付结果确认弹窗
 * ============================================= */
.vp-pay-result-modal {
    display: none;
    position: fixed;
    z-index: 10001;
    left: 0; top: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    animation: vpFadeIn 0.3s ease;
}
.vp-pay-result-content {
    background: white;
    border-radius: 20px;
    padding: 40px 32px;
    width: 420px;
    max-width: 90vw;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: vpSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.vp-pay-result-icon {
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    animation: vpPulse 2s ease-in-out infinite;
}
.vp-pay-result-title {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 12px 0;
}
.vp-pay-result-desc {
    font-size: 14px;
    color: #64748b;
    margin: 0 0 28px 0;
    line-height: 1.6;
}
.vp-pay-result-buttons {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    width: 100%;
}
.vp-pay-result-btn-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.vp-pay-result-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 16px 8px;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
.vp-pay-result-btn svg {
    flex-shrink: 0;
}
.vp-pay-result-btn-note {
    font-size: 12px;
    color: #94a3b8;
    text-align: center;
    margin: 0;
    line-height: 1.4;
}
.vp-pay-result-highlight {
    color: #ef4444;
    font-weight: 500;
}
.vp-pay-result-warning {
    color: #f59e0b;
    font-size: 11px;
    margin-top: 4px;
}
.vp-pay-result-success {
    background: linear-gradient(135deg, #16a34a, #15803d);
    color: white;
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.3);
}
.vp-pay-result-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(22, 163, 74, 0.4);
}
.vp-pay-result-cancel {
    background: #f1f5f9;
    color: #64748b;
    border: 2px solid #e2e8f0;
}
.vp-pay-result-cancel:hover {
    background: #e2e8f0;
    color: #1e293b;
}

/* =============================================
 * 退款弹窗
 * ============================================= */
.vp-refund-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.2);
    backdrop-filter: blur(2px);
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 10002;
}
.vp-refund-modal {
    max-width: 480px;
    width: 100%;
    background: #ffffff;
    border-radius: 20px;
    padding: 28px 24px;
    box-shadow: 0 15px 30px -10px rgba(0,0,0,0.15);
    animation: vpFadeIn 0.2s ease;
    position: relative;
}
.vp-refund-modal .vp-modal-header {
    margin-bottom: 20px;
}
.vp-refund-modal .vp-modal-header h2 {
    font-size: 1.6rem;
    font-weight: 600;
    color: #0f172a;
    line-height: 1.2;
}
.vp-order-line {
    background: #f8fafc;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 20px;
    font-size: 0.95rem;
}
.vp-order-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.vp-order-line .vp-product { font-weight: 600; color: #0f172a; }
.vp-order-line .vp-price { font-size: 1.3rem; font-weight: 650; color: #1e293b; }
.vp-order-id { color: #64748b; font-size: 0.85rem; margin-top: 6px; }
.vp-info-simple { margin-bottom: 20px; padding: 4px 0; }
.vp-info-line {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 14px;
    font-size: 0.95rem;
    color: #1e293b;
}
.vp-info-line:last-child { margin-bottom: 0; }
.vp-info-icon { font-size: 1.1rem; width: 22px; text-align: center; color: #4b5563; }
.vp-info-text { flex: 1; line-height: 1.5; }
.vp-info-strong { font-weight: 600; color: #0f172a; margin-right: 4px; }
.vp-first-line { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; }
.vp-tooltip-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 18px; height: 18px; background: #e2e8f0; color: #475569;
    border-radius: 50%; font-size: 12px; font-weight: 600; cursor: help;
    position: relative; margin-left: 2px;
}
.vp-tooltip-icon:hover .vp-tooltip-text { visibility: visible; opacity: 1; transform: translateX(-50%) translateY(0); }
.vp-tooltip-text {
    visibility: hidden; opacity: 0; position: absolute; bottom: calc(100% + 8px);
    left: 50%; transform: translateX(-50%) translateY(0); background: #1e293b;
    color: #ffffff; font-size: 0.8rem; white-space: nowrap; padding: 6px 12px;
    border-radius: 20px; transition: all 0.2s ease; box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    z-index: 10; pointer-events: none;
}
.vp-tooltip-text::after {
    content: ''; position: absolute; top: 100%; left: 50%; margin-left: -5px;
    border-width: 5px; border-style: solid; border-color: #1e293b transparent transparent transparent;
}
.vp-deadline-tag {
    color: #2563eb; font-weight: 500; background: #f0f7ff; padding: 2px 8px;
    border-radius: 30px; font-size: 0.85rem; display: inline-block; margin-left: 6px;
}
.vp-amount-bar {
    background: #f1f4f9; border-radius: 40px; padding: 14px 18px;
    margin-bottom: 24px; display: flex; justify-content: space-between;
    align-items: center; font-size: 0.95rem;
}
.vp-amount-left { font-weight: 500; color: #334155; }
.vp-amount-right { font-weight: 650; font-size: 1.2rem; color: #0f172a; }
.vp-action-row {
    display: flex; gap: 12px; justify-content: flex-end;
    border-top: 1px solid #edf2f6; padding-top: 20px;
}
.vp-btn {
    border: none; border-radius: 40px; padding: 12px 24px;
    font-size: 0.95rem; font-weight: 550; cursor: pointer;
    font-family: inherit; border: 1px solid transparent;
}
.vp-btn-blue { background: #2563eb; color: #ffffff; }
.vp-btn-blue:hover { background: #1d4ed8; }

/* =============================================
 * 动画
 * ============================================= */
@keyframes vpModalFadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes vpFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes vpSlideUp {
    from { opacity: 0; transform: translateY(30px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes vpPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* 收款方文字 */
.vp-payee-text {
    display: none;
    font-size: 12px;
    color: #94a3b8;
    margin-top: -4px;
    margin-bottom: 8px;
}
