/* dsx_legacy 内页修正 */
#sp-breadcrumb-block {
  background: #f6f6f6;
  padding: 0;
  margin-bottom: 30px;
}
#sp-breadcrumb {
  background: none;
  padding: 0 15px;
}
#sp-breadcrumb .breadcrumb {
  background: none;
  margin: 0;
  padding: 8px 0;
  font-size: 13px;
}
#sp-breadcrumb .breadcrumb > li + li:before {
  content: "›";
  color: #999;
}
#sp-component {
  padding-bottom: 30px;
}
#sp-component .page-header {
  border: 0;
  margin: 0 0 15px;
  padding: 0;
}
#sp-component .page-header h1 {
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
  font-size: 38px;
  font-weight: 400;
  color: #222;
  margin: 0;
}
#sp-component .page-header h2 {
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
  font-size: 20px;
  font-weight: 500;
  color: #333;
  margin: 10px 0;
}
.article-info {
  color: #999;
  font-size: 13px;
  margin-bottom: 15px;
}
.article-info dd {
  margin-bottom: 3px;
}
.com-content-article__body {
  font-size: 15px;
  line-height: 1.9;
  color: #333;
}
.com-content-article__body img {
  max-width: 100%;
  height: auto;
}
.pagination .page-link {
  color: #2796bd;
}

/* Bootstrap 5 兼容旧站 BS3 布局 */
.float-end { float: right !important; }
.float-start { float: left !important; }
.d-flex { display: flex !important; }

/* 面包屑 */
.mod-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  background: none;
  list-style: none;
  font-size: 13px;
  color: #666;
}
.mod-breadcrumbs__here { display: none !important; }
.mod-breadcrumbs__divider { display: none !important; }
.mod-breadcrumbs .breadcrumb-item + .breadcrumb-item::before {
  content: "›";
  color: #999;
  margin-right: 6px;
}
.mod-breadcrumbs a { color: #666; }
.mod-breadcrumbs a:hover { color: #2796bd; }
#sp-breadcrumb .sp-column { padding: 0; }
#sp-breadcrumb .mod-breadcrumbs,
#sp-breadcrumb ol.breadcrumb { list-style: none; }
#sp-breadcrumb .mod-breadcrumbs__wrapper:before,
#sp-breadcrumb .mod-breadcrumbs:before,
#sp-breadcrumb ol.breadcrumb:before { content: none !important; display: none !important; }
#sp-breadcrumb ol.breadcrumb > li:before { display: none !important; }
#sp-breadcrumb ol.breadcrumb > li:after {
  content: "";
  height: 5px;
  width: 5px;
  background: #b1b1b1;
  border-radius: 5px;
  margin: 0 10px;
  display: inline-block;
  vertical-align: middle;
}
#sp-breadcrumb ol.breadcrumb > li.active:after { display: none; }
#sp-breadcrumb ol.breadcrumb > li { font-size: 12px; }
/* 导航当前项 */
.sp-megamenu-parent > li.active > a,
.sp-megamenu-parent > li:hover > a { background: #1b7f9f; color: #fff; }

/* 文章信息 */
.article-info-term { display: none !important; }

/* 分类列表：隐藏作者列，保留名称和点击数 */
.com-content-category table th:nth-child(2),
.com-content-category table td:nth-child(2) { display: none; }
.com-content-category .counter { display: none; }

/* 分页样式（旧站蓝色方块） */
.pagination {
  display: inline-flex;
  gap: 2px;
  margin: 20px 0;
  padding: 0;
  list-style: none;
}
.pagination .page-link {
  display: block;
  padding: 6px 12px;
  border: 1px solid #ddd;
  background: #fff;
  color: #333;
  text-decoration: none;
  line-height: 1.4;
}
.pagination .page-item.active .page-link {
  background: #2796bd;
  border-color: #2796bd;
  color: #fff;
}
.pagination .page-link:hover { background: #f2f2f2; }

/* 站内搜索结果 */
.dsx-search-results .search-summary {
  margin-bottom: 20px;
  font-size: 14px;
  color: #666;
}
.dsx-search-results .search-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.dsx-search-results .search-item {
  padding: 16px 0;
  border-bottom: 1px solid #eee;
}
.dsx-search-results .search-title {
  font-size: 18px;
  margin: 0 0 6px;
  font-weight: normal;
}
.dsx-search-results .search-title a {
  color: #2796bd;
  text-decoration: none;
}
.dsx-search-results .search-title a:hover { text-decoration: underline; }
.dsx-search-results .search-date {
  color: #999;
  font-size: 12px;
  margin-bottom: 6px;
}
.dsx-search-results .search-snippet {
  color: #555;
  font-size: 14px;
  line-height: 1.9;
}
.dsx-search-results .search-tip { color: #666; }

/* 首页轮播：整张图片可点击 */
.sp-slider-item .sp-slider-image {
  display: block;
  cursor: pointer;
  text-decoration: none;
}

/* 首页轮播：中小屏适配（旧模板只在桌面端显示，文字边距会把窄屏撑坏） */
@media (max-width: 1199px) {
  .sp-university-layout .sp-slider-content .sp-introtext {
    margin: 20px 40px 10px;
  }
}

@media (max-width: 991px) {
  .sp-university-layout .sp-slider-content {
    padding: 0 15px;
  }
  .sp-university-layout .sp-slider-content .sp-title {
    font-size: 34px;
    line-height: 1.25;
  }
  .sp-university-layout .sp-slider-content .sp-introtext {
    margin: 20px 40px 10px;
  }
}

/* 旧站遗留的空 SPPB 区块，窄屏会在图片新闻和底部之间撑出大片空白 */
@media (max-width: 991px) {
  #section-id-1488967667777,
  #section-id-1489028018413,
  #section-id-1489028018418 {
    display: none !important;
  }
}

@media (max-width: 767px) {
  /* 手机端：items 与容器同高，图片整体显示（不要被截断为上半部分） */
  .sp-university-layout .sp-slider-item,
  .sp-university-layout .sp-slider-item .sp-slider-image {
    height: 400px;
  }
  .sp-university-layout .sp-slider-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    box-sizing: border-box;
    padding: 28px 18px 12px;
    background: linear-gradient(to top, rgba(0,0,0,.75) 0%, rgba(0,0,0,.45) 55%, rgba(0,0,0,0) 100%);
  }
  .sp-university-layout .sp-slider-content .sp-title {
    font-size: 20px;
    line-height: 1.4;
    margin: 0;
    text-align: left;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0,0,0,.5);
  }
  .sp-university-layout .sp-slider-content .sp-introtext {
    display: none;
  }
  .sp-university-layout .sp-slider-controllers > a {
    width: 34px;
    height: 34px;
  }
  .sp-university-layout .sp-slider-controllers > a span {
    line-height: 32px;
  }
}

@media (max-width: 480px) {
  .sp-university-layout .sp-slider-item,
  .sp-university-layout .sp-slider-item .sp-slider-image {
    height: 300px;
  }
}

/* 文章评分（旧站星星） */
.post_rating .voting-result {
  display: inline;
  margin-left: 6px;
  color: #888;
  font-size: 13px;
}
.post_rating .voting-result.is-success {
  color: #2e9b4f;
  font-weight: 500;
}
.post_rating .voting-result.is-error {
  color: #c0392b;
}
.post_rating .ajax-loader {
  display: none;
  margin-left: 6px;
  color: #2796bd;
}
.post_rating .voting-symbol .star {
  cursor: pointer;
}

/* 移动端 offcanvas 菜单 */
.offcanvas-menu {
  overflow-y: auto;
  overflow-x: hidden;
}
.offcanvas-menu .offcanvas-inner .sp-module ul > li > ul.collapse {
  display: none;
}
.offcanvas-menu .offcanvas-inner .sp-module ul > li > ul.collapse.in {
  display: block;
}
.offcanvas-menu .offcanvas-inner .sp-module ul > li .offcanvas-menu-toggler {
  color: #fff;
  z-index: 2;
}
.offcanvas-menu .offcanvas-inner .sp-module ul > li > a {
  display: block;
  padding-right: 52px;
}

/* ===== 手机端优化 ===== */
@media (max-width: 767px) {
  /* 顶部欢迎条压缩为一行 */
  #sp-header-top {
    padding: 4px 0;
  }
  #sp-header-top .yt-loginform {
    margin: 0;
    padding: 0;
  }
  #sp-header-top .yt-loginform > li {
    line-height: 22px;
  }

  /* logo 与搜索框各占一行，搜索框居中 */
  #sp-header-center {
    margin: 10px 0 12px;
  }
  #sp-header-center #sp-logo {
    width: 100%;
    float: none;
    padding: 0;
    text-align: center;
  }
  #sp-header-center #sp-logo h1.logo img {
    margin: 0 auto;
    max-width: 100%;
    height: auto;
  }
  #sp-top3 {
    width: 100%;
    float: none;
    padding: 0;
  }
  #sp-top3 .sp-column {
    padding: 0;
  }
  #sp-top3 .sp-module {
    display: block;
    float: none;
    width: 100%;
    margin: 8px auto 0;
  }
  #sp-top3 .search.mod_search102 {
    text-align: center;
  }
  #sp-top3 .search.mod_search102 form {
    max-width: 320px;
    margin: 0 auto;
  }
  #sp-top3 .search.mod_search102 input.search-query {
    width: 100%;
    box-sizing: border-box;
  }

  /* 旧站遗留的空 SPPB 区块，窄屏会撑出大片空白 */
  #sp-block-bottom {
    padding: 26px 0 10px;
  }
  #sp-block-bottom #sp-bottom1,
  #sp-block-bottom #sp-bottom2,
  #sp-block-bottom #sp-bottom3,
  #sp-block-bottom #sp-bottom4 {
    width: 50%;
    float: left;
    padding-left: 10px;
    padding-right: 10px;
  }
  #sp-block-bottom .sp-module {
    margin-bottom: 16px;
  }
  #sp-block-bottom .sp-module h3.sp-module-title {
    margin: 0 0 8px;
    font-size: 14px;
  }
  #sp-block-bottom .sp-module .menu > li a {
    font-size: 12px;
    line-height: 22px;
  }
  #sp-block-bottom .custom ul {
    margin: 0;
    padding: 0;
    list-style: none;
  }
  #sp-block-bottom .custom li {
    font-size: 12px;
    line-height: 20px;
  }

  /* 页脚 */
  #sp-footer {
    padding: 12px 0;
    text-align: center;
    font-size: 12px;
    line-height: 1.8;
  }

  /* 文章页：图片、表格不撑破屏幕 */
  #sp-component .page-header h1 {
    font-size: 26px;
    line-height: 1.3;
  }
  .com-content-article__body {
    font-size: 14px;
    overflow-wrap: break-word;
    word-wrap: break-word;
  }
  .com-content-article__body table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
  }

  /* 面包屑 */
  #sp-breadcrumb-block {
    margin-bottom: 15px;
  }
  #sp-breadcrumb .breadcrumb {
    padding: 6px 0;
    font-size: 12px;
  }
}

/* Retina 屏：模板会隐藏 .sp-default-logo，但页面里没有 retina logo，手机端会看不到 logo */
@media only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min-device-pixel-ratio: 1.5) {
  #sp-header-center .sp-default-logo {
    display: inline-block !important;
  }
}



