/* swiper-style.css - 轮播图优化样式 */

/* ============================================
   轮播图容器 - 添加圆角效果
   ============================================ */
.swiper {
    width: 100%;
    height: auto;
    border-radius: 1rem;
    overflow: hidden;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 确保所有子元素也继承圆角 */
.swiper-wrapper,
.swiper-slide,
.carousel-img {
    border-radius: inherit;
}

/* ============================================
   轮播图图片样式
   ============================================ */
.carousel-img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
    border-radius: inherit;
}

/* 固定图片高度，保持比例一致 */
@media (min-width: 1400px) {
    .carousel-img {
        height: 550px;
    }
}

@media (min-width: 1200px) and (max-width: 1399px) {
    .carousel-img {
        height: 500px;
    }
}

@media (min-width: 992px) and (max-width: 1199px) {
    .carousel-img {
        height: 450px;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .carousel-img {
        height: 400px;
    }
}

@media (max-width: 767px) {
    .carousel-img {
        height: 280px;
    }
}

/* ============================================
   轮播图样式
   ============================================ */

/* 文字容器 */
.carousel-caption {
    position: absolute;
    bottom: 25%;
    left: 10%;
    right: auto;
    text-align: left;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
    max-width: 500px;
    z-index: 10;
}

/* 主标题：大、粗 */
.carousel-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 16px;
    line-height: 1.2;
}

/* 副标题：中 */
.carousel-subtitle {
    font-size: 24px;
    font-weight: 400;
    margin-bottom: 12px;
    opacity: 0.95;
    line-height: 1.3;
}

/* 补充说明：小、浅色 */
.carousel-extra {
    font-size: 16px;
    font-weight: 300;
    margin-bottom: 24px;
    opacity: 0.8;
    line-height: 1.4;
}

/* 按钮 */
.carousel-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background-color: #4a90e2;
    color: #fff;
    text-decoration: none;
    border-radius: 40px;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.carousel-btn:hover {
    background-color: #357abd;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    color: #fff;
    text-decoration: none;
}

.carousel-btn i {
    font-size: 14px;
    transition: transform 0.3s ease;
}

.carousel-btn:hover i {
    transform: translateX(4px);
}

/* ============================================
   轮播图控制按钮（左右箭头）- 稍微内移避免被圆角遮挡
   ============================================ */
.swiper-button-next,
.swiper-button-prev {
    width: 44px;
    height: 44px;
    background-color: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    border-radius: 50%;
    transition: all 0.3s ease;
    margin: 0 15px;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    background-color: rgba(0, 0, 0, 0.6);
    transform: scale(1.1);
}

.swiper-button-next::after,
.swiper-button-prev::after {
    font-size: 18px;
    font-weight: bold;
    color: white;
}

/* ============================================
   轮播图分页器
   ============================================ */
.swiper-pagination {
    bottom: 20px !important;
}

.swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    background-color: rgba(255, 255, 255, 0.6);
    opacity: 1;
    transition: all 0.3s ease;
}

.swiper-pagination-bullet-active {
    background-color: #ff3860;
    width: 24px;
    border-radius: 5px;
}

/* ============================================
   移动端适配
   ============================================ */

@media (max-width: 768px) {
    .carousel-caption {
        bottom: 15%;
        left: 5%;
        right: 5%;
        max-width: none;
    }

    .carousel-title {
        font-size: 28px;
        margin-bottom: 8px;
    }

    .carousel-subtitle {
        font-size: 18px;
        margin-bottom: 8px;
    }

    .carousel-extra {
        font-size: 14px;
        margin-bottom: 16px;
    }

    .carousel-btn {
        padding: 8px 20px;
        font-size: 14px;
    }

    .swiper-button-next,
    .swiper-button-prev {
        width: 32px;
        height: 32px;
        margin: 0 8px;
    }

    .swiper-button-next::after,
    .swiper-button-prev::after {
        font-size: 14px;
    }

    .swiper-pagination-bullet {
        width: 6px;
        height: 6px;
    }

    .swiper-pagination-bullet-active {
        width: 16px;
    }
}

@media (max-width: 480px) {
    .carousel-caption {
        bottom: 10%;
    }

    .carousel-title {
        font-size: 22px;
    }

    .carousel-subtitle {
        font-size: 14px;
    }

    .carousel-extra {
        font-size: 12px;
        margin-bottom: 12px;
    }

    .carousel-btn {
        padding: 6px 16px;
        font-size: 12px;
    }

    .swiper-button-next,
    .swiper-button-prev {
        width: 28px;
        height: 28px;
        margin: 0 5px;
    }

    .swiper-button-next::after,
    .swiper-button-prev::after {
        font-size: 12px;
    }
}




