TriangleChart.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831
  1. <template>
  2. <view class="container">
  3. <view class="chart-inner">
  4. <view class="triangle-glow"></view>
  5. <view class="triangle-bg"></view>
  6. <view class="inner-matrix">
  7. <!-- Zone background overlays -->
  8. <view class="zone-left-bg"></view>
  9. <view class="zone-right-bg"></view>
  10. <view class="row row-top" @click="showCellDetail('O', chartNum('innerTop'))">
  11. <view class="cell cell-main" :class="numColorCls(chartNum('innerTop'))">
  12. {{ matrix.innerTop }}
  13. <text v-if="isMasterNum(chartNum('innerTop'))" class="master-star">★</text>
  14. </view>
  15. </view>
  16. <view class="row row-mid">
  17. <view class="cell cell-mid border-right zone-father" @click="showCellDetail('M', chartNum('innerMid', 0))">
  18. <text :class="numColorCls(chartNum('innerMid', 0))">
  19. {{ matrix.innerMid[0] }}
  20. <text v-if="isMasterNum(chartNum('innerMid', 0))" class="master-star-sm">★</text>
  21. </text>
  22. </view>
  23. <view class="cell cell-mid zone-mother" @click="showCellDetail('N', chartNum('innerMid', 1))">
  24. <text :class="numColorCls(chartNum('innerMid', 1))">
  25. {{ matrix.innerMid[1] }}
  26. <text v-if="isMasterNum(chartNum('innerMid', 1))" class="master-star-sm">★</text>
  27. </text>
  28. </view>
  29. </view>
  30. <!-- 行间横向分割线(区分上三区与下两区) -->
  31. <view class="row-sep"></view>
  32. <!-- 底部4数左→右:I(日) J(月) K(年前半) L(年后半) -->
  33. <view class="row row-bot4">
  34. <view class="cell-bot4" @click="showCellDetail('I', chartNum('innerBottom', 0))">
  35. <text :class="numColorCls(chartNum('innerBottom', 0))">
  36. {{ matrix.innerBottom[0] }}
  37. <text v-if="isMasterNum(chartNum('innerBottom', 0))" class="master-star-sm">★</text>
  38. </text>
  39. </view>
  40. <view class="cell-bot4 zone-father" @click="showCellDetail('J', chartNum('innerBottom', 1))">
  41. <text :class="numColorCls(chartNum('innerBottom', 1))">
  42. {{ matrix.innerBottom[1] }}
  43. <text v-if="isMasterNum(chartNum('innerBottom', 1))" class="master-star-sm">★</text>
  44. </text>
  45. </view>
  46. <view class="cell-bot4" @click="showCellDetail('K', chartNum('innerBottom', 2))">
  47. <text :class="numColorCls(chartNum('innerBottom', 2))">
  48. {{ matrix.innerBottom[2] }}
  49. <text v-if="isMasterNum(chartNum('innerBottom', 2))" class="master-star-sm">★</text>
  50. </text>
  51. </view>
  52. <view class="cell-bot4 zone-mother" @click="showCellDetail('L', chartNum('innerBottom', 3))">
  53. <text :class="numColorCls(chartNum('innerBottom', 3))">
  54. {{ matrix.innerBottom[3] }}
  55. <text v-if="isMasterNum(chartNum('innerBottom', 3))" class="master-star-sm">★</text>
  56. </text>
  57. </view>
  58. </view>
  59. </view>
  60. <!-- 顶部外侧:三角排列 X / V W (41-60岁) -->
  61. <view class="outer-tri top-tri">
  62. <view class="tri-main" :class="numColorCls(matrix.outerTop.main)" @click="showCellDetail('X', chartNum('innerTop'))">
  63. {{ matrix.outerTop.main }}
  64. <text v-if="isMasterNum(matrix.outerTop.main)" class="master-star">★</text>
  65. </view>
  66. <view class="tri-subs">
  67. <text class="tri-sub" :class="numColorCls(matrix.outerTop.sub[0])" @click.stop="showCellDetail('V', chartNum('innerTop'))">
  68. {{ matrix.outerTop.sub[0] }}
  69. <text v-if="isMasterNum(matrix.outerTop.sub[0])" class="master-star-sm">★</text>
  70. </text>
  71. <text class="tri-sub" :class="numColorCls(matrix.outerTop.sub[1])" @click.stop="showCellDetail('W', chartNum('innerTop'))">
  72. {{ matrix.outerTop.sub[1] }}
  73. <text v-if="isMasterNum(matrix.outerTop.sub[1])" class="master-star-sm">★</text>
  74. </text>
  75. </view>
  76. </view>
  77. <!-- 左侧外侧:三角排列 R / P Q (21-40岁) -->
  78. <view class="outer-tri left-tri">
  79. <view class="tri-main" :class="numColorCls(matrix.outerLeft.main)" @click="showCellDetail('R', chartNum('innerMid', 0))">
  80. {{ matrix.outerLeft.main }}
  81. <text v-if="isMasterNum(matrix.outerLeft.main)" class="master-star-sm">★</text>
  82. </view>
  83. <view class="tri-subs">
  84. <text class="tri-sub" :class="numColorCls(matrix.outerLeft.sub[0])" @click.stop="showCellDetail('P', chartNum('innerBottom', 0))">
  85. {{ matrix.outerLeft.sub[0] }}
  86. <text v-if="isMasterNum(matrix.outerLeft.sub[0])" class="master-star-sm">★</text>
  87. </text>
  88. <text class="tri-sub" :class="numColorCls(matrix.outerLeft.sub[1])" @click.stop="showCellDetail('Q', chartNum('innerBottom', 1))">
  89. {{ matrix.outerLeft.sub[1] }}
  90. <text v-if="isMasterNum(matrix.outerLeft.sub[1])" class="master-star-sm">★</text>
  91. </text>
  92. </view>
  93. </view>
  94. <!-- 右侧外侧:三角排列 U / S T (61+岁) -->
  95. <view class="outer-tri right-tri">
  96. <view class="tri-main" :class="numColorCls(matrix.outerRight.main)" @click="showCellDetail('U', chartNum('innerMid', 1))">
  97. {{ matrix.outerRight.main }}
  98. <text v-if="isMasterNum(matrix.outerRight.main)" class="master-star-sm">★</text>
  99. </view>
  100. <view class="tri-subs">
  101. <text class="tri-sub" :class="numColorCls(matrix.outerRight.sub[0])" @click.stop="showCellDetail('S', chartNum('innerBottom', 2))">
  102. {{ matrix.outerRight.sub[0] }}
  103. <text v-if="isMasterNum(matrix.outerRight.sub[0])" class="master-star-sm">★</text>
  104. </text>
  105. <text class="tri-sub" :class="numColorCls(matrix.outerRight.sub[1])" @click.stop="showCellDetail('T', chartNum('innerBottom', 3))">
  106. {{ matrix.outerRight.sub[1] }}
  107. <text v-if="isMasterNum(matrix.outerRight.sub[1])" class="master-star-sm">★</text>
  108. </text>
  109. </view>
  110. </view>
  111. <!-- 外三区之间的 V 形分隔线 -->
  112. <view class="sep-v sep-v-left"></view>
  113. <view class="sep-v sep-v-right"></view>
  114. </view>
  115. <!-- 底部 日(2) 月(2) 年(4) -->
  116. <view class="date-footer">
  117. <view class="date-group">
  118. <view class="input-boxes">
  119. <view class="box" v-for="(num, index) in birthday.day" :key="'d-'+index">{{ num }}</view>
  120. </view>
  121. <text class="label">日</text>
  122. </view>
  123. <view class="date-divider"></view>
  124. <view class="date-group">
  125. <view class="input-boxes">
  126. <view class="box" v-for="(num, index) in birthday.month" :key="'m-'+index">{{ num }}</view>
  127. </view>
  128. <text class="label">月</text>
  129. </view>
  130. <view class="date-divider"></view>
  131. <view class="date-group">
  132. <view class="input-boxes">
  133. <view class="box" v-for="(num, index) in birthday.year" :key="'y-'+index">{{ num }}</view>
  134. </view>
  135. <text class="label">年</text>
  136. </view>
  137. </view>
  138. <!-- 数字点击详情弹窗 -->
  139. <view v-if="selectedCell" class="detail-overlay" @click="hideDetail">
  140. <view class="detail-panel" @click.stop>
  141. <view class="detail-close" @click="hideDetail">✕</view>
  142. <view class="detail-num" :class="numColorCls(selectedCell.value)">{{ selectedCell.value }}</view>
  143. <view class="detail-name">{{ selectedCell.label }}</view>
  144. <view class="detail-zone-tag" :class="'tag-' + selectedCell.zone">{{ zoneName(selectedCell.zone) }}</view>
  145. <view class="detail-trait">{{ selectedCell.trait }}</view>
  146. <view class="detail-desc">{{ selectedCell.desc }}</view>
  147. <view v-if="selectedCell.isMaster" class="detail-master">✦ 卓越数 — 能量倍增,非同凡响 ✦</view>
  148. </view>
  149. </view>
  150. </view>
  151. </template>
  152. <script>
  153. // style-guide §2.4: 命盘数字色
  154. const NUM_COLORS = {
  155. 1: '#D94A4A', 2: '#4A90D9', 3: '#E8A238',
  156. 4: '#2D8B67', 5: '#D4A017', 6: '#7B6FA0',
  157. 7: '#4A6FA5', 8: '#C9A84C', 9: '#B85C3A'
  158. }
  159. // 30位完整命盘:US-1.3 位置命名对照表
  160. const POSITION_INFO = {
  161. // 内部层(7位)
  162. O: { label: '主性格', zone: 'main', trait: '核心人格特质', desc: '代表你的核心性格、人生方向和主要能量特征,是整个命盘的中心。' },
  163. M: { label: '青年综合数', zone: 'left', trait: '青年期自身力量的呈现', desc: '由月能量与日能量结合而成,代表青年期的内在动力与外在表现。' },
  164. N: { label: '晚年综合数', zone: 'right', trait: '晚年期自身力量的呈现', desc: '由年前位与年后位结合而成,代表晚年的人生经验积累与智慧沉淀。' },
  165. I: { label: '日能量', zone: 'left', trait: '出生日能量', desc: '代表你出生当天的能量特质,影响你的日常行为和表达方式。(原位置 G → I)' },
  166. J: { label: '月能量', zone: 'father', trait: '父亲遗传与先天能量', desc: '代表来自父亲/父系的先天遗传能量,影响你的内在根基。(原位置 F → J)' },
  167. K: { label: '年前位', zone: 'right', trait: '前半生积累', desc: '代表早年环境与成长经历,影响人生前期的运势走向。(原位置 H)' },
  168. L: { label: '年后位', zone: 'mother', trait: '母亲遗传与后天能量', desc: '代表来自母亲/母系的遗传能量以及后天环境的影响。(原位置 I)' },
  169. // 外部层(9位)
  170. P: { label: '左侧左子', zone: 'left', trait: '外部左翼基础', desc: '由日能量(I)与青年综合数(M)结合,代表左翼外部能量的基础层面。' },
  171. Q: { label: '左侧右子', zone: 'left', trait: '外部左翼辅助', desc: '由月能量(J)与青年综合数(M)结合,代表左翼外部能量的辅助层面。' },
  172. R: { label: '左侧主数', zone: 'left', trait: '左翼外部能量总和(21-40岁)', desc: '左侧子数之和,代表21-40岁年龄段的综合外部能量。' },
  173. S: { label: '右侧左子', zone: 'right', trait: '外部右翼基础', desc: '由年前位与晚年综合数结合,代表右翼外部能量的基础层面。' },
  174. T: { label: '右侧右子', zone: 'right', trait: '外部右翼辅助', desc: '由年后位与晚年综合数结合,代表右翼外部能量的辅助层面。' },
  175. U: { label: '右侧主数', zone: 'right', trait: '右翼外部能量总和(61+岁)', desc: '右侧子数之和,代表61岁以后年龄段的综合外部能量。' },
  176. V: { label: '顶部左子', zone: 'main', trait: '顶部外部基础', desc: '由青年综合数与主性格结合,代表顶部外部能量的基础层面。' },
  177. W: { label: '顶部右子', zone: 'main', trait: '顶部外部辅助', desc: '由晚年综合数与主性格结合,代表顶部外部能量的辅助层面。' },
  178. X: { label: '顶部主数', zone: 'main', trait: '顶部外部能量总和(41-60岁)', desc: '顶部子数之和,代表41-60岁年龄段的综合外部能量。' }
  179. }
  180. export default {
  181. props: {
  182. chartData: { type: Object, default: null },
  183. birthYear: { type: Number, default: 0 },
  184. birthMonth: { type: Number, default: 0 },
  185. birthDay: { type: Number, default: 0 }
  186. },
  187. data() {
  188. return {
  189. selectedCell: null
  190. }
  191. },
  192. computed: {
  193. matrix() {
  194. if (!this.chartData) {
  195. return {
  196. innerTop: 3,
  197. innerMid: [2, 1],
  198. innerBottom: [1, 2, 3, 4],
  199. outerTop: { main: 7, sub: [5, 6] },
  200. outerLeft: { main: 1, sub: [8, 9] },
  201. outerRight: { main: 4, sub: [2, 3] }
  202. }
  203. }
  204. const d = this.chartData
  205. return {
  206. innerTop: d.O,
  207. innerMid: [d.M, d.N],
  208. innerBottom: [d.I, d.J, d.K, d.L],
  209. outerTop: { main: d.X, sub: [d.V, d.W] },
  210. outerLeft: { main: d.R, sub: [d.P, d.Q] },
  211. outerRight: { main: d.U, sub: [d.S, d.T] }
  212. }
  213. },
  214. birthday() {
  215. if (this.birthYear > 0) {
  216. return {
  217. year: String(this.birthYear).padStart(4, '0').split(''),
  218. month: String(this.birthMonth).padStart(2, '0').split(''),
  219. day: String(this.birthDay).padStart(2, '0').split('')
  220. }
  221. }
  222. return {
  223. month: ['0', '1'],
  224. day: ['0', '1'],
  225. year: ['1', '9', '9', '0']
  226. }
  227. }
  228. },
  229. methods: {
  230. chartNum(row, index) {
  231. if (row === 'innerTop') return this.matrix.innerTop
  232. if (row === 'innerMid') return this.matrix.innerMid[index]
  233. if (row === 'innerBottom') return this.matrix.innerBottom[index]
  234. return 0
  235. },
  236. numColorCls(num) {
  237. return 'num-color-' + num
  238. },
  239. isMasterNum(num) {
  240. return num === 11 || num === 22 || num === 33
  241. },
  242. showCellDetail(pos, value) {
  243. const info = POSITION_INFO[pos]
  244. if (!info) return
  245. this.selectedCell = {
  246. position: pos,
  247. value: value,
  248. label: info.label,
  249. zone: info.zone,
  250. trait: info.trait,
  251. desc: info.desc,
  252. isMaster: this.isMasterNum(value)
  253. }
  254. },
  255. hideDetail() {
  256. this.selectedCell = null
  257. },
  258. zoneName(zone) {
  259. const names = {
  260. main: '主性格区',
  261. left: '左区(月日能量)',
  262. right: '右区(年份能量)',
  263. father: '父源区',
  264. mother: '母源区'
  265. }
  266. return names[zone] || ''
  267. }
  268. }
  269. }
  270. </script>
  271. <style scoped>
  272. /* ================================================
  273. 数字能量三角图 - 深邃星空 · 黄金三角
  274. ================================================ */
  275. .container {
  276. width: 100%;
  277. background: linear-gradient(160deg, #0c0a1a 0%, #1a1040 40%, #0f0c2e 100%);
  278. display: flex;
  279. flex-direction: column;
  280. align-items: center;
  281. padding: 85rpx 0 14rpx;
  282. border-radius: 20rpx;
  283. position: relative;
  284. overflow: hidden;
  285. }
  286. /* 星空粒子 */
  287. .container::before {
  288. content: '';
  289. position: absolute;
  290. inset: 0;
  291. background-image:
  292. radial-gradient(1rpx 1rpx at 10% 20%, rgba(255,255,255,0.5) 0%, transparent 100%),
  293. radial-gradient(1.5rpx 1.5rpx at 30% 60%, rgba(255,255,255,0.4) 0%, transparent 100%),
  294. radial-gradient(1rpx 1rpx at 50% 15%, rgba(255,255,255,0.6) 0%, transparent 100%),
  295. radial-gradient(1rpx 1rpx at 70% 80%, rgba(255,255,255,0.35) 0%, transparent 100%),
  296. radial-gradient(1.5rpx 1.5rpx at 85% 30%, rgba(255,255,255,0.45) 0%, transparent 100%),
  297. radial-gradient(1rpx 1rpx at 20% 90%, rgba(255,255,255,0.3) 0%, transparent 100%);
  298. pointer-events: none;
  299. z-index: 0;
  300. }
  301. .chart-inner {
  302. position: relative;
  303. width: 100%;
  304. height: 520rpx;
  305. padding: 120rpx 60rpx 0 60rpx;
  306. box-sizing: border-box;
  307. z-index: 1;
  308. }
  309. /* 三角形光晕 */
  310. /* ---- 五区色块叠加 ---- */
  311. .zone-left-bg,
  312. .zone-right-bg {
  313. position: absolute;
  314. pointer-events: none;
  315. z-index: 0;
  316. opacity: 0.12;
  317. }
  318. .zone-left-bg {
  319. left: 0;
  320. bottom: 0;
  321. width: 55%;
  322. height: 85%;
  323. clip-path: polygon(0% 100%, 15% 0%, 100% 100%);
  324. background: linear-gradient(135deg, #f59e0b, #fbbf24);
  325. }
  326. .zone-right-bg {
  327. right: 0;
  328. bottom: 0;
  329. width: 55%;
  330. height: 85%;
  331. clip-path: polygon(100% 100%, 85% 0%, 0% 100%);
  332. background: linear-gradient(135deg, #4A90D9, #4A6FA5);
  333. }
  334. /* 父源/母源指示标记 */
  335. .zone-father {
  336. position: relative;
  337. }
  338. .zone-father::after {
  339. content: '';
  340. position: absolute;
  341. bottom: -2rpx;
  342. left: 50%;
  343. transform: translateX(-50%);
  344. width: 20rpx;
  345. height: 3rpx;
  346. border-radius: 2rpx;
  347. background: #4A90D9;
  348. opacity: 0.5;
  349. }
  350. .zone-mother {
  351. position: relative;
  352. }
  353. .zone-mother::after {
  354. content: '';
  355. position: absolute;
  356. bottom: -2rpx;
  357. left: 50%;
  358. transform: translateX(-50%);
  359. width: 20rpx;
  360. height: 3rpx;
  361. border-radius: 2rpx;
  362. background: #7B6FA0;
  363. opacity: 0.5;
  364. }
  365. /* 垂直中分割线(从 O/M-N 交汇处向下贯穿至底部,分隔左右半区) */
  366. .inner-matrix::after {
  367. content: '';
  368. position: absolute;
  369. top: 28%;
  370. bottom: 0;
  371. left: 50%;
  372. transform: translateX(-50%);
  373. width: 1rpx;
  374. background: linear-gradient(180deg,
  375. rgba(255, 255, 255, 0.06) 0%,
  376. rgba(255, 255, 255, 0.10) 15%,
  377. rgba(255, 255, 255, 0.10) 85%,
  378. rgba(255, 255, 255, 0.04) 100%
  379. );
  380. pointer-events: none;
  381. z-index: 1;
  382. }
  383. /* ---- 数字 1-9 独立配色 ---- */
  384. .num-color-1 { color: #D94A4A !important; }
  385. .num-color-2 { color: #4A90D9 !important; }
  386. .num-color-3 { color: #E8A238 !important; }
  387. .num-color-4 { color: #2D8B67 !important; }
  388. .num-color-5 { color: #D4A017 !important; }
  389. .num-color-6 { color: #7B6FA0 !important; }
  390. .num-color-7 { color: #4A6FA5 !important; }
  391. .num-color-8 { color: #C9A84C !important; }
  392. .num-color-9 { color: #B85C3A !important; }
  393. /* 卓越数 ★ 标记 */
  394. .master-star {
  395. font-size: 28rpx;
  396. color: #fbbf24;
  397. text-shadow: 0 0 16rpx rgba(251, 191, 36, 0.8);
  398. display: inline-block;
  399. margin-left: 4rpx;
  400. animation: pulse-star 1.5s ease-in-out infinite;
  401. }
  402. .master-star-sm {
  403. font-size: 20rpx;
  404. color: #fbbf24;
  405. text-shadow: 0 0 12rpx rgba(251, 191, 36, 0.6);
  406. display: inline-block;
  407. margin-left: 2rpx;
  408. animation: pulse-star 1.5s ease-in-out infinite;
  409. }
  410. @keyframes pulse-star {
  411. 0%, 100% { opacity: 1; transform: scale(1); }
  412. 50% { opacity: 0.6; transform: scale(1.2); }
  413. }
  414. .triangle-glow {
  415. position: absolute;
  416. top: 100rpx;
  417. left: 44rpx;
  418. right: 44rpx;
  419. bottom: 10rpx;
  420. clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
  421. background: linear-gradient(135deg, rgba(255, 200, 50, 0.2), rgba(255, 100, 200, 0.15));
  422. filter: blur(20rpx);
  423. }
  424. /* 三角形主体 */
  425. .triangle-bg {
  426. position: absolute;
  427. top: 104rpx;
  428. left: 48rpx;
  429. right: 48rpx;
  430. bottom: 14rpx;
  431. clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
  432. background: linear-gradient(165deg, #fbbf24 0%, #f59e0b 30%, #d97706 60%, #b45309 100%);
  433. padding: 3rpx;
  434. box-sizing: border-box;
  435. }
  436. .triangle-bg::after {
  437. content: '';
  438. display: block;
  439. width: 100%;
  440. height: 100%;
  441. background: linear-gradient(180deg, #0f0a1e 0%, #1a1035 50%, #0f0a20 100%);
  442. clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
  443. }
  444. /* ---- 内部数字矩阵 ---- */
  445. .inner-matrix {
  446. position: absolute;
  447. bottom: 14rpx;
  448. left: 48rpx;
  449. right: 48rpx;
  450. height: 74%;
  451. display: flex;
  452. flex-direction: column;
  453. z-index: 2;
  454. }
  455. .row { display: flex; }
  456. .row-top {
  457. height: 36%;
  458. justify-content: center;
  459. align-items: flex-end;
  460. padding-bottom: 4rpx;
  461. }
  462. .row-mid {
  463. height: 28%;
  464. justify-content: center;
  465. align-items: center;
  466. gap: 56rpx;
  467. position: relative;
  468. }
  469. /* 顶部 O 区与中间 M/N 区之间的横向分割线 */
  470. .row-mid::before {
  471. content: '';
  472. position: absolute;
  473. top: -4rpx;
  474. left: 50%;
  475. transform: translateX(-50%);
  476. width: 32%;
  477. height: 1rpx;
  478. background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08) 20%, rgba(255, 255, 255, 0.08) 80%, transparent);
  479. pointer-events: none;
  480. }
  481. /* 底部4数紧凑排列 */
  482. .row-bot4 {
  483. height: 36%;
  484. display: flex;
  485. justify-content: center;
  486. align-items: center;
  487. gap: 16rpx;
  488. padding: 0 20rpx;
  489. position: relative;
  490. }
  491. /* 行间横向分割线(位于 row-mid 与 row-bot4 之间,区分上三区与下两区) */
  492. .row-sep {
  493. height: 2rpx;
  494. width: 62%;
  495. margin: 0 auto;
  496. background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.12) 20%, rgba(255, 255, 255, 0.12) 80%, transparent);
  497. flex-shrink: 0;
  498. }
  499. /* 底部四数 J 与 K 之间的垂直分割线(左右两区边界) */
  500. .row-bot4::before {
  501. content: '';
  502. position: absolute;
  503. top: 6rpx;
  504. bottom: 6rpx;
  505. left: 50%;
  506. transform: translateX(-50%);
  507. width: 1rpx;
  508. background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.15) 20%, rgba(255, 255, 255, 0.15) 80%, transparent);
  509. pointer-events: none;
  510. z-index: 1;
  511. }
  512. .cell-main {
  513. font-size: 64rpx;
  514. font-weight: 700;
  515. color: #fbbf24;
  516. text-shadow: 0 0 24rpx rgba(251, 191, 36, 0.5), 0 0 80rpx rgba(251, 191, 36, 0.2);
  517. letter-spacing: 2rpx;
  518. }
  519. .cell-mid {
  520. flex: none;
  521. width: auto;
  522. font-size: 44rpx;
  523. font-weight: 600;
  524. color: #ffffff;
  525. text-shadow: 0 0 16rpx rgba(255, 255, 255, 0.25);
  526. padding: 0 6rpx;
  527. }
  528. .cell-bot4 {
  529. width: 64rpx;
  530. text-align: center;
  531. font-size: 40rpx;
  532. font-weight: 500;
  533. color: #ffffff;
  534. text-shadow: 0 0 12rpx rgba(255, 255, 255, 0.2);
  535. }
  536. .border-right {
  537. border-right: 1rpx solid rgba(255, 255, 255, 0.1);
  538. }
  539. /* ---- 外侧三角排列 ---- */
  540. .outer-tri {
  541. position: absolute;
  542. display: flex;
  543. flex-direction: column;
  544. align-items: center;
  545. z-index: 3;
  546. }
  547. .tri-main {
  548. font-size: 44rpx;
  549. font-weight: 700;
  550. color: #ffffff;
  551. text-shadow: 0 0 18rpx rgba(255, 255, 255, 0.2);
  552. line-height: 1.1;
  553. }
  554. .tri-subs {
  555. display: flex;
  556. gap: 20rpx;
  557. margin-top: 4rpx;
  558. }
  559. .tri-sub {
  560. font-size: 44rpx;
  561. font-weight: 700;
  562. color: rgba(255, 255, 255, 0.75);
  563. }
  564. /* 顶部 */
  565. .top-tri {
  566. top: -58rpx;
  567. left: 50%;
  568. transform: translateX(-50%);
  569. position: absolute;
  570. }
  571. .top-tri .tri-main {
  572. font-size: 52rpx;
  573. color: #fbbf24;
  574. text-shadow: 0 0 28rpx rgba(251, 191, 36, 0.4);
  575. }
  576. /* 左侧 */
  577. .left-tri {
  578. top: 28%;
  579. left: 58rpx;
  580. position: absolute;
  581. }
  582. /* 右侧 */
  583. .right-tri {
  584. top: 28%;
  585. right: 58rpx;
  586. position: absolute;
  587. }
  588. /* 顶部的两外侧数字之间的分隔线 */
  589. .top-tri .tri-subs {
  590. position: relative;
  591. }
  592. .top-tri .tri-subs::before {
  593. content: '';
  594. position: absolute;
  595. left: 50%;
  596. bottom: -20rpx;
  597. transform: translateX(-50%);
  598. width: 130rpx;
  599. height: 1rpx;
  600. background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15) 15%, rgba(255, 255, 255, 0.15) 85%, transparent);
  601. }
  602. /* ---- 外三区之间的 V 形分隔线 ---- */
  603. .sep-v {
  604. position: absolute;
  605. z-index: 2;
  606. width: 1rpx;
  607. background: linear-gradient(180deg, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0.05) 100%);
  608. pointer-events: none;
  609. }
  610. .sep-v-left {
  611. top: 20rpx;
  612. left: 50%;
  613. height: 70rpx;
  614. transform-origin: top center;
  615. transform: rotate(-36deg);
  616. }
  617. .sep-v-right {
  618. top: 20rpx;
  619. left: 50%;
  620. height: 70rpx;
  621. transform-origin: top center;
  622. transform: rotate(36deg);
  623. }
  624. /* ---- 底部日期 ---- */
  625. .date-footer {
  626. display: flex;
  627. align-items: center;
  628. margin-top: 20rpx;
  629. padding: 0 40rpx;
  630. z-index: 1;
  631. }
  632. .date-group {
  633. display: flex;
  634. flex-direction: column;
  635. align-items: center;
  636. }
  637. .date-divider {
  638. width: 1rpx;
  639. height: 40rpx;
  640. background: rgba(255, 255, 255, 0.08);
  641. margin: 0 24rpx;
  642. }
  643. .input-boxes { display: flex; }
  644. .box {
  645. width: 34rpx;
  646. height: 42rpx;
  647. border: 1rpx solid rgba(255, 255, 255, 0.25);
  648. border-radius: 6rpx;
  649. margin: 0 3rpx;
  650. text-align: center;
  651. line-height: 42rpx;
  652. font-size: 22rpx;
  653. color: #ffffff;
  654. background: rgba(255, 255, 255, 0.08);
  655. }
  656. .label {
  657. font-size: 18rpx;
  658. color: rgba(255, 255, 255, 0.45);
  659. margin-top: 8rpx;
  660. letter-spacing: 2rpx;
  661. }
  662. /* ---- 数字点击详情弹窗 ---- */
  663. .detail-overlay {
  664. position: fixed;
  665. inset: 0;
  666. background: rgba(0, 0, 0, 0.6);
  667. z-index: 100;
  668. display: flex;
  669. align-items: flex-end;
  670. justify-content: center;
  671. animation: fadeIn 0.2s ease-out;
  672. }
  673. @keyframes fadeIn {
  674. from { opacity: 0; }
  675. to { opacity: 1; }
  676. }
  677. .detail-panel {
  678. width: 100%;
  679. background: linear-gradient(180deg, #1a1040 0%, #0f0c2e 100%);
  680. border-radius: 28rpx 28rpx 0 0;
  681. padding: 40rpx 36rpx 60rpx;
  682. position: relative;
  683. animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  684. border-top: 1rpx solid rgba(251, 191, 36, 0.2);
  685. max-height: 60vh;
  686. overflow-y: auto;
  687. }
  688. @keyframes slideUp {
  689. from { transform: translateY(100%); }
  690. to { transform: translateY(0); }
  691. }
  692. .detail-close {
  693. position: absolute;
  694. top: 20rpx;
  695. right: 28rpx;
  696. font-size: 32rpx;
  697. color: rgba(255, 255, 255, 0.3);
  698. width: 50rpx;
  699. height: 50rpx;
  700. display: flex;
  701. align-items: center;
  702. justify-content: center;
  703. }
  704. .detail-num {
  705. font-size: 80rpx;
  706. font-weight: 700;
  707. text-align: center;
  708. text-shadow: 0 0 30rpx currentColor;
  709. margin-bottom: 8rpx;
  710. }
  711. .detail-name {
  712. font-size: 30rpx;
  713. font-weight: 600;
  714. color: #ffffff;
  715. text-align: center;
  716. margin-bottom: 16rpx;
  717. }
  718. .detail-zone-tag {
  719. display: inline-block;
  720. font-size: 20rpx;
  721. padding: 4rpx 16rpx;
  722. border-radius: 20rpx;
  723. text-align: center;
  724. margin: 0 auto 20rpx;
  725. width: fit-content;
  726. }
  727. .tag-main {
  728. background: rgba(251, 191, 36, 0.15);
  729. color: #fbbf24;
  730. border: 1rpx solid rgba(251, 191, 36, 0.2);
  731. }
  732. .tag-left {
  733. background: rgba(245, 158, 11, 0.15);
  734. color: #fbbf24;
  735. border: 1rpx solid rgba(245, 158, 11, 0.2);
  736. }
  737. .tag-right {
  738. background: rgba(74, 144, 217, 0.15);
  739. color: #4A90D9;
  740. border: 1rpx solid rgba(74, 144, 217, 0.2);
  741. }
  742. .tag-father {
  743. background: rgba(74, 144, 217, 0.15);
  744. color: #4A90D9;
  745. border: 1rpx solid rgba(74, 144, 217, 0.2);
  746. }
  747. .tag-mother {
  748. background: rgba(123, 111, 160, 0.15);
  749. color: #7B6FA0;
  750. border: 1rpx solid rgba(123, 111, 160, 0.2);
  751. }
  752. .detail-trait {
  753. font-size: 26rpx;
  754. font-weight: 500;
  755. color: rgba(255, 255, 255, 0.8);
  756. text-align: center;
  757. margin-bottom: 16rpx;
  758. }
  759. .detail-desc {
  760. font-size: 24rpx;
  761. color: rgba(255, 255, 255, 0.5);
  762. line-height: 1.8;
  763. text-align: center;
  764. padding: 0 20rpx;
  765. }
  766. .detail-master {
  767. margin-top: 24rpx;
  768. text-align: center;
  769. font-size: 22rpx;
  770. color: #fbbf24;
  771. background: rgba(251, 191, 36, 0.1);
  772. border: 1rpx solid rgba(251, 191, 36, 0.15);
  773. border-radius: 12rpx;
  774. padding: 12rpx;
  775. letter-spacing: 2rpx;
  776. }
  777. </style>