/* 基本重置和全局样式 */
body, h1, h2, h3, p, ul, li, a {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    line-height: 1.7;
    background-color: #f4f7f6;
    color: #333;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a {
    color: #007bff;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* 头部 */
header {
    background-color: #2c3e50;
    color: #ecf0f1;
    text-align: center;
    padding: 2.5rem 1rem;
}

header h1 {
    margin-bottom: 0.5rem;
    font-size: 2.5rem;
}

header p {
    font-size: 1.1rem;
    color: #bdc3c7;
}

/* 导航栏 */
nav {
    background-color: #34495e;
    padding: 1rem;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav a {
    color: #ffffff;
    text-decoration: none;
    font-weight: bold;
    padding: 0.5rem 1.5rem;
    display: inline-block;
    transition: background-color 0.3s ease;
    border-radius: 4px;
}

nav a:hover {
    background-color: #46627f;
    text-decoration: none;
}

/* 导航高亮 */
nav a.active {
    background-color: #1abc9c;
    color: #fff;
}

/* 页面布局容器 */
.container {
    display: flex;
    max-width: 1100px;
    margin: 2rem auto;
    padding: 0 1rem;
    flex-grow: 1;
}

/* 主内容区域 */
main {
    flex: 3;
    margin-right: 2rem;
}

.page-title {
    font-size: 2rem;
    color: #2c3e50;
    border-bottom: 2px solid #ecf0f1;
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

/* 文章样式 */
article {
    background-color: #ffffff;
    border-radius: 8px;
    padding: 1.5rem 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

article h2 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
    font-size: 1.8rem;
}

article h2 a {
    color: #2c3e50;
    text-decoration: none;
}
article h2 a:hover {
    color: #1abc9c;
    text-decoration: none;
}

article .date {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    border-bottom: 1px dashed #eee;
    padding-bottom: 0.5rem;
}

article p {
    margin-bottom: 1rem;
}

article .read-more {
    display: inline-block;
    font-weight: bold;
    color: #1abc9c;
}
article .read-more:hover {
    color: #16a085;
    text-decoration: none;
}

/* "关于" 页面特定样式 */
.about-page ul {
    list-style-type: disc;
    margin: 1rem 0 1rem 2rem;
}
.about-page li {
    margin-bottom: 0.5rem;
}


/* 侧边栏 */
aside {
    flex: 1;
    min-width: 240px;
}

.widget {
    background-color: #ffffff;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    margin-bottom: 2rem;
}

.widget h3 {
    font-size: 1.3rem;
    color: #34495e;
    border-bottom: 2px solid #f4f7f6;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

.widget ul {
    list-style: none;
}

.widget li {
    margin-bottom: 0.75rem;
}

.widget li a {
    text-decoration: none;
    color: #555;
}
.widget li a:hover {
    color: #1abc9c;
    text-decoration: none;
}

/* 页脚 */
footer {
    background-color: #222;
    color: #aaa;
    text-align: center;
    padding: 1.5rem 1rem;
    width: 100%;
    margin-top: auto; /* 确保页脚在内容不足时也贴底 */
    font-size: 0.9rem;
}

footer p {
    margin-bottom: 0.5rem;
}

footer a {
    color: #ecf0f1;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* 响应式设计（简单） */
@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }
    main {
        margin-right: 0;
    }
}