/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    margin: 0 auto;
}

/* 导航栏样式 */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo img {
    width: 260px;
    height: 60px;
}

.nav-menu {
    list-style: none;
    display: flex;
    gap: 30px;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    display: inline-block;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-size: 16px;
    padding: 10px 15px;
    border-radius: 25px;
    transition: all 0.3s ease;
    display: block;
}

.nav-link:hover,
.nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* 主要内容区域 */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    min-height: calc(100vh - 140px);
}

/* 轮播图样式 */
.hero-section {
    margin-top: 20px;
    margin-bottom: 50px;
}

.slider-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.slider {
    position: relative;
    height: 400px;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

.slide.active {
    opacity: 1;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    padding: 40px;
}

.slide-content h3 {
    font-size: 28px;
    margin-bottom: 10px;
}

.slide-content p {
    font-size: 16px;
    opacity: 0.9;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: white;
    transform: scale(1.2);
}

.section-title {
    text-align: center;
    font-size: 32px;
    margin-bottom: 40px;
    color: #333;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

.news-grid {
    max-width: 1200px;
    margin: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    padding-bottom: 40px;
}

.news-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.news-card.featured {
    grid-column: span 2;
}

.news-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.news-card.featured img {
    height: 300px;
}

.news-content {
    padding: 20px;
}

.news-category {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 12px;
    margin-bottom: 10px;
}

.news-card h3 {
    font-size: 18px;
    margin-bottom: 10px;
    line-height: 1.4;
}

.news-card.featured h3 {
    font-size: 24px;
}

.news-card p {
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
    line-height: 1.5;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.news-date {
    color: #999;
    font-size: 12px;
}

.read-more {
    color: #667eea;
    text-decoration: none;
    font-weight: bold;
    font-size: 12px;
}

.read-more:hover {
    color: #764ba2;
}

.more-news {
    text-align: center;
}

.btn-more {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
}

.btn-more:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* 资讯列表页样式 */

.news-list {
    max-width: 1200px;
    margin: auto;
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding: 20px 0 40px 0;
}

.news-item {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    display: flex;
    transition: all 0.3s ease;
}

.news-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.news-image {
    flex-shrink: 0;
    width: 300px;
}

.news-image img {
    margin: 10px;
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.news-details {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    color: #999;
}

.news-item h3 {
    font-size: 20px;
    margin-bottom: 15px;
    line-height: 1.4;
}

.news-item p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
    flex: 1;
}

.read-more-link {
    color: #667eea;
    text-decoration: none;
    font-weight: bold;
    align-self: flex-start;
}

.read-more-link:hover {
    color: #764ba2;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 40px 0 40px 0;
}

.page-btn {
    padding: 10px 15px;
    border: 2px solid #667eea;
    background: white;
    color: #667eea;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.page-btn:hover:not(:disabled),
.page-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 文章详情页样式 */
.breadcrumb {
    margin-bottom: 30px;
    color: #666;
}

.breadcrumb a {
    color: #667eea;
    text-decoration: none;
}

.breadcrumb a:hover {
    color: #764ba2;
}

.breadcrumb span {
    margin: 0 10px;
}

.breadcrumb .current {
    color: #333;
}

.article-detail {
    background: white;
    border-radius: 15px;
    padding: 40px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    margin-bottom: 40px;
}

.article-header {
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.article-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.article-category {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 12px;
}

.article-date,
.article-views {
    color: #666;
    font-size: 14px;
}

.article-title {
    font-size: 32px;
    line-height: 1.3;
    margin-bottom: 15px;
    color: #333;
}

.article-author {
    color: #666;
    font-size: 14px;
}

.article-image {
    margin-bottom: 30px;
    text-align: center;
}

.article-image img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.article-content {
    font-size: 16px;
    line-height: 1.8;
    color: #333;
}

.article-content h2 {
    font-size: 24px;
    margin: 30px 0 15px 0;
    color: #333;
    border-left: 4px solid #667eea;
    padding-left: 15px;
}

.article-content p {
    text-indent: 2ch;
    line-height: 2.5;
    margin-bottom: 20px;
}

.article-content p img{
    display: block;
    margin: auto;
}

.article-content ul {
    margin: 20px 0;
    padding-left: 30px;
}

.article-content li {
    margin-bottom: 8px;
}

.content-image {
    text-align: center;
    margin: 30px 0;
}

.content-image img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.image-caption {
    color: #666;
    font-size: 14px;
    margin-top: 10px;
    font-style: italic;
}

blockquote {
    border-left: 4px solid #667eea;
    background: #f8f9fa;
    padding: 20px;
    margin: 30px 0;
    border-radius: 0 10px 10px 0;
}

blockquote p {
    margin-bottom: 10px;
    font-style: italic;
}

blockquote cite {
    color: #666;
    font-size: 14px;
}

.article-tags {
    display: flex;
    gap: 10px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.tag {
    background: #f0f0f0;
    color: #666;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 12px;
}

.article-share {
    border-top: 1px solid #eee;
    padding-top: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.share-btn {
    padding: 8px 15px;
    border: 1px solid #ddd;
    background: white;
    color: #666;
    border-radius: 20px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.share-btn:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.related-articles {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.related-articles h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: #333;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 20px;
}

.related-item {
    display: flex;
    gap: 15px;
    padding: 15px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.related-item:hover {
    background: #f8f9fa;
}

.related-item img {
    width: 200px;
    height: 140px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

.related-content h1 {
    color: #999;
    font-size: 14px;
    line-height: 1.4;
    margin-bottom: 5px;
}

.related-date {
    color: #666;
    font-size: 12px;
}

/* 页脚样式 */
.footer {
    background: #333;
    color: white;
    text-align: center;
    padding: 20px 0;
    margin-top: auto;
}

.footer .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer p {
    font-size: 14px;
    opacity: 0.8;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-container {
        padding: 0 15px;
        height: 60px;
    }

    .nav-logo h2 {
        font-size: 20px;
    }

    .nav-menu {
        gap: 15px;
    }

    .nav-link {
        font-size: 14px;
        padding: 8px 12px;
    }

    .container {
        padding: 0 15px;
    }

    .slider {
        height: 250px;
    }

    .slide-content {
        padding: 20px;
    }

    .slide-content h3 {
        font-size: 20px;
    }

    .slide-content p {
        font-size: 14px;
    }

    .section-title {
        font-size: 24px;
    }

    .news-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .news-card.featured {
        grid-column: span 1;
    }

    .news-item {
        flex-direction: column;
    }

    .news-image {
        width: 100%;
    }


    .article-detail {
        padding: 20px;
    }

    .article-title {
        font-size: 24px;
    }

    .article-meta {
        gap: 10px;
    }

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

    .related-item {
        flex-direction: row;
    }

    .pagination {
        gap: 5px;
    }

    .page-btn {
        padding: 8px 12px;
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .nav-menu {
        gap: 10px;
    }

    .nav-link {
        font-size: 12px;
        padding: 6px 10px;
    }

    .slider {
        height: 200px;
    }

    .slide-content {
        padding: 15px;
    }

    .slide-content h3 {
        font-size: 16px;
    }

    .article-title {
        font-size: 20px;
    }

    .article-content h2 {
        font-size: 20px;
    }

    .related-item {
        flex-direction: column;
    }

    .related-item img {
        width: 100%;
        height: 120px;
    }
}
