/*
Theme Name: 链鹿 ChainDeer
Theme URI: https://chaindeer.com
Author: 链鹿
Description: 简洁的加密货币资讯主题
Version: 2.1
License: GPL v2 or later
Text Domain: chaindeer
*/

/* ===== 全局变量 ===== */
:root {
    --primary: #007cba;
    --primary-dark: #005f8c;
    --dark: #1a1a1a;
    --gray: #333;
    --gray-light: #555;
    --gray-lighter: #999;
    --bg: #f5f5f5;
    --bg-light: #f8f8f8;
    --white: #fff;
    --border: #eaeaea;
    --border-light: #f0f0f0;
    --shadow: 0 1px 3px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.1);
    --radius: 8px;
    --radius-lg: 12px;
    --transition: all 0.2s ease;
    --transition-slow: all 0.3s ease;
}

/* ===== 重置 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--dark);
    line-height: 1.5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

img {
    max-width: 100%;
    height: auto;
}

/* ===== 页眉 ===== */
.site-header {
    background: var(--white);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border);
    padding: 15px 0;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-name {
    text-decoration: none;
    font-size: 22px;
    font-weight: 600;
    color: var(--dark);
    white-space: nowrap;
    transition: color var(--transition);
}

.site-name:hover {
    color: var(--primary);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 30px;
}

.main-nav {
    display: flex;
    align-items: center;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-menu li a {
    text-decoration: none;
    color: var(--gray);
    font-size: 15px;
    font-weight: 500;
    transition: color var(--transition);
    white-space: nowrap;
}

.nav-menu li a:hover {
    color: var(--primary);
}

.search-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray);
    transition: color var(--transition);
}

.search-btn svg {
    width: 20px;
    height: 20px;
}

.search-btn:hover {
    color: var(--primary);
}

/* 搜索遮罩 */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 1001;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-slow);
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

.search-container {
    position: relative;
    width: 90%;
    max-width: 500px;
}

.search-container form {
    display: flex;
    gap: 10px;
}

.search-container input {
    flex: 1;
    padding: 15px;
    font-size: 16px;
    border: none;
    border-radius: var(--radius);
    background: var(--white);
}

.search-container input:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--primary);
}

.search-container button[type="submit"] {
    padding: 0 20px;
    background: var(--primary);
    border: none;
    border-radius: var(--radius);
    color: var(--white);
    cursor: pointer;
    transition: background var(--transition);
}

.search-container button[type="submit"]:hover {
    background: var(--primary-dark);
}

.search-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: var(--white);
    font-size: 28px;
    cursor: pointer;
    opacity: 0.8;
}

.search-close:hover {
    opacity: 1;
}

/* 移动端菜单 */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.mobile-menu-btn span {
    width: 22px;
    height: 2px;
    background: var(--gray);
    transition: var(--transition-slow);
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-menu {
    display: none;
    background: var(--white);
    padding: 20px;
    border-top: 1px solid var(--border);
}

.mobile-menu.active {
    display: block;
}

.mobile-nav-menu {
    list-style: none;
}

.mobile-nav-menu li {
    margin-bottom: 15px;
}

.mobile-nav-menu li a {
    text-decoration: none;
    color: var(--gray);
    font-size: 16px;
    display: block;
    padding: 8px 0;
}

.mobile-nav-menu li a:hover {
    color: var(--primary);
}

/* ===== 幻灯片 ===== */
.inner-slider-container {
    position: relative;
    margin-bottom: 30px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--dark);
}

.inner-slider {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.inner-slide-item {
    flex-shrink: 0;
    width: 100%;
    position: relative;
}

.inner-slide-item a {
    text-decoration: none;
    display: block;
}

.inner-slide-image {
    position: relative;
    height: 280px;
    overflow: hidden;
}

.inner-slide-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.inner-slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    color: var(--white);
}

.inner-slide-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.inner-slider-prev,
.inner-slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.5);
    color: var(--white);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-slow);
    z-index: 10;
}

.inner-slider-prev {
    left: 10px;
}

.inner-slider-next {
    right: 10px;
}

.inner-slider-prev:hover,
.inner-slider-next:hover {
    background: var(--primary);
}

.inner-slider-dots {
    position: absolute;
    bottom: 10px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 8px;
    z-index: 10;
}

.inner-dot {
    width: 8px;
    height: 8px;
    background: rgba(255,255,255,0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition-slow);
}

.inner-dot.active {
    background: var(--white);
    width: 20px;
    border-radius: 4px;
}

/* ===== 首页布局 ===== */
.homepage-container {
    display: flex;
    gap: 40px;
    margin-top: 20px;
}

.main-content {
    flex: 2;
}

.sidebar {
    flex: 1;
}

/* ===== 文章卡片 ===== */
.post-card {
    display: flex;
    gap: 20px;
    background: transparent;
    margin-bottom: 30px;
    padding: 20px;
    border-radius: var(--radius-lg);
    transition: var(--transition-slow);
    cursor: pointer;
}

.post-card:hover {
    background: var(--white);
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.post-thumb {
    flex-shrink: 0;
    width: 200px;
    overflow: hidden;
    border-radius: var(--radius);
}

.post-thumb img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.post-card:hover .post-thumb img {
    transform: scale(1.05);
}

.post-content {
    flex: 1;
}

.post-title {
    margin: 0 0 10px;
    font-size: 20px;
}

.post-title a {
    color: var(--dark);
    text-decoration: none;
    transition: color var(--transition);
}

.post-title a:hover {
    color: var(--primary);
}

.post-tags {
    margin-bottom: 10px;
}

.tag-link {
    display: inline-block;
    background: var(--bg);
    padding: 3px 8px;
    border-radius: 4px;
    text-decoration: none;
    color: var(--gray-light);
    font-size: 12px;
    margin-right: 5px;
    margin-bottom: 5px;
    transition: var(--transition);
}

.tag-link:hover {
    background: var(--primary);
    color: var(--white);
}

.post-excerpt {
    color: var(--gray-light);
    line-height: 1.6;
    margin-bottom: 12px;
    font-size: 14px;
}

.post-date {
    margin-top: 8px;
    font-size: 13px;
    color: var(--gray-lighter);
}

/* ===== 侧边栏 ===== */
.sidebar-box {
    background: var(--white);
    padding: 20px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.sidebar-title {
    font-size: 18px;
    margin: 0 0 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
}

.hot-list {
    list-style: none;
}

.hot-item {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    align-items: center;
}

.hot-thumb {
    width: 60px;
    flex-shrink: 0;
}

.hot-thumb img {
    width: 100%;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
}

.hot-info h4 {
    margin: 0 0 5px;
    font-size: 14px;
}

.hot-info h4 a {
    text-decoration: none;
    color: var(--dark);
}

.hot-info h4 a:hover {
    color: var(--primary);
}

.hot-date {
    font-size: 11px;
    color: var(--gray-lighter);
}

/* ===== 分页 ===== */
.pagination {
    text-align: center;
    margin-top: 30px;
}

.pagination a,
.pagination span {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 3px;
    background: var(--white);
    border-radius: 6px;
    text-decoration: none;
    color: var(--gray);
    transition: var(--transition);
}

.pagination a:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

.pagination .current {
    background: var(--primary);
    color: var(--white);
}

/* ===== 页脚 ===== */
.site-footer {
    background: var(--bg-light);
    margin-top: 60px;
    padding: 15px 0;
    border-top: 1px solid var(--border);
    text-align: center;
}

.site-footer p {
    margin: 0;
    font-size: 12px;
    color: var(--gray-lighter);
}

.site-footer a {
    color: var(--gray-light);
    text-decoration: none;
}

.site-footer a:hover {
    color: var(--primary);
}

/* ===== 文章页 ===== */
.single-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

.single-article {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.article-header {
    padding: 40px 40px 20px;
    border-bottom: 1px solid var(--border-light);
}

.article-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 20px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    font-size: 14px;
    color: #718096;
}

.article-content {
    padding: 40px;
    font-size: 16px;
    line-height: 1.8;
    color: #2d3748;
}

.article-content h2 {
    font-size: 28px;
    margin: 1.5em 0 0.5em;
    padding-bottom: 0.3em;
    border-bottom: 1px solid #e2e8f0;
}

.article-content h3 {
    font-size: 24px;
    margin: 1.2em 0 0.5em;
}

.article-content p {
    margin-bottom: 1.5em;
}

.article-content img {
    border-radius: var(--radius);
    margin: 20px 0;
}

.article-content a {
    color: var(--primary);
    text-decoration: none;
    border-bottom: 1px solid #bee3f8;
}

.article-content a:hover {
    color: var(--primary-dark);
}

.article-content blockquote {
    margin: 20px 0;
    padding: 15px 25px;
    border-left: 4px solid var(--primary);
    background: #f7fafc;
    font-style: italic;
}

.article-content pre {
    background: #2d3748;
    color: #e2e8f0;
    padding: 20px;
    border-radius: var(--radius);
    overflow-x: auto;
}

.article-footer {
    padding: 30px 40px;
    background: #f7fafc;
    border-top: 1px solid #e2e8f0;
}

/* 标签 */
.article-tags {
    margin-bottom: 0;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-item {
    display: inline-block;
    padding: 6px 16px;
    background: #edf2f7;
    border-radius: 30px;
    font-size: 13px;
    transition: all 0.2s ease;
}

.tag-item a {
    color: #2d3748;
    text-decoration: none;
    transition: color 0.2s ease;
}

.tag-item:hover {
    background: #edf2f7;  /* 背景不变，或者改成你想要的颜色 */
}

.tag-item:hover a {
    color: var(--primary);  /* 字体变成蓝色 (#007cba) */
}

/* 上下篇导航 */
.post-navigation {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

.nav-links {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

.nav-previous,
.nav-next {
    flex: 1;
}

.nav-link {
    display: block;
    padding: 30px;
    background: var(--white);
    text-decoration: none;
    transition: var(--transition-slow);
}

.nav-link:hover {
    background: #f7fafc;
}

.prev-link {
    text-align: left;
}

.next-link {
    text-align: right;
}

.nav-direction {
    display: block;
    font-size: 12px;
    color: #a0aec0;
    margin-bottom: 10px;
}

.nav-title {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
}

.nav-link:hover .nav-title {
    color: var(--primary);
}

/* ===== 阅读更多（相关文章） ===== */
.related-posts {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 40px;
}

.related-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}

.related-list {
    display: flex;
    flex-direction: column;
}

.related-item {
    border-bottom: 1px solid var(--border-light);
}

.related-item:last-child {
    border-bottom: none;
}

.related-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 14px 0;
    text-decoration: none;
    transition: var(--transition);
}

.related-link:hover {
    padding-left: 10px;
}

.related-thumb {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--bg);
}

.related-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.related-link:hover .related-thumb img {
    transform: scale(1.05);
}

.related-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.related-title-text {
    margin: 0;
    font-size: 15px;
    font-weight: 500;
    color: var(--dark);
    line-height: 1.4;
}

.related-link:hover .related-title-text {
    color: var(--primary);
}

.related-date-simple {
    color: var(--gray-lighter);
    font-size: 12px;
}

/* ===== 归档/列表页 ===== */
.archive-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

.archive-header {
    margin-bottom: 40px;
}

.archive-title {
    font-size: 28px;
    border-left: 5px solid var(--primary);
    padding-left: 15px;
}

.archive-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.archive-thumb {
    width: 200px;
    flex-shrink: 0;
}

.archive-thumb img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: var(--radius);
}

.archive-item-title {
    margin: 0 0 10px;
    font-size: 22px;
}

.archive-item-title a {
    text-decoration: none;
    color: var(--dark);
}

.archive-item-title a:hover {
    color: var(--primary);
}

.archive-meta {
    font-size: 13px;
    color: var(--gray-lighter);
    margin-bottom: 10px;
}

.archive-excerpt {
    color: var(--gray-light);
    line-height: 1.6;
    font-size: 14px;
}

/* ===== 标签页 ===== */
.tag-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

.tag-header {
    text-align: center;
    margin-bottom: 40px;
}

.tag-icon {
    font-size: 48px;
}

.tag-title {
    font-size: 32px;
    margin: 10px 0;
}

.tag-count {
    font-size: 14px;
    color: var(--gray-lighter);
}

.tag-item {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    padding: 15px;
    background: #f9f9f9;
    border-radius: var(--radius-lg);
    transition: var(--transition);
}

.tag-item:hover {
    background: var(--white);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.tag-item-thumb {
    width: 80px;
    flex-shrink: 0;
}

.tag-item-thumb img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-radius: var(--radius);
}

.tag-item-title {
    margin: 0 0 8px;
    font-size: 18px;
}

.tag-item-title a {
    text-decoration: none;
    color: var(--dark);
}

.tag-item-title a:hover {
    color: var(--primary);
}

.tag-cloud-section {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid #eee;
}

.tag-cloud-section a {
    margin: 0 8px;
    text-decoration: none;
    display: inline-block;
}

.tag-cloud-section a:hover {
    color: var(--primary);
    transform: scale(1.05);
}

/* ===== 搜索页 ===== */
.search-container-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
}

.search-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: var(--radius-lg);
    color: var(--white);
}

.search-title {
    font-size: 28px;
    margin-bottom: 12px;
}

.search-keyword {
    background: rgba(255,255,255,0.2);
    padding: 4px 16px;
    border-radius: 30px;
}

.search-item {
    display: flex;
    gap: 20px;
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 20px;
    transition: var(--transition);
}

.search-item:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}

.search-item-thumb {
    flex-shrink: 0;
    width: 160px;
    height: 120px;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--bg);
}

.search-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.search-item-content {
    flex: 1;
}

.search-item-title {
    margin: 0 0 10px;
    font-size: 18px;
}

.search-item-title a {
    text-decoration: none;
    color: var(--dark);
}

.search-item-title a:hover {
    color: var(--primary);
}

.search-item-meta {
    display: flex;
    gap: 20px;
    font-size: 12px;
    color: var(--gray-lighter);
    margin-bottom: 12px;
}

.search-item-excerpt {
    color: var(--gray-light);
    font-size: 14px;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.search-no-results {
    text-align: center;
    padding: 60px;
    background: var(--white);
    border-radius: var(--radius-lg);
}

/* ===== 响应式（手机端） ===== */
@media (max-width: 768px) {
    /* 关键修复：手机版显示搜索按钮，隐藏导航菜单 */
    .main-nav {
        display: none;
    }
    
    .header-right {
        display: flex;
        gap: 15px;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .site-name {
        font-size: 18px;
    }
    
    .homepage-container {
        flex-direction: column;
        gap: 20px;
    }
    
    .inner-slide-image {
        height: 200px;
    }
    
    .inner-slide-title {
        font-size: 14px;
    }
    
    .inner-slider-prev,
    .inner-slider-next {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
    
    .post-card {
        flex-direction: row;
        gap: 12px;
        padding: 12px;
    }
    
    .post-thumb {
        width: 100px;
    }
    
    .post-thumb img {
        height: 80px;
    }
    
    .post-title {
        font-size: 16px;
    }
    
    .post-excerpt {
        font-size: 12px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    
    .sidebar-box {
        padding: 15px;
    }
    
    .hot-thumb {
        width: 50px;
    }
    
    .article-title {
        font-size: 24px;
    }
    
    .article-header,
    .article-content,
    .article-footer {
        padding: 20px;
    }
    
    .related-link {
        gap: 12px;
        padding: 10px 0;
    }
    
    .related-thumb {
        width: 60px;
        height: 60px;
    }
    
    .related-title-text {
        font-size: 14px;
    }
    
    .archive-item {
        flex-direction: column;
    }
    
    .archive-thumb {
        width: 100%;
    }
    
    .archive-thumb img {
        height: 180px;
    }
    
    .tag-item {
        flex-direction: column;
    }
    
    .tag-item-thumb {
        width: 100%;
    }
    
    .tag-item-thumb img {
        height: 160px;
    }
    
    .search-item {
        flex-direction: column;
    }
    
    .search-item-thumb {
        width: 100%;
        height: 180px;
    }
    
    .nav-links {
        flex-direction: column;
        gap: 0;
    }
}
/* ===== 页面模板样式 ===== */
.page-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
}

.page-article {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 40px;
}

.page-title {
    font-size: 32px;
    font-weight: 700;
    margin: 0 0 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-light);
}

.page-content {
    font-size: 16px;
    line-height: 1.8;
    color: #2d3748;
}

.page-content p {
    margin-bottom: 1.5em;
}

.page-content h2 {
    font-size: 28px;
    margin: 1.5em 0 0.5em;
}

.page-content h3 {
    font-size: 24px;
    margin: 1.2em 0 0.5em;
}

.page-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius);
    margin: 20px 0;
}

.page-content ul,
.page-content ol {
    margin: 1em 0;
    padding-left: 2em;
}

.page-content li {
    margin: 0.5em 0;
}

.edit-link {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-light);
    text-align: right;
}

.edit-link a {
    color: var(--primary);
    text-decoration: none;
}

/* 手机版 */
@media (max-width: 768px) {
    .page-article {
        padding: 25px;
    }
    
    .page-title {
        font-size: 24px;
    }
    
    .page-content {
        font-size: 15px;
    }
    
    .page-content h2 {
        font-size: 22px;
    }
    
    .page-content h3 {
        font-size: 20px;
    }
}
/* ===== 404错误页面样式 ===== */
.error-container {
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
}

.error-content {
    text-align: center;
}

.error-code {
    font-size: 100px;
    font-weight: 700;
    color: var(--primary, #007cba);
    margin: 0 0 15px;
}

.error-text {
    font-size: 16px;
    color: var(--gray-light, #555);
    margin-bottom: 25px;
}

.error-home-link {
    display: inline-block;
    padding: 10px 24px;
    background: var(--primary, #007cba);
    color: #fff;
    text-decoration: none;
    border-radius: 6px;
    transition: background 0.2s;
}

.error-home-link:hover {
    background: var(--primary-dark, #005f8c);
}

/* 手机版 */
@media (max-width: 768px) {
    .error-code {
        font-size: 70px;
    }
    
    .error-text {
        font-size: 14px;
    }
}
/* ===== 文章页左右布局 ===== */
.single-wrapper {
    display: flex;
    gap: 40px;
}

.single-main {
    flex: 2;
}

.single-sidebar {
    flex: 1;
}

/* 右侧相关阅读样式 */
.related-posts-sidebar {
    background: var(--white, #fff);
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    padding: 20px;
    position: sticky;
    top: 20px;
}

.related-posts-sidebar .related-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary, #007cba);
}

.related-posts-sidebar .related-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.related-posts-sidebar .related-item {
    border-bottom: 1px solid #f0f0f0;
}

.related-posts-sidebar .related-item:last-child {
    border-bottom: none;
}

.related-posts-sidebar .related-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    text-decoration: none;
    transition: all 0.2s ease;
}

.related-posts-sidebar .related-link:hover {
    padding-left: 8px;
}

.related-posts-sidebar .related-thumb {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    overflow: hidden;
    border-radius: 8px;
    background: #f5f5f5;
}

.related-posts-sidebar .related-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-posts-sidebar .related-info {
    flex: 1;
}

.related-posts-sidebar .related-title-text {
    margin: 0 0 5px;
    font-size: 14px;
    font-weight: 500;
    color: #1a1a1a;
    line-height: 1.4;
}

.related-posts-sidebar .related-link:hover .related-title-text {
    color: var(--primary, #007cba);
}

.related-posts-sidebar .related-date-simple {
    font-size: 11px;
    color: #999;
}

/* 风险提示样式 */
.risk-warning {
    margin: 30px 0 20px;
    padding: 16px 20px;
    background: #fef9e6;
    border-left: 4px solid #ff9800;
    border-radius: 8px;
}

.risk-title {
    font-weight: 600;
    color: #ff9800;
    margin-bottom: 8px;
    font-size: 14px;
}

.risk-text {
    font-size: 12px;
    line-height: 1.6;
    color: #555;
    margin-bottom: 0;
}

/* 手机版 */
@media (max-width: 768px) {
    .single-wrapper {
        flex-direction: column;
        gap: 30px;
    }
    
    .related-posts-sidebar {
        position: static;
    }
    
    .risk-warning {
        padding: 12px 15px;
    }
    
    .risk-text {
        font-size: 11px;
    }
}