
/* 首页Banner轮播样式 */
.banner{
  width: 100%;
  aspect-ratio: 1920 / 460;
  max-height: 540px;
  position: relative;
  overflow: hidden;
}
.banner-slides{
  display: flex;
  width: 300%;
  height: 100%;
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.banner-slide{
  width: 100%;
  height: 100%;
  flex-shrink: 0;
  display:flex;
  align-items:center;
  justify-content:center;
}
/* Banner图片容器样式 */
.banner-slide-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
/* banner轮播小圆点指示器 */
.banner-dots{
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 2;
}
.banner-dot{
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
}
/* 激活状态的圆点样式 */
.banner-dot.active {
  background: #805a33;
  transform: scale(1.2);
}

/* 第二区：创新发展+重要活动 (核心修复：仅改外层盒子，不动内部元素) */
.news-section{
  background: #faf8f5;
  height: auto;
  padding: 20px 0;
  box-sizing: border-box;
}
.news-section .content-inner {
  display:grid;
  grid-template-columns:1.5fr 1fr;
  gap: 0;
  /* 核心修复：把stretch改为flex-start，取消强制拉伸，让子元素高度自主 */
  align-items: flex-start;
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
  /* 核心：让容器高度自适应内部内容 */
  height: auto;
}
.news-section .news-card:last-child {
  margin-left: 0;
}
/* 以下样式完全保留你原来的，只改外层盒子，不动内部高度 */
.news-card{
  padding:0 20px 20px 10px;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.news-card-content{
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.news-section .more-btn{color:#c8102e;border-color:#c8102e}
.news-section .more-btn:hover{background:#c8102e;color:#fff}

/* 创新发展轮播Banner样式 */
.innovation-banner {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
  border-radius: 4px;
}
.innovation-banner-slides {
  width: 100%;
  height: 100%;
  position: relative;
}
.innovation-banner-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.8s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 0;
}
.innovation-banner-slide.active {
  opacity: 1;
  z-index: 1;
}
.innovation-banner-title {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding:15px 20px;
  background: rgba(0,0,0,0.8); 
  color: #fff; 
  font-size:18px;
  line-height:1.6;
  text-align: left;
}

/* 新闻公告列表样式 (完全保留你原来的高度，不改动) */
.event-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
  height: 100%;
}
.event-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px dashed #eee;
  font-weight: normal;
  cursor: pointer;
  transition: all 0.3s ease;
  gap: 8px;
  border-radius: 6px;
  border-left: 3px solid transparent;
}
.event-item > div:first-child {
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  flex: 1;
  min-width: 0;
  max-width: 90%;
  font-weight: normal;
}
.event-item:hover {
  color: #c8102e;
  background: #fef5f5;
  transform: translateX(4px);
}
.event-date {
  font-size: 13px;
  color: #999;
  flex-shrink: 0;
  transition: color 0.3s;
}
.event-item:hover .event-date {
  color: #c8102e;
}

/* 第二区：好书共读 - 核心修改：作者单独一行 + 小红书翻页动效 */
.books-section{
  background: #f9f8f5;
  padding: 60px 0;
}
.books-section .content-inner {
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}
.books-section .section-header {
  justify-content: center;
}
.books-section .more-btn{display: inline-block;} 
/* 图书网格容器 */
.books-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr); /* 固定5列 */
  gap: 30px;
  justify-items: center; /* 居中对齐 */
}
/* 图书卡片样式 */
.book-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
  border-radius: 8px;
  border: none;
}
.book-card:hover {
  box-shadow: 0 8px 20px rgba(241, 178, 42, 0.08);
}
.book-cover {
  border-radius: 4px;
  background: #f8f8f8;
  box-shadow: 0 4px 8px rgba(0,0,0,0.05);
  display:flex;
  align-items:center;
  justify-content:center;
  color:#666;
  font-size:14px;
  position: relative;
  overflow: hidden;
  transition: all 0.4s ease;
}

.book-cover::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 25px;
  height: 25px;
  background: linear-gradient(135deg, transparent 50%, #e8e8e8 50%);
  border-radius: 0 0 0 6px;
  box-shadow: -1px -1px 3px rgba(0,0,0,0.08);
  transform: scale(0);
  transform-origin: bottom right;
  transition: transform 0.3s ease;
  z-index: 2;
}

.book-card:hover .book-cover {
  transform: translateY(-6px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.12);
}

.book-card:hover .book-cover::after {
  transform: scale(1);
}

/* 第三区：品牌刊物 - 核心修改：作者单独一行 + 小红书翻页动效 + 悬停效果统一 */
.magazine-section{
  background: #f9f8f5;
  padding: 60px 0;
}
.magazine-section .content-inner {
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}
.magazine-section .section-header {
  justify-content: center;
}
.magazine-section .more-btn{display: inline-block;} 
/* 期刊网格容器 */
.magazine-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr); /* 修正注释：实际是5列 */
  gap: 30px;
  justify-items: center; /* 居中对齐 */
}
/* 期刊卡片样式 */
.magazine-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
  border-radius: 8px;
  border: none;
}
.magazine-card:hover {
  box-shadow: 0 8px 20px rgba(241, 178, 42, 0.08);
}
.magazine-cover {
  border-radius: 4px;
  background: #f8f8f8;
  box-shadow: 0 4px 8px rgba(0,0,0,0.05);
  display:flex;
  align-items:center;
  justify-content:center;
  color:#666;
  font-size:14px;
  position: relative;
  overflow: hidden;
  transition: all 0.4s ease;
}

.magazine-cover::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 25px;
  height: 25px;
  background: linear-gradient(135deg, transparent 50%, #e8e8e8 50%);
  border-radius: 0 0 0 6px;
  box-shadow: -1px -1px 3px rgba(0,0,0,0.08);
  transform: scale(0);
  transform-origin: bottom right;
  transition: transform 0.3s ease;
  z-index: 2;
}

.magazine-card:hover .magazine-cover {
  transform: translateY(-6px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.12);
}

.magazine-card:hover .magazine-cover::after {
  transform: scale(1);
}

/* 第五区：公众号矩阵 */
.wechat-section{
  background: #f9f8f5;
  padding:20px 0 60px; 
  margin-top: -1px; 
}
.wechat-section .content-inner {
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}
.wechat-section .more-btn{display: none;}
.wechat-section .more-btn{color:#2e7d32;border-color:#2e7d32}
.wechat-section .more-btn:hover{background:#2e7d32;color:#fff}
.wechat-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:20px}
.wechat-card{
  background:rgba(255,255,255,0.8);
  padding:15px;
  border-radius:6px;
  text-align:center;
  cursor:default; 
  transition:none; 
}
.wechat-card:hover{box-shadow:none}
.wechat-qrcode{
  width:120px;
  height:120px;
  background:#e0f2e0;
  border-radius:6px;
  margin:0 auto 10px;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden; 
}
.wechat-qrcode img{
  width:100%;
  height:100%;
  object-fit:cover; 
}
.wechat-name{font-size:14px;font-weight:normal;color:#333}
.wechat-desc{font-size:12px;color:#999;margin-top:5px}

/* 轮播动画定义 */
/* 响应式适配 */
@media (max-width: 1200px) {
  .books-grid, .magazine-grid {
    grid-template-columns: repeat(3, 1fr); /* 平板端3列 */
  }
  .recommend-section .content-inner,
  .news-section .content-inner,
  .books-section .content-inner,
  .magazine-section .content-inner,
  .wechat-section .content-inner { 
    width:90%; 
    max-width: none;
  }

  /* 核心修复：移动端布局+轮播高度 */
  .news-section .content-inner {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
    gap: 20px !important;
    align-items: stretch !important;
  }
  .news-section .news-card:last-child {
    margin-left: 0 !important; /* 修复负边距错位 */
  }
  
  /* 强制创新轮播图400px高度 */
  .innovation-banner {
    height: 400px !important;
    min-height: 400px !important;
    max-height: 400px !important;
    flex-shrink: 0 !important;
    width: 100% !important;
  }
  .innovation-banner-slides, .innovation-banner-slide {
    height: 400px !important;
  }
  
  /* 新闻列表自适应 */
  .news-card {
    height: auto !important;
    width: 100% !important;
  }
  .event-list {
    height: auto !important;
  }
}
@media (max-width: 900px) {
  /* 好书推荐/期刊适配 */
  .books-grid, .magazine-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
  
  /* 核心修复：移动端布局+轮播高度 */
  .news-section .content-inner {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
    gap: 20px !important;
    align-items: stretch !important;
  }
  .news-section .news-card:last-child {
    margin-left: 0 !important; /* 修复负边距错位 */
  }
  
  /* 强制创新轮播图400px高度 */
  .innovation-banner {
    height: 400px !important;
    min-height: 400px !important;
    max-height: 400px !important;
    flex-shrink: 0 !important;
    width: 100% !important;
  }
  .innovation-banner-slides, .innovation-banner-slide {
    height: 400px !important;
  }
  
  /* 新闻列表自适应 */
  .news-card {
    height: auto !important;
    width: 100% !important;
  }
  .event-list {
    height: auto !important;
  }
}
@media (max-width: 600px) {
  /* 好书推荐/期刊适配 */
  .books-grid, .magazine-grid {
    grid-template-columns: repeat(2, 1fr); /* 手机端2列 */
    gap: 15px;
  }
  
  .wechat-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .header {
    padding: 15px 20px;
  }
  .nav {
    gap: 15px;
    font-size: 14px;
  }
  
  /* 手机端保留轮播400px高度 */
  .innovation-banner {
    height: 400px !important;
    min-height: 400px !important;
    max-height: 400px !important;
    flex-shrink: 0 !important;
  }
  .innovation-banner-slides, .innovation-banner-slide {
    height: 400px !important;
  }
  
  /* 修复布局细节 */
  .news-section .content-inner {
    display: flex !important;
    flex-direction: column !important;
    gap: 15px !important;
    padding: 0 10px !important;
  }
}