You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
608 lines
9.7 KiB
608 lines
9.7 KiB
.container {
|
|
display: flex;
|
|
flex-direction: column;
|
|
min-height: 100vh;
|
|
background: linear-gradient(135deg, #F9FAFB 0%, #F2F4F8 100%);
|
|
font-family: 'PingFang SC', 'Helvetica Neue', Arial, sans-serif;
|
|
overflow-x: hidden;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
/* 步骤指示器 */
|
|
.step-indicator {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
padding: 32rpx;
|
|
background: #FFFFFF;
|
|
box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.05);
|
|
margin-bottom: 24rpx;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.step-item {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
flex: 1;
|
|
}
|
|
|
|
.step-number {
|
|
width: 48rpx;
|
|
height: 48rpx;
|
|
border-radius: 50%;
|
|
background: #E5E5E5;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 24rpx;
|
|
font-weight: 600;
|
|
color: #999;
|
|
margin-bottom: 8rpx;
|
|
transition: all 0.3s ease;
|
|
}
|
|
|
|
.step-text {
|
|
font-size: 20rpx;
|
|
color: #999;
|
|
transition: all 0.3s ease;
|
|
}
|
|
|
|
.step-item.active .step-number {
|
|
background: #007AFF;
|
|
color: #FFFFFF;
|
|
box-shadow: 0 0 0 8rpx rgba(0,122,255,0.1);
|
|
}
|
|
|
|
.step-item.active .step-text {
|
|
color: #007AFF;
|
|
font-weight: 500;
|
|
}
|
|
|
|
.step-line {
|
|
flex: 1;
|
|
height: 2rpx;
|
|
background: #E5E5E5;
|
|
margin: 0 16rpx;
|
|
transition: all 0.3s ease;
|
|
}
|
|
|
|
.step-line.active {
|
|
background: #007AFF;
|
|
}
|
|
|
|
.header {
|
|
background: #FFFFFF;
|
|
box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.05);
|
|
position: sticky;
|
|
top: 0;
|
|
z-index: 10;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.header-content {
|
|
display: flex;
|
|
align-items: center;
|
|
padding: 24rpx 32rpx;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
height: 100rpx;
|
|
max-width: 100%;
|
|
}
|
|
|
|
.title {
|
|
font-size: 36rpx;
|
|
font-weight: 700;
|
|
color: #2c3e50;
|
|
letter-spacing: 2rpx;
|
|
text-align: center;
|
|
margin: 0;
|
|
padding: 0;
|
|
flex: 1;
|
|
position: absolute;
|
|
left: 50%;
|
|
transform: translateX(-50%);
|
|
width: 100%;
|
|
max-width: 300rpx;
|
|
}
|
|
|
|
.header-content {
|
|
position: relative;
|
|
}
|
|
|
|
/* 返回按钮样式 */
|
|
.back-button {
|
|
width: 100rpx;
|
|
height: 60rpx;
|
|
line-height: 60rpx;
|
|
font-size: 36rpx;
|
|
color: #4a90e2;
|
|
background: transparent;
|
|
border: none;
|
|
padding: 0 16rpx 0 0;
|
|
margin: 0;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: flex-start;
|
|
border-radius: 8rpx;
|
|
transition: all 0.3s ease;
|
|
flex-shrink: 0;
|
|
overflow: visible;
|
|
}
|
|
|
|
.back-button:hover {
|
|
color: #3b82f6;
|
|
background: rgba(74, 144, 226, 0.1);
|
|
}
|
|
|
|
.back-icon {
|
|
margin-right: 8rpx;
|
|
font-size: 36rpx;
|
|
font-weight: 600;
|
|
transition: all 0.3s ease;
|
|
display: inline-block;
|
|
}
|
|
|
|
.back-button:hover .back-icon {
|
|
transform: translateX(-12rpx);
|
|
font-weight: 700;
|
|
}
|
|
|
|
.back-text {
|
|
font-size: 36rpx;
|
|
font-weight: 700;
|
|
}
|
|
|
|
.title {
|
|
font-size: 36rpx;
|
|
font-weight: 700;
|
|
color: #2c3e50;
|
|
letter-spacing: 2rpx;
|
|
flex: 1;
|
|
text-align: center;
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
|
|
.header-right {
|
|
width: 60rpx;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.content {
|
|
flex: 1;
|
|
padding: 32rpx;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
overflow-x: hidden;
|
|
}
|
|
|
|
/* 加载状态 */
|
|
.loading {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
background: rgba(255, 255, 255, 0.9);
|
|
z-index: 9999;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.loading-spinner {
|
|
width: 80rpx;
|
|
height: 80rpx;
|
|
border: 8rpx solid rgba(74, 144, 226, 0.2);
|
|
border-top: 8rpx solid #4a90e2;
|
|
border-radius: 50%;
|
|
animation: spin 1s linear infinite;
|
|
margin-bottom: 32rpx;
|
|
}
|
|
|
|
@keyframes spin {
|
|
0% { transform: rotate(0deg); }
|
|
100% { transform: rotate(360deg); }
|
|
}
|
|
|
|
.loading-text {
|
|
font-size: 28rpx;
|
|
color: #666;
|
|
font-weight: 500;
|
|
}
|
|
|
|
/* 错误提示卡片 */
|
|
.error-card {
|
|
background: #fff;
|
|
border-radius: 16rpx;
|
|
padding: 48rpx;
|
|
margin: 32rpx 0;
|
|
box-shadow: 0 4rpx 20rpx rgba(0,0,0,0.08);
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
text-align: center;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.error-icon {
|
|
font-size: 80rpx;
|
|
margin-bottom: 24rpx;
|
|
}
|
|
|
|
.error-text {
|
|
font-size: 28rpx;
|
|
color: #e74c3c;
|
|
margin-bottom: 32rpx;
|
|
line-height: 1.5;
|
|
}
|
|
|
|
/* 按钮样式 */
|
|
.btn-primary {
|
|
width: 240rpx;
|
|
height: 80rpx;
|
|
line-height: 80rpx;
|
|
font-size: 28rpx;
|
|
font-weight: 600;
|
|
border-radius: 40rpx;
|
|
background: linear-gradient(135deg, #60a5fa 0%, #3b82f6 100%);
|
|
color: #fff;
|
|
border: none;
|
|
box-shadow: 0 4rpx 12rpx rgba(96, 165, 250, 0.4);
|
|
transition: all 0.3s ease;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.btn-primary:hover {
|
|
transform: translateY(-2rpx);
|
|
box-shadow: 0 6rpx 16rpx rgba(74, 144, 226, 0.5);
|
|
}
|
|
|
|
/* 商品列表区域 */
|
|
.product-section {
|
|
margin-top: 24rpx;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
/* 当前选择的分类 */
|
|
.current-category {
|
|
display: flex;
|
|
flex-direction: column;
|
|
background: #F8F9FA;
|
|
padding: 24rpx 32rpx;
|
|
border-radius: 16rpx;
|
|
margin-bottom: 32rpx;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.current-category-content {
|
|
display: flex;
|
|
align-items: center;
|
|
margin-bottom: 8rpx;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.current-category-name {
|
|
font-size: 36rpx;
|
|
font-weight: 600;
|
|
color: #333;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
/* 价格范围 */
|
|
.price-range {
|
|
display: flex;
|
|
align-items: center;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.price-range-value {
|
|
font-size: 28rpx;
|
|
color: #666;
|
|
}
|
|
|
|
.section-header {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
margin-bottom: 24rpx;
|
|
padding: 0;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.section-title {
|
|
font-size: 32rpx;
|
|
font-weight: 600;
|
|
color: #2c3e50;
|
|
padding-left: 0;
|
|
border-left: none;
|
|
}
|
|
|
|
.section-count {
|
|
font-size: 28rpx;
|
|
color: #999;
|
|
background: #F0F0F0;
|
|
padding: 8rpx 16rpx;
|
|
border-radius: 24rpx;
|
|
}
|
|
|
|
.section-divider {
|
|
height: 1rpx;
|
|
background: #EDEDED;
|
|
margin-bottom: 24rpx;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
/* 商品网格布局 */
|
|
.product-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(2, 1fr);
|
|
gap: 24rpx;
|
|
margin-top: 0;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
overflow-x: hidden;
|
|
}
|
|
|
|
/* 商品卡片 */
|
|
.product-card {
|
|
background: #FFFFFF;
|
|
border-radius: 16rpx;
|
|
padding: 16rpx;
|
|
cursor: pointer;
|
|
min-height: 240rpx;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: flex-start;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
box-shadow: 0 4rpx 12rpx rgba(0,0,0,0.04);
|
|
transition: all 0.3s ease;
|
|
}
|
|
|
|
.product-image-container {
|
|
width: 100%;
|
|
height: 160rpx;
|
|
margin-bottom: 16rpx;
|
|
border-radius: 12rpx;
|
|
overflow: hidden;
|
|
background: #F5F5F5;
|
|
}
|
|
|
|
.product-image {
|
|
width: 100%;
|
|
height: 100%;
|
|
object-fit: cover;
|
|
}
|
|
|
|
.product-card:hover {
|
|
box-shadow: 0 8rpx 20rpx rgba(0,0,0,0.08);
|
|
transform: translateY(-2rpx);
|
|
}
|
|
|
|
.product-name {
|
|
font-size: 28rpx;
|
|
font-weight: 500;
|
|
color: #333;
|
|
line-height: 1.4;
|
|
word-break: break-word;
|
|
text-align: center;
|
|
padding: 0 8rpx;
|
|
display: -webkit-box;
|
|
-webkit-line-clamp: 2;
|
|
-webkit-box-orient: vertical;
|
|
overflow: hidden;
|
|
}
|
|
|
|
/* 响应式设计 */
|
|
@media (max-width: 750rpx) {
|
|
.content {
|
|
padding: 24rpx;
|
|
}
|
|
|
|
.product-grid {
|
|
gap: 20rpx;
|
|
}
|
|
|
|
.product-card {
|
|
padding: 16rpx;
|
|
min-height: 220rpx;
|
|
}
|
|
|
|
.product-image-container {
|
|
height: 140rpx;
|
|
}
|
|
|
|
.title {
|
|
font-size: 32rpx;
|
|
}
|
|
|
|
.section-title {
|
|
font-size: 28rpx;
|
|
}
|
|
|
|
.product-name {
|
|
font-size: 26rpx;
|
|
}
|
|
|
|
.current-category {
|
|
padding: 20rpx 24rpx;
|
|
}
|
|
|
|
.current-category-name {
|
|
font-size: 32rpx;
|
|
}
|
|
|
|
.price-range-value {
|
|
font-size: 24rpx;
|
|
}
|
|
}
|
|
|
|
/* 小屏幕设备适配 */
|
|
@media (max-width: 414rpx) {
|
|
.content {
|
|
padding: 24rpx;
|
|
}
|
|
|
|
.product-grid {
|
|
gap: 20rpx;
|
|
}
|
|
|
|
.product-card {
|
|
padding: 16rpx;
|
|
min-height: 200rpx;
|
|
}
|
|
|
|
.product-image-container {
|
|
height: 120rpx;
|
|
}
|
|
|
|
.product-name {
|
|
font-size: 24rpx;
|
|
}
|
|
|
|
.title {
|
|
font-size: 32rpx;
|
|
}
|
|
|
|
.section-title {
|
|
font-size: 28rpx;
|
|
}
|
|
|
|
.current-category {
|
|
padding: 16rpx 20rpx;
|
|
}
|
|
|
|
.current-category-name {
|
|
font-size: 28rpx;
|
|
}
|
|
|
|
.price-range-value {
|
|
font-size: 22rpx;
|
|
}
|
|
}
|
|
|
|
/* 大屏幕适配 */
|
|
@media (min-width: 900px) {
|
|
.product-grid {
|
|
grid-template-columns: repeat(4, 1fr);
|
|
max-width: 1200rpx;
|
|
margin: 0 auto;
|
|
}
|
|
|
|
.current-category {
|
|
max-width: 1200rpx;
|
|
margin: 0 auto 32rpx;
|
|
}
|
|
|
|
.section-header {
|
|
max-width: 1200rpx;
|
|
margin: 0 auto 24rpx;
|
|
}
|
|
|
|
.section-divider {
|
|
max-width: 1200rpx;
|
|
margin: 0 auto 24rpx;
|
|
}
|
|
}
|
|
|
|
/* 平板适配 */
|
|
@media (min-width: 600px) and (max-width: 899px) {
|
|
.product-grid {
|
|
grid-template-columns: repeat(3, 1fr);
|
|
}
|
|
}
|
|
|
|
/* 暂无更多商品提示 */
|
|
.no-more {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 48rpx 0;
|
|
margin-top: 24rpx;
|
|
}
|
|
|
|
.no-more::before,
|
|
.no-more::after {
|
|
content: '';
|
|
flex: 1;
|
|
height: 1rpx;
|
|
background: #E5E5E5;
|
|
margin: 0 16rpx;
|
|
}
|
|
|
|
.no-more-text {
|
|
font-size: 24rpx;
|
|
color: #BBB;
|
|
font-weight: 500;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
/* 空状态 */
|
|
.empty-state {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 120rpx 0;
|
|
text-align: center;
|
|
}
|
|
|
|
.empty-icon {
|
|
font-size: 120rpx;
|
|
margin-bottom: 40rpx;
|
|
opacity: 0.6;
|
|
color: #CCC;
|
|
}
|
|
|
|
.empty-text {
|
|
font-size: 32rpx;
|
|
font-weight: 600;
|
|
color: #333;
|
|
margin-bottom: 16rpx;
|
|
line-height: 1.4;
|
|
padding: 0 40rpx;
|
|
}
|
|
|
|
.empty-subtext {
|
|
font-size: 28rpx;
|
|
color: #999;
|
|
margin-bottom: 48rpx;
|
|
line-height: 1.4;
|
|
padding: 0 40rpx;
|
|
}
|
|
|
|
.btn-secondary {
|
|
width: 200rpx;
|
|
height: 80rpx;
|
|
line-height: 80rpx;
|
|
font-size: 32rpx;
|
|
font-weight: 600;
|
|
border-radius: 48rpx;
|
|
background: #fff;
|
|
color: #4a90e2;
|
|
border: 1rpx solid #4a90e2;
|
|
transition: all 0.3s ease;
|
|
padding: 0 48rpx;
|
|
}
|
|
|
|
.btn-secondary:hover {
|
|
background: rgba(74, 144, 226, 0.05);
|
|
transform: translateY(-2rpx);
|
|
}
|
|
|