:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --bg-light: #f8f9fa;
    --text-color: #333;
}

.main-nav {
    background: var(--primary-color);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.main-nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 15px;
}

.nav-logo a {
    color: white;
    font-size: 1.5em;
    text-decoration: none;
    font-weight: bold;
    white-space: nowrap;
}

.nav-links {
    list-style: none;
    display: flex; /* 确保在PC上显示为flex */
    margin: 0;
    padding: 0;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
}

.nav-links li {
    margin: 0 10px;
    white-space: nowrap;
}

.nav-links a {
    color: white;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 4px;
    transition: background-color 0.3s;
    font-size: 0.9em;
}

.nav-links a:hover {
    background-color: var(--secondary-color);
}

/* 媒体查询 */
@media (max-width: 768px) {
    .nav-links {
        display: none; /* 默认隐藏导航链接 */
        flex-direction: column; /* 垂直排列 */
    }
    .nav-links.active {
        display: flex; /* 显示导航链接 */
    }
}

.nav-toggle {
    display: none; /* 默认隐藏 */
    background: none;
    border: none;
    color: white;
    font-size: 1.5em;
}

/* 媒体查询中显示按钮 */
@media (max-width: 768px) {
    .nav-toggle {
        display: block; /* 在小屏幕上显示 */
    }
    .nav-links {
        display: none; /* 默认隐藏导航链接 */
        flex-direction: column; /* 垂直排列 */
    }
    .nav-links.active {
        display: flex; /* 显示导航链接 */
    }
}

.nav-links.active {
    display: flex; /* 在小屏幕上显示 */
} 