/* 首页样式 */

/* 轮播图 */
.banner-section {
    margin-top: 50px;
    padding: 10px;
}

.swiper-container {
    width: 100%;
    height: 150px;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

.swiper-wrapper {
    display: flex;
    transition: transform 0.3s ease;
}

.swiper-slide {
    width: 100%;
    height: 100%;
}

.swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.swiper-pagination {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 5px;
}

.swiper-pagination-bullet {
    width: 6px;
    height: 6px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
}

.swiper-pagination-bullet-active {
    background-color: #fff;
}

/* 分类导航 */
.category-nav {
    background-color: #fff;
    padding: 15px;
    margin: 10px;
    border-radius: 8px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
}

.category-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    cursor: pointer;
}

.category-item img {
    width: 40px;
    height: 40px;
    margin-bottom: 5px;
}

.category-item span {
    font-size: 12px;
    color: #333;
}

/* 限时抢购 */
.flash-sale {
    background-color: #fff;
    margin: 10px;
    border-radius: 8px;
}

.flash-sale .section-title {
    display: flex;
    align-items: center;
}

.countdown {
    margin-left: 10px;
    padding: 3px 8px;
    background-color: #FF5722;
    color: #fff;
    font-size: 12px;
    border-radius: 3px;
}

.flash-scroll {
    overflow-x: auto;
    white-space: nowrap;
    padding: 0 15px 15px;
}

.flash-list {
    display: inline-flex;
    gap: 10px;
}

.flash-item {
    display: inline-block;
    width: 100px;
    cursor: pointer;
}

.flash-item img {
    width: 100px;
    height: 100px;
    border-radius: 4px;
    object-fit: cover;
}

.flash-info {
    padding: 8px 0;
}

.flash-name {
    font-size: 12px;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.flash-price {
    display: flex;
    align-items: baseline;
    margin-top: 5px;
}

.flash-progress {
    margin-top: 5px;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background-color: #FFE0E0;
    border-radius: 2px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: #FF5722;
}

.progress-text {
    font-size: 10px;
    color: #999;
    margin-top: 2px;
}

/* 推荐商品 */
.recommend-section {
    background-color: #fff;
    margin: 10px;
    border-radius: 8px;
    padding-bottom: 15px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 0 15px;
}

.product-item {
    cursor: pointer;
}

/* 页面间距 */
.main-content {
    padding-bottom: 60px;
}