/* 公共样式文件 - 首页、列表页、内容页 共用 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Microsoft YaHei", Arial, sans-serif;
}

body {
    background-color: #f8fcf9;
    color: #333;
    line-height: 1.8;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

header {
    background-color: #ffffff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 999;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: #28a745;
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-menu li {
    margin-left: 30px;
}

.nav-menu a {
    text-decoration: none;
    color: #555;
    font-size: 16px;
    transition: color 0.3s;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: #28a745;
    font-weight: 500;
}

.mobile-btn {
    display: none;
    font-size: 24px;
    cursor: pointer;
}

.btn {
    display: inline-block;
    padding: 10px 25px;
    background-color: #28a745;
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    transition: background 0.3s;
    border: none;
    cursor: pointer;
    font-size: 15px;
}

.btn:hover {
    background-color: #218838;
}

.card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: transform 0.3s;
}

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

.ad-box {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px;
    margin: 20px 0;
    border-radius: 6px;
    text-align: center;
}

footer {
    background-color: #2c3e50;
    color: #fff;
    padding: 40px 0 20px;
    margin-top: 60px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-col {
    flex: 1;
    min-width: 250px;
}

.footer-col h3 {
    color: #28a745;
    margin-bottom: 15px;
    font-size: 18px;
}

.footer-col p,
.footer-col a {
    color: #ddd;
    text-decoration: none;
    line-height: 1.8;
}

.copyright {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #444;
    color: #aaa;
    font-size: 14px;
}

/* 首页样式 */
.banner {
    background: linear-gradient(to right, #e6f7e9, #f1fcf4);
    padding: 60px 0;
}

.banner-content {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
}

.banner-text {
    flex: 1;
    min-width: 300px;
}

.banner-text h1 {
    font-size: 36px;
    color: #2c3e50;
    margin-bottom: 20px;
    line-height: 1.4;
}

.banner-text p {
    font-size: 17px;
    color: #666;
    margin-bottom: 30px;
}

.banner-img {
    flex: 1;
    min-width: 300px;
    text-align: center;
}

.banner-img img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
}

.section-title {
    text-align: center;
    margin: 40px 0;
    color: #2c3e50;
}

.section-title h2,
.section-title h3 {
    display: inline-block;
    padding-bottom: 10px;
    position: relative;
}

.section-title h2::after,
.section-title h3::after {
    content: '';
    width: 60px;
    height: 3px;
    background-color: #28a745;
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.core-section {
    padding: 40px 0;
}

.grid-box {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.core-item {
    padding: 30px;
    text-align: center;
}

.core-item h3 {
    color: #28a745;
    margin: 15px 0;
    font-size: 20px;
}

.core-item p {
    color: #666;
}

.article-list {
    padding: 40px 0;
}

.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.article-card {
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.article-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 15px;
}

.article-card h2 {
    font-size: 18px;
    margin-bottom: 10px;
    line-height: 1.5;
}

.article-card a {
    text-decoration: none;
    color: #2c3e50;
    transition: color 0.3s;
}

.article-card a:hover {
    color: #28a745;
}

.article-card p {
    color: #777;
    font-size: 14px;
    line-height: 1.6;
    flex-grow: 1;
}

/* 列表页样式 */
.list-wrapper {
    margin: 30px 0;
}

.list-title {
    font-size: 26px;
    color: #2c3e50;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

/* 内容页样式 */
.content-wrapper {
    display: flex;
    gap: 30px;
    margin: 30px 0;
}

.article-left {
    flex: 0 0 70%;
    max-width: 70%;
}

.article-right {
    flex: 0 0 30%;
    max-width: 30%;
}

.article-container {
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.05);
}

.article-title {
    font-size: 30px;
    color: #2c3e50;
    margin-bottom: 15px;
    line-height: 1.4;
}

.article-meta {
    color: #999;
    font-size: 14px;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px dashed #eee;
}

.article-content {
    font-size: 16px;
    color: #444;
}

.content-title {
    font-size: 20px;
    color: #2c3e50;
    margin: 25px 0 15px;
    font-weight: bold;
}

.article-content p {
    margin-bottom: 15px;
    text-align: justify;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
    display: block;
}

.sidebar-box {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.05);
}

.sidebar-title {
    font-size: 18px;
    color: #28a745;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
    font-weight: bold;
}

.sidebar-question {
    font-size: 16px;
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 8px;
}

.sidebar-answer {
    color: #555;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px dashed #eee;
}

.sidebar-answer:last-child {
    border: none;
    margin: 0;
    padding: 0;
}

.today-list {
    list-style: none;
}

.today-list li {
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px dashed #eee;
}

.today-list li:last-child {
    margin: 0;
    padding: 0;
    border: none;
}

.today-list a {
    color: #333;
    text-decoration: none;
    font-size: 15px;
}

.today-list a:hover {
    color: #28a745;
}

.like-box {
    margin: 50px 0;
}

.like-title {
    font-size: 20px;
    color: #2c3e50;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #28a745;
    display: inline-block;
}

.like-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 15px;
}

.like-item {
    padding: 15px;
}

/* 横版图片（非正方形） */
.like-item img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 10px;
}

.like-item a {
    font-size: 15px;
    color: #333;
    text-decoration: none;
    line-height: 1.5;
}

.like-item a:hover {
    color: #28a745;
}

.faq-box {
    margin: 40px 0;
}

.faq-item {
    margin-bottom: 15px;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
}

.faq-question {
    background: #f1f9f3;
    padding: 15px 20px;
    font-weight: bold;
    color: #2c3e50;
    cursor: pointer;
}

.faq-answer {
    padding: 15px 20px;
    background: #fff;
    color: #555;
}

/* 响应式 */
@media (max-width: 992px) {
    .content-wrapper {
        flex-direction: column;
    }

    .article-left,
    .article-right {
        max-width: 100%;
        flex: 0 0 100%;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .mobile-btn {
        display: block;
    }

    .article-container {
        padding: 20px;
    }

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

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

    /* 手机端猜你喜欢 横版 */
    .like-item img {
        height: 90px !important;
    }

    .banner-text h1 {
        font-size: 28px;
        text-align: center;
    }

    .banner-text {
        text-align: center;
    }
}