:root {
  --body: linear-gradient(to bottom, #f7e1ff 0%, #f3f3f3 100%);
  --btn: #7300dd;
  --font: #333;
  --a: #333;
}

* {
  box-sizing: border-box;
}

body {
  line-height: 1.6;
  position: relative;
  min-height: 100vh;
  max-width: 100vw;
  overflow-x: hidden;
  margin: 0;
  color: var(--font);
  background: var(--body);
  background-size: contain;
}
html {
  font-size: 16px;
}
a {
  line-height: 20px;
  text-decoration: none;
  color: var(--a);
}

a:hover,
a:active {
  text-decoration: none;
}

strong {
  font-weight: bolder;
}
img {
  object-fit: cover;
  background-repeat: no-repeat;
  background-size: 100%;
}

.fx-r {
  display: flex;
  flex-direction: row;
}

.fx-h {
  display: flex;
  flex-direction: column;
}

.fx-ac {
  justify-content: center;
}

.fx-bc {
  align-items: center;
}

.flex-1 {
  flex: 1;
}

.jb {
  justify-content: space-between;
}

.hideText {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mobile-show {
  display: none;
}

.pc-show {
  display: flex;
}

.h-full {
  height: 100%;
}
.w-full {
  width: 100%;
}
.grid {
  display: grid;
}
.grid-cols-1 {
  grid-template-columns: repeat(1, minmax(0, 1fr));
}
.grid-cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.grid-cols-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
/* Header 样式改进 */
header {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 15px 20px;
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

/* Logo 区域样式 */
header .fx-r.fx-ac.fx-bc {
  display: flex;
  align-items: center;
  gap: 12px;
}

header img {
  width: 50px;
  aspect-ratio: 1/1;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

header img:hover {
  transform: scale(1.05);
}

header .fx-r.fx-ac.fx-bc a:nth-child(2) {
  text-decoration: none;
}

header .fx-r.fx-ac.fx-bc div {
  font-size: 22px;
  font-weight: 700;
  color: var(--btn);
  letter-spacing: -0.5px;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* 导航链接样式 */
nav {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 25px;
}

nav a {
  color: var(--font);
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  position: relative;
  transition: color 0.3s ease;
  padding: 8px 0;
}

nav a:hover {
  color: var(--btn);
}

nav a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--btn);
  transition: width 0.3s ease;
}

nav a:hover::after {
  width: 100%;
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  color: var(--font);
  cursor: pointer;
}
main {
  flex: 1;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
}
.article-link {
  text-decoration: none;
  color: inherit;
  display: block;
}
h3 {
  font-size: 24px;
}
/* 骨架屏样式 */
.skeleton-card {
  background-color: #f0f0f0;
  border-radius: 10px;
  overflow: hidden;
  height: 200px;
  position: relative;
  animation: skeleton-loading 1.5s infinite alternate;
}

@keyframes skeleton-loading {
  0% {
    background-color: #f0f0f0;
  }
  100% {
    background-color: #e0e0e0;
  }
}

/* 占位符样式 */
.placeholder {
  color: transparent;
  /* background-color: #f0f0f0; */
  border-radius: 4px;
  padding: 2px 0;
  width: 120px;
}

.per-section {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  min-height: 400px;
  grid-auto-rows: minmax(200px, auto);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 25px 0 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid #000000;
  min-height: 60px;
}

.section-title-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-header h3 {
  font-size: 22px;
  font-weight: 600;
  color: #333;
  margin: 0;
  position: relative;
  min-width: 120px;
}

.section-divider {
  flex-grow: 1;
  height: 1px;
  background-color: #eee;
  margin-left: 15px;
}

.view-all {
  color: #666;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s ease;
  display: flex;
  align-items: center;
  gap: 5px;
}

.view-all:hover {
  color: #333;
  text-decoration: underline;
}

/* 卡片样式 */
.article-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  background-color: #f8f9fa; /* 淡淡背景色 */
  border: 1px solid #e9ecef; /* 边框 */
  border-radius: 10px; /* 圆角 */
  padding: 10px; /* 内边距，增加内容与边框的距离 */
  transition: all 0.3s ease-in-out; /* 过渡效果移到这里统一管理 */
}
.article-card:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 8px rgba(0,0,0,0.05); /* 悬停时增加轻微阴影效果 */
}

.article-card img {
  width: 100%;
  height: 100%;
  border-radius: 8px; /* 调整图片圆角与卡片整体风格协调 */
  overflow: hidden;
}

.article-card p{
  padding: 0 8px 0 8px;
}
/* 卡片样式 */

/* 分页器样式 */
.pagination-container {
  margin: 20px auto;
  text-align: center;
  max-width: 700px;
  padding: 0 20px;
}

.pagination-info {
  margin-bottom: 30px;
  font-size: 16px;
  color: #666;
  font-weight: 500;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.page-btn, .page-number {
  padding: 10px 16px;
  border: 1px solid #e0e0e0;
  background: white;
  color: #333;
  text-decoration: none;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
  min-width: 44px;
  text-align: center;
  font-weight: 500;
}

.page-btn:hover, .page-number:hover {
  background: #f8f9fa;
  border-color: #007bff;
  transform: translateY(-1px);
}

.page-btn:disabled {
  background: #f5f5f5;
  color: #999;
  cursor: not-allowed;
  transform: none;
}

.page-number.active {
  background: #007bff;
  color: white;
  border-color: #007bff;
  font-weight: 600;
}

.page-numbers {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.page-jump {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 16px;
  font-size: 14px;
  color: #666;
}

.page-jump input {
  width: 70px;
  padding: 8px;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  text-align: center;
  font-size: 14px;
}

.page-jump button {
  padding: 8px 16px;
  background: #007bff;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: background 0.3s ease;
}

.page-jump button:hover {
  background: #0056b3;
}
/* 分页器样式 */

/* Footer部分样式 */
footer {
  width: 100%;
  background-color: #f8f8f8;
  padding: 20px 0;
  border-top: 1px solid #e0e0e0;
  margin-top: 40px;
}

.footer-container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 20px;
}

.footer-logo img {
  width: 40px;
  height: 40px;
  margin-bottom: 15px;
}

.footer-links {
  display: flex;
  gap: 20px;
  margin-bottom: 15px;
}

.footer-links a {
  color: #333;
  text-decoration: none;
  font-size: 14px;
}

.footer-links a:hover {
  color: #555;
  text-decoration: underline;
}

.footer-copyright {
  color: #666;
  font-size: 12px;
  text-align: center;
}
/*Footer部分样式 */
@media screen and (max-width: 1024px) {
  .content-container {
    padding: 0 10px 10px 10px;
  }
}
/* 定义全局滚动条样式 */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  border-radius: 4px;
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  border-radius: 4px;
  background: #c1c1c1;
}

::-webkit-scrollbar-thumb:hover {
  background: #a8a8a8;
}

/* 返回顶部按钮样式 */
#backToTop {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--btn);
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 24px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  z-index: 1000;
}

#backToTop:hover {
  background-color: #c0a1ee;
  transform: translateY(-3px);
}

#backToTop.show {
  display: flex;
}
/* 返回顶部按钮样式 */

/* 懒加载图片样式 */
.lazy-image {
  background-size: 100%;
  aspect-ratio: 11/8;
  opacity: 1;
  transition: opacity 0.3s ease-in-out;
  position: relative;
}

.lazy-image-loading {
  opacity: 0.7;
}

.lazy-image-loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 30px;
  height: 30px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid #3498db;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  transform: translate(-50%, -50%);
  z-index: 1;
}

.lazy-image-loaded {
  opacity: 1;
  transition: opacity 0.5s ease-in-out;
}

.lazy-image-error {
  border: 2px solid #ff4d4d;
  background-color: #ffebee;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ff4d4d;
  font-weight: bold;
}

@keyframes spin {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}
/* 懒加载图片样式 */
