index.wxss 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327
  1. .i-btn {
  2. text-align: center;
  3. vertical-align: middle;
  4. touch-action: manipulation;
  5. cursor: pointer;
  6. background-image: none;
  7. white-space: nowrap;
  8. user-select: none;
  9. font-size: 28rpx;
  10. border: 0 !important;
  11. position: relative;
  12. text-decoration: none;
  13. height: 88rpx;
  14. line-height: 88rpx;
  15. background: none;
  16. color: #495060;
  17. border-radius: 0;
  18. margin: 0;
  19. box-shadow: none;
  20. }
  21. .i-btn::after {
  22. border: none;
  23. }
  24. .spu {
  25. width: 100%;
  26. display: block;
  27. }
  28. .spu .img-class {
  29. width: 240rpx;
  30. height: 240rpx;
  31. border-radius: 10rpx;
  32. }
  33. .spu .mask {
  34. background: rgba(255, 255, 255, 0.5);
  35. width: 240rpx;
  36. height: 240rpx;
  37. position: absolute;
  38. left: 20rpx;
  39. top: 20rpx;
  40. }
  41. .spu .act-end {
  42. position: absolute;
  43. height: 60rpx;
  44. border-radius: 10rpx;
  45. background: rgba(0, 0, 0, 0.5);
  46. color: #fff;
  47. font-size: 28rpx;
  48. text-align: center;
  49. line-height: 60rpx;
  50. left: 140rpx;
  51. top: 112rpx;
  52. padding: 0 12rpx;
  53. transform: translateX(-50%);
  54. }
  55. .spu .act-end.act-out {
  56. left: 140rpx;
  57. }
  58. .spu .spu-content {
  59. background: #fff;
  60. width: 710rpx;
  61. border-radius: 20rpx;
  62. overflow: hidden;
  63. position: relative;
  64. box-shadow: 0 0 40rpx rgba(0, 0, 0, 0.05);
  65. margin: 0 auto 20rpx;
  66. display: flex;
  67. padding: 20rpx;
  68. box-sizing: border-box;
  69. }
  70. .spu .spu-content.disabled {
  71. opacity: 0.6;
  72. }
  73. .spu .spu-content .item-left {
  74. width: 240rpx;
  75. height: 240rpx;
  76. position: relative;
  77. }
  78. .spu .spu-content .item-right {
  79. box-sizing: border-box;
  80. margin-left: 20rpx;
  81. display: flex;
  82. flex-direction: column;
  83. justify-content: space-between;
  84. }
  85. .spu .spu-content .item-right .spu-title {
  86. color: #222;
  87. font-size: 30rpx;
  88. height: 32rpx;
  89. width: 400rpx;
  90. margin-bottom: 12rpx;
  91. margin-top: 10rpx;
  92. font-weight: 500;
  93. position: relative;
  94. }
  95. .spu .spu-content .item-right .spu-title .span {
  96. width: 100%;
  97. height: 40rpx;
  98. position: absolute;
  99. left: 0;
  100. top: -4rpx;
  101. line-height: 40rpx;
  102. overflow: hidden;
  103. text-overflow: ellipsis;
  104. white-space: nowrap;
  105. margin: 0;
  106. }
  107. .spu .spu-content .item-right .spu-tag {
  108. padding-left: 196rpx;
  109. margin-bottom: 20rpx;
  110. display: flex;
  111. height: 28rpx;
  112. }
  113. .spu .spu-content .item-right .spu-desc {
  114. font-size: 26rpx;
  115. line-height: 26rpx;
  116. color: #999;
  117. position: relative;
  118. width: 400rpx;
  119. height: 26rpx;
  120. margin-bottom: 12rpx;
  121. }
  122. .spu .spu-content .item-right .spu-desc em {
  123. width: 100%;
  124. height: 32rpx;
  125. position: absolute;
  126. left: 0;
  127. top: -2rpx;
  128. line-height: 32rpx;
  129. overflow: hidden;
  130. text-overflow: ellipsis;
  131. white-space: nowrap;
  132. }
  133. .spu .spu-content .item-right .spu-price {
  134. display: flex;
  135. align-items: flex-end;
  136. font-size: 26rpx;
  137. line-height: 26rpx;
  138. overflow: hidden;
  139. margin-bottom: 10rpx;
  140. }
  141. .spu .spu-content .item-right .spu-price .sale-price {
  142. color: #ff5344;
  143. margin-right: 12rpx;
  144. }
  145. .spu .spu-content .item-right .spu-price .sale-price .span {
  146. font-size: 46rpx;
  147. line-height: 42rpx;
  148. margin: 0;
  149. font-weight: bold;
  150. }
  151. .spu .spu-content .item-right .spu-price .market-price {
  152. text-decoration: line-through;
  153. color: #999;
  154. margin-right: 30rpx;
  155. }
  156. .spu .spu-content .item-right .spu-count {
  157. font-size: 24rpx;
  158. height: 24rpx;
  159. color: #999;
  160. margin-bottom: 30rpx;
  161. }
  162. .spu .spu-content .item-right .spu-count .spu-count-border {
  163. display: inline-block;
  164. border: 1rpx solid #f78076;
  165. border-radius: 20rpx;
  166. overflow: hidden;
  167. height: 30rpx;
  168. line-height: 30rpx;
  169. }
  170. .spu .spu-content .item-right .spu-count .spu-count-border .txt {
  171. padding: 0 10rpx;
  172. color: #f78076;
  173. height: 30rpx;
  174. line-height: 30rpx;
  175. }
  176. .spu .spu-content .item-right .spu-count .spu-count-border .spu-count-num {
  177. background-color: #f78076;
  178. color: #fff;
  179. }
  180. .spu .spu-content .add-cart {
  181. width: 68rpx;
  182. height: 68rpx;
  183. padding: 0;
  184. margin: 0;
  185. position: absolute;
  186. right: 28rpx;
  187. bottom: 20rpx;
  188. display: flex;
  189. align-items: center;
  190. justify-content: center;
  191. }
  192. .spu .spu-content .add-cart .img {
  193. width: 54rpx;
  194. height: 54rpx;
  195. display: block;
  196. }
  197. .spu .spu-content .spu-active {
  198. position: absolute;
  199. left: 0;
  200. bottom: 0;
  201. z-index: 9;
  202. display: flex;
  203. flex-direction: column-reverse;
  204. align-items: flex-start;
  205. }
  206. .spu .spu-content .spu-active .tag {
  207. background: linear-gradient(to right, #ff5041, #ff994b);
  208. border-radius: 0 14rpx 14rpx 0;
  209. padding: 0 12rpx;
  210. height: 30rpx;
  211. font-size: 22rpx;
  212. line-height: 30rpx;
  213. color: #fff;
  214. display: inline-block;
  215. align-items: center;
  216. justify-content: center;
  217. width: auto;
  218. max-width: 180rpx;
  219. overflow: hidden;
  220. text-overflow: ellipsis;
  221. white-space: nowrap;
  222. }
  223. .spu .spu-content .spu-active .tag-green {
  224. background: linear-gradient(to left, #46c8d0, #29ba9a);
  225. }
  226. /* 标签 */
  227. .spu .item-tag {
  228. position: absolute;
  229. left: -1rpx;
  230. top: 0;
  231. width: 54rpx;
  232. height: 62rpx;
  233. z-index: 1;
  234. color: #fff;
  235. text-align: center;
  236. }
  237. .item-tag-bg {
  238. position: absolute;
  239. left: 0;
  240. top: 0;
  241. width: 54rpx;
  242. height: 62rpx;
  243. z-index: 0;
  244. }
  245. .spu .item-tag .tag-name {
  246. position: relative;
  247. padding-top: 6rpx;
  248. font-size: 20rpx;
  249. line-height: 1;
  250. font-weight: 600;
  251. z-index: 1;
  252. }
  253. .spu .item-tag .tag-name.two-word {
  254. font-size: 22rpx;
  255. padding-top: 14rpx;
  256. }
  257. .spu .index-input-number {
  258. position: absolute;
  259. right: 0;
  260. bottom: 10rpx;
  261. display: flex;
  262. justify-content: center;
  263. align-items: center;
  264. }
  265. .spu .index-input-number .i-input-number-view {
  266. width: 80rpx;
  267. height: 80rpx;
  268. display: flex;
  269. justify-content: center;
  270. align-items: center;
  271. }
  272. .spu .index-input-number .i-input-number-view .img{
  273. width: 40rpx;
  274. height: 40rpx;
  275. }
  276. .spu .index-input-number .i-input-number-minus {
  277. justify-content: flex-end;
  278. }
  279. .spu .index-input-number .i-input-number-plus {
  280. justify-content: flex-start;
  281. }
  282. .spu .index-input-number .input-number-text {
  283. height: 88rpx;
  284. line-height: 88rpx;
  285. font-size: 24rpx;
  286. color: #333;
  287. width: 58rpx;
  288. }