/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', sans-serif;
    line-height: 1.5;
    color: #102a42;
}

ul {
    list-style-type: none;
}

a {
    text-decoration: none;
}

h1, h2 {
    letter-spacing: 0.25rem;
    text-transform: capitalize;
    line-height: 1.25;
    margin-bottom: 0.75rem;
}

h1 {
    font-size: 3rem;
}

h2 {
    font-size: 2rem;
}

p {
    margin-bottom: 1.25rem;
    color: #617d98;
}

/* 导航栏样式 */
nav {
    background: transparent; /* 初始透明 */
    padding: 1rem 1.5rem;
    transition: all 0.3s linear;
    z-index: 999;
    position: fixed; /* 改为固定定位，始终吸顶 */
    top: 0;
    left: 0;
    width: 100%;
}

/* 固定导航栏类 */
.fixed-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: #fff; /* 滚动后变白 */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.nav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    height: 40px;
    font-size: 1.5rem;
    color: #fff; /* 初始白色 */
    font-weight: bold;
    letter-spacing: 0.1rem;
    display: flex;
    align-items: center;
    transition: all 0.3s linear;
}

/* 滚动后 logo 变黑 */
.fixed-nav .logo {
    color: #102a42;
}

.nav-toggle {
    font-size: 1.5rem;
    color: #fff; /* 初始白色 */
    background: transparent;
    border-color: transparent;
    transition: all 0.3s linear;
    cursor: pointer;
    display: none;
}

.fixed-nav .nav-toggle {
    color: #49a6e9;
}

.links-container {
    height: auto !important;
    overflow: hidden;
    transition: all 0.3s linear;
}

.links {
    display: flex;
}

.links a {
    color: #fff; /* 初始白色 */
    font-size: 1.1rem;
    text-transform: capitalize;
    letter-spacing: 0.1rem;
    display: block;
    padding: 0.75rem 1.25rem;
    transition: all 0.3s linear;
}

.links a:hover {
    color: #49a6e9;
}

/* 激活状态样式 */
.links a.active {
    color: #49a6e9;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 0.25rem;
}

/* 滚动后链接变黑 */
.fixed-nav .links a {
    color: #102a42;
}

.fixed-nav .links a:hover {
    color: #49a6e9;
}

.fixed-nav .links a.active {
    color: #49a6e9;
    background: transparent;
    font-weight: bold;
    border-bottom: 2px solid #49a6e9;
    border-radius: 0;
}

/* 英雄区域 */
header {
    min-height: 100vh;
    background: linear-gradient(rgba(63, 208, 212, 0.5), rgba(0, 0, 0, 0.7)),
        url("https://images.pexels.com/photos/1659438/pexels-photo-1659438.jpeg?auto=compress&cs=tinysrgb&w=1260&h=750&dpr=1")
            center/cover no-repeat;
}

.banner {
    min-height: 100vh;
    display: grid;
    place-items: center;
    text-align: center;
    color: #fff;
}

.container p {
    color: #fff;
    max-width: 25rem;
    margin: 0 auto;
    margin-bottom: 1.25rem;
}

.btn {
    text-transform: uppercase;
    background: transparent;
    color: #102a42;
    padding: 0.375rem 0.75rem;
    letter-spacing: 0.1rem;
    display: inline-block;
    transition: all 0.3s linear;
    font-size: 0.875rem;
    border: 2px solid #102a42;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    border-radius: 0.25rem;
}

.btn-white {
    color: #fff;
    border-color: #fff;
}

.btn:hover {
    background: #49a6e9;
    color: #fff;
    border-color: #49a6e9;
}

/* 各个部分样式 */
.section {
    padding: 5rem 0;
    width: 90vw;
    margin: 0 auto;
    max-width: 1170px;
    min-height: 100vh; /* 为了演示滚动效果 */
}

.title {
    text-align: center;
    margin-bottom: 4rem;
}

footer {
    background: #102a42;
    padding: 5rem 1rem;
    text-align: center;
    color: #fff;
    min-height: auto;
    width: 100%;
    max-width: 100%;
}

footer p {
    color: #fff;
    margin-bottom: 0;
}

/* 返回顶部按钮 */
.top-link {
    font-size: 1.25rem;
    position: fixed;
    bottom: 3rem;
    right: 3rem;
    background: #49a6e9;
    width: 2rem;
    height: 2rem;
    display: grid;
    place-items: center;
    border-radius: 0.25rem;
    color: #fff;
    transition: all 0.3s linear;
    visibility: hidden;
    z-index: -100;
}

.show-link {
    visibility: visible;
    z-index: 100;
}

.arrow-up {
    font-weight: bold;
}