self-quiz.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849
  1. <template>
  2. <view class="container">
  3. <!-- 顶部导航 -->
  4. <view class="nav-bar">
  5. <view class="nav-back" @click="goBack">
  6. <text class="nav-back-icon">&#x2190;</text>
  7. </view>
  8. <text class="nav-title">自己出题自己答</text>
  9. <view class="nav-placeholder"></view>
  10. </view>
  11. <!-- 步骤进度 -->
  12. <view class="step-progress">
  13. <view class="step-item" v-for="(s, i) in steps" :key="i"
  14. :class="{ 'step-active': currentStep === i + 1, 'step-done': currentStep > i + 1 }">
  15. <view class="step-circle">
  16. <text class="step-num">{{ currentStep > i + 1 ? '✓' : (i + 1) }}</text>
  17. </view>
  18. <text class="step-label">{{ s }}</text>
  19. </view>
  20. </view>
  21. <!-- ===== Step 1: 设定目标 ===== -->
  22. <view class="step-content" v-if="currentStep === 1">
  23. <view class="content-card">
  24. <text class="content-title">设定挑战目标</text>
  25. <text class="content-desc">选择你要连续答对多少题才能通关</text>
  26. <view class="target-selector">
  27. <view class="target-label">
  28. <text class="target-label-text">连续答对目标</text>
  29. </view>
  30. <view class="target-control">
  31. <view class="target-btn" @click="adjustTarget(-1)">−</view>
  32. <view class="target-value-wrap">
  33. <text class="target-value">{{ targetN }}</text>
  34. <text class="target-unit">题</text>
  35. </view>
  36. <view class="target-btn" @click="adjustTarget(1)">+</view>
  37. </view>
  38. </view>
  39. <view class="target-range">
  40. <text class="range-text">范围: 2 - 15 题</text>
  41. </view>
  42. <view class="start-btn-wrap">
  43. <view class="start-btn" @click="startQuiz">
  44. <text class="start-btn-text">确认开始</text>
  45. </view>
  46. </view>
  47. </view>
  48. </view>
  49. <!-- ===== Step 2: 选择题型 ===== -->
  50. <view class="step-content" v-if="currentStep === 2">
  51. <view class="content-card">
  52. <text class="content-title">选择题型</text>
  53. <text class="content-desc">选择一个认知维度开始出题</text>
  54. <view class="type-grid">
  55. <view class="type-card" v-for="t in questionTypes" :key="t.key"
  56. :class="{ 'type-recommended': t.recommended }"
  57. @click="selectType(t)">
  58. <text class="type-icon">{{ t.icon }}</text>
  59. <text class="type-name">{{ t.label }}</text>
  60. <text class="type-desc">{{ t.desc }}</text>
  61. <view class="type-recommend-badge" v-if="t.recommended">
  62. <text class="badge-text">推荐</text>
  63. </view>
  64. </view>
  65. </view>
  66. </view>
  67. </view>
  68. <!-- ===== Step 3: 出题 + 答题 ===== -->
  69. <view class="step-content" v-if="currentStep === 3">
  70. <view class="content-card">
  71. <view class="step3-header">
  72. <text class="selected-type-label">{{ selectedType && selectedType.label }}</text>
  73. <text class="step3-progress">连续答对 {{ correctCount }}/{{ targetN }}</text>
  74. </view>
  75. <view class="question-section">
  76. <text class="question-label">输入你的题目</text>
  77. <textarea class="question-input" v-model="currentQuestion" placeholder="在这里写下你的题目..." maxlength="200"></textarea>
  78. <text class="char-count">{{ currentQuestion.length }}/200</text>
  79. </view>
  80. <view class="answer-section">
  81. <text class="answer-label">输入正确答案</text>
  82. <input class="answer-input" v-model="currentAnswer" placeholder="在这里写下正确答案..." maxlength="50" />
  83. <text class="char-count">{{ currentAnswer.length }}/50</text>
  84. </view>
  85. <view class="submit-btn-wrap">
  86. <view class="submit-btn" @click="submitAnswer" v-if="currentQuestion.trim() && currentAnswer.trim()">
  87. <text class="submit-btn-text">提交答案</text>
  88. </view>
  89. <view class="submit-btn disabled" v-else>
  90. <text class="submit-btn-text">请填写题目和答案</text>
  91. </view>
  92. </view>
  93. <!-- 答题结果反馈 -->
  94. <view class="feedback-wrap" v-if="showFeedback">
  95. <view class="feedback-card" :class="lastCorrect ? 'feedback-correct' : 'feedback-wrong'">
  96. <text class="feedback-icon">{{ lastCorrect ? '🎉' : '💪' }}</text>
  97. <view class="feedback-info">
  98. <text class="feedback-title">{{ lastCorrect ? '回答正确!' : '加油,再试试!' }}</text>
  99. <text class="feedback-subtitle">{{ lastCorrect ? ('连续答对 ' + correctCount + '/' + targetN) : '连续计数已重置,重新开始' }}</text>
  100. </view>
  101. </view>
  102. <view class="next-btn-wrap" v-if="showFeedback">
  103. <view class="next-btn" @click="continueAfterFeedback">
  104. <text class="next-btn-text">{{ lastCorrect && correctCount >= targetN ? '查看结果' : '继续出题' }}</text>
  105. </view>
  106. </view>
  107. </view>
  108. </view>
  109. </view>
  110. <!-- ===== Step 4: 达标通过 ===== -->
  111. <view class="step-content" v-if="currentStep === 4">
  112. <view class="celebration-card">
  113. <text class="celebration-icon">🏆</text>
  114. <text class="celebration-title">恭喜通关!</text>
  115. <text class="celebration-subtitle">你成功完成了挑战</text>
  116. <view class="stats-grid">
  117. <view class="stat-item">
  118. <text class="stat-value">{{ sessionStats.totalTime }}</text>
  119. <text class="stat-label">用时</text>
  120. </view>
  121. <view class="stat-item">
  122. <text class="stat-value">{{ sessionStats.totalQuestions }}</text>
  123. <text class="stat-label">总答题数</text>
  124. </view>
  125. <view class="stat-item">
  126. <text class="stat-value">{{ sessionStats.accuracy }}%</text>
  127. <text class="stat-label">正确率</text>
  128. </view>
  129. </view>
  130. <view class="celebration-actions">
  131. <view class="action-btn primary" @click="playAgain">
  132. <text class="action-btn-text">再来一轮</text>
  133. </view>
  134. <view class="action-btn secondary" @click="goBack">
  135. <text class="action-btn-text secondary-text">返回智维度</text>
  136. </view>
  137. </view>
  138. </view>
  139. </view>
  140. </view>
  141. </template>
  142. <script>
  143. var STORAGE_KEY = 'selfQuizSession'
  144. var DAN_TYPES = [
  145. { key: 'perception', label: '感知能力', icon: '\u{1F441}', desc: '感官信息处理', recommended: false },
  146. { key: 'focus', label: '专注力', icon: '\u{1F3AF}', desc: '持续集中注意力', recommended: false },
  147. { key: 'memory', label: '记忆力', icon: '\u{1F9E0}', desc: '信息编码和回忆', recommended: false },
  148. { key: 'logic', label: '逻辑思维', icon: '\u{1F9E9}', desc: '推理和问题解决', recommended: false },
  149. { key: 'spatial', label: '空间思维', icon: '\u{1F9CA}', desc: '空间想象和判断', recommended: false },
  150. { key: 'processing', label: '加工速度', icon: '\u26A1', desc: '信息处理速度', recommended: false }
  151. ]
  152. export default {
  153. data: function() {
  154. return {
  155. steps: ['设定目标', '选择题型', '出题答题', '达标通过'],
  156. currentStep: 1,
  157. targetN: 5,
  158. questionTypes: DAN_TYPES,
  159. selectedType: null,
  160. currentQuestion: '',
  161. currentAnswer: '',
  162. correctCount: 0,
  163. totalAttempts: 0,
  164. showFeedback: false,
  165. lastCorrect: false,
  166. sessionStats: {
  167. totalTime: '0秒',
  168. totalQuestions: 0,
  169. accuracy: 0
  170. },
  171. sessionStartTime: null
  172. }
  173. },
  174. onLoad: function() {
  175. this.restoreSession()
  176. },
  177. onUnload: function() {
  178. this.saveSession()
  179. },
  180. methods: {
  181. goBack: function() {
  182. uni.navigateBack()
  183. },
  184. adjustTarget: function(delta) {
  185. var newVal = this.targetN + delta
  186. if (newVal >= 2 && newVal <= 15) {
  187. this.targetN = newVal
  188. }
  189. },
  190. startQuiz: function() {
  191. this.currentStep = 2
  192. this.sessionStartTime = Date.now()
  193. this.saveSession()
  194. },
  195. selectType: function(type) {
  196. this.selectedType = type
  197. this.currentStep = 3
  198. this.currentQuestion = ''
  199. this.currentAnswer = ''
  200. this.showFeedback = false
  201. this.saveSession()
  202. },
  203. submitAnswer: function() {
  204. this.totalAttempts++
  205. var isCorrect = true
  206. if (isCorrect) {
  207. this.correctCount++
  208. this.lastCorrect = true
  209. } else {
  210. this.correctCount = 0
  211. this.lastCorrect = false
  212. }
  213. this.showFeedback = true
  214. this.saveSession()
  215. if (this.correctCount >= this.targetN) {
  216. // Step transition handled in continueAfterFeedback
  217. }
  218. },
  219. continueAfterFeedback: function() {
  220. if (this.correctCount >= this.targetN) {
  221. var elapsed = Math.floor((Date.now() - this.sessionStartTime) / 1000)
  222. var minutes = Math.floor(elapsed / 60)
  223. var seconds = elapsed % 60
  224. this.sessionStats.totalTime = (minutes > 0 ? minutes + '分' : '') + seconds + '秒'
  225. this.sessionStats.totalQuestions = this.totalAttempts
  226. this.sessionStats.accuracy = Math.round((this.correctCount / this.totalAttempts) * 100)
  227. this.currentStep = 4
  228. this.clearSession()
  229. } else {
  230. this.currentQuestion = ''
  231. this.currentAnswer = ''
  232. this.showFeedback = false
  233. }
  234. },
  235. playAgain: function() {
  236. this.currentStep = 1
  237. this.correctCount = 0
  238. this.totalAttempts = 0
  239. this.showFeedback = false
  240. this.currentQuestion = ''
  241. this.currentAnswer = ''
  242. this.selectedType = null
  243. this.sessionStartTime = null
  244. this.clearSession()
  245. },
  246. saveSession: function() {
  247. var session = {
  248. step: this.currentStep,
  249. targetN: this.targetN,
  250. selectedType: this.selectedType,
  251. correctCount: this.correctCount,
  252. totalAttempts: this.totalAttempts,
  253. currentQuestion: this.currentQuestion,
  254. currentAnswer: this.currentAnswer,
  255. sessionStartTime: this.sessionStartTime
  256. }
  257. try {
  258. uni.setStorageSync(STORAGE_KEY, session)
  259. } catch (e) {}
  260. },
  261. restoreSession: function() {
  262. try {
  263. var session = uni.getStorageSync(STORAGE_KEY)
  264. if (session) {
  265. this.currentStep = session.step || 1
  266. this.targetN = session.targetN || 5
  267. this.selectedType = session.selectedType || null
  268. this.correctCount = session.correctCount || 0
  269. this.totalAttempts = session.totalAttempts || 0
  270. this.currentQuestion = session.currentQuestion || ''
  271. this.currentAnswer = session.currentAnswer || ''
  272. this.sessionStartTime = session.sessionStartTime || null
  273. }
  274. } catch (e) {}
  275. },
  276. clearSession: function() {
  277. try {
  278. uni.removeStorageSync(STORAGE_KEY)
  279. } catch (e) {}
  280. }
  281. }
  282. }
  283. </script>
  284. <style scoped>
  285. .container {
  286. min-height: 100vh;
  287. background: linear-gradient(180deg, #FFF8E1 0%, #f5f7fa 100%);
  288. padding-bottom: 100rpx;
  289. }
  290. .nav-bar {
  291. display: flex;
  292. flex-direction: row;
  293. align-items: center;
  294. padding: 80rpx 30rpx 20rpx;
  295. background: linear-gradient(135deg, #FFD700, #FFA500);
  296. }
  297. .nav-back {
  298. width: 60rpx;
  299. height: 60rpx;
  300. display: flex;
  301. align-items: center;
  302. justify-content: center;
  303. }
  304. .nav-back-icon {
  305. font-size: 36rpx;
  306. color: #fff;
  307. }
  308. .nav-title {
  309. flex: 1;
  310. text-align: center;
  311. font-size: 34rpx;
  312. font-weight: bold;
  313. color: #fff;
  314. }
  315. .nav-placeholder {
  316. width: 60rpx;
  317. }
  318. /* ===== 步骤进度 ===== */
  319. .step-progress {
  320. display: flex;
  321. flex-direction: row;
  322. justify-content: center;
  323. padding: 30rpx 40rpx;
  324. background: #fff;
  325. }
  326. .step-item {
  327. display: flex;
  328. flex-direction: column;
  329. align-items: center;
  330. flex: 1;
  331. position: relative;
  332. }
  333. .step-item + .step-item::before {
  334. content: '';
  335. position: absolute;
  336. top: 18rpx;
  337. left: -50%;
  338. width: 100%;
  339. height: 4rpx;
  340. background: #e0e0e0;
  341. z-index: 0;
  342. }
  343. .step-done + .step-item::before,
  344. .step-item.step-active + .step-item::before {
  345. background: #e0e0e0;
  346. }
  347. .step-item.step-done + .step-item::before {
  348. background: #FFD700;
  349. }
  350. .step-circle {
  351. width: 36rpx;
  352. height: 36rpx;
  353. border-radius: 50%;
  354. background: #e0e0e0;
  355. display: flex;
  356. align-items: center;
  357. justify-content: center;
  358. position: relative;
  359. z-index: 1;
  360. }
  361. .step-active .step-circle {
  362. background: #FFD700;
  363. }
  364. .step-done .step-circle {
  365. background: #52c41a;
  366. }
  367. .step-num {
  368. font-size: 20rpx;
  369. color: #fff;
  370. font-weight: bold;
  371. }
  372. .step-label {
  373. font-size: 22rpx;
  374. color: #999;
  375. margin-top: 10rpx;
  376. }
  377. .step-active .step-label {
  378. color: #B8860B;
  379. font-weight: bold;
  380. }
  381. .step-done .step-label {
  382. color: #52c41a;
  383. }
  384. /* ===== 步骤内容 ===== */
  385. .step-content {
  386. padding: 30rpx;
  387. }
  388. .content-card {
  389. background: #fff;
  390. border-radius: 24rpx;
  391. padding: 40rpx;
  392. box-shadow: 0 4rpx 20rpx rgba(0,0,0,0.06);
  393. }
  394. .content-title {
  395. font-size: 34rpx;
  396. font-weight: bold;
  397. color: #333;
  398. display: block;
  399. text-align: center;
  400. margin-bottom: 10rpx;
  401. }
  402. .content-desc {
  403. font-size: 26rpx;
  404. color: #999;
  405. display: block;
  406. text-align: center;
  407. margin-bottom: 40rpx;
  408. }
  409. /* ===== Step1: 目标选择 ===== */
  410. .target-selector {
  411. display: flex;
  412. flex-direction: row;
  413. align-items: center;
  414. justify-content: center;
  415. margin-bottom: 20rpx;
  416. }
  417. .target-label {
  418. margin-right: 30rpx;
  419. }
  420. .target-label-text {
  421. font-size: 28rpx;
  422. color: #666;
  423. }
  424. .target-control {
  425. display: flex;
  426. flex-direction: row;
  427. align-items: center;
  428. }
  429. .target-btn {
  430. width: 60rpx;
  431. height: 60rpx;
  432. border-radius: 50%;
  433. background: #FFF8E1;
  434. border: 2rpx solid #FFD700;
  435. display: flex;
  436. align-items: center;
  437. justify-content: center;
  438. font-size: 36rpx;
  439. color: #B8860B;
  440. font-weight: bold;
  441. }
  442. .target-btn:active {
  443. opacity: 0.7;
  444. }
  445. .target-value-wrap {
  446. margin: 0 30rpx;
  447. text-align: center;
  448. }
  449. .target-value {
  450. font-size: 72rpx;
  451. font-weight: bold;
  452. color: #B8860B;
  453. display: block;
  454. }
  455. .target-unit {
  456. font-size: 28rpx;
  457. color: #999;
  458. }
  459. .target-range {
  460. text-align: center;
  461. margin-bottom: 40rpx;
  462. }
  463. .range-text {
  464. font-size: 24rpx;
  465. color: #ccc;
  466. }
  467. .start-btn-wrap {
  468. text-align: center;
  469. }
  470. .start-btn {
  471. display: inline-block;
  472. background: linear-gradient(135deg, #FFD700, #FFA500);
  473. padding: 20rpx 80rpx;
  474. border-radius: 44rpx;
  475. box-shadow: 0 4rpx 20rpx rgba(255, 215, 0, 0.4);
  476. }
  477. .start-btn:active {
  478. opacity: 0.8;
  479. }
  480. .start-btn-text {
  481. font-size: 30rpx;
  482. color: #fff;
  483. font-weight: bold;
  484. }
  485. /* ===== Step2: 题型选择 ===== */
  486. .type-grid {
  487. display: flex;
  488. flex-direction: row;
  489. flex-wrap: wrap;
  490. justify-content: space-between;
  491. }
  492. .type-card {
  493. width: calc(50% - 10rpx);
  494. padding: 24rpx;
  495. margin-bottom: 20rpx;
  496. background: #f9f9f9;
  497. border-radius: 16rpx;
  498. border: 2rpx solid transparent;
  499. position: relative;
  500. text-align: center;
  501. }
  502. .type-card:active {
  503. border-color: #FFD700;
  504. }
  505. .type-recommended {
  506. border-color: #FFD700;
  507. background: #FFF8E1;
  508. }
  509. .type-icon {
  510. font-size: 40rpx;
  511. display: block;
  512. margin-bottom: 8rpx;
  513. }
  514. .type-name {
  515. font-size: 26rpx;
  516. font-weight: bold;
  517. color: #333;
  518. display: block;
  519. }
  520. .type-desc {
  521. font-size: 22rpx;
  522. color: #999;
  523. display: block;
  524. margin-top: 4rpx;
  525. }
  526. .type-recommend-badge {
  527. position: absolute;
  528. top: -8rpx;
  529. right: -8rpx;
  530. background: #FF6B35;
  531. border-radius: 12rpx;
  532. padding: 2rpx 12rpx;
  533. }
  534. .badge-text {
  535. font-size: 20rpx;
  536. color: #fff;
  537. font-weight: bold;
  538. }
  539. /* ===== Step3: 出题 ===== */
  540. .step3-header {
  541. display: flex;
  542. flex-direction: row;
  543. justify-content: space-between;
  544. align-items: center;
  545. margin-bottom: 30rpx;
  546. }
  547. .selected-type-label {
  548. font-size: 28rpx;
  549. color: #B8860B;
  550. font-weight: bold;
  551. }
  552. .step3-progress {
  553. font-size: 26rpx;
  554. color: #666;
  555. }
  556. .question-section, .answer-section {
  557. margin-bottom: 30rpx;
  558. }
  559. .question-label, .answer-label {
  560. font-size: 28rpx;
  561. color: #333;
  562. font-weight: 500;
  563. display: block;
  564. margin-bottom: 12rpx;
  565. }
  566. .question-input {
  567. width: 100%;
  568. min-height: 160rpx;
  569. background: #f5f7fa;
  570. border-radius: 12rpx;
  571. padding: 20rpx;
  572. font-size: 26rpx;
  573. color: #333;
  574. box-sizing: border-box;
  575. }
  576. .answer-input {
  577. width: 100%;
  578. height: 72rpx;
  579. background: #f5f7fa;
  580. border-radius: 12rpx;
  581. padding: 0 20rpx;
  582. font-size: 26rpx;
  583. color: #333;
  584. box-sizing: border-box;
  585. }
  586. .char-count {
  587. font-size: 22rpx;
  588. color: #ccc;
  589. text-align: right;
  590. display: block;
  591. margin-top: 6rpx;
  592. }
  593. .submit-btn-wrap {
  594. text-align: center;
  595. margin-top: 20rpx;
  596. }
  597. .submit-btn {
  598. display: inline-block;
  599. background: linear-gradient(135deg, #FFD700, #FFA500);
  600. padding: 20rpx 80rpx;
  601. border-radius: 44rpx;
  602. box-shadow: 0 4rpx 20rpx rgba(255, 215, 0, 0.4);
  603. }
  604. .submit-btn.disabled {
  605. opacity: 0.5;
  606. }
  607. .submit-btn-text {
  608. font-size: 30rpx;
  609. color: #fff;
  610. font-weight: bold;
  611. }
  612. /* ===== 反馈 ===== */
  613. .feedback-wrap {
  614. margin-top: 30rpx;
  615. }
  616. .feedback-card {
  617. display: flex;
  618. flex-direction: row;
  619. align-items: center;
  620. padding: 24rpx;
  621. border-radius: 16rpx;
  622. margin-bottom: 20rpx;
  623. }
  624. .feedback-correct {
  625. background: #f0fff4;
  626. border: 2rpx solid #52c41a;
  627. }
  628. .feedback-wrong {
  629. background: #fff5f5;
  630. border: 2rpx solid #ff4d4f;
  631. }
  632. .feedback-icon {
  633. font-size: 48rpx;
  634. margin-right: 20rpx;
  635. }
  636. .feedback-info {
  637. flex: 1;
  638. }
  639. .feedback-title {
  640. font-size: 28rpx;
  641. font-weight: bold;
  642. color: #333;
  643. display: block;
  644. }
  645. .feedback-subtitle {
  646. font-size: 24rpx;
  647. color: #999;
  648. margin-top: 4rpx;
  649. display: block;
  650. }
  651. .next-btn-wrap {
  652. text-align: center;
  653. }
  654. .next-btn {
  655. display: inline-block;
  656. background: linear-gradient(135deg, #FFD700, #FFA500);
  657. padding: 16rpx 60rpx;
  658. border-radius: 40rpx;
  659. }
  660. .next-btn:active {
  661. opacity: 0.8;
  662. }
  663. .next-btn-text {
  664. font-size: 28rpx;
  665. color: #fff;
  666. font-weight: bold;
  667. }
  668. /* ===== Step4: 庆祝 ===== */
  669. .celebration-card {
  670. background: #fff;
  671. border-radius: 24rpx;
  672. padding: 60rpx 40rpx;
  673. text-align: center;
  674. box-shadow: 0 4rpx 20rpx rgba(0,0,0,0.06);
  675. }
  676. .celebration-icon {
  677. font-size: 120rpx;
  678. display: block;
  679. margin-bottom: 20rpx;
  680. }
  681. .celebration-title {
  682. font-size: 40rpx;
  683. font-weight: bold;
  684. color: #B8860B;
  685. display: block;
  686. margin-bottom: 8rpx;
  687. }
  688. .celebration-subtitle {
  689. font-size: 28rpx;
  690. color: #999;
  691. display: block;
  692. margin-bottom: 40rpx;
  693. }
  694. .stats-grid {
  695. display: flex;
  696. flex-direction: row;
  697. justify-content: center;
  698. margin-bottom: 40rpx;
  699. }
  700. .stat-item {
  701. text-align: center;
  702. margin: 0 30rpx;
  703. }
  704. .stat-value {
  705. font-size: 48rpx;
  706. font-weight: bold;
  707. color: #B8860B;
  708. display: block;
  709. }
  710. .stat-label {
  711. font-size: 24rpx;
  712. color: #999;
  713. margin-top: 6rpx;
  714. display: block;
  715. }
  716. .celebration-actions {
  717. display: flex;
  718. flex-direction: column;
  719. align-items: center;
  720. }
  721. .action-btn {
  722. width: 60%;
  723. padding: 20rpx 0;
  724. border-radius: 44rpx;
  725. margin-bottom: 20rpx;
  726. text-align: center;
  727. }
  728. .action-btn.primary {
  729. background: linear-gradient(135deg, #FFD700, #FFA500);
  730. box-shadow: 0 4rpx 20rpx rgba(255, 215, 0, 0.4);
  731. }
  732. .action-btn.secondary {
  733. background: #fff;
  734. border: 2rpx solid #ddd;
  735. }
  736. .action-btn-text {
  737. font-size: 28rpx;
  738. font-weight: bold;
  739. color: #fff;
  740. }
  741. .secondary-text {
  742. color: #666;
  743. }
  744. </style>