/* 基础样式设置 */
:root {
  --primary-color: #ff6b81;
  --primary-light: #ffccd5;
  --primary-dark: #e84a5f;
  --text-color: #4a4a4a;
  --text-light: #8a8a8a;
  --bg-color: #fff;
  --bg-light: #f9f9f9;
  --bg-accent: #fff0f3;
  --border-color: #eee;
  --border-accent: #ffccd5;
  --link-hover: #ff4757;
  --font-main: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-title: 'LXGW WenKai', 'Noto Serif SC', 'SimSun', serif;
  --font-code: 'JetBrains Mono', 'Fira Code', monospace;
  --font-cute: 'MiSans', 'HarmonyOS Sans SC', sans-serif;
  --shadow: 0 5px 15px rgba(0,0,0,0.05);
  --transition: all 0.3s ease;
}

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

body {
  font-family: var(--font-main);
  color: var(--text-color);
  line-height: 1.8;
  background-color: var(--bg-color);
  font-size: 16px;
  letter-spacing: 0.3px;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  font-display: swap;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  position: relative;
}

a:hover {
  color: var(--primary-dark);
}

a:after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--primary-light);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

a:hover:after {
  transform: scaleX(1);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--primary-dark);
  line-height: 1.4;
  margin-bottom: 1rem;
}

p {
  margin-bottom: 1.5rem;
}

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

/* 头部样式 */
.header {
  padding: 25px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid var(--primary-light);
  margin-bottom: 20px;
}

.site-brand a {
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--primary-dark);
  position: relative;
}

.site-brand a:after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--primary-light);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s ease;
}

.site-brand a:hover:after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav {
  display: flex;
  gap: 25px;
}

.nav a {
  font-size: 1.05rem;
  font-weight: 500;
  position: relative;
  padding: 5px 0;
}

.nav a:before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--primary-color);
  transform: scaleX(0);
  transition: var(--transition);
}

.nav a:hover:before {
  transform: scaleX(1);
}

/* 主要内容区 */
.main-content {
  padding: 30px 0;
  min-height: 70vh;
}

/* 文章列表 */
.post-list {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.post-item {
  padding: 30px;
  border-radius: 12px;
  background: var(--bg-color);
  box-shadow: var(--shadow);
  transition: var(--transition);
  border-left: 4px solid var(--primary-light);
}

.post-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
  border-left-color: var(--primary-color);
}

.post-date {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 10px;
  display: inline-block;
  padding: 3px 10px;
  background: var(--bg-light);
  border-radius: 20px;
}

.post-title {
  margin-bottom: 15px;
}

.post-title a {
  color: var(--text-color);
  font-size: 1.6rem;
  line-height: 1.4;
  transition: var(--transition);
}

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

.post-excerpt {
  color: var(--text-light);
  margin: 15px 0;
  line-height: 1.8;
}

.read-more a {
  display: inline-block;
  margin-top: 15px;
  padding: 6px 15px;
  border-radius: 20px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
}

.read-more a:hover {
  background: var(--primary-color);
  color: white;
  transform: translateX(5px);
}

/* 文章页面 */
.post {
  padding: 30px;
  border-radius: 12px;
  background: var(--bg-color);
  box-shadow: var(--shadow);
}

.post-header {
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px dashed var(--border-accent);
}

.post-meta {
  color: var(--text-light);
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 10px;
}

.post-time {
  background: var(--primary-light);
  padding: 3px 10px;
  border-radius: 20px;
  color: var(--primary-dark);
}

.post-category a {
  margin-right: 5px;
}

.post-content {
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  line-height: 1.9;
}

.post-footer {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px dashed var(--border-accent);
}

.post-tags a {
  font-family: var(--font-cute);
  font-size: 0.9rem;
  background: var(--primary-light);
  color: var(--primary-dark);
  padding: 2px 8px;
  border-radius: 12px;
  transition: all 0.3s ease;
}

.post-tags a:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

/* 归档页面 */
.archive, .category, .tag {
  background: var(--bg-color);
  padding: 30px;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.page-title {
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 2px solid var(--primary-light);
  color: var(--primary-dark);
}

.archive-year h2 {
  font-size: 1.5rem;
  margin: 40px 0 20px;
  color: var(--primary-dark);
  display: inline-block;
  padding: 5px 15px;
  background: var(--primary-light);
  border-radius: 20px;
}

.archive-list {
  margin-left: 20px;
}

.archive-item {
  margin-bottom: 15px;
  padding-bottom: 15px;
  border-bottom: 1px dashed var(--border-color);
  display: flex;
  align-items: center;
}

.archive-date {
  min-width: 100px;
  color: var(--text-light);
}

.archive-title {
  font-weight: 500;
}

/* 分页 */
.pagination {
  display: flex;
  justify-content: space-between;
  margin-top: 40px;
}

.prev, .next {
  padding: 8px 20px;
  background: var(--primary-light);
  color: var(--primary-dark);
  border-radius: 25px;
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
}

.prev:hover, .next:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-3px);
}

/* 页脚样式 */
.footer {
  padding: 30px 0;
  text-align: center;
  color: var(--text-light);
  font-size: 0.9rem;
  border-top: 2px solid var(--primary-light);
  margin-top: 50px;
}

.copyright {
  margin-bottom: 8px;
}

.powered-by a {
  font-weight: 500;
}

/* 返回顶部按钮 */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 45px;
  height: 45px;
  background: var(--primary-color);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  box-shadow: 0 3px 10px rgba(232, 74, 95, 0.3);
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--primary-dark);
  transform: translateY(-5px);
}

/* 响应式设计 */
@media (max-width: 768px) {
  .header {
    flex-direction: column;
    gap: 15px;
  }
  
  .nav {
    gap: 15px;
  }
  
  .post-item {
    padding: 20px;
  }
  
  .post-title a {
    font-size: 1.4rem;
  }
}

/* 动画效果 */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.main-content {
  animation: fadeIn 0.5s ease;
}

/* 在style.css中添加头像样式 */
.site-info {
  display: flex;
  align-items: center;
  gap: 15px;
}

.avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--primary-light);
  box-shadow: 0 3px 10px rgba(255, 107, 129, 0.2);
  transition: var(--transition);
}

.avatar:hover {
  transform: scale(1.1);
  border-color: var(--primary-color);
  box-shadow: 0 5px 15px rgba(255, 107, 129, 0.3);
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 代码块字体 */
pre, code {
  font-family: var(--font-code);
}

/* 特殊文本样式 */
.cute-text {
  font-family: var(--font-cute);
  color: var(--primary-color);
} 