WelcomeGuide.vue 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306
  1. <template>
  2. <div class="step1-card">
  3. <!-- 顶部插画区域 -->
  4. <div class="step1-illustration">
  5. <div class="illustration-bubble bubble-1">🎁</div>
  6. <div class="illustration-bubble bubble-2">⭐</div>
  7. <!-- <div class="illustration-bubble bubble-3">🏆</div> -->
  8. <div class="illustration-icon-wrap">
  9. <div class="illustration-icon">🎉</div>
  10. <div class="illustration-ring ring-1"></div>
  11. <div class="illustration-ring ring-2"></div>
  12. </div>
  13. </div>
  14. <!-- 文字内容 -->
  15. <div class="step1-body">
  16. <h2 class="step1-title">欢迎来到誉商城!</h2>
  17. <p class="step1-desc">
  18. 这里是你的<strong>专属积分奖励平台</strong><br />
  19. 完成任务赚积分,积分兑换好礼!
  20. </p>
  21. <!-- 特性展示 -->
  22. <div class="step1-features">
  23. <div class="feature-item">
  24. <span class="feature-icon">📌</span>
  25. <span class="feature-text">每日签到赚积分</span>
  26. </div>
  27. <div class="feature-item">
  28. <span class="feature-icon">🛒</span>
  29. <span class="feature-text">积分商城兑好礼</span>
  30. </div>
  31. <div class="feature-item">
  32. <span class="feature-icon">🎊</span>
  33. <span class="feature-text">参与活动赢大奖</span>
  34. </div>
  35. </div>
  36. </div>
  37. <!-- 底部按钮 -->
  38. <div class="step1-footer">
  39. <button class="btn-start" @click="$emit('next')">
  40. {{ isLast ? '完成新手教程' : '开始探索' }}
  41. <span class="btn-arrow" v-if="!isLast">→</span>
  42. <span class="btn-check" v-else>✓</span>
  43. </button>
  44. <button class="btn-prev" v-if="!isFirst" @click="$emit('prev')">
  45. 上一步
  46. </button>
  47. </div>
  48. </div>
  49. </template>
  50. <script>
  51. export default {
  52. name: 'WelcomeGuide',
  53. props: {
  54. isLast: {
  55. type: Boolean,
  56. default: false,
  57. },
  58. isFirst: {
  59. type: Boolean,
  60. default: false,
  61. },
  62. },
  63. }
  64. </script>
  65. <style scoped>
  66. .step1-card {
  67. width: 440px;
  68. max-width: 90vw;
  69. background: #fff;
  70. border-radius: 20px;
  71. overflow: hidden;
  72. box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  73. animation: cardFloat 0.5s ease-out;
  74. }
  75. @keyframes cardFloat {
  76. from {
  77. opacity: 0;
  78. transform: translateY(30px) scale(0.95);
  79. }
  80. to {
  81. opacity: 1;
  82. transform: translateY(0) scale(1);
  83. }
  84. }
  85. /* ---- 插画区域 ---- */
  86. .step1-illustration {
  87. position: relative;
  88. height: 180px;
  89. background: linear-gradient(135deg, #2C6FBF 0%, #5B9FE6 50%, #87CEEB 100%);
  90. display: flex;
  91. align-items: center;
  92. justify-content: center;
  93. overflow: hidden;
  94. }
  95. .illustration-icon-wrap {
  96. position: relative;
  97. z-index: 2;
  98. }
  99. .illustration-icon {
  100. width: 80px;
  101. height: 80px;
  102. line-height: 80px;
  103. text-align: center;
  104. font-size: 52px;
  105. background: rgba(255, 255, 255, 0.2);
  106. border-radius: 50%;
  107. backdrop-filter: blur(4px);
  108. }
  109. .illustration-ring {
  110. position: absolute;
  111. top: 50%;
  112. left: 50%;
  113. border: 2px solid rgba(255, 255, 255, 0.2);
  114. border-radius: 50%;
  115. animation: ringPulse 3s ease-in-out infinite;
  116. }
  117. .ring-1 {
  118. width: 120px;
  119. height: 120px;
  120. margin-top: -60px;
  121. margin-left: -60px;
  122. animation-delay: 0s;
  123. }
  124. .ring-2 {
  125. width: 160px;
  126. height: 160px;
  127. margin-top: -80px;
  128. margin-left: -80px;
  129. animation-delay: 1.5s;
  130. }
  131. @keyframes ringPulse {
  132. 0%, 100% {
  133. transform: scale(1);
  134. opacity: 0.3;
  135. }
  136. 50% {
  137. transform: scale(1.1);
  138. opacity: 0.6;
  139. }
  140. }
  141. .illustration-bubble {
  142. position: absolute;
  143. font-size: 24px;
  144. z-index: 1;
  145. animation: bubbleFloat 4s ease-in-out infinite;
  146. }
  147. .bubble-1 {
  148. top: 20px;
  149. left: 30px;
  150. animation-delay: 0s;
  151. }
  152. .bubble-2 {
  153. top: 30px;
  154. right: 40px;
  155. animation-delay: 1.3s;
  156. }
  157. .bubble-3 {
  158. bottom: 25px;
  159. left: 50%;
  160. transform: translateX(-50%);
  161. animation-delay: 2.6s;
  162. }
  163. @keyframes bubbleFloat {
  164. 0%, 100% { transform: translateY(0); }
  165. 50% { transform: translateY(-10px); }
  166. }
  167. /* ---- 内容区域 ---- */
  168. .step1-body {
  169. padding: 28px 32px 20px;
  170. text-align: center;
  171. }
  172. .step1-title {
  173. font-size: 22px;
  174. font-weight: 700;
  175. color: #1d2129;
  176. margin: 0 0 12px;
  177. }
  178. .step1-desc {
  179. font-size: 14px;
  180. line-height: 1.8;
  181. color: #86909c;
  182. margin: 0 0 24px;
  183. }
  184. .step1-desc strong {
  185. color: #2C6FBF;
  186. }
  187. /* ---- 特性卡片 ---- */
  188. .step1-features {
  189. display: flex;
  190. gap: 12px;
  191. justify-content: center;
  192. }
  193. .feature-item {
  194. display: flex;
  195. flex-direction: column;
  196. align-items: center;
  197. gap: 8px;
  198. flex: 1;
  199. padding: 14px 8px;
  200. background: #f7f9fc;
  201. border-radius: 12px;
  202. transition: all 0.25s;
  203. }
  204. .feature-item:hover {
  205. background: #eaf2ff;
  206. transform: translateY(-2px);
  207. }
  208. .feature-icon {
  209. font-size: 22px;
  210. }
  211. .feature-text {
  212. font-size: 12px;
  213. color: #4e5969;
  214. font-weight: 500;
  215. }
  216. /* ---- 底部按钮 ---- */
  217. .step1-footer {
  218. padding: 0 32px 28px;
  219. text-align: center;
  220. }
  221. .btn-start {
  222. display: inline-flex;
  223. align-items: center;
  224. justify-content: center;
  225. gap: 8px;
  226. width: 100%;
  227. height: 48px;
  228. font-size: 16px;
  229. font-weight: 600;
  230. color: #fff;
  231. background: linear-gradient(135deg, #2C6FBF, #5B9FE6);
  232. border: none;
  233. border-radius: 24px;
  234. cursor: pointer;
  235. transition: all 0.3s;
  236. box-shadow: 0 4px 16px rgba(44, 111, 191, 0.35);
  237. }
  238. .btn-start:hover {
  239. transform: translateY(-1px);
  240. box-shadow: 0 6px 20px rgba(44, 111, 191, 0.5);
  241. }
  242. .btn-start:active {
  243. transform: translateY(0);
  244. }
  245. .btn-arrow {
  246. font-size: 18px;
  247. transition: transform 0.25s;
  248. }
  249. .btn-start:hover .btn-arrow {
  250. transform: translateX(4px);
  251. }
  252. .btn-prev {
  253. display: inline-flex;
  254. align-items: center;
  255. justify-content: center;
  256. width: 100%;
  257. height: 40px;
  258. margin-top: 10px;
  259. font-size: 14px;
  260. font-weight: 500;
  261. color: #86909c;
  262. background: #f7f9fc;
  263. border: none;
  264. border-radius: 20px;
  265. cursor: pointer;
  266. transition: all 0.25s;
  267. }
  268. .btn-prev:hover {
  269. color: #4e5969;
  270. background: #eef1f6;
  271. }
  272. </style>