/* 公共样式 - 湖南能源装备研究院（蓝色主题，依 Figma 设计稿） */

:root {
    --primary-blue: #0a5fb4;
    --deep-blue: #004d9c;
    --gradient-blue: #3b79cc;
    --accent-red: #e1220f;
    --gold: #cea983;
    --gold-light: #dec6ae;
    --gold-dark: #ceb295;
    --bg-light-blue: #e8f3ff;
    --bg-lighter-blue: #f8fbff;
    --bg-card: #f8f9fa;
    --text-main: #333333;
    --text-sub: #666666;
    --text-more: #7593b4;
    --container-width: 1560px;
}

/* 容器 */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    box-sizing: border-box;
}

/* 页面整体：内容不足时让页脚始终贴底（sticky footer） */
body {
    height: auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ========== 页头 ========== */
.site-header {
    width: 100%;
}

/* 顶部通栏 */
.top-strip {
    height: 30px;
    background: var(--primary-blue);
    color: #fff;
    font-size: 12px;
    line-height: 30px;
}

.top-strip .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.top-strip-date {
    color: #fff;
    font-size: 12px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.top-strip-links {
    display: flex;
    align-items: center;
    gap: 22px;
}

.top-strip-link {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #fff;
    font-size: 12px;
    line-height: 1;
}

.top-strip-link:hover {
    opacity: 0.85;
}

.top-strip-icon {
    display: block;
    object-fit: contain;
}

/* 顶部通栏：微信公众号 hover 二维码 */
.top-strip-qr {
    position: relative;
    display: flex;
    align-items: center;
}

.top-strip-qr > .top-strip-link {
    cursor: default;
}

.top-strip-qr:hover > .top-strip-link {
    opacity: 0.85;
}

.top-strip-qr-pop {
    position: absolute;
    top: 100%;
    right: 0;
    width: 150px;
    padding-top: 10px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    z-index: 300;
}

.top-strip-qr:hover .top-strip-qr-pop {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.top-strip-qr-pop img {
    display: block;
    box-sizing: border-box;
    width: 100%;
    max-width: none;
    height: auto;
    object-fit: contain;
    background: #fff;
    padding: 10px;
    border-radius: 4px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.22);
}

/* 联系我们（单页图文） */
.contact-info {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 140px;
    padding: 70px 0 70px;
}

.contact-item {
    width: 260px;
    text-align: center;
}

.contact-icon {
    width: 78px;
    height: 78px;
    margin: 0 auto 22px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2f7fd4 0%, var(--primary-blue) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 16px rgba(10, 95, 180, 0.28);
}

.contact-icon svg {
    display: block;
}

.contact-label {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 12px;
}

.contact-value {
    font-size: 13px;
    color: var(--text-sub);
    line-height: 1.8;
    word-break: break-all;
}

@media (max-width: 768px) {
    .contact-info {
        flex-direction: column;
        align-items: center;
        gap: 40px;
        padding: 10px 0 40px;
    }

    .contact-item {
        width: 100%;
        max-width: 320px;
    }
}

/* 主导航区 */
.header-main {
    height: 101px;
    background: linear-gradient(90deg, var(--deep-blue) 0%, var(--gradient-blue) 100%);
    position: relative;
    overflow: visible;
    z-index: 100;
}

.header-main::after {
    content: '';
    position: absolute;
    inset: 0;
    background: url('../hnu-images/home/header-bg.png') center / cover no-repeat;
    opacity: 0.25;
    pointer-events: none;
}

.header-main .container {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.header-logo {
    flex-shrink: 0;
    display: block;
}

.header-logo img {
    width: 368px;
    height: auto;
    display: block;
}

.main-nav {
    height: 100%;
}

.nav-menu {
    display: flex;
    align-items: center;
    height: 100%;
    gap: 44px;
}

.nav-menu > li > a {
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    position: relative;
    padding: 8px 0;
}

.nav-menu > li > a:hover {
    opacity: 0.85;
}

.nav-menu > li > a.active {
    color: #FBC976;
}

/* 一级菜单项（含子菜单） */
.nav-menu > li.has-submenu {
    position: relative;
    display: flex;
    align-items: center;
    height: 100%;
}

/* 下拉指示箭头 */
.nav-menu > li.has-submenu > a::after {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    margin-left: 8px;
    margin-bottom: 3px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    vertical-align: middle;
    transition: transform 0.3s;
}

.nav-menu > li.has-submenu:hover > a::after {
    transform: rotate(-135deg);
}

/* 二级菜单（下拉面板）——紧贴导航文字下方，配色沿用项目蓝金风格 */
.nav-menu .submenu {
    position: absolute;
    top: calc(50% + 18px);
    left: 50%;
    min-width: 176px;
    padding: 8px 0;
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 14px 30px rgba(0, 77, 156, 0.22);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(12px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
    z-index: 200;
}

/* 顶部品牌金装饰条 */
.nav-menu .submenu::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    border-radius: 6px 6px 0 0;
    background: linear-gradient(90deg, var(--gold) 0%, #FBC976 100%);
}

.nav-menu > li.has-submenu:hover .submenu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.nav-menu .submenu li {
    display: block;
}

.nav-menu .submenu li a {
    position: relative;
    display: block;
    padding: 11px 24px;
    color: var(--text-sub);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.4;
    white-space: nowrap;
    transition: background 0.2s, color 0.2s;
}

.nav-menu .submenu li a::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 3px;
    border-radius: 0 3px 3px 0;
    background: var(--primary-blue);
    transform: scaleY(0);
    transition: transform 0.2s ease;
}

.nav-menu .submenu li a:hover {
    background: var(--bg-light-blue);
    color: var(--primary-blue);
    font-weight: 700;
}

.nav-menu .submenu li a:hover::before {
    transform: scaleY(1);
}

/* PC 端二级菜单开关：默认不显示（可在后台「站点配置」开启；移动端抽屉不受影响） */
@media (min-width: 1201px) {
    .site-header.nav-submenu-off .nav-menu .submenu {
        display: none;
    }

    .site-header.nav-submenu-off .nav-menu > li.has-submenu > a::after {
        display: none;
    }
}

/* 汉堡菜单按钮 - PC 隐藏 */
.hamburger-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
}

.hamburger-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: #fff;
    transition: all 0.3s;
}

/* ========== 栏目标签（红色标签 + 小三角） ========== */
.section-tabs {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    height: 56px;
    position: relative;
}

.section-tabs-left {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.section-tab {
    font-size: 26px;
    font-weight: 700;
    line-height: 56px;
    color: var(--primary-blue);
    cursor: pointer;
    white-space: nowrap;
    position: relative;
    padding: 0 23px;
}

/* 深色文字标签（浅蓝底区域） */
.section-tabs .section-tab {
    color: var(--text-main);
}

.section-tab.is-active {
    background: var(--accent-red);
    color: #fff;
    height: 56px;
}

.section-tab.is-active::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -8px;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 9px solid transparent;
    border-right: 9px solid transparent;
    border-top: 8px solid var(--accent-red);
}

.more-link {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-more);
    font-size: 14px;
    line-height: 26px;
    margin-top: 15px;
}

.more-link:hover {
    color: var(--primary-blue);
}

.more-link img {
    width: 11px;
    height: 11px;
    display: block;
}

/* ========== 页脚 ========== */
.page-footer {
    width: 100%;
    background: var(--deep-blue) url('../hnu-images/home/footer-bg.png') center / cover no-repeat;
    color: #fff;
    position: relative;
    margin-top: auto;
}

.footer-inner {
    padding-top: 41px;
    box-sizing: border-box;
}

.footer-main {
    display: flex;
    align-items: flex-start;
    gap: 60px;
}

.footer-logo {
    flex-shrink: 0;
    display: block;
}

.footer-logo img {
    width: 368px;
    height: auto;
    display: block;
}

.footer-links {
    flex: 1;
    display: none;
    align-items: center;
    justify-content: center;
    gap: 40px;
    padding-top: 24px;
}

.footer-link-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-size: 16px;
}

.footer-link-item:hover {
    opacity: 0.85;
}

.footer-link-icon {
    display: block;
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.footer-qrcode {
    flex-shrink: 0;
    width: 97px;
    height: 97px;
    padding: 5px;
    border: 1px solid #286CAE;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    background: transparent;
}

.footer-qrcode img {
    width: 100%;
    height: 100%;
    display: block;
}

.footer-contact {
    font-size: 14px;
    line-height: 26px;
    color: #fff;
    width: 310px;
    flex-shrink: 0;
}

.footer-contact p {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 4px;
}

.footer-contact-icon {
    flex-shrink: 0;
    margin-top: 6px;
    object-fit: contain;
}

.footer-contact-text {
    flex: 1;
    min-width: 0;
    text-align: left;
    padding-left: 3em;
    text-indent: -3em;
}

.footer-divider {
    width: 100%;
    height: 1px;
    background: rgba(255, 255, 255, 0.25);
    margin-top: 35px;
}

.footer-copyright {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 17px 0;
    font-size: 14px;
    line-height: 26px;
    color: #fff;
}

.footer-badge {
    width: 20px;
    height: 20px;
    display: block;
}

/* ========== 回到顶部按钮 ========== */
.back-to-top {
    position: fixed;
    right: 30px;
    bottom: 30px;
    width: 48px;
    height: 48px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 50%;
    cursor: pointer;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.back-to-top::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -40%) rotate(-45deg);
    width: 12px;
    height: 12px;
    border-top: 2px solid var(--primary-blue);
    border-right: 2px solid var(--primary-blue);
}

.back-to-top:hover {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
}

.back-to-top:hover::before {
    border-color: #fff;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* ========== 滚动动画 ========== */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

.animate-on-scroll.delay-1 { transition-delay: 0.1s; }
.animate-on-scroll.delay-2 { transition-delay: 0.2s; }
.animate-on-scroll.delay-3 { transition-delay: 0.3s; }
.animate-on-scroll.delay-4 { transition-delay: 0.4s; }
.animate-on-scroll.delay-5 { transition-delay: 0.5s; }
.animate-on-scroll.delay-6 { transition-delay: 0.6s; }

/* ========== 图文分栏（富文本） ========== */
/* 文字列首/末子元素去掉默认外边距，保证“顶部/居中”对齐时文字与图片真正对齐 */
.rt-imgtext-body > :first-child {
    margin-top: 0;
}

.rt-imgtext-body > :last-child {
    margin-bottom: 0;
}

/* ========== 富文本正文：列表与链接 ========== */
/* reset.css 已清除列表符号与内边距、去掉链接下划线，
   此处仅对正文区恢复，保证编辑器与前台显示一致 */
.article-body ul,
.article-body ol {
    padding-left: 1.6em;
}

.article-body ul {
    list-style: disc;
}

.article-body ul ul {
    list-style: circle;
}

.article-body ol {
    list-style: decimal;
}

.article-body ol ol {
    list-style: lower-alpha;
}

.article-body a {
    color: var(--primary-blue);
    text-decoration: underline;
}
