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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* 容器 */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
header {
    background-color: #fff;
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    padding: 1rem 0;
}

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

.logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-menu li {
    margin-left: 2rem;
}

.nav-menu a {
    color: #666;
    text-decoration: none;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.nav-menu a:hover {
    color: #333;
}

/* 主内容 */
main {
    padding: 2rem 0;
    min-height: calc(100vh - 200px);
}

/* 文章列表 */
.posts {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.post {
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.post-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: #666;
}

.post-title {
    margin-bottom: 1rem;
    font-size: 1.5rem;
    font-weight: 600;
}

.post-title a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-title a:hover {
    color: #007bff;
}

.post-excerpt {
    color: #666;
    font-size: 1rem;
}

.post-excerpt p {
    margin: 0;
}

/* 文章详情页 */
.post-detail {
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.post-content {
    margin-top: 2rem;
    line-height: 1.8;
}

.post-content h2 {
    margin: 1.5rem 0 1rem;
    font-size: 1.25rem;
    font-weight: 600;
}

.post-content p {
    margin-bottom: 1rem;
}

/* 关于页面 */
.about {
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.about h2 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
    font-weight: 600;
}

.about p {
    margin-bottom: 1rem;
    color: #666;
    line-height: 1.8;
}

/* 页脚 */
footer {
    background-color: #fff;
    border-top: 1px solid #e9ecef;
    padding: 1.5rem 0;
    margin-top: 2rem;
}

footer p {
    text-align: center;
    color: #666;
    font-size: 0.875rem;
    margin: 0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    nav .container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-menu li {
        margin: 0 1rem;
    }
    
    .post, .post-detail, .about {
        padding: 1.5rem;
    }
    
    .post-title {
        font-size: 1.25rem;
    }
}