/**
 * 自适应轮播图样式（PC/H5 通用）
 * 目标：在任意分辨率下完整展示图片，同时兼容顶部固定导航
 */

:root {
    --banner-max-height: 760px;
    --banner-dynamic-height: 760px;
}

@media (max-width: 1600px) {
    :root {
        --banner-max-height: 640px;
    }
}

@media (max-width: 1200px) {
    :root {
        --banner-max-height: 560px;
    }
}

@media (max-width: 1024px) {
    :root {
        --banner-max-height: 480px;
    }
}

@media (max-width: 768px) {
    :root {
        --banner-max-height: 420px;
    }
}

@media (max-width: 576px) {
    :root {
        --banner-max-height: 360px;
    }
}

/* ==================== 布局容器 ==================== */
.page-layout {
    display: grid;
    grid-template-rows: auto 1fr;
    min-height: 100vh;
    width: 100%;
}

.header-section {
    grid-row: 1;
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.main-content {
    grid-row: 2;
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* ==================== 轮播容器 ==================== */
.banner-section {
    position: relative;
    width: 100%;
    background: #fff;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.banner-section .banner-inner {
    position: relative;
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    padding: 0;
}

.main-banner {
    position: relative !important;
    width: 100% !important;
    height: auto !important;
    z-index: 10 !important;
}

.main-banner .swiper-wrapper {
    width: 100%;
}

.main-banner .swiper-slide {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #fff;
    padding: 0;
}

.main-banner .swiper-slide img {
    width: 100% !important;
    height: auto !important;
    max-height: var(--banner-dynamic-height, var(--banner-max-height));
    object-fit: contain !important;
    object-position: center center !important;
    display: block !important;
}

/* ==================== 分页器 ==================== */
.main-banner .swiper-pagination {
    bottom: 30px !important;
    z-index: 20 !important;
    display: flex !important;
    justify-content: center !important;
    gap: 10px !important;
}

.main-banner .swiper-pagination-bullet {
    width: 14px !important;
    height: 14px !important;
    background: rgba(0, 0, 0, 0.25) !important;
    opacity: 1 !important;
    border-radius: 50% !important;
    transition: all 0.3s ease !important;
    cursor: pointer !important;
}

.main-banner .swiper-pagination-bullet-active {
    background: #0055a2 !important;
    transform: scale(1.15) !important;
    box-shadow: 0 0 10px rgba(0, 85, 162, 0.35) !important;
}

@media (max-width: 768px) {
    .main-banner .swiper-pagination {
        bottom: 20px !important;
    }

    .main-banner .swiper-pagination-bullet {
        width: 10px !important;
        height: 10px !important;
    }
}

/* ==================== 内容分区兼容 ==================== */
.content-sections {
    display: flex;
    flex-direction: column;
    width: 100%;
    background: #fff;
}

.content-section {
    width: 100%;
    padding: 60px 0;
}

@media (max-width: 768px) {
    .content-section {
        padding: 40px 0;
    }
}

.main-banner .swiper-wrapper,
.main-banner .swiper-slide,
.main-banner .swiper-slide img {
    transition: height 0.3s ease;
}

/* 焦点可访问性 */
.main-banner .swiper-pagination-bullet {
    outline: none;
}

.main-banner .swiper-pagination-bullet:focus {
    box-shadow: 0 0 0 3px rgba(0, 85, 162, 0.35) !important;
}
