/* =====================================================
   新版CMS站点布局样式 - 简洁大气、层级清晰、响应式设计
   ===================================================== */

/* ==================== 基础变量 ==================== */
:root {
    --primary-color: #FF5509;
    --primary-hover: #e64d08;
    --text-dark: #cfc6c6;
    --text-gray: #ffffff;
    --text-light: #cfcfcf;
    --bg-light: rgba(0, 212, 255, 0.3);
    --bg-white: rgba(0, 212, 255, 0.3);
    --border-color: rgba(0, 212, 255, 0.3);
    --shadow: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-hover: 0 4px 16px rgba(0,0,0,0.12);
    --radius: 8px;
    --radius-sm: 4px;
}

/* ==================== 顶部固定导航 ==================== */
.header-fixed {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--bg-white);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.header-main {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-logo {
    flex-shrink: 0;
}

.header-logo img {
    height: 45px;
    width: auto;
}

.header-nav {
    flex: 1;
    margin: 0 40px;
}

.header-nav ul {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 35px;
}

.header-nav ul li a {
    font-size: 16px;
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s;
    position: relative;
}

.header-nav ul li a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s;
}

.header-nav ul li a:hover,
.header-nav ul li.active a {
    color: var(--primary-color);
}

.header-nav ul li a:hover::after,
.header-nav ul li.active a::after {
    width: 100%;
}

.header-search {
    position: relative;
    width: 220px;
}

.header-search input {
    width: 100%;
    height: 38px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 0 40px 0 15px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.header-search input:focus {
    border-color: var(--primary-color);
    outline: none;
}

.header-search button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 5px 10px;
}

.header-search button:hover {
    color: var(--primary-color);
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 20px;
    color: var(--text-dark);
}

/* ==================== Banner区域 ==================== */
.banner-section {
    /* margin-top: 70px; */
    position: relative;
    height: 400px;
    overflow: hidden;
}

.banner-slide {
    width: 100%;
    height: 100%;
    position: relative;
}

.banner-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.banner-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #fff;
    z-index: 2;
}

.banner-content h2 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.banner-content p {
    font-size: 18px;
    opacity: 0.95;
    text-shadow: 0 1px 5px rgba(0,0,0,0.3);
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.2), rgba(0,0,0,0.4));
    z-index: 1;
}

/* ==================== 核心内容分类区 ==================== */
.category-section {
    padding: 50px 0;
    background:var(--ar-border);
}

.section-header {
    text-align: center;
    margin-bottom: 40px;
}

.section-header h3 {
    font-size: 28px;
    color: var(--text-dark);
    font-weight: 600;
    margin-bottom: 10px;
}

.section-header p {
    color: var(--text-light);
    font-size: 15px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.category-item {
    background: var(--bg-white);
    border-radius: var(--radius);
    padding: 30px 20px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: var(--shadow);
}

.category-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.category-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    background: linear-gradient(135deg, var(--primary-color), #ff7b3d);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 24px;
}

.category-item h4 {
    font-size: 18px;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.category-item p {
    font-size: 13px;
    color: var(--text-light);
    line-height: 1.6;
}

/* ==================== 内容区块布局 ==================== */
.content-section {
    padding: 50px 0;
    background: var(--ar-border);
}

.content-wrapper {
    display: flex;
    gap: 30px;
}

.content-main {
    flex: 0 0 70%;
    max-width: 70%;
}

.content-sidebar {
    flex: 0 0 30%;
    max-width: 30%;
}

/* ==================== 文章列表卡片 ==================== */
.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-color);
}

.section-title h4 {
    font-size: 20px;
    color: var(--text-dark);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title h4::before {
    content: '';
    width: 4px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 2px;
}

.section-title .more {
    font-size: 14px;
    color: var(--text-light);
}

.section-title .more:hover {
    color: var(--primary-color);
}

.article-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.article-card {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: var(--bg-white);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.article-card:hover {
    box-shadow: var(--shadow);
    border-color: transparent;
}

.article-thumb {
    flex-shrink: 0;
    width: 180px;
    height: 120px;
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.article-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.article-card:hover .article-thumb img {
    transform: scale(1.05);
}

.article-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.article-info h5 {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.4;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-info h5:hover {
    color: var(--primary-color);
}

.article-desc {
    font-size: 14px;
    color: var(--text-gray);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 10px;
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    font-size: 13px;
    color: var(--text-light);
}

.article-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* ==================== 侧边栏组件 ==================== */
.sidebar-box {
    background: var(--bg-white);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    margin-bottom: 25px;
    overflow: hidden;
}

.sidebar-title {
    padding: 15px 20px;
    background: linear-gradient(135deg, #fafafa, #f0f0f0);
    border-bottom: 1px solid var(--border-color);
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-content {
    padding: 20px;
}

/* 热门文章列表 */
.hot-list li {
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.hot-list li:last-child {
    border-bottom: none;
}

.hot-list li a {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    overflow: hidden;
}

.hot-list .rank {
    width: 22px;
    height: 22px;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: var(--text-gray);
    flex-shrink: 0;
}

.hot-list li:nth-child(1) .rank,
.hot-list li:nth-child(2) .rank,
.hot-list li:nth-child(3) .rank {
    background: var(--primary-color);
    color: #fff;
}

.hot-list .title {
    flex: 1;
    font-size: 14px;
    color: var(--text-dark);
    line-height: 1.5;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    max-width: calc(100% - 40px);
}

.hot-list li:hover .title {
    color: var(--primary-color);
}

/* 标签云 */
.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-cloud a {
    padding: 6px 14px;
    background: var(--bg-light);
    border-radius: 20px;
    font-size: 13px;
    color: var(--text-gray);
    transition: all 0.3s;
}

.tag-cloud a:hover {
    background: var(--primary-color);
    color: #fff;
}

/* ==================== 列表页样式 ==================== */
.breadcrumb-section {
    padding: 20px 0;
    background: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-light);
}

.breadcrumb a {
    color: var(--text-gray);
}

.breadcrumb a:hover {
    color: var(--primary-color);
}

.breadcrumb .current {
    color: var(--text-dark);
    font-weight: 500;
}

/* 筛选栏 */
.filter-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    background: var(--bg-white);
    border-radius: var(--radius);
    margin-bottom: 25px;
    border: 1px solid var(--border-color);
}

.filter-options {
    display: flex;
    gap: 20px;
}

.filter-options a {
    font-size: 14px;
    color: var(--text-gray);
    padding: 5px 0;
    position: relative;
}

.filter-options a.active,
.filter-options a:hover {
    color: var(--primary-color);
}

.filter-options a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-color);
}

.filter-result {
    font-size: 13px;
    color: var(--text-light);
}

/* 列表页卡片布局 */
.list-card {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: var(--bg-white);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.list-card:hover {
    box-shadow: var(--shadow);
}

.list-card .thumb {
    flex-shrink: 0;
    width: 240px;
    height: 150px;
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.list-card .thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.list-card:hover .thumb img {
    transform: scale(1.05);
}

.list-card .info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.list-card .info h4 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.list-card .info h4:hover {
    color: var(--primary-color);
}

.list-card .info .desc {
    font-size: 14px;
    color: var(--text-gray);
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.list-card .meta {
    display: flex;
    align-items: center;
    gap: 25px;
    font-size: 13px;
    color: var(--text-light);
    margin-top: 15px;
}

/* 分页 */
.pagination-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.pagination {
    display: flex;
    gap: 8px;
}

.pagination a,
.pagination span {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    font-size: 14px;
    color: var(--text-gray);
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.pagination a:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.pagination .current,
.pagination .active span {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

/* ==================== 详情页样式 ==================== */
.article-detail {
    background: var(--bg-white);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    padding: 40px;
}

.article-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
}

.article-header h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.4;
    margin-bottom: 20px;
}

.article-header .meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    font-size: 14px;
    color: var(--text-light);
}

.article-header .meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.article-header .tags {
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.article-header .tags a {
    padding: 4px 12px;
    background: var(--bg-light);
    border-radius: 20px;
    font-size: 13px;
    color: var(--text-gray);
}

.article-header .tags a:hover {
    background: var(--primary-color);
    color: #fff;
}

/* 正文内容 */
.article-body {
    font-size: 16px;
    line-height: 1.9;
    color: var(--text-dark);
}

.article-body p {
    margin-bottom: 20px;
}

.article-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-sm);
    margin: 20px 0;
}

.article-body h2,
.article-body h3,
.article-body h4 {
    margin: 30px 0 15px;
    font-weight: 600;
}

.article-body h2 {
    font-size: 22px;
}

.article-body h3 {
    font-size: 19px;
}

.article-body h4 {
    font-size: 17px;
}

/* 上下篇导航 */
.article-nav {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid var(--border-color);
}

.article-nav a {
    flex: 1;
    padding: 20px;
    background: var(--bg-light);
    border-radius: var(--radius);
    transition: all 0.3s;
}

.article-nav a:hover {
    background: var(--primary-color);
    color: #fff;
}

.article-nav a:hover span,
.article-nav a:hover h6 {
    color: #fff;
}

.article-nav .prev {
    text-align: left;
}

.article-nav .next {
    text-align: right;
}

.article-nav span {
    display: block;
    font-size: 12px;
    color: var(--text-light);
    margin-bottom: 8px;
}

.article-nav h6 {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 相关推荐 */
.related-section {
    margin-top: 40px;
}

.related-section h4 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-left: 12px;
    border-left: 4px solid var(--primary-color);
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.related-item {
    background: var(--bg-white);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: all 0.3s;
}

.related-item:hover {
    box-shadow: var(--shadow);
}

.related-item .thumb {
    width: 100%;
    height: 130px;
    overflow: hidden;
}

.related-item .thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.related-item:hover .thumb img {
    transform: scale(1.05);
}

.related-item h6 {
    padding: 15px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-item:hover h6 {
    color: var(--primary-color);
}

/* ==================== 底部样式 ==================== */
.footer {
    background: #25262E;
    color: #8A8A8A;
    padding: 50px 0 20px;
    margin-top: 50px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    margin-bottom: 40px;
}

.footer-col h5 {
    color: #fff;
    font-size: 16px;
    margin-bottom: 20px;
    font-weight: 600;
}

.footer-col p {
    font-size: 14px;
    line-height: 1.8;
    margin-bottom: 10px;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul li a {
    font-size: 14px;
    color: #8A8A8A;
    transition: color 0.3s;
}

.footer-col ul li a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid #3a3b44;
    padding-top: 20px;
    text-align: center;
    font-size: 13px;
}

.footer-bottom a {
    color: #fff;
    margin: 0 10px;
}

.footer-bottom a:hover {
    color: var(--primary-color);
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 992px) {
    .header-nav {
        display: none;
    }
    
    .header-search {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .banner-section {
        height: 280px;
    }
    
    .banner-content h2 {
        font-size: 28px;
    }
    
    .banner-content p {
        font-size: 15px;
    }
    
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .content-wrapper {
        flex-direction: column;
    }
    
    .content-main,
    .content-sidebar {
        flex: 1;
        max-width: 100%;
    }
    
    .article-card {
        flex-direction: column;
    }
    
    .article-thumb {
        width: 100%;
        height: 180px;
    }
    
    .list-card {
        flex-direction: column;
    }
    
    .list-card .thumb {
        width: 100%;
        height: 180px;
    }
    
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .header-main {
        height: 60px;
    }
    
    .header-logo img {
        height: 38px;
    }
    
    .banner-section {
        /* margin-top: 60px; */
        height: 200px;
    }
    
    .banner-content h2 {
        font-size: 22px;
    }
    
    .banner-content p {
        font-size: 13px;
    }
    
    .category-section {
        padding: 30px 0;
    }
    
    .category-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .category-item {
        padding: 20px 15px;
    }
    
    .content-section {
        padding: 30px 0;
    }
    
    .section-title {
        margin-bottom: 20px;
    }
    
    .article-detail {
        padding: 20px;
    }
    
    .article-header h1 {
        font-size: 20px;
    }
    
    .article-header .meta {
        flex-wrap: wrap;
        gap: 15px;
    }
    
    .article-nav {
        flex-direction: column;
    }
    
    .article-nav .prev,
    .article-nav .next {
        text-align: left;
    }
    
    .related-grid {
        grid-template-columns: 1fr;
    }
    
    .filter-bar {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .footer-bottom {
        font-size: 12px;
    }
    
    .footer-bottom a {
        display: block;
        margin: 5px 0;
    }
}
