/* 宏彦科技 · 全站头部：固定 / 白底 / logo + 菜单 + 搜索 + 获取方案 */

/* ============================================================
   V3 头部重构：单排三段（logo / 菜单 / 搜索+方案）
   ============================================================ */

.headerBox,
.headerBox.h-bg-active {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    height: auto;
    background: rgba(255, 255, 255, .93);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(4, 42, 86, .08);
    box-shadow: none;
    transition: box-shadow .35s, background .35s;
}
.headerBox.scrolled { box-shadow: 0 12px 34px rgba(4, 42, 86, .08) }

.hd-bar {
    width: 1280px;
    max-width: 92%;
    height: 88px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 48px;
}

.hd-logo {
    flex: 0 0 236px;
    display: block;
}
.hd-logo img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 56px;
    object-fit: contain;
}

.hd-nav { flex: 1; display: flex; justify-content: center }
.hd-nav ul {
    display: flex;
    align-items: center;
    gap: 42px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.hd-nav li { position: relative }
.hd-nav li>a {
    display: block;
    padding: 10px 0;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: .1em;
    color: #16202e;
    white-space: nowrap;
    transition: color .3s;
}
.hd-nav li>a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 2px;
    width: 0;
    height: 2px;
    background: #005097;
    transition: width .35s;
}
.hd-nav li>a:hover { color: #005097 }
.hd-nav li>a:hover::after,
.hd-nav li.on>a::after { width: 100% }
.hd-nav li.on>a { color: #0d1b2a }

/* 二级下拉 */
.hd-sub {
    position: absolute;
    top: 100%;
    left: 50%;
    min-width: 208px;
    padding: 10px 0;
    background: #ffffff;
    border: 1px solid rgba(4, 42, 86, .08);
    box-shadow: 0 26px 52px rgba(4, 42, 86, .12);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(10px);
    transition: .32s;
    z-index: 12;
}
.hd-nav li:hover .hd-sub {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.hd-sub ul { display: block; gap: 0 }
.hd-sub li>a {
    display: block;
    padding: 11px 26px;
    font-size: 13.5px;
    font-weight: 400;
    letter-spacing: .04em;
    color: #45566a;
}
.hd-sub li>a::after { display: none }
.hd-sub li>a:hover { color: #005097; background: #f5f8fc }

.hd-right {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 18px;
}
.hd-search {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: 0;
    padding: 0;
    cursor: pointer;
    color: #16202e;
    font-size: 18px;
    transition: color .3s;
}
.hd-search:hover { color: #005097 }

.h-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    height: 44px;
    padding: 0 24px;
    margin-left: 0;
    background: #005097;
    border: 1px solid #005097;
    color: #ffffff;
    font-size: 13px;
    letter-spacing: .08em;
    transition: .35s;
    white-space: nowrap;
}
.h-cta i { font-style: normal; font-size: 15px; transition: .35s }
.h-cta:hover { background: #003f78; border-color: #003f78; color: #fff }
.h-cta:hover i { transform: translateX(3px) }

/* 搜索面板：从头下沿铺开 */
.hd-search-panel {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 0;
    overflow: hidden;
    background: #ffffff;
    border-bottom: 1px solid rgba(4, 42, 86, .08);
    box-shadow: 0 24px 44px rgba(4, 42, 86, .08);
    transition: height .36s cubic-bezier(.2, .7, .2, 1);
}
.headerBox.search-open .hd-search-panel { height: 104px }
.hd-search-form {
    width: 1280px;
    max-width: 92%;
    height: 104px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 22px;
}
.hd-search-form input[name=keyword] {
    flex: 1;
    height: 54px;
    border: 0;
    border-bottom: 1px solid rgba(4, 42, 86, .16);
    background: transparent;
    font-size: 15px;
    color: #16202e;
    letter-spacing: .02em;
    outline: none;
}
.hd-search-form input[name=keyword]::placeholder { color: #9aa8b8 }
.hd-search-form input[name=keyword]:focus { border-bottom-color: #005097 }
.hd-search-form button {
    height: 54px;
    padding: 0 40px;
    border: 0;
    background: #005097;
    color: #fff;
    font-size: 14px;
    letter-spacing: .12em;
    cursor: pointer;
    transition: background .3s;
}
.hd-search-form button:hover { background: #003f78 }
.hd-search-close {
    font-size: 13px;
    color: #8b97a6;
    letter-spacing: .06em;
    padding: 8px;
}
.hd-search-close:hover { color: #005097 }

/* 手机端 */
@media screen and (max-width: 1023px) {
    .hd-bar { gap: 14px; height: 64px; padding-right: 48px }
    .hd-logo { flex: 0 0 132px }
    .hd-logo img { max-height: 43px }
    .hd-nav, .h-cta { display: none }
    .hd-right { margin-left: auto; gap: 6px }
    .hd-search { width: 38px; height: 38px }
    .hd-search { font-size: 17px }
    .headerBox.search-open .hd-search-panel,
    .hd-search-form { height: 92px }
    .hd-search-form { gap: 12px }
    .hd-search-form button { padding: 0 22px }
    .hd-search-close { display: none }
}




/* ===== 1688 官方店铺图标（搜索图标右侧，与放大镜同尺寸） ===== */
.hd-1688 {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    padding: 0;
    background: none;
    text-decoration: none;
    transition: transform .22s, filter .22s;
}
.hd-1688 img {
    display: block;
    width: 28px;
    height: 28px;
    border-radius: 7px;
    object-fit: contain;
}
.hd-1688:hover {
    transform: translateY(-1px) scale(1.06);
    filter: brightness(1.06);
}
/* ===== 1024–1280 窄桌面：压缩间距，避免导航与右侧按钮溢出 ===== */
@media screen and (max-width: 1280px) and (min-width: 1024px) {
    .hd-bar { gap: 26px }
    .hd-nav ul { gap: 20px }
    .hd-nav li > a { font-size: 14px; letter-spacing: .04em }
    .hd-right { gap: 10px }
    .h-cta { padding: 0 16px; font-size: 14px }
    .hd-1688 { width: 22px; height: 22px; flex: 0 0 22px }
    .hd-1688 img { width: 22px; height: 22px; border-radius: 5px }
}