/* ===== 阿拉伯语字体与导航修正（布局保持模板原始 LTR 方向） ===== */

/* 全站阿拉伯语字体 */
body {
    font-family: 'Tajawal', 'Segoe UI', 'Microsoft YaHei', Arial, sans-serif;
}

/* 固定导航链接行高：与 hover 高亮的 line-height 一致，避免移入时文字跳动、背景高度不统一 */
.nav_wrap .head_nav>li>a {
    line-height: 44px;
}

/* 在线客服：固定显示在页面顶部右侧 */
#scrollsidebar {
    position: fixed;
    top: 40px;
    right: 0;
    z-index: 9999;
}

/* ===== 导航条：统一背景色横贯全宽，去除菜单项拼凑色块 ===== */
@media screen and (min-width: 951px) {
    /* 导航背景：独立全宽层，铺满整个屏幕宽度（零计算，任何分辨率都填满） */
    .web_head .head_layer {
        position: relative;
    }
    .web_head .nav_bg {
        position: absolute;
        left: 0;
        right: 0;
        top: calc(100% - 44px);
        height: 44px;
        background-color: rgb(147, 120, 98);
        z-index: 0;
    }
    .nav_wrap {
        float: none;
        width: 100%;
        position: relative;
        z-index: 1;
        background-color: transparent;
    }
    .web_head .head_right {
        position: absolute;
        right: 0;
        top: 0;
        z-index: 10000;
        padding-right: 6px;
        background-color: transparent !important;
        height: 44px;
        display: flex;
        align-items: center;
        justify-content: flex-end;
    }
    /* 搜索按钮、语言切换在导航条内垂直居中 */
    .web_head .head_right .btn--search {
        margin-top: 0;
    }
    .web_head .head_right .change-language-title {
        display: flex;
        align-items: center;
    }
    /* 语言切换：导航条标题区只显示独立地球图标 + 箭头，标题区国旗隐藏（下拉语言列表里的国旗保留） */
    .web_head .head_right .change-language-title .country-flag {
        display: none;
    }
    /* 排列顺序：地球在左、小三角在右 */
    .web_head .head_right .change-language-title .language-flag {
        order: 2;
    }
    .web_head .head_right .language-icon {
        order: 1;
        width: 24px;
        height: 24px;
        display: inline-block;
        vertical-align: middle;
        background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='1.6'><circle cx='12' cy='12' r='9'/><path d='M3 12h18'/><path d='M12 3c2.4 2.5 2.4 15.5 0 18'/><path d='M12 3c-2.4 2.5-2.4 15.5 0 18'/><path d='M5.6 6.8c4.3 1.1 8.5 1.1 14.8 0'/><path d='M5.6 17.2c4.3-1.1 8.5-1.1 14.8 0'/></svg>") no-repeat center / contain;
        margin: 0 0 0 4px;
    }
    .web_head .head_right .language-flag a:after {
        margin: 0 2px 0 4px;
    }
    /* 导航顶部 logo 水平居中 */
    .web_head .head_layer .layout:nth-child(1) {
        justify-content: center;
    }
}

/* 窗口宽度在 951-1550px 之间时（内容区比视口宽），背景层保持全宽，按钮仍在内容容器内 */
@media screen and (min-width: 951px) and (max-width: 1550px) {
    .nav_wrap {
        margin-left: 0;
    }
}

/* ===== 移动端/平板导航菜单（侧滑面板） ===== */
@media screen and (max-width: 480px) {
    /* 手机宽度显示返回顶部按钮（覆盖原模板的隐藏规则），尺寸缩小 50% */
    .gotop {
        display: block !important;
        width: 36px;
        height: 36px;
        line-height: 36px;
        border-width: 2px;
        font-size: 15px;
    }
}
@media screen and (max-width: 950px) {
    /* 移动端隐藏导航条右侧的搜索/语言区（移动端由抽屉菜单提供） */
    .web_head .head_right {
        display: none !important;
    }
    /* 一级菜单项样式与当前栏目高亮 */
    .mobile-head-nav .head_nav > li > a {
        display: block;
        padding: 12px 10px;
        border-bottom: 1px solid #f0f0f0;
    }
    .mobile-head-nav .head_nav li.nav-current > a {
        color: #7F644E;
        font-weight: 700;
        background-color: #f7f2ea;
    }
    /* 箭头：只在有二级菜单的一级菜单右侧显示（深色，白底面板可见） */
    .mobile-head-nav .head_nav > li > a > b {
        float: right;
        margin-left: 8px;
        margin-top: 6px;
    }
    .mobile-head-nav .head_nav > li > a > b:after {
        border: 4px solid #666;
        border-top-width: 5px;
        border-bottom: 0;
        border-left-color: transparent;
        border-right-color: transparent;
    }
}

/* ===== 菜单箭头：只显示在有二级菜单的一级菜单右侧 ===== */
.head_nav > li:after {
    display: none;
}
.head_nav > li.has-sub:after {
    display: inline-block;
}

/* 菜单文字白色；hover/高亮不再出现背景色块，改用文字颜色区分 */
.nav_wrap .head_nav>li>a {
    background-color: transparent !important;
    color: #fff;
}
.nav_wrap .head_nav:hover>li.nav-current:hover>a,
.nav_wrap .head_nav:hover>li:hover>a {
    background-color: transparent !important;
    color: #ffd9a0;
}
.nav_wrap .head_nav>li.nav-current>a:before {
    display: none;
}
.nav_wrap .head_nav>li.nav-current>a {
    color: #ffd9a0;
    font-weight: 700;
}
