@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700&display=swap');

body {
    margin: 0;
    padding: 0;
    background: #f4f7f9;
    font-family: 'Roboto', sans-serif;
    color: #333;
}

/* 固定顶部及导航 */
.fixed-top {
    width: 100%;
    background-color: #35374C;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 500;
}

/* 采用 nav-pills 生成导航项 */
.nav.nav-pills {
    gap: 0.5rem;
}

.nav-pills .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
    font-size: 18px;
    color: #fff;
    transition: background 0.3s, color 0.3s;
    border: none;
    background: transparent;
    border-radius: 5px;
}

.nav-pills .nav-link:hover {
    background: #DF1A54;
    color: #fff;
}

.nav-pills .nav-link.active {
    background: #2196F3; /* 蓝色高亮 */
    color: #fff;
}

/* Loader 效果 */
.cssloader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 50vh;
}

.sh1, .sh2 {
    width: 0;
    height: 0;
    border-style: solid;
}

.sh1 {
    border-width: 50px 50px 0 0;
    border-color: #354952 transparent transparent transparent;
    margin: 0 auto;
    animation: shk1 1s ease-in-out infinite;
}

.sh2 {
    border-width: 0 0 50px 50px;
    border-color: transparent transparent #df1a54 transparent;
    margin-top: -50px;
    animation: shk2 1s ease-in-out infinite alternate;
}

@keyframes shk1 {
    0% { transform: rotate(-360deg); }
    100% { transform: rotate(0deg); }
}

@keyframes shk2 {
    0% { transform: rotate(360deg); }
    100% { transform: rotate(0deg); }
}

.lt {
    margin-top: 2rem;
    font-size: 1.25rem;
    letter-spacing: 2px;
    color: #000;
    font-family: Simsun, sans-serif;
    text-align: center;
    font-weight: 300;
}

/* 新闻卡片美化：采用全新布局 */
.news-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin: 1.5rem auto;
    transition: transform 0.3s, box-shadow 0.3s;
}

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

.news-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    margin-right: 1rem;
    border: 1px solid #ddd;
}

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

.news-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin: 1.5rem auto;
    padding: 1rem;
    display: flex;
    align-items: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

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


/* 新闻内容 */
.news-content {
    padding: 1rem;
}

.news-content .badge {
    font-size: 0.75rem;
}

.news-content .title a {
    text-decoration: none;
    color: #333;
    font-weight: bold;
    transition: color 0.3s;
}

.news-content .title a:hover {
    color: #007bff;
}

.mg-blog-meta {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    color: #888;
}

.mg-content {
    margin-top: 0.75rem;
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* 所有分页链接居中显示 */
.pagination .page-item .page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    overflow: hidden;
    text-align: center;
    cursor: pointer;
}

/* 数字分页按钮，保留圆形样式 */
.pagination .page-item .page-number,
.page-dot-prev, .page-dot-next {
    border-radius: 50%;
    width: 40px;
    height: 40px;
    line-height: 38px;
    font-size: 16px;
    color: #007bff;
}

.page-dot-prev::after, 
.page-dot-next::after {
    font-family: "bootstrap-icons";
    content: "\f5d4";
    color: #007bff;
}

.page-dot-prev:hover::after {
    font-family: "bootstrap-icons";
    content: "\f276";
    color: #fff;
}

.page-dot-next:hover::after {
    font-family: "bootstrap-icons";
    content: "\f277";
    color: #fff;
}

/* 对于上一页和下一页，调整为自动宽度，并设置内边距 */
.pagination .page-item .page-btn-prev,
.pagination .page-item .page-btn-next {
    border-radius: 20px;
    padding: 0 10px;
    height: 40px;
    line-height: 40px;
    font-size: 14px;
    color: #007bff;
}

.pagination .page-item .page-link:hover {
    background-color: #DF1A54;
    border-color: #DF1A54;
    color: #fff;
}

/* 激活状态 */
.pagination .page-item.active .page-link {
    background-color: #007bff;
    border-color: #007bff;
    color: #fff;
}

/* 响应式优化 */
@media (max-width: 767.98px) {
    .news-card {
        margin: 1rem auto;
    }
}