body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    margin: 0;
    background-color: #f4f6f8;
    color: #333;
}

header {
    background-color: #fff;
    padding: 20px 40px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

h1 {
    margin: 0;
    font-size: 24px;
    color: #0056b3;
}

.search-container {
    display: flex;
    align-items: center;
}

.search-container input {
    width: 250px;
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 20px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s;
}

.search-container button {
    background-color: #0056b3;
    color: white;
    border: none;
    border-radius: 20px;
    padding: 8px 16px;
    margin-left: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
    white-space: nowrap;
}

.search-container button:hover {
    background-color: #004494;
}

.search-container input:focus {
    border-color: #0056b3;
}

nav {
    display: flex;
    border-bottom: 1px solid #ddd;
}

nav a {
    padding: 10px 20px;
    text-decoration: none;
    color: #555;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    transition: color 0.3s, border-bottom-color 0.3s;
}

nav a.active,
nav a:hover {
    color: #0056b3;
    border-bottom-color: #0056b3;
}

main {
    padding: 20px 40px;
}

.category {
    background-color: #fff;
    margin-bottom: 20px;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.category h2 {
    font-size: 18px;
    color: #333;
    margin-top: 0;
    margin-bottom: 15px;
    border-left: 4px solid #0056b3;
    padding-left: 10px;
}

.site-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.site-item {
    display: block;
    background-color: #f9f9f9;
    padding: 10px 15px;
    border-radius: 5px;
    text-decoration: none;
    color: #333;
    transition: background-color 0.3s, color 0.3s;
    border: 1px solid #eee;
}

.site-item:hover {
    background-color: #0056b3;
    color: #fff;
}

/* 响应式设计 */
@media (max-width: 768px) {
    header {
        padding: 20px;
    }
    .header-content {
        flex-direction: column;
        align-items: flex-start;
    }
    h1 {
        margin-bottom: 15px;
    }
    .search-container {
        width: 100%;
        margin-bottom: 15px;
    }
    .search-container input {
        width: 100%;
        box-sizing: border-box;
    }
    nav {
        flex-wrap: wrap;
    }
    main {
        padding: 20px;
    }
}