159 lines
3.0 KiB
Plaintext
159 lines
3.0 KiB
Plaintext
.goods-card {
|
|
display: flex;
|
|
flex-direction: column;
|
|
box-sizing: border-box;
|
|
width: 100%;
|
|
height: 100%;
|
|
font-size: 24rpx;
|
|
background: var(--bg-card);
|
|
border-radius: var(--radius-lg);
|
|
box-shadow: var(--shadow-card);
|
|
overflow: hidden;
|
|
transition: transform 0.16s ease, box-shadow 0.16s ease;
|
|
}
|
|
|
|
.goods-card--hover {
|
|
transform: scale(0.98);
|
|
box-shadow: 0 2rpx 8rpx rgba(29, 33, 41, 0.06);
|
|
}
|
|
|
|
.goods-card__main {
|
|
position: relative;
|
|
display: flex;
|
|
flex: 1 1 auto;
|
|
flex-direction: column;
|
|
width: 100%;
|
|
background: var(--bg-card);
|
|
border-radius: var(--radius-lg);
|
|
overflow: hidden;
|
|
}
|
|
|
|
.goods-card__thumb {
|
|
position: relative;
|
|
flex-shrink: 0;
|
|
width: 100%;
|
|
height: 340rpx;
|
|
background: var(--bg-grey);
|
|
overflow: hidden;
|
|
}
|
|
|
|
.goods-card__thumb:empty {
|
|
display: none;
|
|
margin: 0;
|
|
}
|
|
|
|
.goods-card__img {
|
|
display: block;
|
|
width: 100%;
|
|
height: 100%;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.goods-card__img--empty {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
.goods-card__body {
|
|
display: flex;
|
|
flex: 1 1 auto;
|
|
flex-direction: column;
|
|
padding: 20rpx 24rpx 24rpx;
|
|
background: var(--bg-card);
|
|
}
|
|
|
|
.goods-card__title {
|
|
flex-shrink: 0;
|
|
display: -webkit-box;
|
|
height: 80rpx;
|
|
-webkit-box-orient: vertical;
|
|
-webkit-line-clamp: 2;
|
|
overflow: hidden;
|
|
font-size: 28rpx;
|
|
font-weight: 500;
|
|
line-height: 40rpx;
|
|
color: var(--text-primary);
|
|
word-break: break-word;
|
|
}
|
|
|
|
.goods-card__tags {
|
|
display: flex;
|
|
flex-direction: row;
|
|
flex-wrap: nowrap;
|
|
margin: 10rpx 0 0 0;
|
|
overflow: hidden;
|
|
height: 36rpx;
|
|
}
|
|
|
|
.goods-card__tag {
|
|
display: block;
|
|
max-width: 200rpx;
|
|
margin: 0 8rpx 0 0;
|
|
padding: 2rpx 12rpx;
|
|
overflow: hidden;
|
|
font-size: 20rpx;
|
|
line-height: 30rpx;
|
|
color: var(--brand);
|
|
white-space: nowrap;
|
|
word-break: keep-all;
|
|
text-overflow: ellipsis;
|
|
background: var(--brand-light);
|
|
border-radius: var(--radius-round);
|
|
}
|
|
|
|
.goods-card__down {
|
|
display: flex;
|
|
flex-direction: row;
|
|
align-items: baseline;
|
|
justify-content: flex-start;
|
|
margin: auto 0 0 0;
|
|
padding-top: 10rpx;
|
|
line-height: 44rpx;
|
|
}
|
|
|
|
/* "购买"引导按钮:圆形加号图标,沉底右对齐 */
|
|
.goods-card__buy {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
align-self: flex-end;
|
|
margin-left: auto;
|
|
width: 52rpx;
|
|
height: 52rpx;
|
|
flex-shrink: 0;
|
|
color: var(--text-inverse);
|
|
background: var(--brand-gradient);
|
|
border-radius: var(--radius-round);
|
|
box-shadow: 0 4rpx 12rpx rgba(255, 95, 21, 0.28);
|
|
transition: transform 0.16s ease, box-shadow 0.16s ease;
|
|
}
|
|
|
|
.goods-card__buy--hover {
|
|
transform: scale(0.9);
|
|
box-shadow: 0 2rpx 6rpx rgba(255, 95, 21, 0.2);
|
|
}
|
|
|
|
.goods-card__origin-price {
|
|
order: 2;
|
|
margin: 0 0 0 12rpx;
|
|
font-size: 22rpx;
|
|
font-weight: 400;
|
|
color: var(--text-placeholder);
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.spec-for-price {
|
|
order: 1;
|
|
margin: 0;
|
|
font-size: 38rpx;
|
|
font-weight: 700;
|
|
color: var(--brand);
|
|
white-space: nowrap;
|
|
font-family: 'DIN Alternate', -apple-system, sans-serif;
|
|
}
|
|
|
|
.spec-for-symbol {
|
|
font-size: 24rpx;
|
|
}
|