index.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945
  1. <template>
  2. <view class="container">
  3. <!-- TabTransition overlay -->
  4. <tab-transition v-if="showTabTransition" dimCode="wealth" ref="tabTransition" @close="showTabTransition = false" />
  5. <!-- 未登录时显示精简内容 -->
  6. <template v-if="!isLoggedIn">
  7. <PageBanner theme="wealth"
  8. tagline="利他创富 · 价值共享"
  9. quote="富足源于利他与坚持" />
  10. <!-- 品牌定位语 -->
  11. <view class="brand-strap">
  12. <text class="brand-strap-text">分享价值,收获财富</text>
  13. </view>
  14. <!-- 月度引导语 -->
  15. <view class="monthly-guidance" v-if="!isLoggedIn">
  16. <text class="guidance-icon">💧</text>
  17. <text class="guidance-text">{{ monthlyGuidance }}</text>
  18. </view>
  19. <!-- 登录引导 -->
  20. <view class="login-guide-section">
  21. <LoginGuideCard
  22. title="解锁财富能量与推广收益"
  23. :items="[
  24. '查看家庭财富能量仪表盘与推广收益',
  25. '管理邀请返利,开通会员享专属折扣',
  26. '浏览商城精选商品,一键加入购物车'
  27. ]" />
  28. </view>
  29. <!-- 商城精选预览(无需登录) -->
  30. <view class="section">
  31. <view class="section-header">
  32. <text class="section-title">🛍️ 商城精选</text>
  33. <text class="section-more" @click="goToShop">查看全部 ›</text>
  34. </view>
  35. <scroll-view scroll-x class="product-scroll" show-scrollbar="false">
  36. <view class="product-list">
  37. <view class="product-card" v-for="(item, idx) in guestProducts" :key="idx" @click="goProductDetail(item.id)">
  38. <image class="product-img" :src="getImageUrl(item.coverImage || item.image) || '/static/default-product.png'" mode="aspectFill" />
  39. <text class="product-name">{{ item.name }}</text>
  40. <text class="product-price">¥{{ item.price || 0 }}</text>
  41. </view>
  42. </view>
  43. </scroll-view>
  44. </view>
  45. </template>
  46. <template v-else>
  47. <!-- 品牌头部 -->
  48. <PageBanner theme="wealth"
  49. tagline="利他创富 · 价值共享"
  50. quote="富足源于利他与坚持" />
  51. <!-- 家庭成员选择条 -->
  52. <FamilyMemberStrip
  53. v-if="currentView === 'self'"
  54. v-if="isLoggedIn"
  55. :members="familyMembersVisible"
  56. :selectedMemberId="selectedMemberId"
  57. @select="onFamilyMemberSelect"
  58. @removed="loadFamilyMembersVisible" />
  59. <!-- 身克富杠杆警告 -->
  60. <body-wealth-alert
  61. :status="bodyWealthStatus"
  62. :message="bodyWealthMessage"
  63. :showTip="true" />
  64. <!-- 财富能量环 -->
  65. <WealthEnergyRing
  66. :score="wealthScore"
  67. :delta="deltaPercent" />
  68. <!-- 财富成长 -->
  69. <view class="section stream-section">
  70. <view class="section-header">
  71. <text class="section-title">💰 财富成长</text>
  72. <text class="section-sub">记录家庭财富积累过程,看到每月的成长变化</text>
  73. </view>
  74. <view class="stream-stages">
  75. <view
  76. class="stage-card"
  77. :class="{ active: stage.key === currentStage }"
  78. v-for="stage in streamStages"
  79. :key="stage.key">
  80. <text class="stage-icon">{{ stage.icon }}</text>
  81. <text class="stage-name">{{ stage.name }}</text>
  82. <text class="stage-desc">{{ stage.desc }}</text>
  83. <text class="stage-range">{{ stage.range }}</text>
  84. </view>
  85. </view>
  86. <view class="stream-water">
  87. <view class="stream-water-fill" :style="{ width: wealthScore + '%' }"></view>
  88. </view>
  89. <text class="stream-percent">水位 {{ wealthScore }}%</text>
  90. <text class="stream-tip">{{ streamTip }}</text>
  91. </view>
  92. <!-- 子维度水滴 -->
  93. <wealth-sub-scores
  94. :role="role"
  95. :income="wealthIncome"
  96. :achievement="wealthAchievement"
  97. :network="wealthNetwork"
  98. :education="wealthEducation"
  99. :social="wealthSocial"
  100. :points="wealthPoints" />
  101. <!-- 财富数据卡(家长) -->
  102. <view class="section" v-if="role === 'parent'">
  103. <view class="disc-card">
  104. <text class="disc-label">💰 累计收益</text>
  105. <text class="disc-value">¥{{ wealthData.totalEarnings || 0 }}</text>
  106. <text class="disc-sub">较上月 ↑ {{ deltaPercent }}%</text>
  107. </view>
  108. <view class="disc-sub-row">
  109. <view class="disc-sub-card" @click="goToIncome">
  110. <text class="disc-sub-label">可提现</text>
  111. <text class="disc-sub-value">¥{{ wealthData.availableAmount || 0 }}</text>
  112. <text class="disc-sub-action">提现 →</text>
  113. </view>
  114. <view class="disc-sub-card" @click="goToAchievements">
  115. <text class="disc-sub-label">邀请人数</text>
  116. <text class="disc-sub-value">{{ wealthData.referralCount || 0 }}人</text>
  117. <text class="disc-sub-action">邀请 →</text>
  118. </view>
  119. </view>
  120. <view class="referral-code-bar" v-if="wealthData.referralCode" @click="copyReferralCode">
  121. <text class="referral-code-label">我的邀请码</text>
  122. <text class="referral-code-value">{{ wealthData.referralCode }}</text>
  123. <text class="referral-code-copy">复制</text>
  124. </view>
  125. </view>
  126. <!-- 财富数据卡(孩子) -->
  127. <view class="section" v-else>
  128. <view class="child-wealth-card">
  129. <view class="child-wealth-item">
  130. <text class="child-wealth-icon">⭐</text>
  131. <text class="child-wealth-value">{{ wealthPoints || 0 }}</text>
  132. <text class="child-wealth-label">累计积分</text>
  133. </view>
  134. <view class="child-wealth-item">
  135. <text class="child-wealth-icon">📝</text>
  136. <text class="child-wealth-value">{{ taskPercent }}%</text>
  137. <text class="child-wealth-label">任务完成</text>
  138. </view>
  139. <view class="child-wealth-item">
  140. <text class="child-wealth-icon">🏆</text>
  141. <text class="child-wealth-value">{{ badgeCount }}</text>
  142. <text class="child-wealth-label">已获徽章</text>
  143. </view>
  144. </view>
  145. <view class="child-trend">
  146. <text class="child-trend-title">📊 本周成长趋势</text>
  147. <view class="child-trend-bars">
  148. <view class="trend-bar" v-for="(h, i) in weekTrend" :key="i" :style="{ height: h + '%' }"></view>
  149. </view>
  150. <view class="child-trend-days">
  151. <text class="trend-day" v-for="(d, i) in weekDays" :key="i">{{ d }}</text>
  152. </view>
  153. </view>
  154. </view>
  155. <!-- 财富服务 8 宫格 -->
  156. <view class="section">
  157. <view class="section-header">
  158. <text class="section-title">🚀 财富服务</text>
  159. </view>
  160. <view class="service-grid">
  161. <view class="service-item" v-for="item in serviceList" :key="item.label" @click="onServiceClick(item.action)">
  162. <view class="service-icon-wrap">
  163. <text class="service-icon">{{ item.icon }}</text>
  164. </view>
  165. <text class="service-label">{{ item.label }}</text>
  166. </view>
  167. </view>
  168. </view>
  169. <!-- 富维度介绍卡片 -->
  170. <DimensionIntroCard dimCode="wealth" v-if="isLoggedIn" learn-more-url="/pages/wealth/dimension-intro" />
  171. </template>
  172. </view>
  173. </template>
  174. <script>
  175. import TabTransition from '../../components/tab-transition.vue'
  176. import PageBanner from '../../components/PageBanner.vue'
  177. import WealthEnergyRing from '../../components/WealthEnergyRing.vue'
  178. import WealthSubScores from '../../components/WealthSubScores.vue'
  179. import BodyWealthAlert from '../../components/BodyWealthAlert.vue'
  180. import FamilyMemberStrip from '../../components/FamilyMemberStrip.vue'
  181. import DimensionIntroCard from '../../components/DimensionIntroCard.vue'
  182. import {
  183. getChildren,
  184. getWealthDetail,
  185. getReferralCode,
  186. getReferralSummary,
  187. getCommissionSummary,
  188. getVisibleFamilyMembers,
  189. productList
  190. } from '../../utils/api.js'
  191. import nav from '../../utils/nav.js'
  192. import config from '../../config.js'
  193. export default {
  194. components: { TabTransition, PageBanner, WealthEnergyRing, WealthSubScores, BodyWealthAlert, FamilyMemberStrip, DimensionIntroCard },
  195. data() {
  196. return {
  197. showTabTransition: true,
  198. isLoggedIn: false,
  199. role: 'parent',
  200. // 五维评分
  201. wealthScore: 0,
  202. // 子维度 - parent
  203. wealthIncome: null,
  204. wealthAchievement: null,
  205. wealthNetwork: null,
  206. // 子维度 - child
  207. wealthEducation: null,
  208. wealthSocial: null,
  209. wealthPoints: null,
  210. // 身克富杠杆
  211. bodyWealthStatus: 'normal',
  212. bodyWealthMessage: '',
  213. // 财富数据
  214. wealthData: {
  215. totalEarnings: 0,
  216. availableAmount: 0,
  217. referralCount: 0,
  218. referralCode: ''
  219. },
  220. // 财富成长
  221. deltaPercent: 5.2,
  222. streamStages: [
  223. { key: 'start', icon: '💧', name: '起步', desc: '新人阶段', range: '0-30%' },
  224. { key: 'mid', icon: '🌊', name: '汇流', desc: '成长阶段', range: '30-70%' },
  225. { key: 'surge', icon: '🌊🌊', name: '奔涌', desc: '达人阶段', range: '70-100%' }
  226. ],
  227. // 孩子数据
  228. taskPercent: 0,
  229. badgeCount: 0,
  230. weekTrend: [30, 40, 35, 50, 60, 55, 70],
  231. weekDays: ['一', '二', '三', '四', '五', '六', '日'],
  232. // 服务列表
  233. serviceList: [
  234. { icon: '📝', label: '记账打卡', action: 'goToCheckin' },
  235. { icon: '🛡️', label: '保单管理', action: 'goToInsurance' },
  236. { icon: '🎨', label: '创客中心', action: 'goToCreator' },
  237. { icon: '🏪', label: '商城首页', action: 'goToShop' },
  238. { icon: '🛒', label: '购物车', action: 'goToCart' },
  239. { icon: '📋', label: '我的订单', action: 'goToOrders' },
  240. { icon: '🔄', label: '售后服务', action: 'goToAfterSales' },
  241. { icon: '📊', label: '收益中心', action: 'goToIncome' },
  242. { icon: '💎', label: '家庭CF值', action: 'goToFamilyCf' }
  243. ],
  244. children: [],
  245. familyMembersVisible: [],
  246. selectedMemberId: null,
  247. guestProducts: [],
  248. }
  249. },
  250. computed: {
  251. activeChildId() {
  252. if (this.role === 'child') {
  253. return uni.getStorageSync('currentChildId')
  254. }
  255. return ''
  256. },
  257. currentStage() {
  258. var s = this.wealthScore
  259. if (s >= 70) return 'surge'
  260. if (s >= 30) return 'mid'
  261. return 'start'
  262. },
  263. streamTip() {
  264. var s = this.wealthScore
  265. if (s >= 70) return '🎉 已是富足达人,继续引领全家成长!'
  266. if (s >= 30) return '💡 坚持分享,下一阶段"奔涌"在望'
  267. return '🌱 从今天开始,迈出创富第一步'
  268. }
  269. },
  270. onShow() {
  271. this.showTabTransition = true
  272. var token = uni.getStorageSync('token')
  273. if (!token) {
  274. this.isLoggedIn = false
  275. this.loadGuestProducts()
  276. this._watchPageReady()
  277. return
  278. }
  279. this.isLoggedIn = true
  280. var currentRole = uni.getStorageSync('currentRole') || uni.getStorageSync('role') || 'parent'
  281. if (currentRole === 'teacher') {
  282. uni.redirectTo({ url: '/pages/teacher/teacher-profile' })
  283. return
  284. }
  285. this.role = currentRole
  286. this.loadChildren()
  287. this.loadWealthDetail()
  288. this.loadWealthData()
  289. this.loadFamilyMembersVisible()
  290. this._watchPageReady()
  291. },
  292. /** 每月引导语 */
  293. monthlyGuidance: function() {
  294. var month = new Date().getMonth()
  295. var messages = [
  296. '一月:理财从记账开始,养习惯',
  297. '二月:新年规划,梳理家庭收支',
  298. '三月:春耕时节,播种财富种子',
  299. '四月:清明踏青,规划家庭支出',
  300. '五月:劳动节后,复盘收支状况',
  301. '六月:年中复盘,调整财富目标',
  302. '七月:暑期规划,优化家庭消费',
  303. '八月:开学季,教育专项规划',
  304. '九月:金秋收获,检视推广收益',
  305. '十月:国庆消费,理性理财',
  306. '十一月:年终冲刺,盘点年度收益',
  307. '十二月:年度总结,规划来年财富'
  308. ]
  309. return messages[month] || messages[0]
  310. },
  311. methods: {
  312. onFamilyMemberSelect(member) {
  313. this.selectedMemberId = member.id
  314. },
  315. loadFamilyMembersVisible() {
  316. var self = this
  317. getVisibleFamilyMembers().then(function(res) {
  318. self.familyMembersVisible = res.data || []
  319. }).catch(function(e) {
  320. console.log('获取可见家庭成员失败', e)
  321. self.familyMembersVisible = []
  322. })
  323. },
  324. goLogin() {
  325. uni.navigateTo({ url: '/pages/login/login' })
  326. },
  327. _watchPageReady() {
  328. var self = this
  329. this.$nextTick(function() {
  330. if (self.$refs.tabTransition) self.$refs.tabTransition.markReady()
  331. })
  332. },
  333. async loadChildren() {
  334. try {
  335. var res = await getChildren()
  336. this.children = res.data || []
  337. } catch (e) {
  338. console.error('获取孩子列表失败', e)
  339. }
  340. },
  341. async loadWealthDetail() {
  342. var memberId = null
  343. var memberType = this.role
  344. if (this.role === 'child') {
  345. memberId = uni.getStorageSync('currentChildId')
  346. if (!memberId && this.children.length > 0) {
  347. memberId = this.children[0].id
  348. }
  349. } else {
  350. memberId = uni.getStorageSync('userId')
  351. }
  352. if (!memberId) return
  353. try {
  354. var res = await getWealthDetail(memberId, memberType)
  355. if (res && res.data) {
  356. var d = res.data
  357. this.wealthScore = d.wealthScore || 0
  358. if (memberType === 'parent') {
  359. this.wealthIncome = d.wealthIncome
  360. this.wealthAchievement = d.wealthAchievement
  361. this.wealthNetwork = d.wealthNetwork
  362. } else {
  363. this.wealthEducation = d.wealthEducation
  364. this.wealthSocial = d.wealthSocial
  365. this.wealthPoints = d.wealthPoints
  366. }
  367. // 身克富杠杆状态
  368. this.bodyWealthStatus = d.bodyWealthStatus || 'normal'
  369. this.bodyWealthMessage = d.bodyWealthMessage || ''
  370. }
  371. } catch (e) {
  372. console.error('获取富维度详情失败', e)
  373. }
  374. },
  375. async loadWealthData() {
  376. if (this.role !== 'parent') return
  377. try {
  378. var codeRes = await getReferralCode()
  379. if (codeRes && codeRes.code === 200 && codeRes.data) {
  380. this.wealthData.referralCode = codeRes.data.code || codeRes.data || ''
  381. }
  382. } catch (e) {
  383. console.error('获取邀请码失败', e)
  384. }
  385. try {
  386. var summaryRes = await getReferralSummary()
  387. if (summaryRes && summaryRes.code === 200 && summaryRes.data) {
  388. this.wealthData.referralCount = summaryRes.data.totalCount || summaryRes.data.count || 0
  389. }
  390. } catch (e) {
  391. console.error('获取邀请统计失败', e)
  392. }
  393. try {
  394. var commissionRes = await getCommissionSummary()
  395. if (commissionRes && commissionRes.code === 200 && commissionRes.data) {
  396. this.wealthData.totalEarnings = commissionRes.data.totalEarnings || 0
  397. this.wealthData.availableAmount = commissionRes.data.availableAmount || 0
  398. }
  399. } catch (e) {
  400. console.error('获取佣金统计失败', e)
  401. }
  402. },
  403. copyReferralCode() {
  404. if (!this.wealthData.referralCode) return
  405. uni.setClipboardData({
  406. data: this.wealthData.referralCode,
  407. success: function() {
  408. uni.showToast({ title: '邀请码已复制', icon: 'success' })
  409. }
  410. })
  411. },
  412. logout() {
  413. uni.showModal({
  414. title: '退出登录',
  415. content: '确定要退出登录吗?',
  416. success: function(res) {
  417. if (res.confirm) {
  418. uni.clearStorageSync()
  419. uni.reLaunch({ url: '/pages/login/login' })
  420. }
  421. }
  422. })
  423. },
  424. goToCheckin() {
  425. uni.navigateTo({ url: '/pages/wealth-sub/checkin' })
  426. },
  427. goToInsurance() {
  428. uni.navigateTo({ url: '/pages/wealth-sub/insurance-list' })
  429. },
  430. goToCreator() {
  431. uni.navigateTo({ url: '/pages/promotion/index' })
  432. },
  433. goToShop() {
  434. uni.navigateTo({ url: '/pages/shop/index/index' })
  435. },
  436. goToOrders() {
  437. uni.navigateTo({ url: '/pages/shop/order-list/order-list' })
  438. },
  439. goToAfterSales() {
  440. uni.navigateTo({ url: '/pages/shop/after-sales/after-sales' })
  441. },
  442. goToIncome() {
  443. uni.navigateTo({ url: '/pages/promotion/commission' })
  444. },
  445. goToFamilyCf() {
  446. uni.navigateTo({ url: '/pages/wealth-cf/index' })
  447. },
  448. goToAchievements() {
  449. uni.navigateTo({ url: '/pages/rewards/badge' })
  450. },
  451. goToNetwork() {
  452. uni.navigateTo({ url: '/pages/promotion/team' })
  453. },
  454. goToCart() {
  455. uni.navigateTo({ url: '/pages/shop/cart/cart' })
  456. },
  457. loadGuestProducts() {
  458. var self = this
  459. productList({ page: 1, size: 4, sort: 'sales' }).then(function(res) {
  460. if (res.code === 200 && res.data && res.data.records) {
  461. self.guestProducts = res.data.records.slice(0, 4)
  462. }
  463. }).catch(function() {})
  464. },
  465. goProductDetail(id) {
  466. uni.navigateTo({ url: '/pages/shop/detail/detail?id=' + id })
  467. },
  468. getImageUrl: function(path) {
  469. return config.API_BASE_URL + path
  470. },
  471. onServiceClick(action) {
  472. if (this[action]) {
  473. this[action]()
  474. }
  475. }
  476. }
  477. }
  478. </script>
  479. .view-toggle {
  480. display: flex;
  481. margin: 20rpx 30rpx;
  482. background: rgba(255,255,255,0.12);
  483. border-radius: 12rpx;
  484. padding: 6rpx;
  485. }
  486. .toggle-btn {
  487. flex: 1;
  488. text-align: center;
  489. padding: 12rpx 0;
  490. border-radius: 8rpx;
  491. font-size: 26rpx;
  492. color: rgba(255,255,255,0.65);
  493. }
  494. .toggle-btn.active {
  495. background: rgba(255,255,255,0.22);
  496. color: #fff;
  497. font-weight: 600;
  498. }
  499. /* 页面说明 */
  500. .section-sub {
  501. font-size: 22rpx;
  502. color: rgba(255,255,255,0.55);
  503. margin-top: 6rpx;
  504. display: block;
  505. }
  506. /* 得分解读卡片 */
  507. .score-explain-card {
  508. margin: 20rpx 30rpx;
  509. padding: 28rpx 24rpx;
  510. background: rgba(255,255,255,0.1);
  511. border-radius: 20rpx;
  512. border: 1rpx solid rgba(255,255,255,0.15);
  513. }
  514. .explain-header {
  515. display: flex;
  516. align-items: center;
  517. margin-bottom: 14rpx;
  518. }
  519. .explain-icon {
  520. font-size: 36rpx;
  521. margin-right: 10rpx;
  522. }
  523. .explain-title {
  524. font-size: 28rpx;
  525. font-weight: 600;
  526. color: #fff;
  527. }
  528. .explain-text {
  529. font-size: 26rpx;
  530. color: rgba(255,255,255,0.8);
  531. line-height: 1.6;
  532. }
  533. <style scoped>
  534. .container {
  535. min-height: 100vh;
  536. background: #f5f7fa;
  537. padding-bottom: 120rpx;
  538. }
  539. .section {
  540. margin: 20rpx 30rpx;
  541. }
  542. .section-header {
  543. display: flex;
  544. justify-content: space-between;
  545. align-items: center;
  546. margin-bottom: 20rpx;
  547. }
  548. .section-title {
  549. font-size: 30rpx;
  550. font-weight: bold;
  551. color: #333;
  552. }
  553. .section-more {
  554. font-size: 24rpx;
  555. color: #999;
  556. }
  557. /* 财富成长 */
  558. .stream-section {
  559. background: #fff;
  560. border-radius: 20rpx;
  561. padding: 24rpx;
  562. box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.08);
  563. }
  564. .stream-stages {
  565. display: flex;
  566. justify-content: space-between;
  567. margin-bottom: 20rpx;
  568. }
  569. .stage-card {
  570. flex: 1;
  571. margin: 0 8rpx;
  572. padding: 20rpx;
  573. border-radius: 16rpx;
  574. background: #F5F9FC;
  575. display: flex;
  576. flex-direction: column;
  577. align-items: center;
  578. }
  579. .stage-card.active {
  580. background: #FFF7ED;
  581. border: 2rpx solid #FBBF24;
  582. }
  583. .stage-icon {
  584. font-size: 44rpx;
  585. }
  586. .stage-name {
  587. font-size: 26rpx;
  588. font-weight: bold;
  589. color: #333;
  590. margin-top: 8rpx;
  591. }
  592. .stage-desc {
  593. font-size: 20rpx;
  594. color: #999;
  595. margin-top: 4rpx;
  596. }
  597. .stage-range {
  598. font-size: 20rpx;
  599. color: #F59E0B;
  600. margin-top: 4rpx;
  601. }
  602. .stream-water {
  603. height: 20rpx;
  604. border-radius: 10rpx;
  605. background: #FEF3C7;
  606. overflow: hidden;
  607. }
  608. .stream-water-fill {
  609. height: 100%;
  610. border-radius: 10rpx;
  611. background: linear-gradient(90deg, #F59E0B, #FBBF24);
  612. transition: width 0.8s ease;
  613. }
  614. .stream-percent {
  615. display: block;
  616. text-align: right;
  617. font-size: 22rpx;
  618. color: #F59E0B;
  619. margin-top: 8rpx;
  620. }
  621. .stream-tip {
  622. display: block;
  623. text-align: center;
  624. font-size: 24rpx;
  625. color: #92400E;
  626. margin-top: 12rpx;
  627. }
  628. /* 财富数据主卡 */
  629. .disc-card {
  630. background: linear-gradient(135deg, #FFF7ED, #FEF3C7);
  631. border-radius: 20rpx;
  632. padding: 30rpx;
  633. margin-bottom: 16rpx;
  634. display: flex;
  635. flex-direction: column;
  636. }
  637. .disc-label {
  638. font-size: 26rpx;
  639. color: #92400E;
  640. }
  641. .disc-value {
  642. font-size: 56rpx;
  643. font-weight: bold;
  644. color: #F59E0B;
  645. margin-top: 8rpx;
  646. }
  647. .disc-sub {
  648. font-size: 24rpx;
  649. color: #B45309;
  650. margin-top: 8rpx;
  651. }
  652. .disc-sub-row {
  653. display: flex;
  654. margin-bottom: 16rpx;
  655. }
  656. .disc-sub-card {
  657. flex: 1;
  658. background: #fff;
  659. border-radius: 16rpx;
  660. padding: 24rpx;
  661. display: flex;
  662. flex-direction: column;
  663. box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.06);
  664. }
  665. .disc-sub-card:first-child {
  666. margin-right: 8rpx;
  667. }
  668. .disc-sub-card:last-child {
  669. margin-left: 8rpx;
  670. }
  671. .disc-sub-label {
  672. font-size: 24rpx;
  673. color: #999;
  674. }
  675. .disc-sub-value {
  676. font-size: 36rpx;
  677. font-weight: bold;
  678. color: #333;
  679. margin-top: 8rpx;
  680. }
  681. .disc-sub-action {
  682. font-size: 22rpx;
  683. color: #F59E0B;
  684. margin-top: 8rpx;
  685. }
  686. /* 孩子财富卡 */
  687. .child-wealth-card {
  688. display: flex;
  689. background: #fff;
  690. border-radius: 20rpx;
  691. padding: 24rpx 0;
  692. box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.08);
  693. }
  694. .child-wealth-item {
  695. flex: 1;
  696. display: flex;
  697. flex-direction: column;
  698. align-items: center;
  699. }
  700. .child-wealth-icon {
  701. font-size: 44rpx;
  702. }
  703. .child-wealth-value {
  704. font-size: 36rpx;
  705. font-weight: bold;
  706. color: #F59E0B;
  707. margin-top: 8rpx;
  708. }
  709. .child-wealth-label {
  710. font-size: 22rpx;
  711. color: #999;
  712. margin-top: 4rpx;
  713. }
  714. .child-trend {
  715. margin-top: 16rpx;
  716. background: #fff;
  717. border-radius: 20rpx;
  718. padding: 24rpx;
  719. box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.08);
  720. }
  721. .child-trend-title {
  722. font-size: 26rpx;
  723. color: #333;
  724. font-weight: bold;
  725. }
  726. .child-trend-bars {
  727. display: flex;
  728. align-items: flex-end;
  729. height: 120rpx;
  730. margin-top: 16rpx;
  731. }
  732. .trend-bar {
  733. flex: 1;
  734. margin: 0 6rpx;
  735. background: linear-gradient(180deg, #FBBF24, #F59E0B);
  736. border-radius: 6rpx 6rpx 0 0;
  737. }
  738. .child-trend-days {
  739. display: flex;
  740. margin-top: 8rpx;
  741. }
  742. .trend-day {
  743. flex: 1;
  744. text-align: center;
  745. font-size: 20rpx;
  746. color: #999;
  747. }
  748. /* 邀请码复制条 */
  749. .referral-code-bar {
  750. display: flex;
  751. align-items: center;
  752. background: #fff;
  753. margin-top: 16rpx;
  754. border-radius: 16rpx;
  755. padding: 24rpx 30rpx;
  756. box-shadow: 0 2rpx 12rpx rgba(0,0,0,0.06);
  757. }
  758. .referral-code-label {
  759. font-size: 26rpx;
  760. color: #666;
  761. margin-right: 16rpx;
  762. }
  763. .referral-code-value {
  764. flex: 1;
  765. font-size: 30rpx;
  766. font-weight: bold;
  767. color: #F59E0B;
  768. letter-spacing: 2rpx;
  769. }
  770. .referral-code-copy {
  771. font-size: 24rpx;
  772. color: #fff;
  773. background: linear-gradient(135deg, #F59E0B, #FBBF24);
  774. padding: 8rpx 24rpx;
  775. border-radius: 20rpx;
  776. }
  777. /* 服务入口 */
  778. .service-grid {
  779. display: flex;
  780. flex-wrap: wrap;
  781. background: #fff;
  782. border-radius: 20rpx;
  783. padding: 24rpx 16rpx;
  784. box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.08);
  785. }
  786. .service-item {
  787. width: 25%;
  788. display: flex;
  789. flex-direction: column;
  790. align-items: center;
  791. padding: 16rpx 0;
  792. }
  793. .service-icon-wrap {
  794. width: 88rpx;
  795. height: 88rpx;
  796. border-radius: 24rpx;
  797. background: #FFF7ED;
  798. display: flex;
  799. align-items: center;
  800. justify-content: center;
  801. margin-bottom: 8rpx;
  802. }
  803. .service-icon {
  804. font-size: 40rpx;
  805. }
  806. .service-label {
  807. font-size: 22rpx;
  808. color: #666;
  809. }
  810. .logout-item {
  811. color: #EF4444;
  812. }
  813. /* 未登录 */
  814. .login-guide-section {
  815. display: flex;
  816. flex-direction: column;
  817. align-items: center;
  818. padding: 60rpx 40rpx;
  819. margin: 30rpx;
  820. background: #fff;
  821. border-radius: 20rpx;
  822. box-shadow: 0 2rpx 12rpx rgba(0,0,0,0.06);
  823. }
  824. .login-guide-text {
  825. font-size: 26rpx;
  826. color: #999;
  827. text-align: center;
  828. margin-bottom: 30rpx;
  829. line-height: 1.6;
  830. }
  831. .login-guide-section .login-btn {
  832. width: 60%;
  833. height: 80rpx;
  834. line-height: 80rpx;
  835. background: linear-gradient(135deg, #5B9BD5, #3A7CC4);
  836. color: #fff;
  837. font-size: 30rpx;
  838. font-weight: bold;
  839. border-radius: 40rpx;
  840. text-align: center;
  841. border: none;
  842. }
  843. .login-prompt .login-btn::after {
  844. border: none;
  845. }
  846. /* 品牌定位语 */
  847. .brand-strap {
  848. margin: 16rpx 30rpx 0;
  849. padding: 20rpx 28rpx;
  850. background: linear-gradient(135deg, #FFFBEB, rgba(245,158,11,0.12));
  851. border-radius: 16rpx;
  852. border-left: 4rpx solid #F59E0B;
  853. }
  854. .brand-strap-text {
  855. font-size: 26rpx;
  856. color: #92400E;
  857. font-weight: 500;
  858. }
  859. /* 商城精选预览 */
  860. .product-scroll {
  861. white-space: nowrap;
  862. padding: 0 30rpx;
  863. }
  864. .product-list {
  865. display: inline-flex;
  866. gap: 20rpx;
  867. }
  868. .product-card {
  869. width: 220rpx;
  870. flex-shrink: 0;
  871. background: #fff;
  872. border-radius: 16rpx;
  873. overflow: hidden;
  874. box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.06);
  875. }
  876. .product-img {
  877. width: 220rpx;
  878. height: 220rpx;
  879. background: #f5f5f5;
  880. }
  881. .product-name {
  882. display: block;
  883. padding: 12rpx 12rpx 4rpx;
  884. font-size: 24rpx;
  885. color: #333;
  886. overflow: hidden;
  887. text-overflow: ellipsis;
  888. white-space: nowrap;
  889. }
  890. .product-price {
  891. display: block;
  892. padding: 4rpx 12rpx 12rpx;
  893. font-size: 26rpx;
  894. font-weight: bold;
  895. color: #F59E0B;
  896. }
  897. </style>
  898. /* 月度引导语 */
  899. .monthly-guidance {
  900. margin: 0 30rpx 20rpx;
  901. background: linear-gradient(135deg, #FFFBEB, rgba(245,158,11,0.1));
  902. border-radius: 16rpx;
  903. padding: 20rpx 24rpx;
  904. display: flex;
  905. align-items: center;
  906. gap: 12rpx;
  907. }
  908. .guidance-icon { font-size: 32rpx; flex-shrink: 0; }
  909. .guidance-text { font-size: 26rpx; color: #F59E0B; font-weight: 500; }