/* 博客头部样式 */
.blog-header {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('../images/blog-bg.png');
    background-size: cover;
    background-position: center;
    padding: 8rem 2rem;
    text-align: center;
    color: #fff;
}

.header-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.header-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* 博客分类和搜索 */
.blog-filter {
    padding: 2rem;
    background: #f9f9f9;
    border-bottom: 1px solid #eee;
}

.filter-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.category-filter {
    display: flex;
    gap: 1rem;
}

.filter-btn {
    padding: 0.5rem 1.5rem;
    border: none;
    background: #fff;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    color: #666;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.filter-btn.active,
.filter-btn:hover {
    background: #e67e22;
    color: #fff;
}

.search-box {
    display: flex;
    gap: 0.5rem;
}

.search-box input {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: 25px;
    width: 250px;
    font-size: 1rem;
}

.search-btn {
    padding: 0.5rem 1.5rem;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.search-btn:hover {
    background: #e67e22;
}

/* 博客内容区 */
.blog-content {
    padding: 4rem 2rem;
}

.content-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
}

/* 特色文章 */
.featured-post {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 3rem;
}

.featured-post .post-image {
    height: 400px;
}

.featured-post .post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-post .post-content {
    padding: 2rem;
}

.post-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.post-meta span {
    color: #666;
    font-size: 0.9rem;
}

.post-meta .category {
    color: #e67e22;
}

.featured-post h2 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #333;
}

.featured-post p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.read-more {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: #333;
    color: #fff;
    text-decoration: none;
    border-radius: 25px;
    transition: background 0.3s ease;
}

.read-more:hover {
    background: #e67e22;
}

/* 文章网格 */
.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.post-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.post-card:hover {
    transform: translateY(-5px);
}

.post-card .post-image {
    height: 200px;
}

.post-card .post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-card .post-content {
    padding: 1.5rem;
}

.post-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #333;
}

.post-card p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

/* 加载更多按钮 */
.load-more {
    text-align: center;
    margin-top: 3rem;
}

.btn {
    padding: 0.8rem 2rem;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: background 0.3s ease;
    font-size: 1rem;
}

.btn:hover {
    background: #e67e22;
}

/* 侧边栏 */
.sidebar {
    position: sticky;
    top: 2rem;
}

.widget {
    background: #fff;
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.widget h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #333;
}

/* 关于作者 */
.about-author {
    text-align: center;
}

.author-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin-bottom: 1rem;
}

.about-author p {
    color: #666;
    line-height: 1.6;
}

/* 热门文章 */
.popular-posts ul {
    list-style: none;
}

.popular-posts li {
    margin-bottom: 1rem;
}

.popular-posts li:last-child {
    margin-bottom: 0;
}

.popular-posts a {
    display: flex;
    gap: 1rem;
    text-decoration: none;
    color: inherit;
}

.popular-posts img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 5px;
}

.post-info h4 {
    font-size: 1rem;
    color: #333;
    margin-bottom: 0.5rem;
}

.post-info .date {
    font-size: 0.9rem;
    color: #666;
}

/* 标签云 */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    padding: 0.5rem 1rem;
    background: #f9f9f9;
    border-radius: 25px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
}

.tag:hover {
    background: #e67e22;
    color: #fff;
}

/* 订阅表单 */
.subscribe-form p {
    color: #666;
    margin-bottom: 1rem;
}

.subscribe-form input {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-bottom: 1rem;
}

.subscribe-form button {
    width: 100%;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .content-container {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    .blog-header {
        padding: 6rem 1rem;
    }

    .header-content h1 {
        font-size: 2.5rem;
    }

    .filter-container {
        flex-direction: column;
        align-items: stretch;
    }

    .category-filter {
        overflow-x: auto;
        padding-bottom: 0.5rem;
    }

    .search-box {
        width: 100%;
    }

    .search-box input {
        flex: 1;
    }

    .featured-post .post-image {
        height: 300px;
    }

    .post-grid {
        grid-template-columns: 1fr;
    }
}

/* 动画效果 */
.post-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.post-card.animate {
    opacity: 1;
    transform: translateY(0);
}

.featured-post {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.featured-post.animate {
    opacity: 1;
    transform: translateY(0);
} 