/* ============================================
   会员中心样式 — 暗金主题
   ============================================ */

:root {
    --bg-page: #0f1319;
    --bg-card-solid: rgba(255,255,255,0.03);
    --text-primary: #e8e6e3;
    --text-secondary: rgba(255,255,255,0.6);
    --text-muted: rgba(255,255,255,0.35);
    --gold: #D4A574;
    --gold-light: #E8C07A;
    --gold-dim: rgba(212,165,116,0.15);
    --border: rgba(212,165,116,0.08);
}

*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html, body { width:100%; height:100%; background:var(--bg-page); }
body { font-family:'Inter',-apple-system,'PingFang SC','Microsoft YaHei',sans-serif; color:var(--text-primary); -webkit-font-smoothing:antialiased; -webkit-tap-highlight-color:transparent; }
a { text-decoration:none; color:inherit; }

/* ====== Header ====== */
.page-header {
    position:fixed; top:0; left:0; right:0; height:50px;
    background:linear-gradient(180deg, #161b28, #121722);
    display:flex; align-items:center; justify-content:center;
    padding:0 12px; z-index:100; border-bottom:1px solid var(--border);
}
.page-title { font-size:17px; font-weight:600; color:var(--text-primary); }

/* ====== Main Content ====== */
.main-content {
    position:fixed; top:50px; left:0; right:0;
    bottom:56px; bottom:calc(56px + env(safe-area-inset-bottom, 20px));
    overflow-y:auto; -webkit-overflow-scrolling:touch; padding-bottom:20px;
}
.main-content::-webkit-scrollbar { display:none; }

/* ====== 用户卡片 ====== */
.user-card {
    background:linear-gradient(180deg, #161b28, #121722);
    padding:20px 20px 24px;
}
.user-card-top { display:flex; align-items:center; gap:14px; margin-bottom:20px; }
.user-avatar {
    width:60px; height:60px; border-radius:50%;
    flex-shrink: 0;
    background:rgba(212,165,116,0.08);
    border:2px solid rgba(212,165,116,0.2);
    display:flex; align-items:center; justify-content:center; overflow:hidden;
}
.user-avatar img { width:100%; height:100%; object-fit:cover; }
.user-info { flex:1; }
.user-name { font-size:18px; font-weight:600; color:#fff; }
.user-meta { display:flex; align-items:center; gap:8px; margin-top:4px; }
.user-badge {
    display:inline-block; padding:2px 10px; border-radius:10px;
    background:rgba(212,165,116,0.15); color:var(--gold);
    font-size:12px; font-weight:600;
}

/* 余额行 */
.balance-row { display:flex; justify-content:space-between; align-items:center; }
.balance-info { display:flex; align-items:center; gap:6px; }
.balance-label { font-size:13px; color:var(--text-muted); }
.balance-num { font-size:16px; font-weight:600; color:var(--gold-light); }
.balance-refresh {
    width:28px; height:28px; display:flex; align-items:center; justify-content:center;
    background:none; border:none; color:var(--text-muted); cursor:pointer;
}
.balance-refresh:active { opacity:0.5; }
.balance-refresh.spinning svg { animation:spin 0.8s linear; }
@keyframes spin { from{transform:rotate(0deg)} to{transform:rotate(360deg)} }

/* 提现/充值按钮 */
.btn-action {
    padding:8px 18px; border:none; border-radius:20px;
    font-size:14px; font-weight:600; cursor:pointer; font-family:inherit;
    text-decoration:none; display:inline-block;
}
.btn-withdraw {
    background:linear-gradient(135deg, var(--gold), var(--gold-light));
    color:#0f1319;
    box-shadow:0 2px 10px rgba(212,165,116,0.25);
}
.btn-withdraw:active { opacity:0.8; }

/* ====== 菜单列表 ====== */
.menu-group {
    background:var(--bg-card-solid);
    margin-top:0;
    border-top:1px solid var(--border);
    border-bottom:1px solid var(--border);
}
.menu-group + .menu-group {
    margin-top:10px;
}
.menu-item {
    display:flex; align-items:center; justify-content:space-between;
    padding:16px 20px;
    border-bottom:1px solid var(--border);
    cursor:pointer;
    transition:background 0.15s;
}
.menu-item:last-child { border-bottom:none; }
.menu-item:active { background:rgba(212,165,116,0.04); }
.menu-item-left {
    display:flex; align-items:center; gap:14px; flex:1;
}
.menu-item-right {
    flex-shrink:0;
}
.menu-icon {
    width:38px; height:38px; border-radius:10px;
    display:flex; align-items:center; justify-content:center;
    flex-shrink:0;
}
.icon-gold { background:rgba(212,165,116,0.12); color:var(--gold); }
.icon-blue { background:rgba(100,149,237,0.12); color:#6495ED; }
.icon-purple { background:rgba(168,130,220,0.12); color:#A882DC; }
.icon-red { background:rgba(244,67,54,0.12); color:#F44336; }
.icon-green { background:rgba(76,175,80,0.12); color:#4CAF50; }
.icon-gray { background:rgba(158,158,158,0.12); color:#9E9E9E; }

.menu-item-title { font-size:15px; color:var(--text-primary); font-weight:400; }
.menu-arrow { font-size:18px; color:var(--text-muted); }
.text-danger { color:#F44336 !important; }

/* ====== 退出登录 ====== */
.bottom-spacer { height:30px; }

/* ====== Toast ====== */
.toast {
    position:fixed; top:50%; left:50%;
    transform:translate(-50%,-50%) scale(0.8);
    background:rgba(0,0,0,0.8); color:#fff;
    padding:12px 24px; border-radius:8px; font-size:14px;
    z-index:9999; opacity:0; pointer-events:none;
    transition:all 0.3s cubic-bezier(0.16,1,0.3,1);
}
.toast.show { opacity:1; transform:translate(-50%,-50%) scale(1); }

/* 底部导航样式见 nav.css */
