productdetails.wxss 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  1. .goodslist_boxs {
  2. margin: 0rpx 30rpx;
  3. width: calc(100% - 60rpx);
  4. height: calc( 100vh - 40rpx);
  5. }
  6. .empty-space {
  7. width: 100%;
  8. height: 500rpx;
  9. background-color: #e0e0e0;
  10. margin-top: 20rpx;
  11. border-radius: 12rpx;
  12. }
  13. .goods-image {
  14. width: 100%;
  15. height: 400rpx;
  16. }
  17. .price-and-views {
  18. display: flex;
  19. justify-content: space-between;
  20. align-items: center;
  21. padding: 20rpx;
  22. }
  23. .price {
  24. color: #ff5722;
  25. font-size: 32rpx;
  26. }
  27. .original-price {
  28. color: #999;
  29. font-size: 24rpx;
  30. margin-left: 20rpx;
  31. text-decoration: line-through;
  32. }
  33. .views {
  34. color: #999;
  35. font-size: 24rpx;
  36. }
  37. .goods-title {
  38. padding: 0 20rpx;
  39. font-size: 32rpx;
  40. font-weight: bold;
  41. }
  42. .specifications {
  43. margin: 20rpx 0;
  44. padding: 20rpx;
  45. background: #fff;
  46. border-radius: 16rpx;
  47. }
  48. .specifications_boxs {
  49. width: 100%;
  50. height: 80%;
  51. margin-top: 20rpx;
  52. display: flex;
  53. flex-wrap: wrap; /* 允许内容自动换行 */
  54. justify-content: flex-start; /* 靠右排列 */
  55. align-content: flex-start;
  56. gap: 20rpx; /* 设置项目之间的间距 */
  57. }
  58. .spec-btn {
  59. width: 48% !important;
  60. margin-bottom: 20rpx; /* 设置底部边距,确保换行后有间距 */
  61. padding: 10rpx 20rpx;
  62. border: 1px solid #ccc;
  63. border-radius: 50rpx;
  64. font-size: 28rpx;
  65. white-space: nowrap; /* 防止文字换行 */
  66. }
  67. .spec-btn.active {
  68. background-color: #fff;
  69. color: #fff;
  70. border-color: #409eff;
  71. color: #409eff;
  72. }
  73. .quantity {
  74. display: flex;
  75. align-items: center;
  76. justify-content: space-between;
  77. padding: 20rpx;
  78. background: #fff;
  79. border-radius: 16rpx;
  80. }
  81. .quantity-controls {
  82. display: flex;
  83. align-items: center;
  84. }
  85. .quantity-btn {
  86. width: 60rpx;
  87. height: 60rpx;
  88. background-color: #f5f5f5;
  89. border: none;
  90. font-size: 40rpx;
  91. color: #999;
  92. }
  93. .quantity-input {
  94. width: 80rpx;
  95. height: 60rpx;
  96. text-align: center;
  97. font-size: 32rpx;
  98. margin: 0 10rpx;
  99. }
  100. .product-details {
  101. padding: 20rpx;
  102. background: #fff;
  103. border-radius: 16rpx;
  104. margin-top: 20rpx;
  105. }
  106. .details-list text {
  107. margin-top: 20rpx;
  108. display: block;
  109. margin-bottom: 10rpx;
  110. font-size: 30rpx;
  111. color: #666;
  112. }
  113. .buttons {
  114. width: 100%;
  115. display: flex;
  116. justify-content: space-around;
  117. padding: 20rpx;
  118. position: fixed;
  119. bottom: 0;
  120. left: 0;
  121. background: #fff;
  122. padding-bottom: 40rpx;
  123. padding-top: 20rpx;
  124. }
  125. .cart-btn, .buy-btn {
  126. width: 40%;
  127. height: 80rpx;
  128. border-radius: 50rpx;
  129. font-size: 32rpx;
  130. color: #fff;
  131. }
  132. .cart-btn {
  133. width: 260rpx !important;
  134. background-color: #ea0000;
  135. }
  136. .buy-btn {
  137. width: 260rpx !important;
  138. background-color: #409eff;
  139. }
  140. .search-icon {
  141. width: 50rpx;
  142. height: 50rpx;
  143. }