index.less 3.76 KB
/* 特价好车页面样式 */
.good-car-list {
  width: 100%;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* 车辆卡片样式 */
.good-car-list .bg-white {
  background-color: #ffffff;
  border: 1px solid #f0f0f0;
  transition: all 0.3s ease;
}

.good-car-list .bg-white:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 图片容器 */
.good-car-list .w-32 {
  width: 200rpx;
  height: 150rpx;
  flex-shrink: 0;
}

.good-car-list image {
  border-radius: 8rpx;
  object-fit: cover;
}

/* 信息区域 */
.good-car-list .flex-1 {
  flex: 1;
  min-width: 0;
}

/* 价格样式 */
.good-car-list .text-orange-500 {
  color: #f97316;
  font-weight: bold;
}

.good-car-list .line-through {
  text-decoration: line-through;
}

/* 特价标签 */
.good-car-list .text-red-600 {
  color: #dc2626;
  font-weight: 500;
}

/* 折扣标签 */
.good-car-list .bg-red-500 {
  background-color: #ef4444;
  padding: 2rpx 6rpx;
  border-radius: 4rpx;
  font-size: 20rpx;
  line-height: 1;
}

/* 加载状态 */
.loading-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 32rpx 0 100rpx 0;
}

.loading-text {
  color: #9ca3af;
  font-size: 28rpx;
}

/* 无更多数据提示 */
.no-more-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 32rpx 0 100rpx 0;
}

.no-more-container text {
  color: #9ca3af;
  font-size: 24rpx;
}

/* NutUI 组件样式覆盖 */
:deep(.nut-menu) {
  background-color: #ffffff;
  border-bottom: 1px solid #f0f0f0;
}

:deep(.nut-menu-item) {
  color: #333333;
  font-size: 28rpx;
}

:deep(.nut-menu-item.active) {
  color: #f97316;
}

// .nut-searchbar{
//   background: transparent !important;
// }

// :deep(.nut-searchbar .nut-searchbar__input-inner) {
//   background-color: #ffffff;
//   border-radius: 20rpx;
//   font-size: 28rpx;
// }

:deep(.nut-sticky) {
  z-index: 999;
}

/* 响应式适配 */
@media screen and (max-width: 750rpx) {
  .good-car-list .w-32 {
    width: 180rpx;
    height: 135rpx;
  }

  .good-car-list .text-xl {
    font-size: 32rpx;
  }

  .good-car-list .text-sm {
    font-size: 24rpx;
  }

  .good-car-list .text-xs {
    font-size: 20rpx;
  }
}

/* 深色模式适配 */
@media (prefers-color-scheme: dark) {
  .good-car-list .bg-white {
    background-color: #1f2937;
    border-color: #374151;
  }

  .good-car-list .text-gray-600 {
    color: #9ca3af;
  }

  .good-car-list .text-gray-500 {
    color: #6b7280;
  }

  .good-car-list .text-gray-400 {
    color: #9ca3af;
  }
}

/* 动画效果 */
.good-car-list .bg-white {
  animation: fadeInUp 0.3s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20rpx);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 收藏按钮动画 */
.good-car-list .absolute {
  transition: transform 0.2s ease;
}

.good-car-list .absolute:active {
  transform: scale(0.9);
}

/* 卡片点击效果 */
.good-car-list .bg-white:active {
  transform: scale(0.98);
  transition: transform 0.1s ease;
}

/* 滚动条样式 */
.good-car-list::-webkit-scrollbar {
  width: 0;
  background: transparent;
}

/* 特价标识样式优化 */
.good-car-list .absolute.bottom-3.right-3 {
  background: linear-gradient(45deg, #ef4444, #dc2626);
  box-shadow: 0 2rpx 4rpx rgba(239, 68, 68, 0.3);
}

.good-car-list .absolute.top-3.left-3 {
  background: linear-gradient(45deg, #ef4444, #dc2626);
  box-shadow: 0 2rpx 4rpx rgba(239, 68, 68, 0.3);
}

/* 价格区域样式优化 */
.good-car-list .flex.items-center {
  align-items: baseline;
  gap: 8rpx;
}

/* 文字省略 */
.good-car-list .font-medium {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

/* 间距调整 */
.good-car-list .space-y-4 > * + * {
  margin-top: 16rpx;
}

.good-car-list .mb-3 {
  margin-bottom: 12rpx;
}