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

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

/* 导航栏样式 */
.navbar {
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

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

.logo a {
    font-size: 1.5rem;
    font-weight: bold;
    color: #2c3e50;
    text-decoration: none;
}

.nav-links a {
    color: #2c3e50;
    text-decoration: none;
    margin: 0 1rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #3498db;
}

.search-box {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.search-box input {
    padding: 0.75rem 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    width: 250px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #3498db;
}

.search-box button {
    padding: 0.75rem 1.5rem;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.search-box button:hover {
    background-color: #2980b9;
}


 /* 添加横幅图片样式 */
 .banner-section {
    width: 100%;
    position: relative;
    overflow: hidden;
    margin-bottom: 3rem;
}

.banner-image-container {
    position: relative;
    width: 100%;
    height: 300px;
}

.banner-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.banner-title {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    width: 100%;
}

.banner-title h2 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.banner-title p {
    font-size: 1.2rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.banner-description {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
    text-align: center;
}

.banner-description p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
    margin-bottom: 1.5rem;
}


/* 热门文章板块样式 */
.featured-section {
    display: flex;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.featured-main {
    flex: 2;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.featured-ad {
    flex: 1;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
    height: fit-content;
    position: sticky;
    top: 2rem;
}


.featured-article {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.featured-article img {
    width: 100%;
    height: 400px;
    object-fit: cover;
}

.featured-article-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
}

.featured-article-content h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.featured-article-content p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.featured-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.featured-item {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.featured-item:hover {
    transform: translateY(-5px);
}

.featured-item img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.featured-item-content {
    padding: 1rem;
    background: white;
}

.featured-item-content h4 {
    font-size: 1.1rem;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.featured-item-content p {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.4;
}

.ad-placeholder {
    width: 100%;
    height: 600px;
    background: #eee;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-size: 1.2rem;
}

@media (max-width: 1024px) {
    .featured-section {
        flex-direction: column;
    }

    .featured-main {
        flex: none;
    }

    .featured-ad {
        position: static;
    }

    .featured-list {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .featured-list {
        grid-template-columns: 1fr;
    }

    .featured-article img {
        height: 300px;
    }

    .featured-article-content h3 {
        font-size: 1.5rem;
    }
} 
/* 主要内容样式 */
main {
    margin-top: 80px;
    padding: 2rem;
}

.category-section {
    max-width: 1200px;
    margin: 0 auto 3rem;
}

.category-section h2 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    text-align: left;
}

.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    padding: 1rem;
}

.card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid #eee;
}

.card-header {
    display: flex;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #eee;
    background: #f8f9fa;
}

.card-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
    margin-right: 1rem;
    border-radius: 4px;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.card-content {
    padding: 1.5rem;
}

.card-content p {
    color: #666;
    margin-bottom: 1.25rem;
    font-size: 0.95rem;
    line-height: 1.5;
}

.btn {
    display:inline-blockright;
    padding: 0.65rem 1.5rem;
    background-color: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: #2980b9;
}

/* 页脚样式 */
footer {
    background-color: #2c3e50;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    padding: 0 2rem;
}

.footer-section h4 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.footer-section a {
    display: block;
    color: #ecf0f1;
    text-decoration: none;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #3498db;
}

.footer-bottom {
    text-align: center;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    .search-box {
        width: 100%;
        justify-content: center;
    }

    .search-box input {
        width: 100%;
        max-width: 300px;
    }

    .card-container {
        grid-template-columns: 1fr;
    }
}

/* 关于我们页面样式 */
.about-section {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
}

.about-section h2 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    text-align: center;
}

.about-content {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.about-content h3 {
    color: #2c3e50;
    margin: 1.5rem 0 1rem;
}

.about-content p {
    color: #666;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.about-content ul {
    list-style-type: disc;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

/* 隐私政策页面样式 */
.privacy-section {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
}

.privacy-section h2 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    text-align: center;
}

.privacy-content {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.privacy-content h3 {
    color: #2c3e50;
    margin: 1.5rem 0 1rem;
}

.privacy-content p {
    color: #666;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.privacy-content ul {
    list-style-type: disc;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

/* 用户条款页面样式 */
.terms-section {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
}

.terms-section h2 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    text-align: center;
}

.terms-content {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.terms-content h3 {
    color: #2c3e50;
    margin: 1.5rem 0 1rem;
}

.terms-content p {
    color: #666;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.terms-content ul {
    list-style-type: disc;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

/* 搜索结果样式 */
#searchResults {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

#searchResults h2 {
    font-size: 2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    text-align: left;
}

.no-results {
    text-align: center;
    padding: 3rem 1rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.no-results h2 {
    color: #e74c3c;
    margin-bottom: 1rem;
}

.no-results p {
    color: #666;
    font-size: 1.1rem;
}

/* 导航栏右侧布局 */
.nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

/* 语言切换按钮样式 */
.language-switch {
    display: flex;
    gap: 0.5rem;
    background: #f8f9fa;
    padding: 0.25rem;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
}

.lang-btn {
    padding: 0.5rem 1rem;
    border: none;
    background: none;
    color: #666;
    font-size: 0.9rem;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.lang-btn:hover {
    color: #3498db;
}

.lang-btn.active {
    background: #3498db;
    color: white;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .nav-right {
        flex-direction: column;
        gap: 1rem;
        width: 100%;
    }

    .language-switch {
        width: 100%;
        justify-content: center;
    }

    .search-box {
        width: 100%;
    }

    .search-box input {
        width: 100%;
    }
} 