/**
 * 文章列表页和详情页样式
 */

/* ============================================
 * 文章列表页 (archive.php)
 * ============================================ */
.blog-archive { padding: 40px 0 60px; }
.blog-archive .commonweb { padding: 0 15px; }

.blog-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-top: 20px;
}

.blog-card {
    display: flex;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    transition: box-shadow 0.3s, transform 0.3s;
}
.blog-card:hover {
    box-shadow: 0 6px 24px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

.blog-card__img {
    flex-shrink: 0;
    width: 280px;
    height: 180px;
    overflow: hidden;
}
.blog-card__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}
.blog-card:hover .blog-card__img img {
    transform: scale(1.08);
}
.blog-card__img--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #399D26, #2d7a1d);
    color: #fff;
    font-size: 28px;
    font-weight: 700;
}

.blog-card__body {
    flex: 1;
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.blog-card__date {
    font-size: 13px;
    color: #999;
    margin-bottom: 8px;
}
.blog-card__title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    line-height: 1.5;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.blog-card__title a { color: inherit; text-decoration: none; }
.blog-card__title a:hover { color: #399D26; }

.blog-card__excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 12px;
}

.blog-card__more {
    font-size: 14px;
    color: #399D26;
    text-decoration: none;
    font-weight: 500;
}
.blog-card__more:hover { text-decoration: underline; }

.blog-pagination {
    text-align: center;
    margin-top: 40px;
}
.blog-pagination .page-numbers {
    display: inline-block;
    padding: 8px 14px;
    margin: 0 3px;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #555;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
}
.blog-pagination .page-numbers:hover,
.blog-pagination .page-numbers.current {
    background: #399D26;
    border-color: #399D26;
    color: #fff;
}

.blog-empty {
    text-align: center;
    padding: 60px 20px;
    color: #999;
    font-size: 16px;
}

@media (max-width: 768px) {
    .blog-card { flex-direction: column; }
    .blog-card__img { width: 100%; height: 200px; }
}

/* ============================================
 * 文章详情页 (single.php)
 * ============================================ */
.blog-single { padding: 40px 0 60px; }
.blog-single .commonweb { padding: 0 15px; }

.blog-single__header { margin-bottom: 30px; }
.blog-single__title {
    font-size: 30px;
    font-weight: 700;
    color: #222;
    line-height: 1.4;
    margin-bottom: 12px;
}
.blog-single__meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    color: #999;
    padding-bottom: 0;
}
.blog-single__meta a { color: #399D26; text-decoration: none; }
.blog-single__meta a:hover { text-decoration: underline; }
.blog-single__meta-sep { color: #ddd; }

.blog-single__featured {
    margin-bottom: 30px;
    border-radius: 8px;
    overflow: hidden;
}
.blog-single__featured img {
    width: 100%;
    height: auto;
    display: block;
}

.blog-single__content {
    font-size: 16px;
    line-height: 1.8;
    color: #444;
}
.blog-single__content h2,
.blog-single__content h3,
.blog-single__content h4 {
    color: #222;
    margin-top: 28px;
    margin-bottom: 14px;
    font-weight: 600;
}
.blog-single__content p { margin-bottom: 18px; }
.blog-single__content a { color: #399D26; }
.blog-single__content img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 16px 0;
}
.blog-single__content blockquote {
    border-left: 4px solid #399D26;
    margin: 20px 0;
    padding: 12px 20px;
    background: #f8faf6;
    color: #555;
    font-style: italic;
}
.blog-single__content ul,
.blog-single__content ol {
    padding-left: 24px;
    margin-bottom: 18px;
}
.blog-single__content li { margin-bottom: 6px; }
.blog-single__content pre {
    background: #f5f5f5;
    padding: 16px;
    border-radius: 6px;
    overflow-x: auto;
    font-size: 14px;
}
.blog-single__content table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}
.blog-single__content th,
.blog-single__content td {
    border: 1px solid #ddd;
    padding: 10px 14px;
    text-align: left;
}
.blog-single__content th { background: #f8faf6; font-weight: 600; }

.blog-single__tags {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}
.blog-single__tags-label {
    font-size: 14px;
    color: #999;
    margin-right: 8px;
}
.blog-single__tags a {
    display: inline-block;
    padding: 4px 12px;
    margin: 0 6px 6px 0;
    background: #f0f0f0;
    border-radius: 4px;
    font-size: 13px;
    color: #666;
    text-decoration: none;
    transition: all 0.2s;
}
.blog-single__tags a:hover {
    background: #399D26;
    color: #fff;
}

.blog-single__nav {
    display: flex;
    justify-content: space-between;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #eee;
}
.blog-single__nav a {
    color: #555;
    text-decoration: none;
    font-size: 14px;
    max-width: 48%;
}
.blog-single__nav a:hover { color: #399D26; }
.blog-single__nav-label {
    display: block;
    font-size: 12px;
    color: #aaa;
    margin-bottom: 4px;
}
.blog-single__nav-title {
    display: block;
    font-weight: 500;
}
.blog-single__nav-prev { text-align: left; }
.blog-single__nav-next { text-align: right; }
