activity-center.css 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434
  1. /* 活动中心页面专属样式 */
  2. * {
  3. margin: 0;
  4. padding: 0;
  5. box-sizing: border-box;
  6. -webkit-tap-highlight-color: transparent;
  7. -webkit-touch-callout: none;
  8. -webkit-user-select: none;
  9. user-select: none;
  10. }
  11. html,
  12. body {
  13. background: var(--bex-page-bg-welfare, #0e0e0e);
  14. color: var(--bex-text-primary, #ffffff);
  15. min-height: 100vh;
  16. }
  17. body {
  18. font-family:
  19. "PingFang SC",
  20. -apple-system,
  21. BlinkMacSystemFont,
  22. "Segoe UI",
  23. Roboto,
  24. "Helvetica Neue",
  25. Arial,
  26. sans-serif;
  27. font-size: 14px;
  28. line-height: 1.4;
  29. }
  30. .container {
  31. position: relative;
  32. width: 100%;
  33. min-height: 100vh;
  34. overflow-x: hidden;
  35. padding-bottom: env(safe-area-inset-bottom);
  36. }
  37. /* ===== 导航栏 ===== */
  38. .activity-navbar {
  39. position: sticky;
  40. top: 0;
  41. z-index: 10;
  42. display: flex;
  43. align-items: center;
  44. justify-content: center;
  45. height: 44px;
  46. background: var(--bex-page-bg-welfare, #0e0e0e);
  47. padding: 0 16px;
  48. }
  49. .activity-navbar-back {
  50. position: absolute;
  51. left: 16px;
  52. top: 50%;
  53. transform: translateY(-50%);
  54. display: flex;
  55. align-items: center;
  56. justify-content: center;
  57. width: 20px;
  58. height: 20px;
  59. background: none;
  60. border: none;
  61. color: var(--bex-text-primary, #ffffff);
  62. cursor: pointer;
  63. padding: 0;
  64. }
  65. .activity-navbar-title {
  66. font-size: 16px;
  67. font-weight: 600;
  68. line-height: 22px;
  69. color: var(--bex-text-primary, #ffffff);
  70. }
  71. /* ===== 主内容区 ===== */
  72. .main-view {
  73. position: relative;
  74. z-index: 1;
  75. padding: 10px 16px 24px;
  76. }
  77. /* ===== 头部区域 ===== */
  78. .ac-header {
  79. position: relative;
  80. display: flex;
  81. align-items: flex-start;
  82. justify-content: space-between;
  83. padding: 28px 0 40px;
  84. }
  85. .ac-header-texts {
  86. display: flex;
  87. flex-direction: column;
  88. gap: 12px;
  89. }
  90. .ac-header-title {
  91. font-size: 26px;
  92. font-weight: 600;
  93. line-height: 26px;
  94. color: var(--bex-text-primary, #ffffff);
  95. }
  96. .ac-header-subtitle {
  97. font-size: 12px;
  98. font-weight: 400;
  99. line-height: 12px;
  100. color: var(--bex-text-secondary, #888888);
  101. }
  102. .ac-header-decor {
  103. position: absolute;
  104. right: -10px;
  105. top: 0;
  106. width: 110px;
  107. height: 101px;
  108. background: url(/images/image-230.png) center center / contain no-repeat;
  109. pointer-events: none;
  110. }
  111. /* ===== Tab 切换栏 ===== */
  112. .ac-tabs {
  113. position: relative;
  114. width: 100%;
  115. height: 30px;
  116. margin-bottom: 24px;
  117. }
  118. .ac-tabs-inner {
  119. display: flex;
  120. align-items: center;
  121. gap: 20px;
  122. height: 28px;
  123. }
  124. .ac-tab {
  125. position: relative;
  126. font-size: 16px;
  127. font-weight: 600;
  128. color: var(--bex-text-secondary, #888888);
  129. cursor: pointer;
  130. padding-bottom: 6px;
  131. user-select: none;
  132. }
  133. .ac-tab.active {
  134. color: var(--bex-text-primary, #ffffff);
  135. }
  136. .ac-tab.active::after {
  137. content: "";
  138. position: absolute;
  139. bottom: -1px;
  140. left: 50%;
  141. transform: translateX(-50%);
  142. width: 14px;
  143. height: 2px;
  144. border-radius: 1px;
  145. background: var(--bex-brand, #fd6f23);
  146. }
  147. .ac-tabs-line {
  148. position: absolute;
  149. bottom: 0;
  150. left: 0;
  151. width: 100%;
  152. height: 1px;
  153. background: #282828;
  154. }
  155. /* ===== 活动卡片列表 ===== */
  156. .ac-card-list {
  157. width: 100%;
  158. }
  159. .activity-card {
  160. position: relative;
  161. width: 100%;
  162. border-radius: 8px;
  163. margin-bottom: 16px;
  164. overflow: hidden;
  165. min-height: 179px;
  166. display: flex;
  167. flex-direction: column;
  168. justify-content: space-between;
  169. background: rgba(255, 255, 255, 0.03);
  170. }
  171. .activity-card-bg {
  172. position: absolute;
  173. left: 0;
  174. top: 0;
  175. width: 141px;
  176. height: 153px;
  177. background: url(/images/unblock-bg-left-round.png) no-repeat left center;
  178. background-size: contain;
  179. border-radius: 0 0 100% 0;
  180. pointer-events: none;
  181. }
  182. .activity-card-image {
  183. position: absolute;
  184. right: 24px;
  185. top: 28px;
  186. width: 76px;
  187. height: 82px;
  188. border-radius: 8px;
  189. background-image: url(/images/unblock-right.png);
  190. background-size: cover;
  191. background-position: center center;
  192. background-repeat: no-repeat;
  193. pointer-events: none;
  194. overflow: hidden;
  195. }
  196. .activity-card-title {
  197. position: relative;
  198. z-index: 1;
  199. font-size: 17px;
  200. font-weight: 600;
  201. color: var(--bex-text-primary, #ffffff);
  202. line-height: 24px;
  203. max-width: 174px;
  204. flex: 1;
  205. display: flex;
  206. align-items: center;
  207. margin: 0 24px;
  208. }
  209. .activity-card-title-text {
  210. height: 72px;
  211. overflow: hidden;
  212. text-overflow: ellipsis;
  213. display: -webkit-box;
  214. -webkit-line-clamp: 3;
  215. -webkit-box-orient: vertical;
  216. }
  217. .activity-card-footer {
  218. position: relative;
  219. z-index: 1;
  220. display: flex;
  221. align-items: center;
  222. justify-content: space-between;
  223. height: 44px;
  224. padding: 0 24px;
  225. background: rgba(255, 255, 255, 0.03);
  226. }
  227. .activity-countdown {
  228. display: flex;
  229. align-items: center;
  230. gap: 4px;
  231. }
  232. .activity-countdown-label,
  233. .activity-countdown-unit {
  234. font-size: 10px;
  235. font-weight: 600;
  236. color: var(--bex-text-secondary, #888888);
  237. line-height: 14px;
  238. }
  239. .activity-ended-info {
  240. font-size: 12px;
  241. font-weight: 500;
  242. color: var(--bex-text-secondary, #888888);
  243. line-height: 16px;
  244. }
  245. .empty-state {
  246. padding: 56px 16px;
  247. text-align: center;
  248. color: var(--bex-text-secondary, #888888);
  249. font-size: 12px;
  250. }
  251. .empty-icon {
  252. width: 64px;
  253. height: 64px;
  254. margin: 0 auto 6px;
  255. display: block;
  256. }
  257. .activity-countdown-days,
  258. .activity-countdown-time {
  259. font-family:
  260. "HarmonyOS Sans",
  261. "DIN Alternate",
  262. "SF Pro Display",
  263. -apple-system,
  264. BlinkMacSystemFont,
  265. sans-serif;
  266. font-size: 16px;
  267. font-weight: 700;
  268. color: var(--bex-text-primary, #ffffff);
  269. line-height: 1;
  270. }
  271. .activity-btn {
  272. height: 24px;
  273. padding: 0 12px;
  274. border: none;
  275. border-radius: 6px;
  276. background: var(--bex-text-primary, #ffffff);
  277. color: #121212;
  278. font-size: 11px;
  279. font-weight: 500;
  280. cursor: pointer;
  281. display: flex;
  282. align-items: center;
  283. line-height: 1;
  284. gap: 4px;
  285. }
  286. .activity-btn:disabled {
  287. opacity: 0.5;
  288. cursor: not-allowed;
  289. }
  290. /* ===== 空状态 ===== */
  291. .ac-empty {
  292. padding: 48px 16px;
  293. text-align: center;
  294. color: var(--bex-text-secondary, #888888);
  295. font-size: 12px;
  296. }
  297. /* ===== 遮罩 ===== */
  298. .loading-overlay,
  299. .error-overlay {
  300. position: fixed;
  301. inset: 0;
  302. z-index: 1000;
  303. display: flex;
  304. align-items: center;
  305. justify-content: center;
  306. }
  307. .loading-overlay,
  308. .error-overlay {
  309. background: var(--bex-page-bg-welfare, #0e0e0e);
  310. flex-direction: column;
  311. gap: 16px;
  312. }
  313. .loading-spinner {
  314. width: 40px;
  315. height: 40px;
  316. border: 3px solid var(--bex-border, #2c2c2c);
  317. border-top-color: var(--bex-brand, #fd6f23);
  318. border-radius: 50%;
  319. animation: spin 1s linear infinite;
  320. }
  321. @keyframes spin {
  322. to {
  323. transform: rotate(360deg);
  324. }
  325. }
  326. .loading-text,
  327. .error-text {
  328. color: var(--bex-text-secondary, #888888);
  329. font-size: 14px;
  330. }
  331. .error-content {
  332. display: flex;
  333. flex-direction: column;
  334. align-items: center;
  335. gap: 24px;
  336. padding: 32px;
  337. text-align: center;
  338. }
  339. .error-actions {
  340. display: flex;
  341. gap: 12px;
  342. }
  343. .error-retry {
  344. padding: 12px 32px;
  345. background: #ffffff;
  346. border: none;
  347. border-radius: 8px;
  348. color: #121212;
  349. font-size: 14px;
  350. font-weight: 500;
  351. cursor: pointer;
  352. }
  353. /* ===== Toast ===== */
  354. .toast {
  355. position: fixed;
  356. bottom: 80px;
  357. left: 50%;
  358. transform: translateX(-50%);
  359. background: rgba(0, 0, 0, 0.85);
  360. color: #ffffff;
  361. font-size: 13px;
  362. padding: 10px 24px;
  363. border-radius: 8px;
  364. z-index: 2000;
  365. opacity: 0;
  366. pointer-events: none;
  367. transition: opacity 0.3s ease;
  368. white-space: nowrap;
  369. }
  370. .toast.show {
  371. opacity: 1;
  372. }
  373. /* 日间主题 */
  374. html .theme-light .ac-tabs-line {
  375. background-color: #efefef;
  376. }
  377. html .theme-light .activity-card {
  378. background-color: #ffffff08;
  379. border-color: #e8e8e8;
  380. border-width: 1px;
  381. border-style: solid;
  382. }
  383. html .theme-light .activity-card-footer {
  384. border-top: 1px solid #e8e8e8;
  385. }
  386. html .theme-light .activity-btn {
  387. color: #fff;
  388. }