* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, "Microsoft YaHei", sans-serif;
    background: #f5f7fb;
    color: #1f2937;
    font-size: 14px;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    width: 1200px;
    margin: 0 auto;
}

/* header */
.site-header {
    background: #fff;
    border-bottom: 1px solid #edf0f5;
}

.header-inner {
    height: 68px;
    display: flex;
    align-items: center;
}

.logo {
    width: 210px;
}

.logo a {
    color: #ff5b22;
    font-size: 28px;
    font-weight: 800;
    font-style: italic;
}

.nav {
    flex: 1;
    display: flex;
    gap: 34px;
}

.nav a {
    height: 68px;
    line-height: 68px;
    color: #1f2937;
    font-weight: 600;
    position: relative;
}

.nav a:hover,
.nav a.active {
    color: #ff5b22;
}

.nav a.active::after {
    content: "";
    height: 2px;
    background: #ff5b22;
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
}

.search-box form {
    width: 300px;
    height: 38px;
    display: flex;
    background: #f7f8fb;
    border: 1px solid #e8ecf2;
    border-radius: 20px;
    overflow: hidden;
}

.search-box input {
    flex: 1;
    border: 0;
    outline: 0;
    background: transparent;
    padding: 0 16px;
    color: #666;
}

.search-box button {
    width: 64px;
    border: 0;
    background: #ff5b22;
    color: #fff;
    cursor: pointer;
}

/* banner */
.news-banner {
    height: 150px;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    color: #fff;
    position: relative;
}

.news-banner::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(5, 18, 42, .58);
}

.news-banner .container {
    height: 150px;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.news-banner h1 {
    font-size: 34px;
    margin-bottom: 12px;
}

.news-banner p {
    color: #d8e4f6;
    font-size: 16px;
}

/* common */
.main {
    padding: 22px 0 42px;
}

.breadcrumb {
    color: #8b95a5;
    margin-bottom: 16px;
    font-size: 13px;
}

.breadcrumb a:hover {
    color: #ff5b22;
}

.news-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 24px;
}

/* list left */
.news-main,
.article-detail-main {
    min-width: 0;
}

.news-tabs {
    background: #fff;
    border: 1px solid #edf0f5;
    border-radius: 8px;
    height: 58px;
    display: flex;
    align-items: center;
    padding: 0 14px;
    gap: 16px;
    margin-bottom: 16px;
}

.news-tabs a {
    padding: 9px 18px;
    border-radius: 4px;
    color: #4b5563;
}

.news-tabs a.active,
.news-tabs a:hover {
    background: #ff5b22;
    color: #fff;
}

.article-list {
    background: #fff;
    border: 1px solid #edf0f5;
    border-radius: 8px;
    padding: 0 18px;
}

.article-item {
    display: grid;
    grid-template-columns: 210px 1fr;
    gap: 20px;
    padding: 18px 0;
    border-bottom: 1px solid #edf0f5;
}

.article-item:last-child {
    border-bottom: 0;
}

.article-img {
    width: 210px;
    height: 120px;
    border-radius: 6px;
    overflow: hidden;
    background: #eef1f5;
}

.article-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: .3s;
}

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

.article-info {
    min-width: 0;
}

.article-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.article-title-row span {
    flex-shrink: 0;
    border: 1px solid #ffb399;
    color: #ff5b22;
    background: #fff7f3;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
}

.article-title-row h2 {
    font-size: 20px;
    line-height: 1.45;
    font-weight: 700;
}

.article-title-row h2 a:hover {
    color: #ff5b22;
}

.article-info p {
    color: #6b7280;
    line-height: 1.8;
    height: 50px;
    overflow: hidden;
    margin-bottom: 14px;
}

.article-meta {
    display: flex;
    gap: 22px;
    color: #9aa2af;
    font-size: 13px;
}

.article-meta em {
    font-style: normal;
}

/* sidebar */
.news-sidebar {
    min-width: 0;
}

.side-card {
    background: #fff;
    border: 1px solid #edf0f5;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 18px;
}

.side-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.side-title h3 {
    font-size: 20px;
    padding-left: 24px;
    position: relative;
}

.side-title h3::before {
    content: "🔥";
    position: absolute;
    left: 0;
    top: 0;
    font-size: 18px;
}

.latest-news .side-title h3::before {
    content: "📰";
}

.tag-card .side-title h3::before {
    content: "🏷";
}

.side-title a {
    color: #8b95a5;
    font-size: 13px;
}

.side-title a:hover {
    color: #ff5b22;
}

/* 推荐模板：单列大图，图片固定150px */
.template-recommend-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.template-recommend-item {
    border: 1px solid #edf0f5;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    transition: .25s;
}

.template-recommend-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(15, 23, 42, .08);
}

.template-recommend-img {
    display: block;
    width: 100%;
    height: 150px;
    overflow: hidden;
    background: #eef1f5;
}

.template-recommend-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: .3s;
}

.template-recommend-item:hover .template-recommend-img img {
    transform: scale(1.04);
}

.template-recommend-info {
    padding: 12px 14px 14px;
}

.template-recommend-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.template-recommend-tags span {
    display: inline-block;
    font-size: 12px;
    color: #8b95a5;
    background: #f7f8fb;
    border: 1px solid #edf0f5;
    padding: 4px 8px;
    border-radius: 4px;
}

.template-recommend-info h4 {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 12px;
    max-height: 52px;
    overflow: hidden;
}

.template-recommend-info h4 a:hover {
    color: #ff5b22;
}

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

.template-recommend-meta strong {
    color: #ff5b22;
    font-size: 22px;
    font-weight: 700;
}

.template-recommend-meta span {
    color: #9aa2af;
    font-size: 12px;
}

/* 兼容旧的推荐模板class，防止旧HTML样式乱 */
.template-grid-small {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.template-small-card {
    border: 1px solid #edf0f5;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.template-small-img {
    display: block;
    width: 100%;
    height: 150px;
    overflow: hidden;
    background: #eef1f5;
}

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

.template-small-info {
    padding: 12px 14px 14px;
}

.template-small-info h4 {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 12px;
    max-height: 52px;
    overflow: hidden;
}

.template-small-info h4 a:hover {
    color: #ff5b22;
}

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

.template-small-meta strong {
    color: #ff5b22;
    font-size: 22px;
}

.template-small-meta span {
    color: #9aa2af;
    font-size: 12px;
}

/* latest sidebar */
.latest-item {
    display: grid;
    grid-template-columns: 92px 1fr;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #edf0f5;
}

.latest-item:last-child {
    border-bottom: 0;
}

.latest-img {
    width: 92px;
    height: 58px;
    border-radius: 4px;
    overflow: hidden;
    background: #eef1f5;
}

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

.latest-item h4 {
    font-size: 14px;
    line-height: 1.5;
    height: 42px;
    overflow: hidden;
}

.latest-item h4 a:hover {
    color: #ff5b22;
}

.latest-item p {
    color: #9aa2af;
    font-size: 12px;
    margin-top: 4px;
}

/* tags */
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-list a {
    background: #f7f8fb;
    border: 1px solid #edf0f5;
    color: #6b7280;
    padding: 7px 13px;
    border-radius: 4px;
    font-size: 13px;
}

.tag-list a:hover {
    background: #ff5b22;
    border-color: #ff5b22;
    color: #fff;
}

/* custom ad */
.custom-banner {
    height: 195px;
    border-radius: 8px;
    overflow: hidden;
    background: linear-gradient(120deg, #247cff, #58b7ff);
    position: relative;
    color: #fff;
}

.custom-banner::before {
    content: "";
    width: 160px;
    height: 160px;
    border-radius: 50%;
    background: rgba(255,255,255,.15);
    position: absolute;
    right: -35px;
    bottom: -45px;
}

.custom-banner::after {
    content: "⚽";
    position: absolute;
    right: 34px;
    bottom: 18px;
    font-size: 58px;
    opacity: .85;
}

.custom-text {
    padding: 28px 24px;
    position: relative;
    z-index: 2;
}

.custom-text h3 {
    font-size: 30px;
    margin-bottom: 10px;
}

.custom-text p {
    width: 220px;
    line-height: 1.7;
    color: #eef6ff;
    margin-bottom: 18px;
}

.custom-text a {
    display: inline-block;
    background: #ff5b22;
    color: #fff;
    padding: 9px 24px;
    border-radius: 22px;
    font-weight: 700;
}

/* pagination */
.page-box {
    margin-top: 24px;
    display: flex;
    justify-content: center;
    gap: 8px;
}

.page-box a,
.page-box span {
    min-width: 34px;
    height: 34px;
    line-height: 32px;
    padding: 0 12px;
    text-align: center;
    background: #fff;
    border: 1px solid #edf0f5;
    border-radius: 4px;
    color: #4b5563;
}

.page-box a:hover,
.page-box .current,
.page-box .active {
    background: #ff5b22;
    border-color: #ff5b22;
    color: #fff;
}

/* detail */
.article-main {
    padding-top: 24px;
}

.article-detail-card {
    background: #fff;
    border: 1px solid #edf0f5;
    border-radius: 8px;
    padding: 34px;
}

.article-head {
    border-bottom: 1px solid #edf0f5;
    padding-bottom: 24px;
    margin-bottom: 28px;
}

.article-head h1 {
    font-size: 30px;
    line-height: 1.45;
    margin-bottom: 16px;
}

.article-head-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    color: #8b95a5;
    margin-bottom: 18px;
}

.article-desc {
    background: #f7f8fb;
    border-left: 4px solid #ff5b22;
    color: #6b7280;
    line-height: 1.8;
    padding: 14px 18px;
}

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

.article-content p {
    margin-bottom: 18px;
}

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

.article-content h2,
.article-content h3 {
    margin: 28px 0 14px;
    color: #1f2937;
}

/* prev next */
.prev-next-card {
    background: #fff;
    border: 1px solid #edf0f5;
    border-radius: 8px;
    margin-top: 18px;
    padding: 18px 24px;
    line-height: 2;
}

.prev-next-card span {
    color: #6b7280;
}

.prev-next-card a:hover {
    color: #ff5b22;
}

/* related */
.related-card {
    background: #fff;
    border: 1px solid #edf0f5;
    border-radius: 8px;
    margin-top: 18px;
    padding: 0 20px 22px;
}

.detail-title {
    height: 58px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
}

.detail-title h2 {
    font-size: 20px;
    padding-left: 12px;
    position: relative;
}

.detail-title h2::before {
    content: "";
    width: 4px;
    height: 18px;
    background: #ff5b22;
    position: absolute;
    left: 0;
    top: 4px;
    border-radius: 2px;
}

.related-list {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    padding-top: 18px;
}

.related-item {
    display: block;
}

.related-item img {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 5px;
    margin-bottom: 10px;
}

.related-item h3 {
    font-size: 15px;
    line-height: 1.5;
    height: 44px;
    overflow: hidden;
}

.related-item h3:hover {
    color: #ff5b22;
}

.related-item p {
    color: #9aa2af;
    font-size: 12px;
    margin-top: 8px;
}

/* footer */
.footer {
    background: #fff;
    border-top: 1px solid #edf0f5;
    padding: 24px 0;
    text-align: center;
    color: #7b8494;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 34px;
    margin-bottom: 14px;
}

.footer-links a:hover {
    color: #ff5b22;
}

/* mobile */
@media (max-width: 1200px) {
    .container {
        width: 94%;
    }
}

@media (max-width: 900px) {
    .header-inner {
        height: auto;
        flex-wrap: wrap;
        padding: 14px 0;
    }

    .logo {
        width: 100%;
        margin-bottom: 10px;
    }

    .nav {
        width: 100%;
        overflow-x: auto;
        gap: 20px;
        margin-bottom: 12px;
    }

    .nav a {
        height: 40px;
        line-height: 40px;
        white-space: nowrap;
    }

    .search-box,
    .search-box form {
        width: 100%;
    }

    .news-layout {
        grid-template-columns: 1fr;
    }

    .article-item {
        grid-template-columns: 120px 1fr;
        gap: 14px;
    }

    .article-img {
        width: 120px;
        height: 86px;
    }

    .article-title-row {
        display: block;
    }

    .article-title-row span {
        display: inline-block;
        margin-bottom: 6px;
    }

    .article-title-row h2 {
        font-size: 16px;
    }

    .article-info p {
        display: none;
    }

    .template-recommend-img,
    .template-small-img {
        height: 150px;
    }

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

    .article-detail-card {
        padding: 22px;
    }

    .article-head h1 {
        font-size: 24px;
    }
}