/* ===== 我的页面 - 个人中心 ===== */
#page-player {
    background: linear-gradient(180deg, #f5f7fa 0%, #edf2f7 100%);
}

/* ===== 充值页面 ===== */
.recharge-sheet-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.45);
    z-index: 5000;
    justify-content: center;
    align-items: flex-end;
    backdrop-filter: blur(6px);
}

.recharge-sheet-overlay.active {
    display: flex;
}

.recharge-sheet {
    background: #ffffff;
    border-radius: 32px 32px 0 0;
    width: 100%;
    max-width: 420px;
    padding: 20px 24px max(28px, env(safe-area-inset-bottom));
    animation: sheetUp 0.35s cubic-bezier(0.32, 0.72, 0, 1);
    box-shadow: 0 -12px 48px rgba(59,130,246,0.1);
}

@keyframes sheetUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

@keyframes marqueeScroll {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

.recharge-sheet-handle {
    width: 40px;
    height: 4px;
    background: #bfdbfe;
    border-radius: 2px;
    margin: 0 auto 16px;
}

.recharge-sheet-title {
    font-size: 18px;
    font-weight: 800;
    color: #1e3a5f;
    margin-bottom: 0;
}

.recharge-sheet-label {
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 8px;
}

.recharge-sheet-input {
    width: 100%;
    padding: 18px 18px;
    background: #f0f7ff;
    border: 2px solid #dbeafe;
    border-radius: 20px;
    color: #1a202c;
    font-size: 18px;
    font-weight: 700;
    outline: none;
    transition: all 0.25s;
    box-sizing: border-box;
}

.recharge-sheet-input:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 4px rgba(96,165,250,0.15);
    background: #fff;
}

.recharge-sheet-input::placeholder {
    color: #93c5fd;
    font-weight: 400;
    font-size: 14px;
}

.recharge-quick-amounts {
    display: flex;
    gap: 8px;
    margin-top: 14px;
    flex-wrap: wrap;
}

.recharge-quick-btn {
    padding: 12px 0;
    background: #f0f7ff;
    border: 2px solid #dbeafe;
    border-radius: 16px;
    font-size: 13px;
    font-weight: 700;
    color: #2563eb;
    cursor: pointer;
    transition: all 0.2s;
    flex: 1;
    min-width: 0;
    text-align: center;
}

.recharge-quick-btn:hover {
    background: #dbeafe;
    border-color: #93c5fd;
}

.recharge-quick-btn.active {
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
    color: #fff;
    border-color: #3b82f6;
    box-shadow: 0 4px 14px rgba(59,130,246,0.3);
}

.recharge-sheet-submit {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
    color: #fff;
    font-size: 17px;
    font-weight: 700;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    margin-top: 22px;
    transition: all 0.25s;
    box-shadow: 0 6px 24px rgba(59,130,246,0.3);
}

.recharge-sheet-submit:hover {
    box-shadow: 0 8px 32px rgba(59,130,246,0.4);
    transform: translateY(-2px);
}

.recharge-sheet-submit:active {
    transform: scale(0.97);
}

/* ===== MPay二维码页内弹窗 ===== */
.pay-iframe-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 9000;
    justify-content: center;
    align-items: center;
}
.pay-iframe-overlay.active {
    display: flex;
}
/* 手机端全屏支付弹窗 */
@media (max-width: 768px) {
    .pay-iframe-overlay.active {
        flex-direction: column;
        background: #fff;
    }
}
.pay-iframe-container {
    position: relative;
    width: 94%;
    max-width: 420px;
    height: 80vh;
    max-height: 700px;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0,0,0,0.3);
    animation: sheetUp 0.3s ease;
}
.pay-iframe-close {
    position: absolute;
    top: 10px; right: 12px;
    width: 32px; height: 32px;
    border-radius: 50%;
    background: rgba(0,0,0,0.5);
    color: #fff;
    font-size: 18px;
    border: none;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
.pay-iframe-close:hover {
    background: rgba(0,0,0,0.7);
}
.pay-iframe-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}
.pay-iframe-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 16px;
}
.pay-iframe-spinner {
    width: 36px; height: 36px;
    border: 3px solid #e2e8f0;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: paySpin 0.8s linear infinite;
}
@keyframes paySpin {
    to { transform: rotate(360deg); }
}
.pay-iframe-loading span {
    font-size: 14px;
    color: #64748b;
    font-weight: 600;
}

/* ===== USDT充值弹窗 ===== */
.usdt-sheet-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.4);
    z-index: 5000;
    justify-content: center;
    align-items: flex-end;
}
.usdt-sheet-overlay.active { display: flex; }
.usdt-sheet {
    background: #fff;
    border-radius: 24px 24px 0 0;
    width: 100%; max-width: 420px;
    padding: 24px 20px max(24px, env(safe-area-inset-bottom));
    animation: sheetUp 0.3s ease;
    max-height: 90vh;
    overflow-y: auto;
}
.usdt-sheet-handle {
    width: 40px; height: 4px;
    background: #e2e8f0;
    border-radius: 2px;
    margin: 0 auto 16px;
}
.usdt-wallet-bar {
    background: linear-gradient(135deg, #1e40af, #3b82f6);
    border-radius: 14px;
    padding: 14px 16px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
}
.usdt-wallet-bar .wi { font-size: 22px; }
.usdt-wallet-bar .winfo { flex: 1; min-width: 0; }
.usdt-wallet-bar .wtitle { font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.usdt-wallet-bar .waddr { font-size: 11px; opacity: 0.9; word-break: break-all; line-height: 1.4; }
.usdt-wallet-bar .wcopy {
    background: rgba(255,255,255,0.2);
    border: none; color: #fff;
    font-size: 12px; font-weight: 600;
    padding: 6px 12px; border-radius: 8px;
    cursor: pointer; white-space: nowrap;
}
.usdt-wallet-bar .wcopy:active { background: rgba(255,255,255,0.35); }
.usdt-fg { margin-bottom: 14px; }
.usdt-fl {
    font-size: 13px; font-weight: 600;
    color: #1a202c;
    margin-bottom: 6px;
    display: flex; align-items: center; gap: 6px;
}
.usdt-fl .urate { font-size: 11px; color: #64748b; font-weight: 400; }
.usdt-fi {
    width: 100%;
    padding: 14px 16px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    color: #1a202c;
    font-size: 16px; font-weight: 600;
    outline: none; box-sizing: border-box;
    transition: border-color 0.2s;
}
.usdt-fi:focus { border-color: #3b82f6; background: #fff; }
.usdt-fi::placeholder { color: #a0aec0; font-weight: 400; font-size: 13px; }
.usdt-cny-row {
    display: flex; align-items: center; justify-content: space-between;
    margin-top: 6px; font-size: 12px; color: #64748b;
}
.usdt-cny-row .cv { font-weight: 700; color: #3b82f6; font-size: 14px; }
.usdt-upbtn {
    width: 100%; padding: 14px;
    background: #f0f9ff;
    border: 1.5px dashed #93c5fd;
    border-radius: 12px;
    color: #3b82f6; font-size: 14px; font-weight: 600;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center; gap: 6px;
}
.usdt-upbtn:active { background: #dbeafe; }
.usdt-upbtn.done { border-color: #10b981; background: #f0fdf4; color: #059669; }
.usdt-uprev { margin-top: 8px; text-align: center; }
.usdt-uprev img { max-width: 120px; max-height: 120px; border-radius: 8px; border: 1px solid #e2e8f0; }
.usdt-tips {
    margin: 14px 0;
    padding: 12px 14px;
    background: #fef2f2;
    border-radius: 10px;
    font-size: 11px; color: #991b1b; line-height: 1.7;
}
.usdt-tips div { display: flex; align-items: flex-start; gap: 6px; margin-bottom: 4px; }
.usdt-tips .dot { color: #dc2626; font-size: 8px; margin-top: 4px; flex-shrink: 0; }
.usdt-sub {
    width: 100%; padding: 16px;
    background: linear-gradient(135deg, #92400e, #b45309);
    color: #fff; font-size: 16px; font-weight: 700;
    border: none; border-radius: 14px;
    cursor: pointer; transition: transform 0.15s;
}
.usdt-sub:active { transform: scale(0.98); }
.usdt-sub:disabled { opacity: 0.5; cursor: not-allowed; }

.profile-card {
    background: linear-gradient(135deg, #1e3a5f, #1e40af);
    border: none;
    border-radius: 20px;
    padding: 0;
    margin-bottom: 16px;
    box-shadow: 0 6px 20px rgba(26, 54, 93, 0.3);
    color: white;
    position: relative;
    overflow: hidden;
}

.profile-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #f59e0b, #fbbf24, #f59e0b);
}

.profile-card-content {
    padding: clamp(16px, 5vw, 24px) clamp(14px, 4vw, 20px) clamp(14px, 4vw, 20px);
}

.profile-header {
    display: flex;
    align-items: center;
    gap: clamp(8px, 2.5vw, 16px);
    margin-bottom: 18px;
}

.profile-avatar {
    width: clamp(40px, 12vw, 56px); height: clamp(40px, 12vw, 56px); border-radius: 14px;
    background: rgba(255, 255, 255, 0.2);
    display: flex; align-items: center; justify-content: center;
    font-size: 26px; flex-shrink: 0;
    border: 2px solid rgba(255, 255, 255, 0.4);
    overflow: hidden; cursor: pointer;
    transition: var(--transition-smooth);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.profile-avatar:hover {
    transform: scale(1.08);
    background: rgba(255, 255, 255, 0.3);
}

.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }

.profile-user-info { flex: 1; min-width: 0; min-width: 80px; }

.profile-username { 
    font-size: clamp(12px, 4.2vw, 18px); 
    font-weight: 800; 
    color: white; 
    margin-bottom: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-balance-info {
    display: inline-flex; align-items: center;
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    border-radius: 14px;
    padding: 6px 14px;
    background: rgba(255, 255, 255, 0.15);
    flex-shrink: 0;
}

.profile-balance-icon { display: none; }

.profile-balance-value { 
    font-size: clamp(14px, 5vw, 22px); 
    font-weight: 800; 
    color: white;
}

.profile-vip-area {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 14px;
    padding: 16px 18px; 
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.vip-top-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }

.vip-badge { 
    display: inline-flex; align-items: center; gap: 4px; 
    background: var(--gradient-gold);
    color: white; 
    font-size: clamp(10px, 3vw, 12px); font-weight: 800; 
    padding: 5px 14px; border-radius: 14px;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.vip-badge-num { font-size: clamp(14px, 5vw, 20px); }

.vip-flow-text { font-size: clamp(10px, 3.2vw, 13px); color: rgba(255, 255, 255, 0.85); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vip-flow-text span { color: white; font-weight: 700; }

.vip-progress-bar { 
    width: 100%; height: 24px; 
    background: rgba(0, 0, 0, 0.6); 
    border-radius: 12px; 
    overflow: hidden; 
    margin-bottom: 8px;
    border: 2px solid rgba(251, 191, 36, 0.3);
    position: relative;
}

.vip-progress-fill { 
    height: 100%; border-radius: 10px; 
    background: linear-gradient(90deg, #fcd34d, #f59e0b);
    transition: width 0.6s ease;
    box-shadow: inset 0 2px 0 rgba(255,255,255,0.4), inset 0 -2px 0 rgba(0,0,0,0.1);
}

.vip-next-row { display: flex; justify-content: space-between; font-size: 12px; color: rgba(255, 255, 255, 0.7); font-weight: 600; }

/* 菜单组 */
.profile-menu-group {
    background: var(--bg-card);
    border-radius: 16px;
    border: 1px solid var(--border);
    overflow: hidden; 
    margin-bottom: 12px;
    box-shadow: var(--shadow-sm);
}

.profile-menu-group-title { 
    font-size: 12px; 
    color: var(--text-dim);
    padding: 12px 16px 4px; 
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.func-row { 
    display: flex; align-items: center; 
    padding: 14px 16px; 
    cursor: pointer; 
    transition: var(--transition-smooth);
    border-top: 1px solid var(--border-light);
    position: relative;
}

.func-row:hover { 
    background: linear-gradient(135deg, #dbeafe, #eff6ff);
    padding-left: 20px;
}

.func-row:active { background: linear-gradient(180deg, #f8fafc, #f1f5f9); }

.func-row-icon { 
    font-size: 20px; 
    margin-right: 14px; 
    flex-shrink: 0; 
    width: 28px; 
    text-align: center;
}

.func-row-text { flex: 1; font-size: 15px; color: var(--text-primary); font-weight: 600; }
.func-row-arrow { font-size: 18px; color: var(--text-dim); flex-shrink: 0; transition: var(--transition-smooth); }
.func-row:hover .func-row-arrow { color: var(--accent); transform: translateX(4px); }

/* 退出登录按钮 */
.profile-logout-btn {
    margin: 20px 0 80px; 
    padding: 14px; 
    text-align: center;
    background: var(--danger-bg); 
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 14px; 
    color: var(--danger);
    font-size: 14px; 
    font-weight: 800; 
    cursor: pointer; 
    transition: var(--transition-smooth);
}

.profile-logout-btn:hover { 
    background: var(--danger); 
    color: white;
    border-color: var(--danger);
    transform: translateY(-2px);
}

.profile-logout-btn:active { transform: scale(0.98); }


/* ===== 客服聊天面板（直接嵌入，非iframe） ===== */
.kefu-chat-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 9000;
    justify-content: center;
    align-items: center;
}
.kefu-chat-overlay.active {
    display: flex;
}
.kefu-chat-panel {
    position: relative;
    width: 94%;
    max-width: 420px;
    height: 80vh;
    max-height: 700px;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0,0,0,0.3);
    animation: sheetUp 0.3s ease;
    display: flex;
    flex-direction: column;
}
.kefu-chat-header {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}
.kefu-status-dot {
    width: 8px; height: 8px;
    background: #4ade80;
    border-radius: 50%;
    animation: kefuPulse 2s infinite;
}
@keyframes kefuPulse {
    0%,100% { opacity:1; }
    50% { opacity:0.4; }
}
.kefu-chat-close {
    width: 32px; height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    color: #fff;
    font-size: 18px;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}
.kefu-chat-close:hover {
    background: rgba(255,255,255,0.4);
}
.kefu-chat-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 0;
    background: #f7f7f7;
}
.kefu-chat-body::-webkit-scrollbar { width: 4px; }
.kefu-chat-body::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 2px; }
.kefu-welcome-msg {
    text-align: center;
    padding: 40px 10px;
    color: #aaa;
    font-size: 13px;
}
.kefu-msg {
    max-width: 75%;
    padding: 10px 14px;
    border-radius: 16px;
    word-wrap: break-word;
    font-size: 14px;
    line-height: 1.5;
    animation: kefuFadeIn 0.15s ease;
}
@keyframes kefuFadeIn {
    from { opacity:0; transform:translateY(4px); }
    to { opacity:1; transform:translateY(0); }
}
.kefu-msg-client {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}
.kefu-msg-admin {
    background: #fff;
    color: #333;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
    border: 1px solid #e5e5e5;
}
.kefu-msg-time {
    font-size: 10px;
    opacity: 0.5;
    margin-top: 4px;
}
.kefu-msg-client .kefu-msg-time { text-align: right; }
.kefu-msg-admin .kefu-msg-time { text-align: left; }
.kefu-msg-img {
    max-width: 200px;
    max-height: 200px;
    border-radius: 8px;
    cursor: pointer;
    display: block;
}
.kefu-chat-input-area {
    background: #fff;
    padding: 10px 12px;
    border-top: 1px solid #eee;
    flex-shrink: 0;
}
.kefu-img-btn {
    width: 40px; height: 40px;
    border-radius: 10px;
    border: 1px solid #e5e5e5;
    background: #f5f5f5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
    transition: all 0.15s;
}
.kefu-img-btn:hover {
    border-color: #8b5cf6;
    background: #f0eeff;
}
.kefu-msg-input {
    flex: 1;
    padding: 10px 14px;
    background: #f5f5f5;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    color: #333;
    font-size: 16px;
    outline: none;
    font-family: inherit;
    line-height: 1.4;
    min-width: 0;
}
.kefu-msg-input:focus { border-color: #8b5cf6; }
.kefu-msg-input::placeholder { color: #bbb; }
.kefu-send-btn {
    padding: 10px 20px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.15s;
}
.kefu-send-btn:hover { box-shadow: 0 2px 12px rgba(99,102,241,0.4); }
.kefu-send-btn:disabled { opacity: 0.5; cursor: not-allowed; }
/* 手机端全屏 */
@media (max-width: 768px) {
    .kefu-chat-overlay.active {
        flex-direction: column;
        background: #fff;
    }
    .kefu-chat-panel {
        width: 100%;
        max-width: none;
        height: 100%;
        max-height: none;
        border-radius: 0;
        box-shadow: none;
        animation: none;
    }
}
/* 图片预览 */
.kefu-img-preview-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.85);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.kefu-img-preview-overlay img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
}