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


body {

    font-family:
        Arial,
        "Helvetica Neue",
        "PingFang SC",
        "Microsoft YaHei",
        sans-serif;

    background: #f7f7f5;

    color: #111;

    line-height: 1.6;
}


/* =========================
   Header
========================= */

.site-header {

    background: #fff;

    border-bottom:
        1px solid #ddd;

    position: sticky;

    top: 0;

    z-index: 100;

}


.header-inner {

    max-width: 1400px;

    margin: auto;

    padding: 22px 40px;

    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 30px;

}


.logo {

    color: #111;

    text-decoration: none;

    font-size: 28px;

    font-weight: 800;

    letter-spacing: -1px;

}


/* =========================
   Search
========================= */

.search-box {

    display: flex;

    height: 40px;

    border:
        1px solid #ccc;

    background: #fff;

}


.search-box input {

    width: 220px;

    border: none;

    outline: none;

    padding: 0 14px;

    font-size: 14px;

}


.search-box button {

    border: none;

    border-left:
        1px solid #ddd;

    background: #111;

    color: white;

    padding: 0 18px;

    cursor: pointer;

}


/* =========================
   分类
========================= */

.category-nav {

    background: #fff;

    border-bottom:
        1px solid #ddd;

}


.category-inner {

    max-width: 1400px;

    margin: auto;

    padding: 0 40px;

    height: 58px;

    display: flex;

    align-items: center;

    gap: 36px;

}


.category-button {

    height: 58px;

    border: none;

    background: transparent;

    color: #777;

    cursor: pointer;

    font-size: 15px;

    font-weight: 600;

    position: relative;

}


.category-button.active {

    color: #111;

}


.category-button.active::after {

    content: "";

    position: absolute;

    bottom: 0;

    left: 0;

    right: 0;

    height: 3px;

    background: #111;

}


/* =========================
   主内容
========================= */

.main-container {

    max-width: 1400px;

    margin: auto;

    padding:
        55px 40px 80px;

}


.page-heading {

    display: flex;

    justify-content: space-between;

    align-items: end;

    border-bottom:
        2px solid #111;

    padding-bottom: 18px;

    margin-bottom: 30px;

}


.small-heading {

    font-size: 11px;

    color: #777;

    letter-spacing: 2px;

}


.page-heading h1 {

    font-size: 36px;

    line-height: 1.1;

}


.news-count {

    font-size: 13px;

    color: #777;

}


/* =========================
   新闻网格
========================= */

.news-grid {

    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 45px 28px;

}


/* =========================
   新闻卡片
========================= */

.news-card {

    min-width: 0;

}


/* =========================
   新闻图片
========================= */

.news-image-wrapper {

    display: block;

    width: 100%;

    aspect-ratio: 16 / 10;

    overflow: hidden;

    background: #ddd;

}


.news-image {

    width: 100%;

    height: 100%;

    object-fit: cover;

    display: block;

    transition:
        transform .45s ease;

}


.news-image-wrapper:hover
.news-image {

    transform: scale(1.05);

}


.no-image {

    display: flex;

    align-items: center;

    justify-content: center;

    background: #e5e5e5;

}


.no-image-text {

    color: #999;

    font-size: 14px;

}


/* =========================
   新闻信息
========================= */

.news-info {

    padding-top: 14px;

}


.news-category {

    font-size: 11px;

    font-weight: 700;

    color: #777;

    letter-spacing: 1px;

}


.news-title {

    display: block;

    color: #111;

    text-decoration: none;

    font-size: 21px;

    font-weight: 700;

    line-height: 1.35;

    margin-top: 6px;

}


.news-title:hover {

    text-decoration: underline;

}


.news-description {

    color: #666;

    font-size: 14px;

    margin-top: 8px;

}


.news-date {

    display: block;

    color: #999;

    font-size: 11px;

    margin-top: 10px;

}


/* =========================
   第一篇大新闻
========================= */

.news-card.featured {

    grid-column: span 2;

}


.news-card.featured
.news-image-wrapper {

    aspect-ratio: 16 / 9;

}


.news-card.featured
.news-title {

    font-size: 30px;

}


/* =========================
   Loading
========================= */

.loading {

    text-align: center;

    padding: 80px;

    color: #777;

}


/* =========================
   Empty
========================= */

.empty-message {

    display: none;

    text-align: center;

    padding: 100px 20px;

}


.empty-message h2 {

    font-size: 24px;

}


.empty-message p {

    color: #777;

    margin-top: 8px;

}


/* =========================
   分页
========================= */

.pagination {

    display: flex;

    justify-content: center;

    align-items: center;

    gap: 10px;

    margin-top: 60px;

    min-height: 42px;

}


.pagination-numbers {

    display: flex;

    align-items: center;

    gap: 6px;

}


.pagination-button {

    min-width: 40px;

    height: 40px;

    padding: 0 12px;

    border:
        1px solid #d5d5d5;

    background: #fff;

    color: #111;

    font-size: 13px;

    cursor: pointer;

    transition:
        background .2s ease,
        color .2s ease,
        border-color .2s ease;

}


.pagination-button:hover:not(:disabled) {

    border-color: #111;

    background: #f2f2f2;

}


.pagination-button.active {

    background: #111;

    border-color: #111;

    color: #fff;

    font-weight: 700;

}


.pagination-button:disabled {

    color: #aaa;

    background: #f5f5f5;

    border-color: #e5e5e5;

    cursor: not-allowed;

}


.pagination-ellipsis {

    min-width: 24px;

    text-align: center;

    color: #777;

    font-size: 14px;

}


.pagination-prev,
.pagination-next {

    min-width: 70px;

}


/* =========================
   Footer
========================= */

.site-footer {

    background: #111;

    color: white;

}


.footer-inner {

    max-width: 1400px;

    margin: auto;

    padding: 45px 40px;

    display: flex;

    justify-content: space-between;

}


.footer-inner p {

    color: #999;

    font-size: 13px;

}


.footer-copy {

    color: #777;

    font-size: 12px;

}


/* =========================
   平板
========================= */

@media (max-width: 900px) {

    .news-grid {

        grid-template-columns:
            repeat(2, 1fr);

    }

}


/* =========================
   手机
========================= */

@media (max-width: 650px) {

    .header-inner {

        flex-direction: column;

        align-items: stretch;

        padding: 18px 20px;

    }


    .logo {

        font-size: 23px;

    }


    .search-box input {

        flex: 1;

        width: auto;

    }


    .category-inner {

        padding: 0 20px;

        gap: 25px;

        overflow-x: auto;

    }


    .main-container {

        padding:
            35px 20px 60px;

    }


    .page-heading h1 {

        font-size: 29px;

    }


    .news-grid {

        grid-template-columns: 1fr;

    }


    .news-card.featured {

        grid-column: span 1;

    }


    .news-card.featured
    .news-title {

        font-size: 25px;

    }


    /* =====================
       手机分页
    ===================== */

    .pagination {

        gap: 6px;

        margin-top: 45px;

        width: 100%;

    }


    .pagination-numbers {

        gap: 4px;

    }


    .pagination-button {

        min-width: 36px;

        height: 36px;

        padding: 0 8px;

        font-size: 12px;

    }


    .pagination-prev,
    .pagination-next {

        min-width: 58px;

        padding: 0 7px;

    }


    .pagination-ellipsis {

        min-width: 16px;

    }


    .footer-inner {

        padding:
            35px 20px;

        flex-direction: column;

        gap: 20px;

    }

}


/* =========================
   超小屏手机
========================= */

@media (max-width: 420px) {

    .pagination {

        gap: 4px;

    }


    .pagination-numbers {

        gap: 2px;

    }


    .pagination-button {

        min-width: 32px;

        height: 34px;

        padding: 0 6px;

    }


    .pagination-prev,
    .pagination-next {

        min-width: 52px;

        font-size: 11px;

    }


    .pagination-ellipsis {

        min-width: 12px;

    }

}
