

/* =============================================================================
 * 文章列表页专用样式 (article-list.html)
 * ============================================================================= */

/* 内容布局容器 */
.content-wrapper {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 2rem;
    margin-top: 0.5rem;
    margin-bottom: 1rem;
    padding: 20px;
    width: 100%;
    background-color: var(--card-bg);
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    box-sizing: border-box;
    transition: var(--transition);
}

/* 列表模板基础样式 */
.article-list-item {
    display: flex;
    gap: 20px;
    padding: 20px;
    background-color: var(--card-bg);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    margin-bottom: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    align-items: stretch;
}

.article-list-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

/* 列表模板图片 */
.article-list-img {
    object-fit: cover;
    border-radius: 10px;
    flex-shrink: 0;
}

/* 列表模板标题 */

.article-list-title a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.article-list-title a:hover {
    color: #1da1f2;
}

/* 列表模板摘要 */
.article-list-excerpt {
    color: var(--light-text);
    line-height: 1.6;
    margin-bottom: auto;
    font-size: 0.95rem;
}

/* 列表排序下拉列表框 */
.sort-control-container {
    margin-bottom: 1rem;
    padding: 8px;
    background: #f5f5f5;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#current-category {
    font-weight: 600;
}

.category-name {
    font-size: 16px;
    color: #333;
}

.custom-dropdown {
    position: relative;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-width: 120px;
}

.dropdown-button {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.dropdown-button:hover {
    border-color: #d0d0d0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.selected-option {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100px;
}

.dropdown-arrow {
    font-size: 10px;
    margin-left: 8px;
    color: #666;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 5px;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    min-width: 120px;
    padding: 4px 0;
}

.dropdown-item {
    padding: 8px 12px;
    cursor: pointer;
    font-size: 14px;
    color: #333;
    transition: all 0.2s ease;
}

.dropdown-item.disabled {
    color: #666;
    font-weight: 600;
    cursor: default;
    padding: 10px 12px;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 4px;
}

.dropdown-item.active {
    background-color: #e3f2fd;
    color: #2196f3;
    font-weight: 600;
}

.dropdown-item:not(.disabled):hover {
    background-color: #f5f5f5;
}

.dropdown-item[data-value="rising"] {
    color: #4caf50;
}

.dropdown-item[data-value="rising"].active {
    background-color: #e8f5e9;
    color: #4caf50;
}

/* 下拉菜单隐藏状态 */
.dropdown-menu.is-hidden {
    display: none !important;
}

/* 分页条容器 */
.pagination-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

/* 分页列表 */
.pagination {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 0.5rem;
}

.pagination-item {
    margin: 0;
}

/* 分页链接 */
.pagination-link {
    display: inline-flex;
    align-items: center;
    height: 40px;
    gap: 0.5rem;
    padding: 0.8rem 1.2rem;
    background-color: var(--card-bg);
    color: var(--text-color);
    text-decoration: none;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    font-weight: 500;
}

.pagination-link:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.pagination-item.active .pagination-link {
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
}

/* 分页省略号 */
.pagination-item.ellipsis {
    display: flex;
    align-items: center;
    padding: 0.8rem 0.5rem;
    color: var(--light-text);
    font-weight: 500;
}

/* 侧边栏容器 */
.sidebar {
    position: static;
    height: fit-content;
    display: flex;
    flex-direction: column;
    overflow: visible;
}

/* 侧边栏区块和小工具 */
.sidebar-section,
.widget {
    background-color: var(--card-bg);
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    box-sizing: border-box;
    width: 100%;
    position: relative;
}

/* 侧边栏标题 */
.sidebar-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
}

/* 查看更多链接 */
.more-link {
    display: block;
    width: 100%;
    text-align: right;
    margin-top: 0.5rem;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    padding: 0.4rem 0.6rem;
    border-radius: 16px;
    transition: var(--transition);
}

/* 查看更多链接悬停效果 */
.more-link:hover {
    color: white;
    background: var(--primary-color);
    transform: translateY(-2px);
}

/* 侧边栏分类模块 */
.categories-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-section .categories-list a {
    display: block;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    text-decoration: none;
    color: #4a5568;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    box-sizing: border-box;
}

.sidebar-section .categories-list li a:hover {
    background: #edf2f7;
    color: #667eea;
    transform: translateX(4px);
    font-size: 1.15rem;
    font-weight: 500;
}

.categories-list li a i {
    font-size: 1.1rem;
}

.categories-list .category-count {
    background-color: rgba(0, 0, 0, 0.1);
    padding: 0.1rem 0.4rem;
    border-radius: 12px;
    font-size: 0.8rem;
    color: #4a5568;
    float:right;
}

/* 侧边栏tags列表模块 */
.tags-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
}

.sidebar-section .tag-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
    transition: var(--transition);
    text-decoration: none;
    color: var(--text-color);
    background: #f8f9fa;
}

.sidebar-section .tag-item:hover {
    background: #edf2f7;
    color: #667eea;
    transform: translateX(4px);
    font-size: 1.15rem;
    font-weight: 500;
}

.tag-count {
    background-color: rgba(0, 0, 0, 0.1);
    padding: 0.1rem 0.4rem;
    border-radius: 12px;
    font-size: 0.8rem;
    color: #4a5568;
}

/* 侧边栏最近文章模块 */
.recent-article-item {
    display: flex;
    gap: 0.5rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
    cursor: pointer;
}

.recent-article-item a {
    display: flex;
    gap: 0.5rem;
    text-decoration: none;
}

.recent-article-item:hover {
    transform: translateX(8px);
}

.recent-article-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.recent-article-img {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 12px;
    flex-shrink: 0;
    transition: transform 0.3s ease;
    border: 2px solid transparent;
}

.recent-article-item:hover .recent-article-img {
    transform: scale(1.05);
    border-color: var(--primary-color);
}

.recent-article-content h4 {
    margin-bottom: 0.65rem;
    font-size: 1rem;
    line-height: 1.45;
    font-weight: 600;
    transition: color 0.3s ease;
}

.recent-article-content h4 a {
    color: var(--text-color);
    transition: var(--transition);
}

.recent-article-item:hover h4 a {
    color: var(--primary-color);
}

.recent-article-date {
    font-size: 0.8rem;
    color: var(--light-text);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

@media (max-width: 1024px) {
    .content-wrapper,
    .article-wrapper {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: none;
    }
}

@media (max-width: 768px) {
.article-list-section .container {
    padding: 0 0.5rem;
}
    .content-wrapper {
        padding: 0.5rem;
        margin: 0.5rem 0;
    }

    .article-list-item {
        gap:10px;
        padding: 10px;
        margin-bottom: 10px;
    }

    .article-list-item .kao-img-wrap {
        width: 120px;
        height: 120px;
    }

    .article-list-content .article-list-title {
        font-size: 1.2rem;
        line-height: 1.2;
    }

    .article-list-content .article-list-excerpt {
        font-size: 1rem;
        line-height: 1;
        color: #718096;
    }

    .sort-control-container {

    }
}

@media (max-width: 480px) {
    .article-list-content .article-list-excerpt {
        display: none;
    }    
}

/* =============================================================================
 * 文章详情页专用样式 (article-temp.html)
 * ============================================================================= */

/* 主内容区域 */
.main-content {
    width: 100%;
    overflow: hidden;
    padding:0;
}

/* 文章内容包装器 - 网格布局 */
.article-wrapper {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 2rem;
    margin-bottom: 1rem;
    width: 100%;
}

/* 全宽布局模式 */
.article-wrapper.full-width {
    grid-template-columns: 1fr;
    gap: 0;
    margin-top: 0.5rem;
}

/* 文章内容容器 */
.article-content {
    background-color: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    padding: 1.5rem;
    width: 100%;
    box-sizing: border-box;
    transition: var(--transition);
}

/* 文章头部容器 */
.article-header {
    margin-bottom: 2rem;
    position: relative;
}

/* 文章标题 */
.article-title {
    line-height: 1.2;
    margin-bottom: 1rem;
}

/* 文章元数据区域 */
.article-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    padding-top: 1rem;
    padding-bottom: 1rem;
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
}

/* 作者信息容器 */
.author-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* 作者头像 */
.author-avatar-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 3px solid #f7fafc;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #007bff;
    color: white;
    font-size: 1.5rem;
}

.author-avatar:hover,
.author-avatar-icon:hover {
    transform: scale(1.05);
}

/* 作者详细信息 */
.author-details {
    display: flex;
    flex-direction: column;
}

/* 作者姓名 */
.author-name {
    font-weight: 600;
    color: var(--text-color);
}

.author-title {
    font-size: 0.85rem;
    color: var(--light-text);
}

.article-date {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    font-size: 0.9rem;
    color: var(--light-text);
}

.reading-time {
    font-weight: 500;
    color: var(--primary-color);
    margin-top: 0.25rem;
}

/* 文章头图 */
.article-featured-image {
    margin-bottom: 1.5rem;
    text-align: center;
}

.featured-img {
    width: 100%;
    height: auto;
    max-height: 600px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 1rem;
    display: block;
    transition: transform 0.5s ease;
    overflow: hidden;
}

.featured-img:hover {
    transform: scale(1.01);
}

.image-caption {
    font-size: 0.95rem;
    color: var(--light-text);
    font-style: italic;
}

/* 文章简述 */
.article-intro {
    font-size: 1.15rem;
    color:#4da599;
    margin-bottom: 2.5rem;
    padding: 1rem;
    border-radius: 8px;
    border-bottom: 1px solid var(--border-color);
    border-left: 8px solid #f88d5c;
}

/* 文章主体 */
.article-body h2 {
    font-size: clamp(1.6rem, 3vw, 2rem);
    margin-bottom: 1.5rem;
    border-bottom: 3px solid var(--primary-color);
    position: relative;

}

.article-body h2::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 60px;
    height: 3px;

}

.article-body h3 {
    font-size: clamp(1.3rem, 2vw, 1.6rem);
    margin-bottom: 1rem;
}

.article-body p {
    font-size: clamp(1rem, 1.1vw, 1.1rem);
    margin-bottom: 1rem;  
}

.article-body p:first-of-type {
    font-size: clamp(1.05rem, 1.2vw, 1.15rem);
    font-weight: 500;
    line-height: 1.8;
}

.article-body ul,
.article-body ol {
    margin-bottom: 1.75rem;
    padding-left: 2.5rem;
}

.article-body li {
    margin-bottom: 0.85rem;
    line-height: 1.7;
    font-size: clamp(1rem, 1.1vw, 1.05rem);
}

.article-body ul li {
    position: relative;
    padding-left: 1rem;
}

.article-body ul li::before {
    content: '•';
    color: var(--primary-color);
    font-weight: bold;
    position: absolute;
    left: -0.5rem;
}

.article-body blockquote {
    border-left: 4px solid var(--primary-color);
    padding: 1.5rem 1.5rem 1.5rem 2rem;
    margin: 2rem 0;
    background-color: var(--background-color);
    border-radius: 0 8px 8px 0;
    font-style: italic;
    position: relative;
}

.article-body blockquote footer {
    text-align: right;
    margin-top: 0.5rem;
    font-style: normal;
    font-weight: 600;
    color: var(--light-text);
}

.article-body img.article-img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 2rem 0;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    display: block;
}

/* 文章标签 */
.tags-label {
    font-weight: 600;
    margin-right: 1rem;
    color: var(--text-color);
}

.tag {
    display: inline-block;
    background: #daedfa;
    color: #4a5568;
    padding: 0.3rem 0.8rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
    white-space: nowrap;
}

.tag:hover {
    background: #f39c12;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 2px 6px #ddd;
}

/* 文章内容页面的相关文章模块 */
.related-articles {
    width: 100%;
    padding-top: 2rem;
    padding-bottom: 2rem;
}

.related-articles h2 {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--border-color);
    position: relative;
}

.related-articles h2::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 270px;
    height: 6px;
    background-color: var(--primary-color);
}

.related-articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.related-article-card {
    background-color: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
}

.related-article-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.related-article-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.5s ease;
    display: block;
    border-radius: var(--img-radius);
}

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

.related-article-content {
    padding: 1rem;
}

.related-article-content h3 {
    font-size: 1.25rem;
    line-height: 1.4;
}

.related-article-content h3 a {
    color: var(--text-color);
    transition: var(--transition);
    font-weight: 500;
}

.related-article-content h3 a:hover {
    color: var(--primary-color);
}

.related-article-content p {
    margin-bottom: 0.5rem;
    line-height: 1.6;
    color: var(--light-text);
    font-size: 0.95rem;
}

.related-article-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: var(--light-text);
}

/* 文章分类徽章 */
.category-badge {
    display: inline-block;
    background: #6fc0a1;
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(29, 161, 242, 0.25);
}

/* 分类徽章悬停效果 */
.category-badge:hover {
    color: #ffffff;
    background-color: #f39c12;
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(29, 161, 242, 0.25);
}

@media (max-width: 768px) {
    .main-content .container {
        padding: 0 0.5rem;
    }

    .main-content .container .article-content {
        padding: 0.5rem;
    }  
    
    .main-content .article-title {
        font-size: 1.5rem;
    }

    .main-content .article-intro {
        font-size: 1rem;
        margin-bottom: 0;
        padding: 0.5rem;
    }

    .main-content .article-intro p {
        line-height: 1.2;
    }

    .main-content .article-featured-image {
        margin-bottom: 0;
    }

    .main-content .article-body h1 {
        font-size: 1.5rem;
        line-height: 1.5;
        padding: 0.5rem 0;
        color: #6e4f37;
    }

    .main-content .article-body h2 {
        font-size: 1.2rem;
        line-height: 1.2;
    }
    .main-content .article-body h3 {
        font-size: 1rem;
        line-height: 1;
    }  
    
    .article-body p:first-of-type {
        line-height: normal;
    }

    .related-articles {
        margin: 0;
        padding: 0;
    }

    .related-articles-grid {
        grid-template-columns: 1fr;
    }

    .related-article-content h3 {
        font-size: 1.1rem;
        line-height: 1.1;
    }

    .related-article-content p {
        line-height: 1.1;
    }
}

/* =============================================================================
 * 文章分类页专用样式 (article-categories.html)
 * ============================================================================= */

 /* 分类模块主体框架 */
 .categories-page .category-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    background-color: var(--card-bg);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
    transition: all 0.4s ease;
    border: 1px solid rgba(0, 0, 0, 0.03);
    margin-top: 0.5rem;
    margin-bottom: 1.5rem;
}

.categories-page .category-card {
    padding: 1.5rem ;
    border-radius: 16px ;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%) ;
    border: 1px solid rgba(0, 0, 0, 0.08) ;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08) ;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) ;
    backdrop-filter: blur(10px) ;
}

.categories-page .category-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.categories-page .category-card:hover::after {
    transform: scaleX(1);
}

.categories-page .category-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.1);
}

.categories-page .category-card h3 {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.categories-page .category-card .category-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.categories-page .category-card .category-count {
    display: inline-block;
    background-color: rgba(93, 138, 168, 0.1);
    color: var(--primary-color);
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.categories-page .category-card:hover .category-count {
    background-color: var(--primary-color);
    color: white;
}

@media (max-width: 768px) {
    .categories-page .container {
        padding: 0;
    }

    .categories-page .category-cards {
        margin: 0.5rem;
        padding: 0.5rem;
        gap: 0.5rem;
    }

    .categories-page .category-card {
        padding: 0.5rem;
        margin: 0;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .categories-page .category-card .category-icon {
        font-size: 2rem;
        margin-bottom: 0;
        order: 1;
    }

    .categories-page .category-card h3 {
        font-size: 1.1rem;
        margin-bottom: 0;
        order: 2;
        flex: 1;
        text-align: center;
        margin: 0 1rem;
    }

    .categories-page .category-card .category-count {
        margin-bottom: 0;
        order: 3;
    }
}

/* =============================================================================
 * 文章标签页专用样式 (article-tags.html)
 * ============================================================================= */
 .tags-page {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

#tags-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    background-color: var(--card-bg);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
    transition: all 0.4s ease;
    border: 1px solid rgba(0, 0, 0, 0.03);
    margin-top: 0.5rem;
}

@media (max-width: 768px) {
     .tags-page {
        padding: 0;
     }

      .tags-page .container {
        padding: 0 0.5rem;
      }

     #tags-container {
        padding: 0.5rem;
        gap: 0.5rem;
     }
}

