/**
 * 文章轮播组件样式
 * 高级文章轮播组件的CSS样式定义
 */

/* 轮播容器 */
.aee-post-carousel {
    position: relative;
    overflow: hidden;
    width: 100%;
}

.aee-post-carousel .swiper-wrapper {
    display: flex;
    align-items: stretch;
}

.aee-post-carousel .swiper-slide {
    height: auto;
    display: flex;
}

/* 文章卡片 - 根据Figma设计稿调整 */
.aee-post-card {
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    height: 409px;
    width: 100%;
}

/* 文章图片 - 根据设计稿调整为全覆盖背景 */
.aee-post-image {
    width: 100%;
    height: 320px;
    overflow: hidden;
    z-index: 1;
    flex-shrink: 0; /* 确保图片不会被压缩 */
}

.aee-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 占位图片样式已移除，现在使用SVG文件 */

/* 文章内容 - 调整为相对定位 */
.aee-post-content {
    position: relative;
    padding: 0;
    display: flex;
    flex-direction: column;
    z-index: 2;
    min-height: 110px; /* 根据设计稿调整 */
}

/* 文章文字包装器 - 包装标题和摘要 */
.aee-post-text-wrapper {
    position: relative;
    padding-top: 15px;
    width: 100%;
    height: 100%;
}

/* 编辑器模式样式 */
.aee-editor-mode .aee-post-title a {
    cursor: default !important;
    pointer-events: none;
}

.aee-editor-mode .aee-post-title span {
    cursor: default;
}

/* 文章标题 - 调整为相对定位 */
.aee-post-title {
    margin: 0 0 8px 0;
    padding-top: 10px;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.5;
    color: #FFFFFF;
    font-family: 'Source Han Sans CN', sans-serif;
    position: relative;
    margin-left: 107px;
    margin-right: 20px;
    max-width: 299px;
    height: 34px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5); /* 添加文字阴影确保可读性 */
    z-index: 2; /* 确保标题在图片上层 */
}

.aee-post-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.aee-post-title a:hover {
    color: rgba(255, 255, 255, 0.8);
}

/* 文章摘要 - 调整为相对定位 */
.aee-post-excerpt {
    margin: 5px 0 0 107px;
    font-size: 14px;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Source Han Sans CN', sans-serif;
    font-weight: 350;
    position: relative;
    max-width: 468px;
    height: 25px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 文章元信息 - 调整日期框定位 */
.aee-post-meta {
    position: absolute;
    top: -24px; /* 调整日期框位置到图片底部附近 */
    left: 14px;
    width: 75px;
    height: 125px;
    background: #E5BF78; /* 根据设计稿的金色背景 */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 3;
}

.aee-post-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #482906; /* 根据设计稿的深棕色文字 */
    font-family: 'Source Han Serif CN', serif;
}

.aee-post-date .day {
    font-size: 30px;
    font-weight: 700;
    line-height: 1.5;
    margin-bottom: 2px;
}

.aee-post-date .month-year {
    font-size: 16px;
    font-weight: 400;
    line-height: 1.5;
}

.aee-post-date:before {
    display: none; /* 移除原有的emoji图标 */
}

/* 导航按钮 */
.aee-post-carousel .swiper-button-next,
.aee-post-carousel .swiper-button-prev {
    width: 44px;
    height: 44px;
    margin-top: -22px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.aee-post-carousel .swiper-button-next:hover,
.aee-post-carousel .swiper-button-prev:hover {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.aee-post-carousel .swiper-button-next:after,
.aee-post-carousel .swiper-button-prev:after {
    font-size: 16px;
    font-weight: 600;
    color: #333333;
}

.aee-post-carousel .swiper-button-next {
    right: 10px;
}

.aee-post-carousel .swiper-button-prev {
    left: 10px;
}

.aee-post-carousel .swiper-button-disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* 分页器 */
.aee-post-carousel .swiper-pagination {
    position: relative;
    bottom: auto;
    left: auto;
    transform: none;
    text-align: center;
    z-index: 10;
    width: 100%;
    margin-top: 15px;
    padding-top: 10px;
}

/* 外部分页器 */
.aee-pagination-external {
    position: relative !important;
    bottom: auto !important;
    left: auto !important;
    transform: none !important;
    width: 100% !important;
    margin-top: 20px;
    padding: 10px 0;
    text-align: center;
}

/* 圆点分页器 */
.aee-post-carousel .swiper-pagination-bullet,
.aee-pagination-external .swiper-pagination-bullet {
    width: 12px;
    height: 12px;
    background: #cccccc;
    opacity: 1;
    margin: 0 4px;
    transition: all 0.3s ease;
    border-radius: 50%;
    display: inline-block;
    cursor: pointer;
}

.aee-post-carousel .swiper-pagination-bullet-active,
.aee-pagination-external .swiper-pagination-bullet-active {
    background: #007cba;
    transform: scale(1.2);
}

/* Elementor样式控制器将在这里应用用户自定义的样式 */

/* 分数分页器 */
.aee-post-carousel .swiper-pagination-fraction,
.aee-pagination-external .swiper-pagination-fraction {
    color: #666666;
    font-size: 14px;
    font-weight: 500;
    line-height: 1;
}

/* Elementor样式控制器将在这里应用分数分页器的用户自定义样式 */

/* 进度条分页器 */
.aee-post-carousel .swiper-pagination-progressbar,
.aee-pagination-external .swiper-pagination-progressbar {
    background: rgba(0, 0, 0, 0.1);
    height: 4px;
    border-radius: 2px;
    position: relative;
    overflow: hidden;
}

.aee-post-carousel .swiper-pagination-progressbar-fill,
.aee-pagination-external .swiper-pagination-progressbar-fill {
    background: #007cba;
    border-radius: 2px;
    height: 100%;
    transition: transform 0.3s ease;
}

/* Elementor样式控制器将在这里应用进度条分页器的用户自定义样式 */

/* 空状态 */
.aee-post-carousel-empty {
    text-align: center;
    padding: 60px 20px;
    color: #666666;
}

.aee-post-carousel-empty p {
    margin: 0;
    font-size: 16px;
}

/* 减少动画模式支持 */
@media (prefers-reduced-motion: reduce) {
    .aee-post-card,
    .aee-post-image img,
    .aee-post-title a,
    .aee-post-carousel .swiper-button-next,
    .aee-post-carousel .swiper-button-prev,
    .aee-post-carousel .swiper-pagination-bullet {
        transition: none;
    }
    
    .aee-post-card:hover {
        transform: none;
    }
    
    .aee-post-card:hover .aee-post-image img {
        transform: none;
    }
}