:root {
    --primary-color: #0056b3;
    --secondary-color: #f8f9fa;
    --accent-color: #ff6b35;
    --e-global-color : #031D61;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

a {
    text-decoration: none;
}

/* 1. 导航栏基础样式 */
.navbar {
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    width: 100%;
    top: 0;
    z-index: 1030;
    padding-top: 15px; /* 初始稍微加点顶距 */
    padding-bottom: 15px;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--primary-color) !important;
}
/* Logo Sizing */
.navbar-brand img {
    height: 25px; /* Adjust height as needed */
    width: auto;
    transition: all 0.3s ease;
}

/* Optional: Ensure the navbar background changes to white on scroll */
.navbar.scrolled {
    background-color: #ffffff !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.nav-link {
    font-weight: 500;
    margin: 0 10px;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color) !important;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 3px;
    background: var(--accent-color);
    border-radius: 2px;
}

/* 下拉菜单 */
.dropdown-menu {
    border: none;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    border-radius: 15px;
    padding: 2rem;
    min-width: 1440px;
    left: 50%;
    transform: translateX(-50%);
    top: 100%;
    margin-top: 0.5rem;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
}

.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid white;
}

.product-category {
    padding: 0 1.5rem;
    border-right: 1px solid #e9ecef;
    height: 100%;
}

.product-category:last-child {
    border-right: none;
}

.product-category-header {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid var(--accent-color);
}

.product-category-icon {
    font-size: 2rem;
    color: var(--primary-color);
    margin-right: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.product-category h6 {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 1.1rem;
    margin: 0;
}

.product-category ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.product-category ul li {
    margin-bottom: 0.6rem;
}

.product-category ul li a {
    color: #555;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    padding: 0.4rem 0.8rem;
    border-radius: 8px;
}

.product-category ul li a:hover {
    color: var(--primary-color);
    background: rgba(0, 86, 179, 0.08);
    padding-left: 1.2rem;
}

.product-category ul li a i {
    font-size: 0.7rem;
    margin-right: 0.5rem;
    opacity: 0;
    transition: all 0.3s ease;
    color: var(--accent-color);
}

.product-category ul li a:hover i {
    opacity: 1;
    margin-right: 0.8rem;
}

.product-hot {
    position: relative;
}

.product-hot::after {
    content: 'HOT';
    position: absolute;
    right: -30px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--accent-color);
    color: white;
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 10px;
    font-weight: bold;
}

/* 通用头部 */
.page-header {
    background: white;
    padding: 4rem 0;
    margin-bottom: 3rem;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.page-header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* 面包屑 */
.breadcrumb {
    background: transparent;
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: ">";
    color: #999;
}

.breadcrumb-item a {
    color: #FFFFFF;
    transition: color 0.3s ease;
}

.breadcrumb-item a:hover {
    color: var(--primary-color);
}

.breadcrumb-item.active {
    color: var(--primary-color);
    font-weight: 600;
}

/* 咨询弹窗 */
.modal-content {
    border-radius: 15px;
    overflow: hidden;
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    border: none;
}

.modal-header .btn-close {
    filter: invert(1);
}

.modal-body {
    padding: 2rem;
}

.form-control,
.form-select {
    border-radius: 10px;
    border: 1px solid #e0e0e0;
    padding: 12px 15px;
    transition: all 0.3s ease;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 86, 179, 0.1);
}

/* 页脚 */
footer {
    background: #031D61;
    color: white;
    padding: 50px 0 20px;
    margin-top: 80px;
}

.footer-links a {
    color: #bdc3c7;
    transition: color 0.3s ease;
    display: block;
    padding: 5px 0;
}

.footer-links a:hover {
    color: white;
}

.social-icons a {
    color: white;
    font-size: 1.5rem;
    margin: 0 10px;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    color: var(--accent-color);
    transform: translateY(-3px);
}

/* --- 语言菜单终极定位修正 --- */

/* 1. 强制父级容器为定位基准 */
/* 这一步非常重要，它确保下拉框是相对于"这个按钮"定位，而不是相对于整个网页 */
#langNavItem {
    position: relative !important;
}

/* 2. 下拉框定位样式 */
.language-menu {
    /* 位置控制 */
    position: absolute !important;
    top: 100% !important;
    /* 紧贴按钮底部 */
    right: 0 !important;
    /* 右侧对齐 */
    left: auto !important;
    /* 禁止左侧对齐（防止被超级菜单样式拉扯） */
    margin-top: 10px !important;
    /* 增加一点顶部间距，不要贴太死 */

    /* 尺寸控制 */
    width: auto !important;
    /* 宽度自适应 */
    min-width: 180px;
    /* 最小宽度 */
    max-height: 400px;
    /* 最大高度 */
    overflow-y: auto;
    /* 超高显示滚动条 */

    /* 外观美化 */
    padding: 8px 0;
    border-radius: 8px;
    background-color: #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid #eee;
    z-index: 9999;
    /* 确保显示在最上层 */

    /* 移除可能存在的 Flex/Grid 干扰 */
    display: none;
    /* 默认隐藏，Bootstrap 会在点击时切换为 block */
}

/* 当添加了 .show 类时显示 (Bootstrap 控制) */
.language-menu.show {
    display: block !important;
}

/* 选项样式微调 */
.language-menu .dropdown-item {
    padding: 8px 16px;
    font-size: 14px;
    color: #333;
    display: flex;
    align-items: center;
    background: transparent;
    /* 防止背景色干扰 */
}

.language-menu .dropdown-item:hover {
    background-color: #f8f9fa;
    /* 浅灰背景 */
    color: #0d6efd;
    /* 蓝色文字 */
}

.language-menu .dropdown-item.active {
    background-color: #0d6efd;
    color: #fff;
}

/* 国旗图标样式 */
.language-menu .flag-icon {
    width: 1.2em;
    line-height: 1em;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* ===== 隐私政策横幅样式 ===== */
.privacy-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: white;
    padding: 2rem 0;
    z-index: 9999;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.3);
    transform: translateY(100%);
    transition: transform 0.5s ease;
}

.privacy-banner.show {
    transform: translateY(0);
}

.privacy-banner-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.privacy-banner-text {
    flex: 1;
    min-width: 300px;
}

.privacy-banner-title {
    font-weight: 600;
    margin-bottom: 0.3rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.privacy-banner-description {
    font-size: 0.9rem;
    opacity: 0.9;
    margin: 0;
}

.privacy-banner-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.btn-privacy {
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.btn-privacy-accept {
    background: var(--accent-color);
    color: white;
}

.btn-privacy-accept:hover {
    background: #ff5722;
    transform: translateY(-2px);
}

.btn-privacy-decline {
    background: transparent;
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-privacy-decline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-privacy-details {
    background: transparent;
    color: #64b5f6;
    border: 1px solid #64b5f6;
}

.btn-privacy-details:hover {
    background: #64b5f6;
    color: white;
}

/* 为横幅留出空间 */
body.has-privacy-banner {
    padding-bottom: 80px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .privacy-banner-content {
        flex-direction: column;
        text-align: center;
    }

    .privacy-banner-text {
        min-width: auto;
        margin-bottom: 1rem;
    }

    .privacy-banner-actions {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .btn-privacy {
        flex: 1;
        min-width: 100px;
    }

    body.has-privacy-banner {
        padding-bottom: 150px;
    }
}


/* 仅在 PC 端 (屏幕宽度 > 992px) 生效的悬浮样式 */
@media (min-width: 992px) {
    /* 当添加了 navbar-scrolled 类名时的样式 */
    .navbar.navbar-scrolled {
        top: 20px; /* 距顶部有一点空间 */
        width: 90%; /* 或者是具体的 calc(100% - 40px) */
        max-width: 1240px; /* 限制最大宽度 */
        left: 50%;
        transform: translateX(-50%); /* 居中定位 */

        border-radius: 50px; /* 大圆角 (胶囊状) */
        background-color: rgba(255, 255, 255, 0.95); /* 白色背景，轻微透明 */
        backdrop-filter: blur(10px); /* 毛玻璃效果 */
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08); /* 悬浮投影 */
        padding: 10px 30px; /* 增加内边距让它看起来更饱满 */
    }

    /* 滚动后，导航栏内的文字颜色可能需要变黑 (如果你原本是白色的) */
    .navbar.navbar-scrolled .nav-link,
    .navbar.navbar-scrolled .navbar-brand {
        color: #333 !important;
    }

    /* 修复下拉菜单在圆角导航栏中的显示 */
    .navbar.navbar-scrolled .dropdown-menu {
        border: none;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        border-radius: 15px;
        margin-top: 15px;
    }
}

/* 移动端保持原样，或者简单的白色背景 */
@media (max-width: 991.98px) {
    .navbar.navbar-scrolled {
        background-color: #fff;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }
}

/* 响应式 */
@media (max-width: 1400px) {
    .dropdown-menu {
        min-width: 1000px;
    }
}

@media (max-width: 1200px) {
    .dropdown-menu {
        min-width: 900px;
    }

    .product-category {
        padding: 0 1rem;
    }
}

@media (max-width: 992px) {
    .navbar-collapse {
        background: white;
        padding: 1rem;
        border-radius: 15px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        margin-top: 1rem;
    }

    .dropdown-menu {
        min-width: 100%;
        left: 0;
        transform: none;
        margin-top: 0;
        padding: 1rem;
        background: transparent;
        box-shadow: none;
        border-radius: 0;
    }

    .dropdown-menu::before {
        display: none;
    }

    .product-category {
        border-right: none;
        border-bottom: 1px solid #e9ecef;
        padding: 1rem 0;
    }

    .product-category:last-child {
        border-bottom: none;
    }
}