/* 顶部导航栏和悬浮联系按钮样式 */

/* 悬浮联系按钮 */
.float-contact {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.float-contact a {
    display: flex;
    align-items: center;
    background: #25D366;
    color: white;
    padding: 12px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
}

.float-contact svg {
    margin-right: 8px;
}

/* 导航栏样式 - 固定头部 */
nav {
    background: #fff;
    border-bottom: 1px solid #eee;
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
    position: fixed; /* 改为 fixed 而不是 sticky */
    top: 0; /* 始终固定在顶部 */
    left: 0; /* 左对齐 */
    width: 100%; /* 全宽度 */
    z-index: 999; /* 确保在最上层 */
    transition: all 0.3s ease; /* 添加过渡效果 */
}

/* 确保页面内容不会被导航栏遮挡 */
body {
    padding-top: 80px; /* 根据导航栏高度调整，这里是80px */
}

nav .nav-wrap {
    max-width: 1100px;
    margin: auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 50px; /* 固定的导航栏高度 */
}

nav .nav-wrap strong {
    font-size: 1.1rem;
    color: #0b4ea2;
}

.nav-links {
    display: flex;
    align-items: center;
}

nav a {
    margin-left: 20px;
    text-decoration: none;
    color: #0b4ea2;
    font-weight: 500;
    transition: color 0.2s ease;
    font-size: 0.95rem;
}

nav a:hover {
    color: #0f6fdc;
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* 可选：添加滚动时导航栏阴影加深效果 */
.nav-scrolled {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    background: rgba(255, 255, 255, 0.98); /* 轻微透明效果 */
    backdrop-filter: blur(5px); /* 毛玻璃效果 */
}

/* 移动端适配 */
@media (max-width: 768px) {
    /* 移动端导航栏高度调整 */
    nav .nav-wrap {
        height: auto;
        min-height: 50px;
    }

    /* 移动端body padding调整 */
    body {
        padding-top: 60px; /* 移动端导航栏较矮 */
    }

    .nav-links {
        flex-wrap: wrap;
        gap: 8px;
        margin-top: 10px;
        width: 100%;
        justify-content: center;
    }

    nav a {
        margin-left: 10px;
        font-size: 14px;
    }

    .float-contact {
        bottom: 20px;
        right: 20px;
    }

    .float-contact a {
        padding: 10px 16px;
        font-size: 14px;
    }
}