/* 全局样式 */
:root {
  --primary-color: #333;
  --secondary-color: #666;
  --accent-color: #4a90e2;
  --background-color: #fff;
  --light-gray: #f5f5f5;
  --border-color: #eaeaea;
  --footer-bg: #f9f9f9;
  --max-width: 1200px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Noto Sans SC', 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: var(--primary-color);
  background-color: var(--background-color);
}

a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: #2c6cb9;
}

.container {
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* 头部样式 */
header {
  padding: 30px 0;
  border-bottom: 1px solid var(--border-color);
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-title {
  font-size: 1.8rem;
  font-weight: 700;
}

.site-title a {
  color: var(--primary-color);
}

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

.site-nav li {
  margin-left: 30px;
}

.site-nav a {
  color: var(--secondary-color);
  font-weight: 500;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--accent-color);
}

/* 主要内容区域 */
main {
  padding: 40px 0;
  min-height: calc(100vh - 200px);
}

.page-title {
  margin-bottom: 30px;
  font-size: 2rem;
  font-weight: 700;
}

.intro-text {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--secondary-color);
  margin-bottom: 40px;
  max-width: 800px;
}

/* 文章列表 */
.article-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 30px;
}

.article-card {
  background: var(--background-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.article-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.article-image {
  height: 180px;
  background-color: var(--light-gray);
  background-size: cover;
  background-position: center;
}

.article-content {
  padding: 20px;
}

.article-date {
  font-size: 0.9rem;
  color: var(--secondary-color);
  margin-bottom: 10px;
}

.article-title {
  font-size: 1.2rem;
  margin-bottom: 10px;
  font-weight: 600;
}

.article-excerpt {
  color: var(--secondary-color);
  font-size: 0.95rem;
  margin-bottom: 15px;
}

.read-more {
  display: inline-block;
  font-size: 0.9rem;
  font-weight: 500;
}

/* 文章详情页 */
.article-header {
  margin-bottom: 30px;
}

.article-meta {
  color: var(--secondary-color);
  margin-bottom: 15px;
  font-size: 0.95rem;
}

.article-title-large {
  font-size: 2.2rem;
  margin-bottom: 20px;
  line-height: 1.3;
}

.article-body {
  max-width: 800px;
  margin: 0 auto;
}

.article-body p {
  margin-bottom: 20px;
  line-height: 1.8;
}

.article-body h2 {
  margin: 40px 0 20px;
  font-size: 1.6rem;
}

.article-body h3 {
  margin: 30px 0 15px;
  font-size: 1.3rem;
}

.article-body img {
  max-width: 100%;
  height: auto;
  margin: 20px 0;
  border-radius: 8px;
}

/* 关于页面 */
.about-content {
  max-width: 800px;
}

.about-content p {
  margin-bottom: 20px;
  line-height: 1.8;
}

/* 页脚样式 */
footer {
  background-color: var(--footer-bg);
  padding: 30px 0;
  border-top: 1px solid var(--border-color);
  font-size: 0.9rem;
  color: var(--secondary-color);
}

.footer-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.beian a {
  color: var(--secondary-color);
}

.beian a:hover {
  color: var(--accent-color);
}

/* 响应式设计 */
@media (max-width: 768px) {
  .site-header {
    flex-direction: column;
    text-align: center;
  }
  
  .site-nav {
    margin-top: 20px;
  }
  
  .site-nav ul {
    justify-content: center;
  }
  
  .site-nav li {
    margin: 0 15px;
  }
  
  .article-list {
    grid-template-columns: 1fr;
  }
  
  .footer-content {
    flex-direction: column;
    text-align: center;
  }
  
  .footer-content > div:first-child {
    margin-bottom: 15px;
  }
  
  .article-title-large {
    font-size: 1.8rem;
  }
}

@media (max-width: 480px) {
  .page-title {
    font-size: 1.6rem;
  }
  
  .intro-text {
    font-size: 1rem;
  }
}