/* ========================================
   泊莱动力 - MUP风格导航样式
   ======================================== */

/* --- 导航栏容器 --- */
.top_header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999;
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease;
}

.top_header.scrolled {
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.top_header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1600px;
    width: 96%;
    margin: 0 auto;
    padding: 0;
    height: 70px;
}

/* --- Logo --- */
.top_logo {
    padding: 0 !important;
    margin: 0;
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.top_logo a {
    display: flex;
    align-items: center;
}

.top_logo img {
    height: 36px;
    width: auto;
    display: block;
}

/* --- 导航菜单区域 --- */
.top_nav_width {
    display: flex;
    align-items: center;
    flex: 1;
    justify-content: flex-end;
    margin: 0;
}

.top_nav {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
}

.top_nav > li {
    position: relative;
    float: none;
}

.top_nav > li > a {
    display: block;
    padding: 0 22px;
    line-height: 70px;
    font-size: 15px;
    font-weight: 500;
    color: #000000;
    text-decoration: none;
    position: relative;
    transition: color 0.4s ease;
}

/* 悬停下划线动画 - 从中心向两侧展开 */
.top_nav > li > a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #1eadf4;
    transition: width 0.4s ease, left 0.4s ease;
}

.top_nav > li:hover > a,
.top_nav > li.active > a {
    color: #1eadf4 !important;
}

.top_nav > li:hover > a::after,
.top_nav > li.active > a::after {
    width: 100%;
    left: 0;
}

/* PC端/移动端链接切换 */
.top_nav .nav_a_mobi {
    display: none;
}

.top_nav .nav_a_pc {
    display: block;
}

/* --- 下拉菜单 --- */
.arrowDG_menu_w {
    position: static;
}

.arrowDG_menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    padding: 8px 0;
}

.arrowDG_menu_w:hover .arrowDG_menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* 没有子菜单时隐藏下拉容器 */
.arrowDG_menu_w:hover .arrowDG_menu:has(> .navbarbox_ul_li) {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.arrowDG_menu:not(:has(> .navbarbox_ul_li)) {
    display: none !important;
}

.navbarbox_ul_li {
    padding: 0;
    text-align: left;
    white-space: nowrap;
}

.navbarbox_ul_li a {
    display: block;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 400;
    color: #666666;
    text-decoration: none;
    transition: color 0.3s ease, background 0.3s ease;
    line-height: 1.6;
}

.navbarbox_ul_li a:hover {
    color: #1eadf4;
    background: #f8f9fa;
}

/* --- 右侧操作按钮 --- */
.top_right {
    display: flex !important;
    align-items: center !important;
    gap: 10px;
    margin-left: 20px;
    flex-shrink: 0;
    float: none !important;
    position: static !important;
}

.top_right_padding {
    width: 42px !important;
    height: 42px !important;
    border-radius: 8px;
    background: #1675EA;
    display: flex !important;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.3s ease;
    color: #ffffff;
    font-size: 14px;
    font-weight: 500;
    margin: 0 !important;
    border: none !important;
}

.top_right_padding:hover {
    background: #0e5dc4;
}

/* 语言切换按钮样式覆盖 */
.top_language {
    margin: 0;
    padding: 0;
    width: 42px;
    height: 42px;
    border-radius: 8px;
    background: #1675EA;
    display: flex;
    align-items: center;
    justify-content: center;
}

.top_language .layui-unselect {
    color: #ffffff !important;
    font-size: 14px;
    font-weight: 500;
    height: auto;
    background: none !important;
    padding: 0;
}

.top_language .layui-form-select {
    padding-left: 0 !important;
    background: none !important;
}

.top_language .layui-form-select .layui-edge {
    display: none;
}

.top_language .layui-form-select dl dd.layui-this {
    background: #1675EA;
    color: #fff;
}

/* --- 汉堡菜单图标（移动端） --- */
.top_nav_icon {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 42px;
    height: 42px;
    cursor: pointer;
    gap: 5px;
    margin-left: 10px;
}

.top_nav_icon span {
    display: block;
    width: 22px;
    height: 2px;
    background: #000;
    transition: all 0.3s ease;
}

.top_nav_Close {
    display: none;
}

.caretl {
    clear: both;
}

/* --- 移动端响应式 --- */
@media (max-width: 992px) {
    .top_header .container {
        height: 60px;
    }

    .top_logo img {
        height: 30px;
    }

    .top_nav_width {
        position: fixed;
        top: 60px;
        left: 0;
        right: 0;
        bottom: 0;
        background: #ffffff;
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        padding: 20px;
        overflow-y: auto;
        transform: translateX(100%);
        transition: transform 0.3s ease;
        z-index: 998;
    }

    .top_nav_width.open {
        transform: translateX(0);
    }

    .top_nav {
        flex-direction: column;
        width: 100%;
    }

    .top_nav > li {
        width: 100%;
    }

    .top_nav > li > a {
        padding: 15px 0;
        line-height: 1.5;
        border-bottom: 1px solid #f0f0f0;
    }

    .top_nav > li > a::after {
        display: none;
    }

    .top_nav .nav_a_pc {
        display: none;
    }

    .top_nav .nav_a_mobi {
        display: block;
        padding: 15px 0;
        font-size: 15px;
        font-weight: 500;
        color: #000;
        border-bottom: 1px solid #f0f0f0;
    }

    .arrowDG_menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        display: none;
        padding: 0 0 0 20px;
    }

    .arrowDG_menu_w.open .arrowDG_menu {
        display: block;
    }

    .navbarbox_ul_li a {
        padding: 10px 0;
        font-size: 14px;
    }

    .top_nav_icon {
        display: flex;
    }

    .top_right {
        margin-left: auto;
    }
}
