﻿body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #f9f9f9;
}

/* 头部样式 */
.top-header {
    max-width: 768px;
    height: 40px;
    margin: 0 auto;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #2c3e50;
    border-bottom: 1px solid #e0e0e0;
}

.top-logo {
    font-size: 24px;
    font-weight: bold;
    color: #fff;
}

.auth-links a {
    margin-left: 15px;
    text-decoration: none;
    color: #fff;
    font-size: 14px;
    transition: color 0.3s ease;
}

    .auth-links a:hover {
        color: #007bff;
    }


/* 导航容器样式 */
.top-nav-container {
    max-width: 768px;
    margin: 0px auto;
    padding: 20px;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 0px;
}

/* 链接容器 */
.top-nav-link-grid {
    display: grid;
    grid-template-rows: repeat(2, 1fr); /* 2 行 */
    grid-template-columns: repeat(9, 1fr); /* 每行 9 个链接 */
    gap: 10px; /* 链接间距 */
}

/* 链接样式 */
.top-nav-link {
    display: block; /* 让 <a> 标签表现为块级元素 */
    padding: 10px;
    text-align: center;
    background-color: #fff;
    color: black;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 16px;
    text-decoration: none; /* 去掉下划线 */
    transition: background-color 0.3s ease;
}

    .top-nav-link:hover {
        background-color: #0056b3;
        color:#fff;
    }

/* 移动端样式 */
@media (max-width: 480px) {
    .top-nav-link {
        font-size: 16px; /* 缩小字体 */
        padding: 8px; /* 缩小内边距 */
    }
}