.banner-carousel {
    position: relative;
    overflow: hidden;
    margin: 0 auto;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.banner-carousel img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.5s ease-in-out;
}

.banner-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    /* 关键修复：隐藏时禁用点击事件 */
    pointer-events: none;
}

.banner-item.active {
    opacity: 1;
    /* 关键修复：显示时启用点击事件 */
    pointer-events: auto;
}

.banner-item:first-child {
    position: relative;
}

/* 移动端样式 */
.mobile-banner {
    display: block;
    width: 350px;
    height: 50px;
}

/* 桌面端样式 */
.desktop-banner {
    display: none;
    width: 700px;
    height: 100px;
}

/* 响应式 */
@media (min-width: 1024px) {
    .mobile-banner {
        display: none;
    }
    .desktop-banner {
        display: block;
    }
}

/* 轮播指示器 */
.carousel-indicators {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.indicator:hover {
    background: rgba(255, 255, 255, 0.7);
    transform: scale(1.2);
}

.indicator.active {
    background: rgba(255, 255, 255, 0.9);
    transform: scale(1.1);
}

/* 左右切换按钮 */
.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    opacity: 0;
}

.banner-carousel:hover .carousel-nav {
    opacity: 1;
}

.carousel-nav:hover {
    background: rgba(0, 0, 0, 0.7);
    transform: translateY(-50%) scale(1.1);
}

.carousel-prev {
    left: 10px;
}

.carousel-next {
    right: 10px;
}

/* 加载状态 */
.banner-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
    color: #666;
}