/* 文章列表样式 */
.post-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.post-item {
    display: flex;
    gap: 25px;
    background: white;
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.post-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateX(5px);
}

.post-thumb {
    flex-shrink: 0;
    width: 240px;
    height: 160px;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.post-item:hover .post-thumb img {
    transform: scale(1.05);
}

.post-content {
    flex: 1;
}

.post-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 12px;
}

.post-title a {
    color: var(--text-color);
}

.post-title a:hover {
    color: var(--primary-color);
}

.post-excerpt {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    font-size: 13px;
    color: var(--text-muted);
}

.post-meta-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.post-meta-item i {
    font-size: 12px;
}

.post-category {
    display: inline-block;
    padding: 4px 12px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: white;
    font-size: 12px;
    border-radius: 20px;
}

/* 文章详情 */
.post-detail,
.article-detail {
    background: white;
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow-sm);
}

.post-header,
.article-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
}

.post-detail-title,
.article-title {
    font-size: 32px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 20px;
}

.post-detail-meta,
.article-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 25px;
    flex-wrap: wrap;
}

.post-detail-meta .post-meta-item,
.article-meta span {
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    color: var(--text-muted);
}

.article-author {
    color: var(--primary-color) !important;
    font-weight: 500;
}

.article-category a {
    color: var(--primary-color);
}

.article-content {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-color);
}

.article-content h2 {
    font-size: 24px;
    margin: 35px 0 15px;
    color: var(--text-color);
}

.article-content h3 {
    font-size: 20px;
    margin: 30px 0 12px;
    color: var(--text-color);
}

.article-content p {
    margin-bottom: 20px;
}

.article-content img {
    max-width: 100%;
    border-radius: var(--radius-md);
    margin: 20px 0;
}

.article-content ul,
.article-content ol {
    margin: 20px 0;
    padding-left: 25px;
}

.article-content li {
    margin-bottom: 10px;
}

.article-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding: 15px 20px;
    margin: 25px 0;
    background: var(--bg-light);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    color: var(--text-light);
}

.article-footer {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid var(--border-color);
}

.article-tags {
    margin-bottom: 20px;
}

.article-tags strong,
.article-share strong {
    font-weight: 600;
    margin-right: 10px;
}

.article-share {
    display: flex;
    align-items: center;
    gap: 10px;
}

.share-btn {
    display: inline-block;
    padding: 6px 16px;
    background: var(--bg-light);
    color: var(--text-color);
    font-size: 13px;
    border-radius: 20px;
    transition: var(--transition);
}

.share-btn:hover {
    background: var(--primary-color);
    color: white;
}

/* 文章导航 */
.article-navigation {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 40px;
}

.nav-prev,
.nav-next {
    flex: 1;
}

.nav-link {
    display: block;
    padding: 20px;
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.nav-link:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.nav-label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.nav-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-color);
}

/* 相关文章 */
.related-posts {
    margin-top: 40px;
    background: white;
    border-radius: var(--radius-lg);
    padding: 30px;
    box-shadow: var(--shadow-sm);
}

.related-posts h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 25px;
    color: var(--text-color);
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.related-post {
    text-align: center;
}

.related-post img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: var(--radius-md);
    margin-bottom: 12px;
    transition: var(--transition);
}

.related-post:hover img {
    transform: scale(1.05);
}

.related-post h4 {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    color: var(--text-color);
}

.related-post:hover h4 {
    color: var(--primary-color);
}

/* 侧边栏作者信息 */
.widget-author {
    text-align: center;
}

.author-avatar {
    width: 100px;
    height: 100px;
    margin: 0 auto 15px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--bg-light);
}

.author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.author-name {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-color);
}

.author-desc {
    font-size: 14px;
    color: var(--text-light);
    line-height: 1.6;
}

/* 移动端文章详情 */
.mobile-article-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    background: white;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 100;
}

.back-btn,
.mobile-article-header .share-btn {
    padding: 8px 12px;
    background: var(--bg-light);
    border: none;
    border-radius: var(--radius-md);
    font-size: 16px;
    cursor: pointer;
}

.mobile-article-header h1 {
    font-size: 18px;
    font-weight: 600;
}

.mobile-article {
    padding: 20px;
}

.article-title-bar {
    margin-bottom: 20px;
}

.article-title-bar .article-title {
    font-size: 22px;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 15px;
}

.article-title-bar .article-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 13px;
    color: var(--text-muted);
}

.article-title-bar .article-meta .author {
    color: var(--primary-color);
    font-weight: 500;
}

.mobile-article-nav {
    padding: 20px;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.mobile-article-nav .nav-item {
    display: block;
    padding: 15px;
    margin-bottom: 10px;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.mobile-article-nav .nav-item:last-child {
    margin-bottom: 0;
}

.mobile-article-nav .nav-label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.mobile-article-nav .nav-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-color);
}

.mobile-related-posts {
    padding: 20px;
}

.mobile-related-posts h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
}

.related-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.related-item {
    display: flex;
    gap: 15px;
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.related-thumb {
    flex-shrink: 0;
    width: 100px;
    height: 75px;
}

.related-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-info {
    flex: 1;
    padding: 10px 10px 10px 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.related-info h4 {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    margin-bottom: 5px;
}

.related-date {
    font-size: 12px;
    color: var(--text-muted);
}

.post-cover {
    margin: 30px 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.post-cover img {
    width: 100%;
}

.post-body {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-color);
}

.post-body h2 {
    font-size: 24px;
    margin: 35px 0 15px;
    color: var(--text-color);
}

.post-body h3 {
    font-size: 20px;
    margin: 30px 0 12px;
    color: var(--text-color);
}

.post-body p {
    margin-bottom: 20px;
}

.post-body img {
    max-width: 100%;
    border-radius: var(--radius-md);
    margin: 20px 0;
}

.post-body ul,
.post-body ol {
    margin: 20px 0;
    padding-left: 25px;
}

.post-body li {
    margin-bottom: 10px;
}

.post-body blockquote {
    border-left: 4px solid var(--primary-color);
    padding: 15px 20px;
    margin: 25px 0;
    background: var(--bg-light);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    color: var(--text-light);
}

.post-tags {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid var(--border-color);
}

.post-tags-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--text-color);
}

.tag {
    display: inline-block;
    padding: 6px 16px;
    background: var(--bg-light);
    color: var(--text-light);
    font-size: 13px;
    border-radius: 20px;
    margin-right: 10px;
    margin-bottom: 10px;
    transition: var(--transition);
}

.tag:hover {
    background: var(--primary-color);
    color: white;
}

/* 侧边栏 */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.widget {
    background: white;
    border-radius: var(--radius-lg);
    padding: 25px;
    box-shadow: var(--shadow-sm);
}

.widget-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--primary-color);
}

/* 搜索 */
.search-form {
    display: flex;
    gap: 10px;
}

.search-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
}

.search-btn {
    padding: 12px 24px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
}

.search-btn:hover {
    background: var(--primary-dark);
}

/* 热门文章 */
.hot-post-list {
    list-style: none;
}

.hot-post-item {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.hot-post-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.hot-post-thumb {
    flex-shrink: 0;
    width: 80px;
    height: 60px;
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.hot-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hot-post-content {
    flex: 1;
}

.hot-post-title {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    margin-bottom: 5px;
}

.hot-post-title a {
    color: var(--text-color);
}

.hot-post-title a:hover {
    color: var(--primary-color);
}

.hot-post-date {
    font-size: 12px;
    color: var(--text-muted);
}

/* 分类 */
.category-list {
    list-style: none;
}

.category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.category-item:last-child {
    border-bottom: none;
}

.category-item a {
    color: var(--text-color);
    font-size: 14px;
}

.category-item a:hover {
    color: var(--primary-color);
}

.category-count {
    background: var(--bg-light);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 12px;
    color: var(--text-muted);
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 40px;
}

.pagination a,
.pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border-radius: var(--radius-md);
    font-size: 14px;
    transition: var(--transition);
}

.pagination a {
    background: white;
    color: var(--text-color);
    box-shadow: var(--shadow-sm);
}

.pagination a:hover {
    background: var(--primary-color);
    color: white;
}

.pagination .current {
    background: var(--primary-color);
    color: white;
}

/* 响应式 */
@media (max-width: 768px) {
    .post-item {
        flex-direction: column;
    }
    
    .post-thumb {
        width: 100%;
        height: 200px;
    }
    
    .post-detail,
    .article-detail {
        padding: 25px;
    }
    
    .post-detail-title,
    .article-title {
        font-size: 24px;
    }
    
    .article-meta {
        gap: 15px;
    }
    
    .article-navigation {
        flex-direction: column;
    }
    
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
}
