<style>
/* 通用样式 */
.xichen-layout {
    margin-bottom: 40px;
    padding: 0;
    border: none;
    background: none;
    box-shadow: none;
}

/* 标题样式 */
.xichen-decorated-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 25px;
}

.xichen-title-text {
    font-size: 2.2rem;
    font-weight: 700;
    color: #333;
    margin: 0;
    padding: 10px 0;
    text-align: center;
}

.xichen-title-divider {
    flex: 1;
    height: 2px;
    background-color: #3B82F6;
    position: relative;
    max-width: 150px;
}

.xichen-title-divider::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #3B82F6;
}

.xichen-title-divider.xichen-right::after {
    left: auto;
    right: 0;
}

/* 第一个布局样式 - 修复图片切换功能 */
.xichen-layout-1-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    justify-content: center; /* 缩放时左右区域整体居中 */
}

@media (min-width: 768px) {
    .xichen-layout-1-container {
        flex-direction: row;
    }
}

/* 图片容器 - 基础样式与布局控制 */
.xichen-image-container {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    min-height: 200px; /* 基础最小高度 */
    flex: 1; /* 自适应宽度分配 */
      /* 确保容器自身在父元素中居中 */
    margin: 0 auto;   
}

/* 主图片样式与过渡效果 */
.xichen-main-image {
    width: auto;
    height: auto;
    max-width: 100%; /* 不超过容器宽度 */
    max-height: 100%; /* 不超过容器高度 */
    object-fit: cover;
    display: inline-block;
    opacity: 1 !important; /* 默认可见 */
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1); /* 平滑过渡 */
}

/* 悬停图片样式与初始状态 */
.xichen-hover-image {
    position: absolute;
    top: 50%; /* 垂直居中 */
    left: 50%; /* 水平居中 */
    width: auto;
    height: auto;
    max-width: 100%; /* 不超过容器 */
    max-height: 100%; /* 不超过容器 */
    object-fit: cover;
    opacity: 0 !important; /* 默认隐藏 */
    transform: scale(1.05); /* 初始轻微放大 */
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1); /* 平滑过渡 */
    z-index: 1; /* 确保在主图片上方 */
}

/* 鼠标悬停切换效果 */
/*.xichen-image-container:hover > .xichen-hover-image {*/
    opacity: 1 !important; /* 悬停图片显示 */
    transform: translate(-50%, -50%) scale(1); /* 恢复正常大小 */
/*}*/
/*.xichen-image-container:hover > .xichen-main-image {*/
    opacity: 0 !important; /* 主图片隐藏 */
    transform: scale(1.1); /* 主图片放大 */
/*}*/

/* 左侧大图容器尺寸 */
.xichen-layout-1-container > .xichen-image-container {
    flex: 1;
    min-height: 100px;
    height: 400px; /* 固定高度 */
}

/* 右侧图片容器布局 */
.xichen-right-images {
    display: flex;
    flex-direction: column;
    gap: 20px; /* 右侧上下图片间距 */
    flex: 1; /* 与左侧平分宽度 */
    height: 400px; /* 总高度与左侧一致 */
    align-items: center; /* 右侧容器内图片居中对齐 */
}

/* 右侧单个图片容器尺寸 */
.xichen-right-images .xichen-image-container {
    flex: 1; /* 上下图片平分右侧高度 */
    min-height: 40px; /* 最小高度限制 */
    width: 100%; /* 占满右侧容器宽度，确保居中范围 */
}
/* 第二个布局样式 */
.xichen-tab-container {
    width: 100%;
}

.xichen-tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.xichen-tab {
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #f0f0f0;
    color: #666;
    font-weight: 500;
}

.xichen-tab.xichen-active {
    background-color: #3B82F6;
    color: white;
}

.xichen-tab:hover:not(.xichen-active) {
    background-color: #e0e0e0;
}

.xichen-tab-content {
    text-align: center;
}

.xichen-tab-pane {
    display: none;
}

.xichen-tab-pane.xichen-active {
    display: block;
    animation: xichenFadeIn 0.5s ease;
}

.xichen-tab-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* 第三个布局样式 */
.xichen-layout-1,
.xichen-full-image-container {
  /* 限制最大宽度，避免过宽 */
  max-width: 1400px; /* 根据设计调整，统一整体布局宽度 */
  margin: 0 auto; /* 核心：整体容器水平居中 */
  padding: 0 15px; /* 左右留白，避免缩小时贴边 */
}

.xichen-full-image {
    width: 100%;
    max-width: 1000px; /* 关键：限制图片最大宽度（根据需求调整） */
    height: auto; /* 等比例缩放 */
    border-radius: 8px;
    display: block;
    margin: 0 auto; /* 可选：让图片在容器中居中 */
}


/* 第五个布局样式 */
.xichen-layered-container {
    width: 100%;
}

.xichen-upper-layer {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
}

@media (min-width: 768px) {
    .xichen-upper-layer {
        flex-direction: row;
    }
}

.xichen-upper-col {
    flex: 1;
    border-radius: 8px;
    overflow: hidden;
}

.xichen-lower-layer {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

@media (min-width: 640px) {
    .xichen-lower-layer {
        flex-direction: row;
        flex-wrap: wrap;
    }
    .xichen-lower-col {
        flex: 1 0 45%;
    }
}

@media (min-width: 1024px) {
    .xichen-lower-layer {
        flex-wrap: nowrap;
    }
    .xichen-lower-col {
        flex: 1;
    }
}

.xichen-layer-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.xichen-upper-col .xichen-layer-image {
    height: 240px;
}

.xichen-lower-col .xichen-layer-image {
    height: 180px;
}

/* 动画 */
@keyframes xichenFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
/* 轮播图容器样式 */
.carousel-container {
    position: relative;
    width: 96%;
    max-width: 1600px;
    margin: 0 auto;
    overflow: hidden;
    padding: 20px 0;
}

/* 轮播内容包装器 */
.carousel-wrapper {
    overflow: hidden;
}

/* 轮播轨道样式 */
#carouselTrack {
    display: flex;
    transition: transform 0.5s ease-out;
    will-change: transform;
}

/* 轮播项样式 */
.carousel-item {
    min-width: 20%; /* 5个图片平分宽度 */
    padding: 0 10px;
    box-sizing: border-box;
}

/* 图片样式 */
.carousel-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    display: block;
}

/* 箭头按钮样式 */
.carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    font-size: 20px;
    font-weight: bold;
    color: #333;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    z-index: 10;
    transition: all 0.3s ease;
}

.carousel-arrow:hover {
    background-color: white;
    transform: translateY(-50%) scale(1.1);
}

.prev-arrow {
    left: 10px;
}

.next-arrow {
    right: 10px;
}

/* 指示器样式 */
.indicators {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 15px;
}

.indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #ddd;
    cursor: pointer;
    transition: all 0.3s ease;
}

.indicator.active {
    background-color: #555;
    width: 30px;
    border-radius: 5px;
}

/* 拖拽时的样式 */
.grabbing {
    cursor: grabbing;
}

.grabbing img {
    pointer-events: none;
}
    
</style>
    