/* ===== 只在dh导航内生效，不污染全局 ===== */
.dh-topbar *,
.dh-header *,
.dh-mmobile * {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --dh-blue: #075bf9;
  --dh-blue-l: #e8f1ff;
  --dh-gold: #f0a020;
  --dh-text: #1f2d40;
  --dh-text-light: #8a97a8;
  --dh-border: #dbe7fb;
  --dh-bg: #f5f8ff;
}

/* ===== 顶部信息条【重点修复：链接黑色】 ===== */
.dh-topbar {
  background: #fcfcfc;
  color: #00010a;
  font-size: 14px;
  padding: 7px 0;
}
.dh-topbar .dh-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 24px;
}
.dh-topbar-left {
  display: flex;
  align-items: center;
  gap: 6px;
}
.dh-topbar-left img {
  width: 13px;
  height: 13px;
}
.dh-topbar-right {
  display: flex;
  gap: 18px;
}
/* 修复：强制黑色，压住全局蓝色a标签 */
.dh-topbar-right a {
  text-decoration: none !important;
  color: #000 !important;
}
.dh-topbar-right a:hover {
  color: var(--dh-gold) !important;
}

/* ===== 主导航区 ===== */
.dh-header {
  background: #fff;
  border-bottom: 1px solid #f5f5f5;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.dh-header .dh-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Logo 区域 */
.dh-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none !important;
  color: inherit;
}
.dh-logo img {
  height: 33px;
  width: auto;
}
.dh-logo p {
  font-size: 12px;
  color: var(--dh-text-light);
  letter-spacing: 1px;
}

/* 桌面端菜单 */
.dh-mainmenu {
  display: flex;
  align-items: center;
  gap: 2px;
}
.dh-mitem {
  position: relative;
}
.dh-mitem > a {
  padding: 10px 14px;
  font-size: 16px;
  color: #00010a;
  font-weight: 500;
  border-radius: 6px;
  display: block;
  text-decoration: none !important;
  transition: all .25s;
}
.dh-mitem > a:hover {
  color: var(--dh-blue);
  background: var(--dh-blue-l);
}

/* 下拉菜单 */
.dh-msub {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  min-width: 140px;
  padding: 12px 0;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  z-index: 99;
}
.dh-msub a {
  display: block;
  padding: 10px 18px;
  color: #333;
  white-space: nowrap;
  text-decoration: none !important;
  transition: all .2s;
}
.dh-msub a:hover {
  background-color: #f2f6fc;
  color: var(--dh-blue);
}
.dh-mdrop:hover .dh-msub {
  display: block;
}

/* 右侧按钮区域 */
.dh-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}
.dh-btn-outline {
  padding: 8px 20px;
  border: 1.5px solid #075bf9;
  color: #0b66e9 !important;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none !important;
  background: #fff;
  transition: all 0.25s;
}
.dh-btn-outline:hover {
  background: #e8f1ff;
  color: #000 !important;
}
.dh-btn-primary {
  padding: 8px 22px;
  background: linear-gradient(135deg, #fe4d6d, #e97b1a);
  color: #fff !important;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none !important;
  box-shadow: 0 2px 8px rgba(15, 44, 92, 0.2);
  transition: all 0.25s;
  border: none;
}
.dh-btn-primary:hover {
  background: linear-gradient(135deg, #ff5c7a, #f0882a);
  color: #fff !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(15, 44, 92, 0.3);
}

/* 移动端汉堡按钮 */
.dh-mtoggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 6px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  background: var(--dh-bg);
  cursor: pointer;
  border: none;
}
.dh-mtoggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: #053a8f;
  border-radius: 2px;
  transition: all .25s;
}
.dh-mtoggle.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.dh-mtoggle.open span:nth-child(2) {
  opacity: 0;
}
.dh-mtoggle.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* 移动端全屏菜单 */
.dh-mmobile {
  display: none;
  position: fixed;
  top: 72px;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  z-index: 999;
  overflow-y: auto;
  padding: 16px 24px 40px;
}
.dh-mmobile.open {
  display: block;
}
.dh-mnitem {
  display: block;
  padding: 15px 6px;
  font-size: 17.5px;
  color: var(--dh-text);
  font-weight: 500;
  border-bottom: 1px solid var(--dh-bg);
  text-decoration: none !important;
}
.dh-mnitem:hover {
  color: var(--dh-blue);
}

/* ===== 响应式 ===== */
@media(max-width: 1024px) {
  .dh-mainmenu { display: none; }
  .dh-mtoggle { display: flex; }
}
@media(max-width: 640px) {
  .dh-header .dh-container { height: 62px; }
  .dh-mmobile { top: 62px; }
  .dh-logo p { display: none; }
}

/* ========== 导航badge标签：只新增，不覆盖原有导航布局 ========== */

/* 给导航项建立定位基准 */
.dh-mainmenu .dh-mitem {
  position: relative;
}

/* badge 基础样式：悬浮在文字右上方，不影响原菜单宽度 */
.dh-badge {
  position: absolute;
  top: -10px;
  right: -10px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 10px;
  font-size: 12px;
  line-height: 20px;
  color: #fff;
  white-space: nowrap;
  z-index: 5;
}

/* hot 标签单独控制 */
.dh-badge.hot {
  background: linear-gradient(135deg, #ff7a28, #ff4b33);
}

/* 免费标签单独控制 */
.dh-badge.free {
  background: linear-gradient(135deg, #ff7a28, #ff4b33);
}

/* 下拉菜单父项预留一点右侧空间，避免badge压住下拉箭头 */
.dh-mdrop > a {
  padding-right: 22px !important;
}

/* 移动端badge单独控制，避免挤爆 */
.dh-mmobile .dh-badge {
  position: static;
  display: inline-block;
  margin-left: 6px;
  vertical-align: middle;
}





/* ===== Hero 重写：参考图片蓝白学术平台样式 ===== */
.hero{
  padding: 80px 0 20px;
  overflow:hidden;
  position:relative;
}
.hero-bg{
  position:absolute;
  inset:0;
  background:linear-gradient(120deg,#f0f6ff,#eef2ff);
  z-index:-1;
}
.hero-content{
  position:relative;
}
.hero-slogan{
  /* ===== 这两个数值自己随便调，单位px ===== */
text-align:center;
  font-size:34px;
  color:#0f3b94;
  font-weight:700;
  margin-top: -22px;
  margin-bottom: 34px;
  line-height:1.3;
}

.hero-search-panel{
  background:#fff;
  border-radius:12px;
  padding:16px;
}
.hst-tabs{
  display:flex;
  gap:4px;
  margin-bottom:12px;
}
.hst-tab{
  padding:8px 16px;
  border:1px solid #e2e8f0;
  background:#fff;
  border-radius:6px 6px 0 0;
  cursor:pointer;
  display:flex;
  align-items:center;
  gap:4px;
  position: relative;
}
.hst-tab.active{
  background:#2563eb;
  color:#fff;
  border-color:#2563eb;
}
.hst-new{
  color:#f43f5e;
  font-size:11px;
  position: absolute;
  top: -3px;
  right: 8px;
}
.hst-ico{
  width:16px;
  height:16px;
}
.hero-search{
  display:flex;
  align-items:center;
  gap:10px;
  position:relative;
}
.hst-select{
  display:flex;
  align-items:center;
  gap:6px;
  padding:0 10px;
  border:1px solid #d1d5db;
  border-radius:6px;
  height:44px;
  min-width:82px;
  position:relative;
  cursor:pointer;
  background:#fff;
}
.hst-options{
  position:absolute;
  top:100%;
  left:0;
  width:180px;
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:8px;
  box-shadow:0 6px 16px rgba(0,0,0,0.12);
  display:none;
  z-index:99;
  max-height:280px;
  overflow-y:auto;
  padding: 6px 0;
}
.hst-select.open .hst-options{
  display:block;
}
.hst-option{
  padding:9px 14px;
  font-size:14px;
  transition: 0.15s;
}
.hst-option:hover{
  background:#f3f4f6;
}
.hst-option.active{
  background:#eff6ff;
  color:#2563eb;
}
.hero-search-box{
  flex:1;
  position:relative;
}
.hero-search-box input{
  width:100%;
  height:44px;
  padding:0 12px 0 32px;
  border:1px solid #d1d5db;
  border-radius:6px;
  font-size:15px;
  box-sizing: border-box;
}
.search-ico{
  position:absolute;
  left:10px;
  top:50%;
  transform:translateY(-50%);
  width:16px;
  height:16px;
}
.search-suggest{
  position:absolute;
  top:calc(100% + 4px);
  left:0;
  right:0;
  width:100%;
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:8px;
  box-shadow:0 4px 12px rgba(0,0,0,0.1);
  display:none;
  z-index:99;
  max-height:360px;
  overflow-y:auto;
  box-sizing: border-box;
}
.search-suggest.show{
  display:block;
}
.hero-search-btn{
  height:44px;
  padding:0 22px;
  background:#2563eb;
  color:#fff;
  border:none;
  border-radius:6px;
  cursor:pointer;
  display:flex;
  align-items:center;
  gap:4px;
  white-space: nowrap;
}
.search-side-link{
  position:absolute;
  right:0;
  top:0;
  display:flex;
  flex-direction:column;
  gap:4px;
}
.search-side-link a{
  font-size:13px;
  color:#2563eb;
  text-decoration:none;
}
.hero-feat{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin:16px 0;
  align-items:center;
}
.hero-feat-label{
  font-size:14px;
  color:#444;
}
.hero-feat-item{
  display:flex;
  align-items:center;
  gap:4px;
  font-size:14px;
  color:#222;
  text-decoration:none;
}
.hfi-ico{
  width:14px;
  height:14px;
}
.hero-feat-more{
  color:#2563eb;
  font-size:14px;
  text-decoration:none;
}
.hero-card-grid{
  display:grid;
  grid-template-columns: 1fr 1.4fr 1fr;
  gap:16px;
  margin-bottom: 48px;
  align-items: stretch; /* 三个卡片整体高度保持一致 */
}
.hero-card{
  background:#fff;
  border-radius:10px;
  overflow:hidden;
  display: flex;
  flex-direction: column;
}
.card-header{
  height:90px;
  padding:0 18px;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  color:#fff;
  position:relative;
  background-size:cover;
  background-position:center;
}
.card-header::after{
  content:"";
  position:absolute;
  inset:0;
  background:rgba(0,0,0,0.45);
  z-index:1;
}
.card-left .card-header{
  background-image:url('/template/freecheck/image/xie1.png');
}
.card-center .card-header{
  background-image:url('/template/freecheck/image/cc1.png');
}
.card-right .card-header{
  background-image:url('/template/freecheck/image/jz1.png');
}
.card-header-text{
  position:relative;
  z-index:2;
}
.card-header-text h2{
  margin:0;
  font-size:24px;
  font-weight:700;
}
.card-header-text span{
  font-size:12px;
  opacity:0.9;
}
/* ========== 核心对齐修改 ========== */
.card-body{
  padding:16px;
  display:grid;
  gap:16px 8px;
  flex:1;
  align-content: start;
}
/* 分组标题固定高度，保证它占用的空间统一，不挤压item */
.body-title{
  grid-column:1/-1;
  font-size:14px;
  color:#555;
  margin:0;
  height:24px;
  line-height:24px;
  text-align:left;
}
/* 所有item统一固定高度，图标+文字垂直居中，顶部基准线对齐 */
.card-item{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:4px;
  text-align:center;
  font-size:13px;
  color:#333;
  text-decoration: none;
  height:72px; /* 固定盒子高度，关键！ */
}
/* 左右卡片：每行2个 */
.card-left .card-body,
.card-right .card-body{
  grid-template-columns: repeat(2,1fr);
}
/* 中间卡片：每行4个 */
.card-center .card-body{
  grid-template-columns: repeat(4,1fr);
}
.card-item img{
  width:42px;
  height:42px;
  object-fit:contain;
}
.tag-new{
  background:#ef4444;
  color:#fff;
  font-size:10px;
  padding:1px 4px;
  border-radius:3px;
  margin-left:3px;
}
.card-more{
  text-align:right;
  padding:6px 16px 12px;
  color:#2563eb;
  font-size:13px;
  text-decoration: none;
}
.search-suggest{
  position:absolute;
  top:calc(100% + 4px);
  left:0;
  right:0;
  background:#fff;
  border-radius:8px;
  box-shadow:0 8px 24px rgba(0,0,0,0.1);
  overflow:hidden;
  display:none;
  z-index:100;
  max-height:360px;
  overflow-y:auto;
}
.search-suggest.show{display:block}
.suggest-group{
  padding:10px 16px 4px;
  font-size:14px;
  color:#666;
  background:#f9fafb;
  font-weight:500;
  text-align:left;
}
.suggest-item{
  display:flex;
  align-items:center;
  gap:10px;
  padding:11px 16px;
  font-size:15px;
  color:#333;
  cursor:pointer;
  transition:background .15s;
  text-align:left;
}
.suggest-item:hover{
  background:#f3f4f6;
}
.suggest-item .s-ico{
  width:30px;
  height:30px;
  border-radius:6px;
  background:#f0f4ff;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}
.suggest-item .s-ico img,
.suggest-item .s-ico svg{
  width:16px;
  height:16px;
}
.suggest-item .s-name{
  flex:1;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  text-align:left;
}
.suggest-item .s-tag{
  font-size:12px;
  color:#2563eb;
  background:#e8f0fe;
  padding:3px 9px;
  border-radius:12px;
  flex-shrink:0;
}
.suggest-empty{
  padding:24px 16px;
  text-align:left;
  color:#999;
  font-size:14px;
}
.hero-user-tip{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:12px;
    margin-bottom:40px;
    font-size:16px;
    color:#475569;
}
.avatar-group{
    display:flex;
    overflow:hidden;
    width:220px;
    height:40px;
}
.avatar-track{
    display:flex;
    animation:avatarLoop 12s linear infinite;
}
.avatar-track img{
    width:40px;
    height:40px;
    border-radius:50%;
    border:2px solid #fff;
    margin-left:-10px;
    object-fit:cover;
}
.avatar-group:hover .avatar-track{
    animation-play-state:paused;
}
@keyframes avatarLoop {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}
.hero-features {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap:24px;
    max-width: 900px;
    margin: 0 auto 40px;
}
.hero-feature-item {
    display:flex;
    gap:10px;
    text-align:left;
}
.hero-feature-icon {
    width:28px;
    height:28px;
    border-radius:50%;
    background: var(--primary-light);
    color:var(--primary);
    display:flex;
    align-items:center;
    justify-content:center;
    flex-shrink:0;
}
.hero-feature-item strong {
    font-size: 18px;
    font-weight:700;
}
@media(max-width:992px){
  .hero-card-grid{
    grid-template-columns:1fr;
  }
  .card-left .card-body,
  .card-right .card-body,
  .card-center .card-body{
    grid-template-columns: repeat(2,1fr);
  }
  .hero-search{
    flex-wrap:wrap;
  }
  .search-side-link{
    position:static;
    flex-direction:row;
    width:100%;
    margin-top:8px;
  }
  .hero-slogan{
    font-size:26px;
    /* 移动端也可以单独控制间距，你需要的话在这里改 */
    --h1-top-space: 16px;
    --h1-bottom-space: 20px;
  }
  .hero{
    padding-top:80px;
  }
}
@media(max-width:768px){
    .hero-user-tip{ font-size:14px; }
    .avatar-group{ width:160px; }
    .avatar-track img{ width:32px; height:32px; }
    .hero-features {
        grid-template-columns: 1fr;
    }
}

.hfi-ico {
  width:16px;
  height:16px;
  vertical-align:middle;
  margin-right:4px;
  fill:#2b74d9;
}
