index.scss
4.65 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
@import '@/styles/_support';
.content {
padding-bottom: 2.25rem;
}
.top-space {
height: 2.25rem;
}
.box {
position: relative;
margin-top: $marginMedium;
}
// banner 轮播
.banner-contaner {
width: 100%;
height: 470px;
margin: 0 auto;
position: relative;
z-index: 1;
overflow: hidden;
}
// PC轮播
.banner-pc {
display: block;
position: absolute;
z-index: 1;
left: 50%;
margin-left: -960px;
top: 0;
width: 1920px;
height: 100%;
overflow: hidden;
.banner-img {
width: 100%;
height: 100%;
}
.btn-wrap {
position: absolute;
z-index: 1;
// 两个banner图按钮位置不一样,和原先约定的按钮位置固定不一致
// 如要调整位置,请调整top,right。如需要右对齐请使用right
// 已用padding适应文本过长的情况(英文等);
// top: 272px;
// left: 1228px;
// top: 310px;
top : 295px;
right: 432px;
display: flex;
.banner-btn {
@extend .pointer;
@extend .bb;
@include btc2(126px, 48px, $fontSizeTitle);
width: auto;
padding: 0 24px;
min-width: 126px;
margin-left: 12px;
background-image: none;
}
}
}
// 移动端轮播
.banner-mobile {
display: none;
.banner-img {
width: 100%;
}
.btn-wrap{
position: absolute;
z-index: 1;
top: 87%;
left: 0;
right: 0;
margin: 0 auto;
display: flex;
justify-content: center;
.banner-btn{
@extend .pointer;
padding: 0 12px;
color: $cOrange;
}
}
}
// 推荐产品
.recommend {
display: flex;
text-align: center;
justify-content: space-between;
flex-wrap: wrap;
&-item {
@extend .bb;
margin-right: $marginSmall;
&:last-child {
margin-right: 0;
}
position: relative;
width: 24.25rem;
// width: 100%;
height: 32.75rem;
border-radius: $borderRadiusSmall;
@extend .box-shadow;
background-color: #fbfbfb;
.img {
width: 100%;
height: 24.25rem;
background-size: cover;
}
.img1 {
background: url("~@/assets/images/index/recommend-1.png") no-repeat center;
background-size: cover;
}
.img2 {
background: url("~@/assets/images/index/recommend-2.png") no-repeat center;
background-size: cover;
}
.img3 {
background: url("~@/assets/images/index/recommend-3.png") no-repeat center;
background-size: cover;
}
.img4 {
background: url("~@/assets/images/index/recommend-4.png") no-repeat center;
background-size: cover;
}
.btn {
position: absolute;
left: 0;
right: 0;
bottom: 3rem;
margin: 0 auto;
@include btc2(13.5rem, 4rem, 16px);
}
img {
width: 100%;
@include border-top-radius($borderRadius);
}
&:first-child {
padding-left: 0;
}
&:last-child {
padding-right: 0;
}
}
}
// 详情
.detail {
display: flex;
max-width: 1200px;
.txt {
position: relative;
@extend .fcc;
@extend .bb;
@include ellipsis(14);
padding-left: 2.166667rem;
flex: 1;
line-height: 2.3;
letter-spacing: 1.4px;
}
}
.swiper-button-prev {
background-image: url('~@/assets/images/common/button-prev.png');
left: 360px;
}
.swiper-button-next {
background-image: url('~@/assets/images/common/button-next.png');
right: 360px;
}
.swiper-container {
height: 100%;
}
.swiper-pagination-fraction,
.swiper-pagination-custom,
.swiper-container-horizontal>.swiper-pagination-bullets {
bottom: 48px;
}
.swiper-pagination-bullet {
width: 12px;
height: 12px;
background-color: #dcdddd;
}
.swiper-pagination-bullet-active {
width: 12px;
height: 12px;
background-color: $cOrange;
}
.box-shadow {
box-shadow: 0 0 1.5rem 0 rgba(255, 87, 0, 0.15);
}
@media (max-width: 1200px) {
.content {
@include content-percent();
}
// 推荐产品
.recommend {
justify-content: center;
&-item {
width: 46% !important;
padding: 0 !important;
margin: 2% !important;
}
}
// 详情
.detail {
display: block;
.vjs-custom-skin {
width: 100%;
}
.txt {
padding: 0;
margin: $marginSmall 0 $marginMedium;
}
}
}
@media (max-width: 768px) {
.content {}
.banner-contaner {
height: auto;
}
.banner-pc {
display: none;
}
.banner-mobile {
display: block;
}
// 推荐产品
.recommend {
&-item {
width: 100% !important;
margin: $marginSmall-M auto !important;
}
}
.box-shadow {
box-shadow: none;
}
.swiper-pagination-fraction,
.swiper-pagination-custom,
.swiper-container-horizontal>.swiper-pagination-bullets {
bottom: 2px;
}
}