/* 轮播图容器样式 */
.banner-container {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

/* 轮播图包装器 */
.banner-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    transition: transform 0.5s ease;
}

/* 轮播图项目 */
.banner-item {
    position: relative;
    /* 改为relative而不是absolute */
    flex: 0 0 100%;
    /* 每个项目占据100%宽度 */
    width: 100%;
    height: 100%;
    opacity: 1;
    /* 保持透明度为1 */
    transition: all 0.5s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
    /* 始终显示 */
}

/* 轮播图图片 */
.banner-item img {
    width: 90%;
    height: 90%;
    object-fit: cover;
    display: block;
}

/* 轮播图标题 */
.banner-title {
    position: absolute;
    bottom: 20px;
    left: 20px;
    color: #fff;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 14px;
}

/* 分页指示器容器 */
.banner-pagination {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

/* 分页指示器项目 */
.banner-pagination-bullet {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s;
}

.banner-pagination-bullet.active {
    background-color: #ffffff;
}

/* 前进后退按钮 */
.banner-buttons {
    position: absolute;
    top: 50%;
    width: 100%;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    pointer-events: none;
    opacity: 0; /* 默认隐藏 */
    transition: opacity 0.3s ease; /* 添加过渡动画 */
}

.banner-buttons.visible {
    opacity: 1; /* 显示状态 */
}

.banner-button-prev,
.banner-button-next {
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.3);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 50%;
    font-size: 20px;
    pointer-events: auto;
    transition: background-color 0.3s;
}

.banner-button-prev:hover,
.banner-button-next:hover {
    background-color: rgba(0, 0, 0, 0.6);
}

@media (hover: none) {
    .banner-buttons {
        opacity: 1;
    }
}

@media (max-width: 480px) {
    .banner-title {
        font-size: 12px;
        bottom: 14px;
        left: 14px;
    }

    .banner-button-prev,
    .banner-button-next {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
}