/**
 * 导航栏样式 - 期货一键查网站
 */

/* 导航栏基础样式 */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.06);
    padding: 0;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    height: 130px; /* 修改高度为130px，大于二维码高度(100px)的1.2倍 */
    width: 100%;
}

/* 导航栏容器 */
.navbar .container {
    max-width: 1200px; /* 设置与页面内容相同的最大宽度 */
    width: 100%;
    margin: 0 auto;
    padding-right: 15px;
    padding-left: 15px;
}

/* 品牌名称 - 全新设计 */
.navbar-brand, .brand-name {
    font-size: 28px;
    font-weight: 600;
    color: #333 !important;
    position: relative;
    padding: 0.7rem 1rem;
    transition: all 0.3s ease;
    letter-spacing: 0;
    font-family: 'Montserrat', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    text-decoration: none;
    display: flex;
    align-items: center;
}

/* 品牌文本样式 */
.brand-text {
    display: inline-block;
    position: relative;
}

/* 品牌标志 */
.brand-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background-color: #0066cc;
    border-radius: 8px;
    margin-right: 8px;
    color: white;
    font-weight: 700;
    font-size: 20px;
    box-shadow: 0 3px 10px rgba(0, 102, 204, 0.2);
    transform: rotate(-5deg);
    transition: all 0.3s ease;
}

/* 品牌名称第一部分 */
.brand-first {
    font-weight: 700;
    color: #0066cc;
}

/* 品牌名称第二部分 */
.brand-second {
    font-weight: 700;
    color: #0066cc;
}

/* 品牌悬停效果 */
.navbar-brand:hover, .brand-name:hover {
    transform: translateY(-2px);
}

.navbar-brand:hover .brand-logo, .brand-name:hover .brand-logo {
    transform: rotate(0deg) scale(1.1);
    box-shadow: 0 5px 15px rgba(0, 102, 204, 0.3);
}

.navbar-brand:hover .brand-first, .brand-name:hover .brand-first {
    color: #0056b3;
}

/* 移除旧的品牌样式 */
.brand-highlight {
    display: none;
}

@keyframes pulse-brand {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

/* 导航链接 */
.navbar-nav .nav-link {
    color: #555;
    font-weight: 500;
    padding: 2.5rem 1rem 1rem !important; /* 减少底部内边距，使下划线更靠近文字 */
    position: relative;
    font-size: 16px;
    transition: all 0.3s ease;
    white-space: nowrap; /* 确保文本在一行显示 */
}

.navbar-nav .nav-link:after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: 5px; /* 将下划线向上移动，更靠近文字 */
    left: 50%;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
    transform: translateX(-50%);
    opacity: 0;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--primary-color);
}

.navbar-nav .nav-link:hover:after,
.navbar-nav .nav-link.active:after {
    width: 80%;
    opacity: 1;
}

/* 导航链接图标 */
.navbar-nav .nav-link .nav-icon {
    margin-right: 5px;
    font-size: 14px;
}

/* 响应式菜单按钮 */
.navbar-toggler {
    border: none;
    padding: 0.5rem;
    transition: all 0.3s ease;
    border-radius: 6px;
}

.navbar-toggler:focus {
    box-shadow: none;
    outline: none;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%280, 0, 0, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* 下拉菜单 */
.dropdown-menu {
    border: none;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.1);
    padding: 1rem 0;
    animation: dropdown-animation 0.3s ease forwards;
    overflow: hidden;
}

@keyframes dropdown-animation {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-item {
    padding: 0.6rem 1.5rem;
    font-weight: 500;
    color: #555;
    font-size: 15px;
    transition: all 0.2s ease;
}

.dropdown-item:hover, 
.dropdown-item:focus, 
.dropdown-item:active {
    background-color: rgba(2, 117, 216, 0.08);
    color: var(--primary-color);
    transform: translateX(5px);
}

/* 导航特殊链接样式 */
.fee-link {
    position: relative;
}

.fee-link::before {
    content: 'HOT';
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 9px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #dc3545, #ff6b6b);
    padding: 2px 6px;
    border-radius: 10px;
    line-height: 1;
    box-shadow: 0 2px 6px rgba(220, 53, 69, 0.3);
    animation: pulse-hot 2s infinite;
    transform-origin: center;
    z-index: 1;
}

@keyframes pulse-hot {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.9;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* 响应式调整 */
@media (max-width: 992px) {
    .navbar {
        height: auto;
    }
    
    .navbar-nav .nav-link {
        padding: 1rem !important; /* 减小移动端内边距 */
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        white-space: nowrap; /* 确保移动设备上也是一行显示 */
    }
    
    .navbar-nav .nav-link:after {
        display: none;
    }
    
    .navbar-nav .nav-item:last-child .nav-link {
        border-bottom: none;
    }
    
    .navbar-collapse {
        background-color: #fff;
        box-shadow: 0 10px 15px rgba(0, 0, 0, 0.05);
        border-radius: 0 0 10px 10px;
        padding: 0.5rem;
    }
    
    /* 移动端品牌样式强制覆盖 */
    .brand-first, .brand-second {
        font-weight: 700 !important;
        color: #0066cc !important;
    }
    
    .navbar-brand, .brand-name {
        font-size: 24px;
    }
    
    .brand-logo {
        width: 32px;
        height: 32px;
        font-size: 18px;
    }
    
    .fee-link::before {
        right: auto;
        left: 80px;
    }
}

/* 添加导航栏微信容器样式 */
.navbar-wechat-container {
    max-width: 100%;
    overflow: visible;
}

@media (max-width: 768px) {
    .navbar-wechat-container {
        width: 100%;
        margin-top: 15px;
        display: flex;
        justify-content: center;
    }
    
    .wechat-qr-container {
        margin-left: 0;
        width: 100%;
        justify-content: center;
    }
} 