/* 文章分类页面样式 */
body {
    padding-top: 0;
    background: #f5f7fa;
    min-height: 100vh;
}

/* 搜索区域 */
.search-section {
    padding: 130px 20px 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
    margin: 0;
    min-height: 300px;
}

.search-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    z-index: 1;
    pointer-events: none;
}

.search-section>* {
    position: relative;
    z-index: 2;
}

.search-slogan {
    color: #fff;
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

.search-subtitle {
    color: rgba(255, 255, 255, 0.95);
    font-size: 14px;
    margin-bottom: 35px;
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.15);
}

.search-content {
    max-width: 800px;
    margin: 0 auto;
}

.search-box {
    width: 100%;
    margin: 0 auto;
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    width: 100%;
    padding: 18px 70px 18px 24px;
    border: none;
    border-radius: 50px;
    font-size: 15px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    transition: all 0.3s;
}

.search-input:focus {
    outline: none;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.18);
    background: #fff;
}

.search-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: #1890ff;
    color: #fff;
    border: none;
    padding: 0;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(24, 144, 255, 0.3);
}

.search-btn:hover {
    background: #40a9ff;
    transform: translateY(-50%) scale(1.05);
}

/* 覆盖首页的grid布局 */
.content-wrapper {
    display: flex !important;
    flex-direction: row !important;
    grid-template-columns: unset !important;
    gap: 20px;
    max-width: 1600px;
    margin: 0 auto;
    padding: 30px 20px;
}

.main-content {
    flex: 1;
    min-width: 0;
}

.right-sidebar {
    width: 320px !important;
    flex-shrink: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 15px !important;
}

.category-nav {
    background: #fff;
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.nav-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.nav-tab {
    padding: 8px 16px;
    background: #f5f5f5;
    border: none;
    border-radius: 6px;
    text-decoration: none;
    color: #666;
    font-size: 14px;
    transition: all 0.2s;
}

.nav-tab:hover,
.nav-tab.active {
    background: #1890ff;
    color: #fff;
}

.articles-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.article-item {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.article-item:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.article-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.article-desc {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 12px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: #999;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 32px;
}

.pagination a,
.pagination span {
    padding: 8px 14px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    text-decoration: none;
    color: #666;
    transition: all 0.2s;
    background: #fff;
}

.pagination a:hover {
    border-color: #1890ff;
    color: #1890ff;
}

.pagination .current {
    background: #1890ff;
    color: #fff;
    border-color: #1890ff;
}

@media (max-width: 768px) {
    .search-section {
        padding: 100px 15px 30px;
        min-height: 220px;
    }

    .search-slogan {
        font-size: 22px;
    }

    .search-subtitle {
        font-size: 13px;
        margin-bottom: 20px;
    }

    .search-input {
        padding: 14px 55px 14px 18px;
        font-size: 14px;
    }

    .search-btn {
        width: 38px;
        height: 38px;
        font-size: 18px;
    }

    .content-wrapper {
        flex-direction: column !important;
        padding: 20px 10px;
        gap: 15px;
    }

    .main-content {
        width: 100%;
    }

    .right-sidebar {
        display: none !important;
    }

    .category-nav {
        padding: 12px 14px;
        margin-bottom: 15px;
        border-radius: 10px;
    }

    .nav-tab {
        padding: 7px 12px;
        font-size: 13px;
        border-radius: 5px;
    }

    .article-item {
        padding: 18px;
        border-radius: 10px;
    }

    .article-title {
        font-size: 16px;
        margin-bottom: 6px;
    }

    .article-desc {
        font-size: 13px;
        margin-bottom: 10px;
    }

    .article-meta {
        gap: 12px;
        font-size: 12px;
    }

    .pagination {
        margin-top: 20px;
        gap: 6px;
        flex-wrap: wrap;
    }

    .pagination a,
    .pagination span {
        padding: 6px 12px;
        font-size: 13px;
        border-radius: 5px;
    }
}

/* 右
侧栏样式 - 从style.css复制过来确保显示 */
.sidebar-top-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.sidebar-banner {
    background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
    padding: 20px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 15px;
}

.sidebar-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
}

.sidebar-banner::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -5%;
    width: 150px;
    height: 150px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
}

.banner-logo {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.banner-logo img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.banner-text {
    flex: 1;
    position: relative;
    z-index: 1;
}

.banner-title {
    font-size: 16px;
    font-weight: 600;
    color: white;
    margin-bottom: 4px;
}

.banner-desc {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
}

.sidebar-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    padding: 15px 0;
}

.sidebar-stat-item {
    text-align: center;
    padding: 8px 0;
}

.stat-num {
    font-size: 20px;
    font-weight: 700;
    color: #1890ff;
    margin-bottom: 4px;
}

.stat-text {
    font-size: 12px;
    color: #999;
}

/* 网站推荐卡片 */
.sidebar-ranking-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.sidebar-card-header {
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: #333;
}

.sidebar-card-header i {
    color: #1890ff;
    font-size: 18px;
}

.ranking-tabs {
    display: flex;
    padding: 12px 20px;
    gap: 8px;
    border-bottom: 1px solid #f0f0f0;
}

.ranking-tab {
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 13px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
    background: #f5f5f5;
}

.ranking-tab.active,
.ranking-tab:hover {
    background: #1890ff;
    color: white;
}

.ranking-list {
    padding: 12px;
}

.ranking-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
}

.ranking-item:hover {
    background: #f5f7fa;
}

.ranking-num {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #f0f0f0;
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
}

.ranking-item:nth-child(1) .ranking-num {
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: white;
}

.ranking-item:nth-child(2) .ranking-num {
    background: linear-gradient(135deg, #C0C0C0 0%, #A8A8A8 100%);
    color: white;
}

.ranking-item:nth-child(3) .ranking-num {
    background: linear-gradient(135deg, #CD7F32 0%, #B8860B 100%);
    color: white;
}

.ranking-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    flex-shrink: 0;
    background: #f5f5f5;
}

.ranking-info {
    flex: 1;
    min-width: 0;
}

.ranking-name {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ranking-desc {
    font-size: 12px;
    color: #999;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ranking-stats {
    font-size: 12px;
    color: #999;
    flex-shrink: 0;
}

.ranking-stats i {
    font-size: 14px;
}

.ranking-more {
    display: block;
    text-align: center;
    padding: 12px;
    color: #1890ff;
    text-decoration: none;
    font-size: 13px;
    border-top: 1px solid #f0f0f0;
    transition: all 0.2s;
}

.ranking-more:hover {
    background: #f5f7fa;
}

/* 最新文章卡片 */
.sidebar-articles-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.sidebar-articles-card .sidebar-card-header {
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
}

.sidebar-articles-card .articles-list {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.sidebar-articles-card .article-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
    box-shadow: none;
}

.sidebar-articles-card .article-item:hover {
    background: #f5f7fa;
    transform: none;
}

.sidebar-articles-card .article-num {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #f0f0f0;
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
}

.sidebar-articles-card .article-title {
    flex: 1;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin: 0;
}

.sidebar-articles-card .article-views {
    font-size: 12px;
    color: #999;
    flex-shrink: 0;
}

.sidebar-articles-card .article-views i {
    font-size: 14px;
}
