/* 分页样式 */

#pagi {
    text-align: center;
    margin: 20px 0;
}

#pagi a,
#pagi b {
    border-radius: 10px;
    display: inline-block;
    padding: 5px 10px;
    margin: 0 5px;
    border: 1px solid #ddd;
    text-decoration: none;
}

#pagi a:hover {
    background-color: #f5f5f5;
}

.zit {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
}

.carousel-container {
    position: relative;
    width: 100%;
    margin-bottom: 20px;
    /* max-width: 958px; */
    /* margin: 50px auto; */
    overflow: hidden;
}

.carousel-wrapper {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.carousel-slide {
    min-width: 100%;
    height: 360px;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 导航按钮样式 */
.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 16px;
    cursor: pointer;
    border: none;
    font-size: 18px;
    transition: background-color 0.3s;
}

.carousel-nav:hover {
    background: rgba(0, 0, 0, 0.8);
}

.carousel-prev {
    left: 10px;
}

.carousel-next {
    right: 10px;
}

/* 指示器样式 */
.carousel-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s;
}

.indicator.active {
    background: white;
}

/* 响应式设计 */
@media (max-width: 600px) {
    .carousel-slide {
        height: 250px;
    }

    .carousel-nav {
        padding: 12px;
        font-size: 14px;
    }
}

/* 相关推荐 */
.recommendations {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.section-title {
    font-size: 24px;
    color: #333;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e0e0e0;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 60px;
    height: 2px;
    background-color: #4CAF50;
}

.recommendations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.recommendation-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.recommendation-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.recommendation-card:hover .card-image {
    transform: scale(1.05);
}

.card-content {
    padding: 15px;
}

.card-tag {
    display: inline-block;
    padding: 4px 8px;
    background-color: #e8f5e9;
    color: #4CAF50;
    border-radius: 4px;
    font-size: 12px;
    margin-bottom: 10px;
}

.card-title {
    font-size: 18px;
    color: #333;
    margin-bottom: 8px;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #999;
    font-size: 13px;
}

.card-author {
    display: flex;
    align-items: center;
    gap: 8px;
}

.author-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.reading-time {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .recommendations-grid {
        grid-template-columns: 1fr;
    }
}

/* 上一章文章下一章文章导航 */
.article-nav {
    display: flex;
    justify-content: space-between;
    /* margin: 40px 0; */
    padding: 20px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.nav-item {
    flex: 1;
    display: flex;
    align-items: center;
    padding: 0 20px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-item:hover {
    color: #1890ff;
}

.nav-item::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: #1890ff;
    transition: width 0.3s ease;
}

.nav-item:hover::before {
    width: 100%;
}

.nav-item.prev {
    text-align: left;
}

.nav-item.next {
    text-align: right;
    flex-direction: row-reverse;
}

.nav-icon {
    font-size: 24px;
    margin: 0 15px;
    color: #999;
    transition: transform 0.3s ease;
}

.nav-item:hover .nav-icon {
    transform: translateX(-5px);
}

.nav-item.next:hover .nav-icon {
    transform: translateX(5px);
}

.nav-content {
    flex: 1;
}

.nav-label {
    font-size: 14px;
    color: #999;
    margin-bottom: 5px;
}

.nav-title {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}


/* 响应式设计 */
@media (max-width: 768px) {
    .article-nav {
        flex-direction: column;
        gap: 20px;
    }

    .nav-item {
        width: 100%;
    }

    .nav-item.next {
        flex-direction: row;
    }

    .nav-icon {
        margin: 0 10px;
    }
}

/* 添加一些动画效果 */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.article-nav {
    animation: slideIn 0.5s ease;
}

/* 搜索结果页面样式 */
.search-page {
    background-color: #f9f9f9;
}

.page-header {
    background-color: #fff;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.page-header h1 {
    font-size: 24px;
    color: #333;
    margin: 0 0 10px 0;
    border-bottom: 2px solid #007bff;
    padding-bottom: 10px;
    display: inline-block;
}

.search-keywords {
    font-size: 16px;
    color: #666;
    margin: 0;
    padding: 5px 0;
}

.no-results {
    background-color: #fff;
    padding: 30px;
    text-align: center;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.no-results p {
    font-size: 16px;
    color: #666;
    margin: 0;
}

.post_list {
    background-color: #fff;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post_list:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.post_list h2 {
    padding: 15px 20px 0;
    margin: 0;
}

.post_list h2 a {
    color: #333;
    text-decoration: none;
    font-size: 20px;
    font-weight: 600;
    transition: color 0.3s ease;
}

.post_list h2 a:hover {
    color: #007bff;
}

.post_list .excerpt {
    padding: 15px 20px;
}

.post_list .meta {
    margin-bottom: 15px;
    font-size: 13px;
    color: #999;
}

.post_list .meta span {
    margin-right: 15px;
}

.post_list .meta a {
    color: #999;
    text-decoration: none;
    transition: color 0.3s ease;
}

.post_list .meta a:hover {
    color: #007bff;
}

.post_list .content_text {
    display: flex;
}

.post_list .content_text p {
    flex: 1;
    margin: 0;
    line-height: 1.6;
    color: #555;
}

.post-image2 {
    margin-right: 15px;
    flex-shrink: 0;
}

.post-image2 img {
    border-radius: 4px;
    transition: transform 0.3s ease;
}

.post-image2:hover img {
    transform: scale(1.05);
}