/* News 页面特定样式 */

.news-page {
  padding-top: 0;
  background-color: #ffffff;
}

/* 覆盖复用的首页 Hero 样式 */
.news-page .hero-section {
  height: 720px;
}

.news-page .hero-title-container {
  margin-bottom: 0;
}

.news-page .hero-title {
  font-size: 0.64rem;
}

/* 新闻内容区 */
.news-content-section {
  padding: 0.8rem 0 1.2rem;
  background-color: #ffffff;
}

.news-tabs-wrapper {
  position: relative;
  max-width: 19.2rem;
  padding: 0 2.04rem;
}

.news-tabs-line {
  position: absolute;
  bottom: 0;
  left: 2.04rem;
  right: 2.04rem;
  height: 4px;
  background-color: #ececec; /* 极浅灰色背景线 */
  z-index: 1;
}

.news-tabs {
  display: flex;
  justify-content: center;
  gap: 0.24rem;
  position: relative;
  z-index: 2; /* 确保 Tab 在线上面 */
  padding-bottom: 0.24rem; /* 为底部灰线和蓝线留出空间 */
}

.news-tab-btn {
  position: relative;
  padding: 0.16rem 0.48rem;
  border-radius: 0.48rem;
  font-size: 0.24rem;
  font-family: "HarmonyOS Sans SC", sans-serif;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.3s;
  background-color: transparent;
  color: #505050;
  border-color: #d9d9d9;
}

.news-tab-btn.active {
  background-color: #0037c3;
  color: #ffffff;
  border-color: #0037c3;
  font-weight: bold;
}

/* 蓝色下划线 */
.news-tab-btn.active::after {
  content: "";
  position: absolute;
  bottom: -0.24rem; /* 贴合底部灰线 */
  left: 0;
  width: 100%;
  height: 0.08rem;
  background-color: #0037c3;
  border-radius: 0.12rem 0.12rem 0 0;
  z-index: 3;
}

.news-list-container {
  max-width: 19.2rem;
  margin: 0 auto;
  padding: 0 2.04rem;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.news-item {
  display: flex;
  align-items: center;
  padding: 0.32rem 0.24rem;
  border-bottom: 1px solid #d9d9d9;
  text-decoration: none;
  transition: background-color 0.3s;
}

.news-item:hover {
  background-color: #f5f5f5;
}

.news-image {
  width: 2.8rem;
  height: 1.8rem;
  border-radius: 0.12rem;
  overflow: hidden;
  flex-shrink: 0;
}

.news-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-info {
  flex: 1;
  padding: 0 0.48rem 0 0.32rem;
}

.news-title {
  font-family: "HarmonyOS Sans SC", sans-serif;
  font-size: 0.24rem;
  font-weight: bold;
  color: #505050; /* 默认深灰色 */
  margin-bottom: 0.16rem;
  line-height: 1.4;
  transition: color 0.3s;
}

.news-item:hover .news-title {
  color: #0037c3; /* hover 时变蓝 */
}

.news-desc {
  font-size: 0.16rem;
  color: #505050;
  line-height: 1.6;
  margin-bottom: 0.24rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-date {
  display: flex;
  align-items: center;
  gap: 0.08rem;
  font-size: 0.16rem;
  color: #999999; /* 默认浅灰色 */
  transition: color 0.3s;
}

.news-item:hover .news-date {
  color: #0037c3; /* hover 时变蓝 */
}

.news-date img {
  width: 0.2rem;
  height: 0.2rem;
  filter: grayscale(100%) opacity(0.6); /* 默认灰色图标 */
  transition: filter 0.3s;
}

.news-item:hover .news-date img {
  filter: none; /* hover 时恢复原本颜色 */
}

.news-arrow {
  flex-shrink: 0;
  width: 1.04rem;
  height: 1.04rem;
  opacity: 0.3;
  transition: opacity 0.3s;
}

.news-item:hover .news-arrow {
  opacity: 1;
}

.news-arrow img {
  width: 1.04rem;
  height: 1.04rem;
  filter: grayscale(100%);
  transition: filter 0.3s;
}

.news-item:hover .news-arrow img {
  filter: none; /* hover 时恢复原色（蓝色） */
}

/* 分页 */
.pagination {
  max-width: 19.2rem;
  margin: 0.64rem auto 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.24rem;
}

.page-numbers {
  display: flex;
  align-items: center;
  gap: 0.08rem;
}

.page-btn {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background-color: transparent;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.page-btn img {
  width: 0.48rem;
  height: 0.48rem;
}

.page-num {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background-color: rgba(222, 222, 222, 0.4);
  border: none;
  font-size: 0.18rem;
  font-family: "HarmonyOS Sans SC", sans-serif;
  color: #999999;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.page-num.active {
  background-color: rgba(43, 103, 255, 0.1);
  color: #0037c3;
  font-weight: normal;
}

.page-dots {
  color: #999999;
  font-size: 0.18rem;
  padding: 0 0.08rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-jump {
  display: flex;
  align-items: center;
  gap: 0.08rem;
  font-size: 0.18rem;
  font-family: "HarmonyOS Sans SC", sans-serif;
  color: #0b0b0c;
}

.page-jump input {
  width: 0.64rem;
  height: 0.48rem;
  border: 1px solid #dedede;
  background-color: rgba(222, 222, 222, 0.2);
  border-radius: 0.53rem;
  text-align: center;
  font-size: 0.18rem;
  outline: none;
  color: #0b0b0c;
}

.jump-btn {
  background-color: transparent;
  color: #0037c3;
  border: none;
  cursor: pointer;
  font-size: 0.18rem;
  font-family: "HarmonyOS Sans SC", sans-serif;
  padding: 0 0.08rem;
}

/* 移动端适配 */
@media (max-width: 768px) {
  .news-page .hero-section {
    height: 43vh;
  }

  .news-page .hero-title {
   
  }

  .news-content-section {
    padding: 0.4rem 0 0.6rem;
  }

  .news-tabs-wrapper {
    margin-bottom: 0.32rem;
  }

  .news-tabs {
    padding-bottom: 0.24rem;
  }

  .news-tab-btn {
    padding: .32rem .48rem;
    font-size: .28rem;
    border-radius: .96rem;
  }

  .news-tab-btn.active::after {
    bottom: -0.24rem;
    width: 100%;
    height: 4px;
    background-color: #0037c3;
    border-radius: 0.12rem 0.12rem 0 0;
  }

  .news-tabs-line {
    left: 16px;
    right: 16px;
  }

  .news-list-container {
    gap: 0;
  }

  .news-image {
    width: 2.3rem;
    height: 1.72rem;
    margin-bottom: 0;
    margin-right: .24rem;
    border-radius: .24rem;
    flex-shrink: 0;
    overflow: hidden;
  }

  .news-item {
    flex-direction: row;
    align-items: flex-start;
    padding: .32rem 0;
  }

  .news-item:hover {
    background-color: #f5f5f5;
  }

  .news-info {
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 86px;
    flex: 1;
    min-width: 0;
  }

  .news-title {
    font-size: .28rem;
    margin-bottom: 0;
    color: #0037c3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
  }

  .news-desc {
    font-size: .24rem;
    margin-bottom: 0;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #505050;
  }
  .news-tabs-line {
    height: 2px;
  }

  .news-date {
    font-size: .24rem;
    color: #0037c3;
  }

  .news-date img {
    filter: none;
    width: .3rem;
    height: .3rem;
  }

  .news-arrow {
    display: none;
  }

  .pagination {
    margin-top: 0.32rem;
    gap: 0.16rem;
  }

  .page-numbers {
    gap: 0.16rem;
  }

  .page-btn {
    width: .48rem;
    height: .48rem;
  }

  .page-btn img {
      width: .48rem;
    height: .48rem;
  }

  .page-num {
    width: .48rem;
    height: .48rem;
    font-size: .24rem;
  }

  .page-ellipsis {
    font-size: .24rem;
  }

  .page-jump {
    margin-left: 0.08rem;
  }

  .jump-input {
    width: .96rem;
    height: .48rem;
    font-size: .24rem;
    margin-right: 0.08rem;
  }

  .jump-btn {
    font-size: .24rem;
  }

  .page-btn {
    width: .48rem;
    height: .48rem;
  }

  .page-jump {
    margin-left: 0.08rem;
    font-size: .24rem;
    gap: 0.04rem;
  }

  .page-jump input {
    width: 0.48rem;
    height: 0.48rem;
    font-size: .24rem;
  }

  .jump-btn {
    font-size: .24rem;
    padding: 0 0.04rem;
  }
}

@media (max-width: 768px) {
  .news-tabs-wrapper {
    padding-left: 16px;
    padding-right: 16px;
  }
  .news-list-container {
    padding-left: 16px;
    padding-right: 16px;
  }
}
