/* ============================================================
   news-detail.html 新闻详情页 独立样式文件
   存放位置：css 文件夹
   功能：新闻详情页主体内容
   说明：类名统一使用下划线命名
   ============================================================ */

/* ================= 新闻详情主体（页面宽度 80%，居中显示） ================= */
.nd_detail_wrap {
  background: #fff;
  padding: 48px 60px;
}
/* 标题区（标题 + 日期，居中） */
.nd_detail_title {
  text-align: center;
  line-height: 1.45;
  letter-spacing: 1px;
  color: var(--text-title1-color);
  font-weight: 500;
  font-size: var(--text-title1-size);
  margin-bottom: 28px;
}
.nd_detail_date {
  text-align: center;
  font-size: 14px;
  color: #666666;
  letter-spacing: 1px;
  margin-bottom: 48px;
}
.nd_detail_fenge {
  width: 80%;
  margin: 0 auto;
  background: #f1f3f5;
  height: 1.5px;
  margin-bottom: 48px;
}

.nd_detail_tag_box {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}
.nd_detail_catname {
  font-size: 12px;
  color: #fff;
  background: var(--text-active-color);
  border: 1px solid var(--text-active-color);
  border-radius: 15px;
  padding: 3px 14px;
  display: inline-block;
  letter-spacing: 1px;
}
.nd_detail_meta_line {
  width: 40px;
  height: 1px;
  background: #c3d8f0;
}

/* 大图 */
.nd_detail_cover {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 16px 44px rgba(30, 80, 150, 0.14);
  margin-bottom: 40px;
  background: #eef3fa;
  min-height: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.nd_detail_cover img {
  width: 100%;
  display: block;
  object-fit: cover;
}

/* 正文 */
.nd_detail_content {
  margin: 0 auto;
  background: #fff;
  border-radius: 24px;
  min-height: 300px;
  height: auto;
  width: 100%;
}
.nd_detail_content p {
  font-size: 16px;
  line-height: 2;
  margin-bottom: 20px;
  text-align: justify;
}
.nd_detail_content img {
  height: auto;
  /* width: 100% !important; */
  /* height: auto !important; */
  object-fit: contain;
}

/* 相关推荐 */
.nd_related_box {
  margin-top: 96px;
}
.nd_related_head {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 32px;
}
.nd_related_title {
  text-align: center;
  align-items: center;
  margin: 0;
  font-size: 26px;
  color: #111;
  position: relative;
}

.nd_related_more {
  position: absolute;
  right: 0;
  top: 21px;
  border: 0;
  color: #939393;
  font-size: 14px;
  cursor: pointer;
  transition:
    background 0.2s,
    color 0.2s;
  display: flex;
  align-items: center;
}
.nd_related_more:hover {
  color: var(--text-active-color);
}
.nd_related_more .iconfont {
  margin-top: 1px;
  font-size: 14px;
  margin-right: 5px;
}
.nd_related_more:hover iconfont {
  color: var(--text-active-color);
}
.nd_related_grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}
.nd_rel_card {
  background: #ffffff;
  border-radius: 24px;
  overflow: hidden;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}
.nd_rel_card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 36px var(--com-shadow-color);
}
.nd_rel_img {
  display: flex;
  justify-content: center;
  border-radius: 20px;
  margin-top: 4px;
  margin-left: 4px;
  margin-right: 4px;
  background-color: #e5e5e5;
  width: calc(100% - 8px);
  height: 200px;
  overflow: hidden;
}
.nd_rel_img img {
  height: 100%;
  object-fit: cover;
  width: 100%;
  display: block;
}
.nd_rel_body {
  padding: 18px 18px 16px;
}
.nd_rel_title {
  height: 50px;
  font-size: 17px;
  font-weight: 700;
  color: #000;
  line-height: 1.5;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.nd_rel_text {
  font-size: 13px;
  color: #5b6b84;
  line-height: 1.7;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.nd_rel_date {
  font-size: 12px;
  color: #8aa0bd;
  letter-spacing: 1px;
}

/* ================= 响应式 ================= */
@media (max-width: 1100px) {
  .nd_related_grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 768px) {
  .nd_detail_wrap {
    padding: 15px;
  }
  .nd_detail_title {
    font-size: 24px;
  }
  .nd_related_grid {
    grid-template-columns: 1fr;
  }
}
