|
|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <view class="page-profile">
|
|
|
+ <view class="page-profile" :class="themeClass">
|
|
|
<!-- ========== Merged Region 1+2: User Card + Membership ========== -->
|
|
|
<view class="user-card">
|
|
|
<!-- Login prompt for unauthenticated users -->
|
|
|
@@ -18,20 +18,23 @@
|
|
|
<image :src="userStore.avatarUrl || '/static/default-avatar.png'" mode="aspectFill" />
|
|
|
</view>
|
|
|
<view class="user-card__info">
|
|
|
- <text class="user-card__nickname">{{ userStore.nickname }}</text>
|
|
|
-
|
|
|
- <!-- Role tag -->
|
|
|
- <view
|
|
|
- class="user-card__tag"
|
|
|
- :class="{
|
|
|
- 'user-card__tag--practitioner': userStore.vipType === 'practitioner',
|
|
|
- 'user-card__tag--annual': userStore.vipType === 'annual',
|
|
|
- 'user-card__tag--normal': !userStore.vipType
|
|
|
- }"
|
|
|
- >
|
|
|
- <text v-if="!userStore.vipType">普通用户</text>
|
|
|
- <text v-else-if="userStore.vipType === 'annual'">C端会员</text>
|
|
|
- <text v-else>能量师 🌟</text>
|
|
|
+ <view class="user-card__name-row">
|
|
|
+ <text class="user-card__nickname">{{ userStore.nickname }}</text>
|
|
|
+
|
|
|
+ <!-- Role tag -->
|
|
|
+ <view
|
|
|
+ class="user-card__tag"
|
|
|
+ :class="{
|
|
|
+ 'user-card__tag--practitioner': userStore.vipType === 'practitioner',
|
|
|
+ 'user-card__tag--annual': userStore.vipType === 'annual',
|
|
|
+ 'user-card__tag--super': userStore.vipType === 'super_annual',
|
|
|
+ 'user-card__tag--normal': !userStore.vipType
|
|
|
+ }"
|
|
|
+ >
|
|
|
+ <text v-if="!userStore.vipType">普通用户</text>
|
|
|
+ <text v-else-if="userStore.vipType === 'annual'">C端会员</text>
|
|
|
+ <text v-else>能量师 🌟</text>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
|
|
|
<!-- Social summary (optional) -->
|
|
|
@@ -39,12 +42,12 @@
|
|
|
{{ userStore.city || '' }}{{ userStore.city && userStore.bio ? ' · ' : '' }}{{ userStore.bio || '' }}
|
|
|
</text>
|
|
|
</view>
|
|
|
-<text class="user-card__arrow">›</text>
|
|
|
-
|
|
|
- <!-- Theme switcher inside user card -->
|
|
|
- <view class="user-card__theme">
|
|
|
- <ThemeToggle />
|
|
|
- </view>
|
|
|
+<view class="user-card__header-right">
|
|
|
+ <view class="theme-toggle-btn" @click.stop="themeStore.toggle">
|
|
|
+ <text class="theme-toggle-text">{{ themeStore.theme === 'dark' ? '亮' : '暗' }}</text>
|
|
|
+ </view>
|
|
|
+ <text class="user-card__arrow">›</text>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
@@ -172,22 +175,10 @@
|
|
|
|
|
|
<!-- ========== Region 3: Feature Menu ========== -->
|
|
|
|
|
|
- <!-- Group 1: My Services -->
|
|
|
- <view class="menu-section">
|
|
|
+ <!-- Group 1: My Services (practitioner workbench only) -->
|
|
|
+ <view v-if="userStore.vipType === 'practitioner' && userStore.isVip" class="menu-section">
|
|
|
<view class="menu-section__header">我的服务</view>
|
|
|
|
|
|
- <!-- Analysis history (all logged-in) -->
|
|
|
- <view v-if="userStore.isLoggedIn" class="menu-item" @click="goRecords">
|
|
|
- <text class="menu-item__label">📋 我的分析</text>
|
|
|
- <text class="menu-item__arrow">›</text>
|
|
|
- </view>
|
|
|
-
|
|
|
- <!-- Distribution panel (paid users only) -->
|
|
|
- <view v-if="userStore.isLoggedIn && userStore.isVip" class="menu-item" @click="goCommission">
|
|
|
- <text class="menu-item__label">💰 我的推广</text>
|
|
|
- <text class="menu-item__arrow">›</text>
|
|
|
- </view>
|
|
|
-
|
|
|
<!-- Practitioner workbench (practitioners only) — EPIC 9 -->
|
|
|
<view v-if="userStore.vipType === 'practitioner' && userStore.isVip" class="menu-item" @click="goWorkbench">
|
|
|
<text class="menu-item__label">🔧 工作台</text>
|
|
|
@@ -196,6 +187,104 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
+ <!-- ===== Promotion Center (paid users only) ===== -->
|
|
|
+ <template v-if="userStore.isLoggedIn && userStore.isVip">
|
|
|
+ <!-- 收益 -->
|
|
|
+ <view class="promo-section earnings-section">
|
|
|
+ <view class="promo-section__header">
|
|
|
+ <text class="promo-section__title">💰 我的收益</text>
|
|
|
+ </view>
|
|
|
+ <view class="earnings-grid">
|
|
|
+ <view class="earn-item">
|
|
|
+ <text class="earn-label">累计收益</text>
|
|
|
+ <text class="earn-value accent">¥{{ formatCommissionMoney(stats.totalEarnings) }}</text>
|
|
|
+ </view>
|
|
|
+ <view class="earn-item">
|
|
|
+ <text class="earn-label">可提现余额</text>
|
|
|
+ <text class="earn-value">¥{{ formatCommissionMoney(stats.availableBalance) }}</text>
|
|
|
+ </view>
|
|
|
+ <view class="earn-item">
|
|
|
+ <text class="earn-label">本月收益</text>
|
|
|
+ <text class="earn-value">¥{{ formatCommissionMoney(stats.monthEarnings) }}</text>
|
|
|
+ </view>
|
|
|
+ <view class="earn-item">
|
|
|
+ <text class="earn-label">今日预估</text>
|
|
|
+ <text class="earn-value">¥{{ formatCommissionMoney(stats.todayEstimate) }}</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view v-if="l1Total > 0 || l2Total > 0" class="earnings-breakdown">
|
|
|
+ <view class="breakdown-row">
|
|
|
+ <text class="breakdown-label">一级推广佣金</text>
|
|
|
+ <text class="breakdown-value">¥{{ formatCommissionMoney(l1Total) }}</text>
|
|
|
+ </view>
|
|
|
+ <view class="breakdown-row">
|
|
|
+ <text class="breakdown-label">二级推广佣金</text>
|
|
|
+ <text class="breakdown-value">¥{{ formatCommissionMoney(l2Total) }}</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <!-- 团队 -->
|
|
|
+ <view class="promo-section">
|
|
|
+ <view class="promo-section__header">
|
|
|
+ <text class="promo-section__title">👥 我的团队</text>
|
|
|
+ <text v-if="team.length > 0" class="promo-section__sub" @click="showTeamDetail">查看全部 →</text>
|
|
|
+ </view>
|
|
|
+ <view class="team-grid">
|
|
|
+ <view class="team-stat">
|
|
|
+ <text class="stat-num">{{ stats.directInvites }}</text>
|
|
|
+ <text class="stat-label">直接下级</text>
|
|
|
+ </view>
|
|
|
+ <view class="team-stat">
|
|
|
+ <text class="stat-num">{{ stats.indirectInvites }}</text>
|
|
|
+ <text class="stat-label">间接下级</text>
|
|
|
+ </view>
|
|
|
+ <view class="team-stat">
|
|
|
+ <text class="stat-num">{{ stats.convertedCount }}</text>
|
|
|
+ <text class="stat-label">下级升级</text>
|
|
|
+ </view>
|
|
|
+ <view class="team-stat">
|
|
|
+ <text class="stat-num">{{ stats.totalCommissions }}</text>
|
|
|
+ <text class="stat-label">佣金笔数</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view v-if="team.length > 0" class="team-preview">
|
|
|
+ <view v-for="(m, idx) in team.slice(0, 5)" :key="idx" class="member-row">
|
|
|
+ <image class="member-avatar" :src="m.avatarUrl || '/static/default-avatar.png'" mode="aspectFill" />
|
|
|
+ <view class="member-info">
|
|
|
+ <text class="member-name">{{ m.nickname || '微信用户' }}</text>
|
|
|
+ <text class="member-date">{{ formatDate(m.createdAt) }} 加入</text>
|
|
|
+ </view>
|
|
|
+ <text v-if="m.isVip" class="member-vip">VIP</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view v-else class="promo-empty">
|
|
|
+ <text class="promo-empty-text">暂无推广成员</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <!-- 佣金明细 -->
|
|
|
+ <view class="promo-section">
|
|
|
+ <view class="promo-section__header">
|
|
|
+ <text class="promo-section__title">📋 佣金明细</text>
|
|
|
+ </view>
|
|
|
+ <view v-if="commissions.length === 0" class="promo-empty">
|
|
|
+ <text class="promo-empty-text">暂无佣金记录</text>
|
|
|
+ </view>
|
|
|
+ <view v-for="(c, idx) in commissions" :key="idx" class="commission-row">
|
|
|
+ <view class="comm-left">
|
|
|
+ <text class="comm-amount">+¥{{ (c.amount / 100).toFixed(2) }}</text>
|
|
|
+ <text class="comm-level">{{ c.level === 1 ? '一级推广' : '二级推广' }}</text>
|
|
|
+ <text v-if="c.remark" class="comm-remark">{{ c.remark }}</text>
|
|
|
+ </view>
|
|
|
+ <view class="comm-right">
|
|
|
+ <text class="comm-status" :class="'status-' + c.status">{{ commissionStatusText(c.status) }}</text>
|
|
|
+ <text class="comm-date">{{ formatDate(c.createdAt) }}</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </template>
|
|
|
+
|
|
|
<!-- Group 2: Promotion Tools (paid users only) -->
|
|
|
<view v-if="userStore.isLoggedIn && userStore.isVip && userStore.referralCode" class="menu-section">
|
|
|
<view class="menu-section__header">推广工具</view>
|
|
|
@@ -242,21 +331,39 @@
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
- import { computed, getCurrentInstance } from 'vue'
|
|
|
- import { onShow } from '@dcloudio/uni-app'
|
|
|
- import { useUserStore } from '@/stores/user'
|
|
|
- import { useThemeStore } from '@/stores/theme'
|
|
|
- import { profileApi } from '@/utils/api'
|
|
|
-
|
|
|
- const userStore = useUserStore()
|
|
|
- const themeStore = useThemeStore()
|
|
|
+ import { ref, computed, getCurrentInstance } from 'vue'
|
|
|
+ import { onShow } from '@dcloudio/uni-app'
|
|
|
+ import { useUserStore } from '@/stores/user'
|
|
|
+ import { useThemeStore } from '@/stores/theme'
|
|
|
+ import { useTheme } from '@/composables/useThemeStyle'
|
|
|
+ import { profileApi, commissionApi } from '@/utils/api'
|
|
|
+
|
|
|
+ const userStore = useUserStore()
|
|
|
+ const themeStore = useThemeStore()
|
|
|
+ const { themeClass } = useTheme()
|
|
|
+
|
|
|
+ // Commission reactive data
|
|
|
+ const commissions = ref([])
|
|
|
+ const team = ref([])
|
|
|
+ const stats = ref({
|
|
|
+ totalEarnings: 0,
|
|
|
+ availableBalance: 0,
|
|
|
+ todayEstimate: 0,
|
|
|
+ monthEarnings: 0,
|
|
|
+ directInvites: 0,
|
|
|
+ indirectInvites: 0,
|
|
|
+ convertedCount: 0,
|
|
|
+ totalCommissions: 0
|
|
|
+ })
|
|
|
|
|
|
- // Initialize theme on page show
|
|
|
- onShow(() => {
|
|
|
- themeStore.init()
|
|
|
- })
|
|
|
+ const l1Total = computed(() =>
|
|
|
+ commissions.value.filter(c => c.level === 1 && c.status === 'settled').reduce((s, c) => s + (c.amount || 0), 0)
|
|
|
+ )
|
|
|
+ const l2Total = computed(() =>
|
|
|
+ commissions.value.filter(c => c.level === 2 && c.status === 'settled').reduce((s, c) => s + (c.amount || 0), 0)
|
|
|
+ )
|
|
|
|
|
|
-// US-4.3: Renewal reminder if expiry within 7 days
|
|
|
+// US-4.3: Renewal reminder if expiry within 7 days
|
|
|
const isExpiringSoon = computed(() => {
|
|
|
if (!userStore.vipEndTime) return false
|
|
|
const expiry = new Date(userStore.vipEndTime)
|
|
|
@@ -277,10 +384,12 @@ function formatDate(dateStr) {
|
|
|
}
|
|
|
|
|
|
onShow(() => {
|
|
|
+ themeStore.init()
|
|
|
if (userStore.isLoggedIn) {
|
|
|
userStore.fetchProfile()
|
|
|
userStore.fetchQuota()
|
|
|
userStore.fetchCommissionSummary()
|
|
|
+ fetchCommissionData()
|
|
|
}
|
|
|
})
|
|
|
|
|
|
@@ -313,16 +422,36 @@ function goSuperMember() {
|
|
|
uni.navigateTo({ url: '/pages/payment/index?product=super_member' })
|
|
|
}
|
|
|
|
|
|
-function goRecords() {
|
|
|
- uni.switchTab({ url: '/pages/records/index' })
|
|
|
+function formatCommissionMoney(cents) {
|
|
|
+ if (cents == null) return '0.00'
|
|
|
+ return (cents / 100).toFixed(2)
|
|
|
}
|
|
|
|
|
|
-function goCommission() {
|
|
|
- if (!userStore.isLoggedIn) {
|
|
|
- uni.navigateTo({ url: '/pages/login/index' })
|
|
|
- return
|
|
|
- }
|
|
|
- uni.navigateTo({ url: '/pages/commission/index' })
|
|
|
+function commissionStatusText(status) {
|
|
|
+ const map = { settled: '已结算', pending: '处理中', withdrawn: '已提现', available: '可提现' }
|
|
|
+ return map[status] || status
|
|
|
+}
|
|
|
+
|
|
|
+async function fetchCommissionData() {
|
|
|
+ if (!userStore.isVip) return
|
|
|
+ try {
|
|
|
+ const [listData, teamData, statsData] = await Promise.all([
|
|
|
+ commissionApi.list(),
|
|
|
+ commissionApi.team(),
|
|
|
+ commissionApi.stats()
|
|
|
+ ])
|
|
|
+ commissions.value = listData || []
|
|
|
+ team.value = teamData || []
|
|
|
+ if (statsData) stats.value = statsData
|
|
|
+ } catch (e) { /* ignore */ }
|
|
|
+}
|
|
|
+
|
|
|
+function showTeamDetail() {
|
|
|
+ uni.showModal({
|
|
|
+ title: '推广团队',
|
|
|
+ content: `直接下级 ${stats.value.directInvites} 人\n间接下级 ${stats.value.indirectInvites} 人\n已升级VIP ${stats.value.convertedCount} 人`,
|
|
|
+ showCancel: false
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
// EPIC 9: Navigate to practitioner workbench
|
|
|
@@ -508,16 +637,98 @@ function handleLogout() {
|
|
|
</script>
|
|
|
|
|
|
<style scoped lang="scss">
|
|
|
-// Brand colors (aligned with style-guide.md)
|
|
|
-$blue-dark: #1E3A5F;
|
|
|
-$gold: #C9A84C;
|
|
|
-$gold-light: #F8F0D8;
|
|
|
-$warm-white: #F8F6F1;
|
|
|
+// Brand colors (using CSS custom properties — responsive to theme)
|
|
|
+$blue-dark: var(--color-brand);
|
|
|
+$gold: var(--color-gold);
|
|
|
+$gold-light: var(--color-gold-light);
|
|
|
+$warm-white: var(--color-bg);
|
|
|
$white: #FFFFFF;
|
|
|
-$text-primary: #1F2937;
|
|
|
-$text-secondary: #6B7280;
|
|
|
-$text-muted: #9CA3AF;
|
|
|
-$danger: #EF4444;
|
|
|
+$card-bg: var(--color-bg-card);
|
|
|
+$text-primary: var(--color-text-primary);
|
|
|
+$text-secondary: var(--color-text-secondary);
|
|
|
+$text-muted: var(--color-text-tertiary);
|
|
|
+$danger: var(--color-danger);
|
|
|
+
|
|
|
+// ===== Theme Variables (class-based, replaces inline :style) =====
|
|
|
+.page-profile {
|
|
|
+ // Default: Dark Theme
|
|
|
+ --color-bg: #0c0a1a;
|
|
|
+ --color-bg-secondary: #120d28;
|
|
|
+ --color-bg-tertiary: #0f0c1e;
|
|
|
+ --color-bg-card: rgba(255, 255, 255, 0.06);
|
|
|
+ --color-bg-card-hover: rgba(255, 255, 255, 0.1);
|
|
|
+ --color-bg-input: rgba(255, 255, 255, 0.1);
|
|
|
+ --color-bg-tag: rgba(255, 255, 255, 0.08);
|
|
|
+ --color-bg-overlay: rgba(12, 10, 26, 0.85);
|
|
|
+ --color-text-primary: #FFFFFF;
|
|
|
+ --color-text-secondary: #CBD5E1;
|
|
|
+ --color-text-tertiary: rgba(255, 255, 255, 0.6);
|
|
|
+ --color-text-link: #60A5FA;
|
|
|
+ --color-text-gold: #C9A84C;
|
|
|
+ --color-brand: #1E3A5F;
|
|
|
+ --color-brand-light: #1E3A5F;
|
|
|
+ --color-elevated: #172943;
|
|
|
+ --color-gold: #C9A84C;
|
|
|
+ --color-gold-bg: rgba(201, 168, 76, 0.15);
|
|
|
+ --color-gold-light: #FEF3C7;
|
|
|
+ --color-border: rgba(255, 255, 255, 0.1);
|
|
|
+ --color-border-light: rgba(255, 255, 255, 0.06);
|
|
|
+ --color-border-focus: rgba(201, 168, 76, 0.5);
|
|
|
+ --color-success: #10b981;
|
|
|
+ --color-success-bg: rgba(16, 185, 129, 0.15);
|
|
|
+ --color-warning: #fbbf24;
|
|
|
+ --color-warning-bg: rgba(251, 191, 36, 0.15);
|
|
|
+ --color-danger: #ef4444;
|
|
|
+ --color-danger-bg: rgba(239, 68, 68, 0.15);
|
|
|
+ --color-info: #3B82F6;
|
|
|
+ --color-info-bg: rgba(59, 130, 246, 0.15);
|
|
|
+ --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
|
|
|
+ --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
|
|
|
+ --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.3);
|
|
|
+ --shadow-modal: 0 10px 40px rgba(0, 0, 0, 0.5);
|
|
|
+ --shadow-btn: 0 4px 15px rgba(30, 58, 95, 0.4);
|
|
|
+ --shadow-gold: 0 4px 15px rgba(201, 168, 76, 0.3);
|
|
|
+
|
|
|
+ // Light Theme override
|
|
|
+ &.theme-light {
|
|
|
+ --color-bg: #F8F6F1;
|
|
|
+ --color-bg-secondary: #F0EDE6;
|
|
|
+ --color-bg-tertiary: #E8E5DE;
|
|
|
+ --color-bg-card: #FFFFFF;
|
|
|
+ --color-bg-card-hover: #F7F8FC;
|
|
|
+ --color-bg-input: #F3F4F6;
|
|
|
+ --color-bg-tag: #F3F4F6;
|
|
|
+ --color-bg-overlay: rgba(248, 246, 241, 0.9);
|
|
|
+ --color-text-primary: #1A1A2E;
|
|
|
+ --color-text-secondary: #4A5568;
|
|
|
+ --color-text-tertiary: #9CA3AF;
|
|
|
+ --color-text-link: #2563EB;
|
|
|
+ --color-text-gold: #92400E;
|
|
|
+ --color-brand: #1E3A5F;
|
|
|
+ --color-brand-light: #1E3A5F;
|
|
|
+ --color-elevated: #2C5282;
|
|
|
+ --color-gold: #C9A84C;
|
|
|
+ --color-gold-bg: #FEF3C7;
|
|
|
+ --color-gold-light: #FEF3C7;
|
|
|
+ --color-border: #E2E8F0;
|
|
|
+ --color-border-light: #F3F4F6;
|
|
|
+ --color-border-focus: rgba(201, 168, 76, 0.6);
|
|
|
+ --color-success: #059669;
|
|
|
+ --color-success-bg: #D1FAE5;
|
|
|
+ --color-warning: #D97706;
|
|
|
+ --color-warning-bg: #FEF3C7;
|
|
|
+ --color-danger: #DC2626;
|
|
|
+ --color-danger-bg: #FEE2E2;
|
|
|
+ --color-info: #2563EB;
|
|
|
+ --color-info-bg: #DBEAFE;
|
|
|
+ --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
|
|
|
+ --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
|
|
|
+ --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.06);
|
|
|
+ --shadow-modal: 0 8px 30px rgba(0, 0, 0, 0.1);
|
|
|
+ --shadow-btn: 0 4px 12px rgba(30, 58, 95, 0.2);
|
|
|
+ --shadow-gold: 0 4px 12px rgba(201, 168, 76, 0.2);
|
|
|
+ }
|
|
|
+}
|
|
|
|
|
|
.page-profile {
|
|
|
padding: 16px;
|
|
|
@@ -527,10 +738,10 @@ $danger: #EF4444;
|
|
|
|
|
|
// ========== Merged Region 1+2: User Card + Membership ==========
|
|
|
.user-card {
|
|
|
- background: linear-gradient(135deg, $blue-dark, darken($blue-dark, 6%));
|
|
|
+ background: linear-gradient(135deg, var(--color-brand), var(--color-elevated));
|
|
|
border-radius: 16px;
|
|
|
padding: 20px 18px;
|
|
|
- margin-bottom: 16px;
|
|
|
+ margin-bottom: 24px;
|
|
|
|
|
|
&__login {
|
|
|
cursor: pointer;
|
|
|
@@ -553,11 +764,17 @@ $danger: #EF4444;
|
|
|
min-width: 0;
|
|
|
}
|
|
|
|
|
|
+ &__name-row {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ gap: 8px;
|
|
|
+ flex-wrap: wrap;
|
|
|
+ }
|
|
|
+
|
|
|
&__nickname {
|
|
|
font-size: 17px;
|
|
|
font-weight: 600;
|
|
|
color: $white;
|
|
|
- display: block;
|
|
|
}
|
|
|
|
|
|
&__login-hint {
|
|
|
@@ -573,27 +790,36 @@ $danger: #EF4444;
|
|
|
border-radius: 20px;
|
|
|
font-size: 11px;
|
|
|
margin-top: 6px;
|
|
|
+ background: rgba(255, 255, 255, 0.22);
|
|
|
+ color: #fff;
|
|
|
|
|
|
&--practitioner {
|
|
|
background: $gold;
|
|
|
- color: $blue-dark;
|
|
|
+ color: #fff;
|
|
|
font-weight: 600;
|
|
|
}
|
|
|
|
|
|
&--annual {
|
|
|
- background: rgba($gold, 0.25);
|
|
|
- color: $gold;
|
|
|
+ background: $gold;
|
|
|
+ color: #fff;
|
|
|
+ font-weight: 600;
|
|
|
+ }
|
|
|
+
|
|
|
+ &--super {
|
|
|
+ background: $gold;
|
|
|
+ color: #fff;
|
|
|
+ font-weight: 600;
|
|
|
}
|
|
|
|
|
|
&--normal {
|
|
|
- background: rgba(255, 255, 255, 0.15);
|
|
|
- color: rgba(255, 255, 255, 0.8);
|
|
|
+ background: rgba(255, 255, 255, 0.22);
|
|
|
+ color: #fff;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
&__summary {
|
|
|
font-size: 11px;
|
|
|
- color: rgba(255, 255, 255, 0.55);
|
|
|
+ color: rgba(255, 255, 255, 0.78);
|
|
|
margin-top: 4px;
|
|
|
display: block;
|
|
|
overflow: hidden;
|
|
|
@@ -607,6 +833,232 @@ $danger: #EF4444;
|
|
|
flex-shrink: 0;
|
|
|
padding-left: 4px;
|
|
|
}
|
|
|
+
|
|
|
+ &__header-right {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ gap: 8px;
|
|
|
+ flex-shrink: 0;
|
|
|
+ align-self: flex-start;
|
|
|
+ padding-top: 2px;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+// Theme toggle button
|
|
|
+.theme-toggle-btn {
|
|
|
+ width: 36px;
|
|
|
+ height: 36px;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: center;
|
|
|
+ background: rgba(255, 255, 255, 0.2);
|
|
|
+ border: 1.5px solid rgba(255, 255, 255, 0.35);
|
|
|
+ border-radius: 50%;
|
|
|
+ cursor: pointer;
|
|
|
+ box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
|
|
+}
|
|
|
+.theme-toggle-text {
|
|
|
+ font-size: 13px;
|
|
|
+ font-weight: 700;
|
|
|
+ color: #fff;
|
|
|
+ line-height: 1;
|
|
|
+}
|
|
|
+
|
|
|
+// ===== Promotion Center Sections =====
|
|
|
+.promo-section {
|
|
|
+ background: var(--color-bg-card);
|
|
|
+ border-radius: 14px;
|
|
|
+ padding: 16px;
|
|
|
+ margin-bottom: 16px;
|
|
|
+
|
|
|
+ &__header {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ align-items: center;
|
|
|
+ margin-bottom: 14px;
|
|
|
+ }
|
|
|
+ &__title {
|
|
|
+ font-size: 16px;
|
|
|
+ font-weight: 700;
|
|
|
+ color: $text-primary;
|
|
|
+ }
|
|
|
+ &__sub {
|
|
|
+ font-size: 12px;
|
|
|
+ color: #3B82F6;
|
|
|
+ font-weight: 500;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.earnings-section {
|
|
|
+ background: linear-gradient(135deg, var(--color-brand), var(--color-elevated));
|
|
|
+ .promo-section__title {
|
|
|
+ color: rgba(255,255,255,0.9);
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.earnings-grid {
|
|
|
+ display: grid;
|
|
|
+ grid-template-columns: 1fr 1fr;
|
|
|
+ gap: 12px;
|
|
|
+}
|
|
|
+.earn-item {
|
|
|
+ text-align: center;
|
|
|
+ padding: 8px 0;
|
|
|
+}
|
|
|
+.earn-label {
|
|
|
+ font-size: 11px;
|
|
|
+ color: rgba(255,255,255,0.78);
|
|
|
+ display: block;
|
|
|
+ margin-bottom: 4px;
|
|
|
+}
|
|
|
+.earn-value {
|
|
|
+ font-size: 22px;
|
|
|
+ font-weight: 700;
|
|
|
+ color: #fff;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+.earn-value.accent {
|
|
|
+ color: var(--color-gold);
|
|
|
+}
|
|
|
+
|
|
|
+.earnings-breakdown {
|
|
|
+ margin-top: 12px;
|
|
|
+ padding: 10px 14px;
|
|
|
+ background: rgba(255,255,255,0.03);
|
|
|
+ border-radius: 8px;
|
|
|
+}
|
|
|
+.breakdown-row {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ align-items: center;
|
|
|
+ padding: 4px 0;
|
|
|
+}
|
|
|
+.breakdown-label {
|
|
|
+ font-size: 12px;
|
|
|
+ color: rgba(255,255,255,0.7);
|
|
|
+}
|
|
|
+.breakdown-value {
|
|
|
+ font-size: 13px;
|
|
|
+ font-weight: 500;
|
|
|
+ color: rgba(255,255,255,0.9);
|
|
|
+}
|
|
|
+
|
|
|
+// Team
|
|
|
+.team-grid {
|
|
|
+ display: grid;
|
|
|
+ grid-template-columns: 1fr 1fr 1fr 1fr;
|
|
|
+ gap: 8px;
|
|
|
+ margin-bottom: 14px;
|
|
|
+}
|
|
|
+.team-stat {
|
|
|
+ text-align: center;
|
|
|
+ padding: 8px 0;
|
|
|
+}
|
|
|
+.stat-num {
|
|
|
+ font-size: 24px;
|
|
|
+ font-weight: 700;
|
|
|
+ color: var(--color-text-primary);
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+.stat-label {
|
|
|
+ font-size: 11px;
|
|
|
+ color: $text-secondary;
|
|
|
+ margin-top: 2px;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+
|
|
|
+.team-preview {
|
|
|
+ border-top: 1px solid var(--color-border);
|
|
|
+ padding-top: 10px;
|
|
|
+}
|
|
|
+.member-row {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ padding: 8px 0;
|
|
|
+ border-bottom: 1px solid var(--color-bg);
|
|
|
+}
|
|
|
+.member-row:last-child { border-bottom: none; }
|
|
|
+.member-avatar {
|
|
|
+ width: 32px;
|
|
|
+ height: 32px;
|
|
|
+ border-radius: 50%;
|
|
|
+ margin-right: 10px;
|
|
|
+ flex-shrink: 0;
|
|
|
+}
|
|
|
+.member-info { flex: 1; }
|
|
|
+.member-name {
|
|
|
+ font-size: 13px;
|
|
|
+ color: $text-primary;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+.member-date {
|
|
|
+ font-size: 11px;
|
|
|
+ color: $text-secondary;
|
|
|
+ margin-top: 1px;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+.member-vip {
|
|
|
+ font-size: 10px;
|
|
|
+ color: var(--color-gold);
|
|
|
+ background: #FEF3C7;
|
|
|
+ padding: 2px 8px;
|
|
|
+ border-radius: 4px;
|
|
|
+ font-weight: 500;
|
|
|
+}
|
|
|
+
|
|
|
+.promo-empty {
|
|
|
+ padding: 24px 0;
|
|
|
+ text-align: center;
|
|
|
+}
|
|
|
+.promo-empty-text {
|
|
|
+ font-size: 13px;
|
|
|
+ color: $text-secondary;
|
|
|
+}
|
|
|
+
|
|
|
+// Commission List
|
|
|
+.commission-row {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ align-items: center;
|
|
|
+ padding: 12px 0;
|
|
|
+ border-bottom: 1px solid var(--color-border);
|
|
|
+}
|
|
|
+.commission-row:last-child { border-bottom: none; }
|
|
|
+.comm-left { flex: 1; }
|
|
|
+.comm-amount {
|
|
|
+ font-size: 15px;
|
|
|
+ font-weight: 600;
|
|
|
+ color: #2D8B67;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+.comm-level {
|
|
|
+ font-size: 12px;
|
|
|
+ color: $text-secondary;
|
|
|
+ margin-top: 2px;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+.comm-remark {
|
|
|
+ font-size: 11px;
|
|
|
+ color: $text-secondary;
|
|
|
+ margin-top: 1px;
|
|
|
+ display: block;
|
|
|
+}
|
|
|
+.comm-right { text-align: right; }
|
|
|
+.comm-status {
|
|
|
+ font-size: 11px;
|
|
|
+ padding: 2px 8px;
|
|
|
+ border-radius: 4px;
|
|
|
+ display: inline-block;
|
|
|
+ margin-bottom: 2px;
|
|
|
+}
|
|
|
+.comm-status.status-settled { background: #ECFDF5; color: #2D8B67; }
|
|
|
+.comm-status.status-pending { background: #FEF3C7; color: #D4A017; }
|
|
|
+.comm-status.status-withdrawn { background: var(--color-bg-input); color: $text-secondary; }
|
|
|
+.comm-status.status-available { background: #EFF6FF; color: #3B82F6; }
|
|
|
+.comm-date {
|
|
|
+ font-size: 11px;
|
|
|
+ color: $text-secondary;
|
|
|
+ display: block;
|
|
|
}
|
|
|
|
|
|
// Avatar
|
|
|
@@ -696,7 +1148,7 @@ $danger: #EF4444;
|
|
|
display: flex;
|
|
|
justify-content: space-between;
|
|
|
align-items: center;
|
|
|
- margin-bottom: 16px;
|
|
|
+ margin-top: 16px;
|
|
|
|
|
|
&__body {
|
|
|
flex: 1;
|
|
|
@@ -710,7 +1162,7 @@ $danger: #EF4444;
|
|
|
|
|
|
&__desc {
|
|
|
font-size: 12px;
|
|
|
- opacity: 0.8;
|
|
|
+ opacity: 0.92;
|
|
|
display: block;
|
|
|
margin-top: 4px;
|
|
|
}
|
|
|
@@ -770,17 +1222,17 @@ $danger: #EF4444;
|
|
|
// Expired
|
|
|
&--expired {
|
|
|
background: #E5E7EB;
|
|
|
- .vip-card__title { color: $text-secondary; }
|
|
|
- .vip-card__desc { color: $text-muted; }
|
|
|
+ .vip-card__title { color: $text-primary; }
|
|
|
+ .vip-card__desc { color: $text-secondary; }
|
|
|
.vip-card__action {
|
|
|
- color: $text-secondary;
|
|
|
- background: $white;
|
|
|
+ color: #fff;
|
|
|
+ background: $text-secondary;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
// Upsell (free user — two options)
|
|
|
&--upsell {
|
|
|
- background: linear-gradient(135deg, $blue-dark, darken($blue-dark, 4%));
|
|
|
+ background: linear-gradient(135deg, var(--color-brand), var(--color-elevated));
|
|
|
flex-direction: column;
|
|
|
align-items: flex-start;
|
|
|
gap: 14px;
|
|
|
@@ -832,7 +1284,7 @@ $danger: #EF4444;
|
|
|
|
|
|
.vip-card__option .option-desc {
|
|
|
font-size: 11px;
|
|
|
- color: rgba(255, 255, 255, 0.45);
|
|
|
+ color: rgba(255, 255, 255, 0.7);
|
|
|
}
|
|
|
|
|
|
.vip-card__option .option-btn {
|
|
|
@@ -857,15 +1309,15 @@ $danger: #EF4444;
|
|
|
}
|
|
|
|
|
|
.vip-card__option--pro {
|
|
|
- border-color: rgba($gold, 0.2);
|
|
|
- background: rgba($gold, 0.06);
|
|
|
+ border-color: rgba(201, 168, 76, 0.2);
|
|
|
+ background: rgba(201, 168, 76, 0.06);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
// Daily quota
|
|
|
.quota-bar {
|
|
|
- background: $white;
|
|
|
+ background: $card-bg;
|
|
|
border-radius: 12px;
|
|
|
padding: 16px;
|
|
|
margin-bottom: 16px;
|
|
|
@@ -899,7 +1351,7 @@ $danger: #EF4444;
|
|
|
|
|
|
// ========== Region 3: Feature Menu ==========
|
|
|
.menu-section {
|
|
|
- background: $white;
|
|
|
+ background: $card-bg;
|
|
|
border-radius: 12px;
|
|
|
margin-bottom: 16px;
|
|
|
overflow: hidden;
|
|
|
@@ -907,7 +1359,7 @@ $danger: #EF4444;
|
|
|
&__header {
|
|
|
font-size: 12px;
|
|
|
font-weight: 600;
|
|
|
- color: $text-muted;
|
|
|
+ color: $text-secondary;
|
|
|
text-transform: uppercase;
|
|
|
letter-spacing: 0.5px;
|
|
|
padding: 14px 16px 6px;
|
|
|
@@ -954,7 +1406,7 @@ $danger: #EF4444;
|
|
|
}
|
|
|
|
|
|
&__arrow {
|
|
|
- color: $text-muted;
|
|
|
+ color: $text-secondary;
|
|
|
font-size: 18px;
|
|
|
}
|
|
|
|
|
|
@@ -982,7 +1434,7 @@ $danger: #EF4444;
|
|
|
|
|
|
&__prefix {
|
|
|
font-size: 13px;
|
|
|
- color: $text-secondary;
|
|
|
+ color: $blue-dark;
|
|
|
}
|
|
|
|
|
|
&__code {
|