/* ── VIP Modal 2026 v20260727 — Optimized for Clarity & Conversion ── */
.qpvm-overlay {
    position: fixed; inset: 0; z-index: 10000;
    background: rgba(15,23,42,0.6); backdrop-filter: blur(12px);
    display: flex; justify-content: center; align-items: center; padding: 24px;
    opacity: 0; visibility: hidden; pointer-events: none;
    transition: opacity 250ms ease, visibility 0s linear 250ms;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
}
.qpvm-overlay.is-open { opacity: 1; visibility: visible; pointer-events: auto; transition: opacity 250ms ease, visibility 0s linear 0s; }

.qpvm-card {
    position: relative; background: #fff; border-radius: 20px;
    box-shadow: 0 40px 100px rgba(15,23,42,0.3), 0 0 0 1px rgba(15,23,42,0.05);
    width: 100%; max-width: 820px; max-height: 90vh; overflow-y: auto;
    transform: translateY(28px) scale(0.97); opacity: 0;
    transition: transform 400ms cubic-bezier(0.16,1,0.3,1), opacity 300ms ease-out;
}
.qpvm-overlay.is-open .qpvm-card { transform: translateY(0) scale(1); opacity: 1; }

.qpvm-close {
    position: absolute; top: 16px; right: 16px;
    background: rgba(255,255,255,0.15); border: none;
    color: rgba(255,255,255,0.95); cursor: pointer; z-index: 5;
    width: 40px; height: 40px; border-radius: 9999px;
    display: flex; align-items: center; justify-content: center;
    transition: background 200ms ease, transform 200ms ease;
    backdrop-filter: blur(6px);
}
.qpvm-close:hover { background: rgba(255,255,255,0.3); transform: rotate(90deg) scale(1.1); }

/* ── Top Bar ── */
.qpvm-topbar {
    background: linear-gradient(135deg,#0D9488,#0F766E); color: #fff;
    display: flex; align-items: center; gap: 14px;
    padding: 16px 56px 16px 20px; position: relative;
    overflow: hidden;
}
.qpvm-topbar::before {
    content: ''; position: absolute; top: -50%; right: -20%;
    width: 300px; height: 300px; border-radius: 50%;
    background: rgba(255,255,255,0.05); pointer-events: none;
}
.qpvm-avatar {
    width: 40px; height: 40px; border-radius: 50%;
    background: rgba(255,255,255,0.18); display: flex; align-items: center;
    justify-content: center; flex-shrink: 0; color: #fff;
    box-shadow: 0 0 0 2px rgba(255,255,255,0.25);
}
.qpvm-avatar svg { width: 20px; height: 20px; }
.qpvm-topinfo { flex: 1; min-width: 0; }
.qpvm-nickname { font-size: 1.1rem; font-weight: 600; color: #fff; margin-bottom: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif; }
.qpvm-role-row { display: flex; align-items: center; gap: 10px; font-size: 0.85rem; color: rgba(255,255,255,0.8); font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif; }
#qpvmRole { font-size: 0.85rem; color: rgba(255,255,255,0.8); }
#qpvmUid { font-size: 0.85rem; color: rgba(255,255,255,0.8); }
.qpvm-topbadge {
    display: inline-flex; align-items: center; gap: 5px;
    background: linear-gradient(135deg,#FBBF24,#F59E0B,#D97706); color: #fff;
    font-size: 0.72rem; font-weight: 700; padding: 4px 12px; border-radius: 9999px;
    box-shadow: 0 3px 10px rgba(245,158,11,0.4); flex-shrink: 0;
}
.qpvm-topbadge svg { width: 12px; height: 12px; }

/* ── Main Content ── */
.qpvm-main { padding: 20px 24px 24px; }

.qpvm-section-title {
    font-weight: 700; font-size: 1.25rem; color: #134E4A; margin-bottom: 16px;
    letter-spacing: -0.02em;
    font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

/* ── Plans ── */
.qpvm-plans { display: flex; gap: 10px; }
.qpvm-plan {
    position: relative; flex: 1; min-width: 0;
    border: 2px solid #E2E8F0; border-radius: 16px;
    padding: 20px 12px 16px; cursor: pointer; text-align: center;
    display: flex; flex-direction: column; align-items: center;
    background: #fff; transition: all .25s ease;
}
.qpvm-plan--free {
    border-color: #CBD5E1;
    background: #F8FAFC;
    cursor: default;
}
.qpvm-plan--free:hover {
    border-color: #94A3B8;
    transform: none;
    box-shadow: none;
}
.qpvm-plan--free .qpvm-plan-title { color: #475569; }
.qpvm-plan--free .qpvm-plan-price { color: #64748B; }
.qpvm-plan--free .qpvm-plan-unit { color: #64748B; }
.qpvm-plan--free .qpvm-plan-desc-line { color: #475569; border-top-color: #E2E8F0; font-size: 0.85rem; font-weight: 600; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
.qpvm-plan:hover {
    border-color: #14B8A6;
    box-shadow: 0 12px 32px rgba(13,148,136,0.14);
}
.qpvm-plan.qpvm-selected {
    border-color: #0D9488; border-width: 2px;
    background: linear-gradient(180deg,#F0FDFA 0%,#fff 100%);
    box-shadow: 0 12px 36px rgba(13,148,136,0.2);
    transform: none;
}
.qpvm-plan.qpvm-selected:hover {
    border-color: #0D9488;
    transform: none;
    box-shadow: 0 12px 36px rgba(13,148,136,0.2);
    background: linear-gradient(180deg,#F0FDFA 0%,#fff 100%);
}
.qpvm-plan.qpvm-selected::after {
    content: '';
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #0D9488;
    box-shadow: 0 2px 8px rgba(13,148,136,0.4);
    z-index: 2;
}
.qpvm-plan.qpvm-selected::before {
    content: '';
    position: absolute;
    bottom: 15px;
    right: 13px;
    width: 10px;
    height: 6px;
    border-left: 2.5px solid #fff;
    border-bottom: 2.5px solid #fff;
    transform: rotate(-45deg);
    z-index: 3;
}

.qpvm-plan-title { font-weight: 700; font-size: 1.05rem; color: #0F172A; margin-bottom: 6px; font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif; }
.qpvm-plan-price { font-weight: 800; font-size: 1.55rem; color: #0D9488; line-height: 1.2; }
.qpvm-plan-unit { font-size: 0.85rem; color: #64748B; margin-bottom: 8px; }
.qpvm-plan-desc-line {
    font-size: 0.85rem; color: #1E293B; line-height: 1.5;
    padding-top: 8px; border-top: 1px solid #E2E8F0; width: 100%;
    font-weight: 500;
    font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
.qpvm-plan:not(.qpvm-plan--free) .qpvm-plan-desc-line {
    color: #0D9488;
    font-weight: 700;
}

.qpvm-plan-badge {
    position: absolute; top: -10px; right: -5px;
    background: linear-gradient(135deg,#F59E0B,#D97706); color: #fff;
    font-size: 0.75rem; font-weight: 600; padding: 4px 12px; border-radius: 10px;
    white-space: nowrap; box-shadow: 0 3px 10px rgba(245,158,11,0.4);
    z-index: 1;
    -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
.qpvm-plan-badge--recommend {
    background: linear-gradient(135deg,#0D9488,#14B8A6);
    box-shadow: 0 3px 10px rgba(13,148,136,0.35);
    font-weight: 700;
    padding: 4px 14px;
}
.qpvm-plan-badge--hot {
    background: linear-gradient(135deg,#EF4444,#F97316);
    box-shadow: 0 3px 10px rgba(239,68,68,0.35);
    font-weight: 700;
    padding: 4px 14px;
}
.qpvm-plan-badge--free {
    background: linear-gradient(135deg,#94A3B8,#64748B);
    box-shadow: 0 3px 10px rgba(100,116,139,0.3);
    font-weight: 700;
    padding: 4px 14px;
}

/* ── Payment Section ── */
.qpvm-pay { display: flex; gap: 20px; margin-top: 20px; align-items: center; padding-top: 18px; border-top: 1px solid #E2E8F0; }
.qpvm-qrwrap { flex-shrink: 0; text-align: center; }
.qpvm-pay-success { padding: 16px 10px; animation: qpvm-pop .3s ease-out; }
.qpvm-pay-success .qpvm-success-icon {
    width: 56px; height: 56px; margin: 0 auto 10px; border-radius: 50%;
    background: #10B981; color: #fff; font-size: 28px; line-height: 56px; font-weight: 700;
    box-shadow: 0 8px 20px rgba(16,185,129,.35);
}
.qpvm-pay-success .qpvm-success-title { font-size: 1.1rem; font-weight: 700; color: #0F172A; }
.qpvm-pay-success .qpvm-success-sub { font-size: 0.9rem; color: #10B981; margin-top: 3px; font-weight: 600; }
.qpvm-status--ok { color: #10B981 !important; }
@keyframes qpvm-pop { from { transform: scale(.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.qpvm-qr {
    width: 140px; height: 140px; background: #fff;
    border: 1px solid #E2E8F0; border-radius: 14px;
    display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.qpvm-qr img { width: 140px; height: 140px; display: block; }
.qpvm-qr-hint { font-size: 0.75rem; color: #94A3B8; padding: 0 10px; }
.qpvm-qr-tip { margin-top: 8px; font-size: 0.75rem; color: #94A3B8; }

.qpvm-payinfo { flex: 1; min-width: 0; }
.qpvm-seckill { font-size: 0.88rem; color: #374151; margin-bottom: 6px; font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif; }
#qpvmCountdown { font-weight: 700; color: #EF4444; font-variant-numeric: tabular-nums; letter-spacing: 0.5px; }
.qpvm-price-row { display: flex; align-items: baseline; gap: 10px; }
#qpvmPrice { font-size: 1.85rem; font-weight: 800; color: #0D9488; line-height: 1; }
#qpvmOrig { font-size: 0.85rem; color: #94A3B8; text-decoration: line-through; }
.qpvm-pay-benefits { font-size: 0.88rem; color: #475569; margin-top: 10px; line-height: 1.6; font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif; }
.qpvm-agreement { font-size: 0.82rem; color: #94A3B8; margin-top: 10px; font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif; }
.qpvm-agreement a { color: #0D9488; text-decoration: none; font-weight: 600; }
.qpvm-agreement a:hover { text-decoration: underline; }

.qpvm-status { font-size: 0.88rem; color: #0D9488; margin-top: 14px; min-height: 1.2em; font-weight: 500; font-family: 'Noto Sans CJK', 'PingFang SC', 'Microsoft YaHei', sans-serif; }
.qpvm-status--tip { color: #64748B !important; }

/* ── Agreement Modal ── */
.qpvm-agreement-overlay {
    display: none; position: fixed; inset: 0; z-index: 10001;
    background: rgba(15,23,42,0.55); justify-content: center; align-items: center; padding: 24px;
}
.qpvm-agreement-overlay.is-open { display: flex; }
.qpvm-agreement-inner {
    background: #fff; border-radius: 20px; max-width: 560px; width: 100%;
    max-height: 80vh; overflow-y: auto; padding: 32px 36px;
    animation: qpvm-pop .25s ease-out;
}
.qpvm-agreement-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.qpvm-agreement-title { font-weight: 700; font-size: 1.15rem; color: #0F172A; }
.qpvm-agreement-close {
    background: none; border: none; color: #94A3B8; cursor: pointer;
    width: 36px; height: 36px; border-radius: 9999px;
    display: flex; align-items: center; justify-content: center;
    transition: background 150ms ease;
}
.qpvm-agreement-close:hover { background: #F1F5F9; color: #334155; }
.qpvm-agreement-body { font-size: 0.95rem; color: #475569; line-height: 1.75; }
.qpvm-agreement-body p { margin: 0 0 14px; }
.qpvm-agreement-body p:last-child { margin-bottom: 0; }

/* ── Responsive ── */
@media (max-width: 768px) {
    .qpvm-main { padding: 20px 20px 24px; }
    .qpvm-plans { gap: 8px; }
    .qpvm-plan { padding: 16px 10px 14px; border-radius: 14px; }
    .qpvm-plan-title { font-size: 0.95rem; }
    .qpvm-plan-price { font-size: 1.35rem; }
    .qpvm-plan-unit { font-size: 0.8rem; }
    .qpvm-plan-desc-line { font-size: 0.8rem; }
    .qpvm-pay { flex-direction: column; align-items: center; text-align: center; gap: 14px; }
    .qpvm-price-row { justify-content: center; }
    .qpvm-card { max-width: 100%; border-radius: 20px; }
    .qpvm-qr { width: 150px; height: 150px; }
    .qpvm-qr img { width: 150px; height: 150px; }
}
@media (max-width: 480px) {
    .qpvm-plans { flex-direction: column; gap: 8px; }
    .qpvm-plan { padding: 14px 10px; }
    .qpvm-plan-badge { font-size: 0.7rem; padding: 3px 10px; top: -8px; right: -4px; }
    .qpvm-section-title { font-size: 1.05rem; }
    .qpvm-topbar { padding: 14px 48px 14px 16px; }
    .qpvm-main { padding: 16px; }
    .qpvm-qr { width: 130px; height: 130px; }
    .qpvm-qr img { width: 130px; height: 130px; }
    #qpvmPrice { font-size: 1.5rem; }
}

/* ── Dark Mode ── */
body.dark-mode .qpvm-overlay { background: rgba(2,6,23,0.75); }
body.dark-mode .qpvm-card { background: #1E293B; }
body.dark-mode .qpvm-section-title { color: #F1F5F9; }
body.dark-mode .qpvm-plan { background: #0F172A; border-color: rgba(71,85,105,0.5); }
body.dark-mode .qpvm-plan:hover { background: #162032; border-color: #2DD4BF; }
body.dark-mode .qpvm-plan.qpvm-selected { background: linear-gradient(180deg,rgba(13,148,136,0.15) 0%,#0F172A 100%); border-color: #2DD4BF; }
body.dark-mode .qpvm-plan.qpvm-selected:hover { border-color: #2DD4BF; background: linear-gradient(180deg,rgba(13,148,136,0.15) 0%,#0F172A 100%); }
body.dark-mode .qpvm-plan.qpvm-selected::after { background: #2DD4BF; box-shadow: 0 2px 8px rgba(45,212,191,0.4); }
body.dark-mode .qpvm-plan.qpvm-selected::before { border-left-color: #0F172A; border-bottom-color: #0F172A; }
body.dark-mode .qpvm-plan-title { color: #F1F5F9; }
body.dark-mode .qpvm-plan-price { color: #2DD4BF; }
body.dark-mode .qpvm-plan-unit { color: #64748B; }
body.dark-mode .qpvm-plan-desc-line { color: #CBD5E1; border-top-color: rgba(71,85,105,0.5); }
body.dark-mode .qpvm-plan--free { background: #0F172A; border-color: rgba(71,85,105,0.4); }
body.dark-mode .qpvm-plan--free:hover { background: #0F172A; border-color: rgba(71,85,105,0.6); }
body.dark-mode .qpvm-plan--free .qpvm-plan-title { color: #94A3B8; }
body.dark-mode .qpvm-plan--free .qpvm-plan-price { color: #CBD5E1; }
body.dark-mode .qpvm-plan--free .qpvm-plan-unit { color: #475569; }
body.dark-mode .qpvm-plan--free .qpvm-plan-desc-line { color: #64748B; border-top-color: rgba(71,85,105,0.4); }
body.dark-mode .qpvm-status--tip { color: #94A3B8 !important; }
body.dark-mode .qpvm-pay-benefits { color: #94A3B8; }
body.dark-mode .qpvm-agreement { color: #94A3B8; }
body.dark-mode .qpvm-agreement a { color: #2DD4BF; }
body.dark-mode .qpvm-agreement-inner { background: #1E293B; }
body.dark-mode .qpvm-agreement-title { color: #F1F5F9; }
body.dark-mode .qpvm-agreement-body { color: #CBD5E1; }
body.dark-mode .qpvm-agreement-close:hover { background: rgba(71,85,105,0.3); color: #F1F5F9; }
