@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: linear-gradient(135deg, #f0f4ff 0%, #faf5ff 50%, #fdf2f8 100%);
  color: #1a1a2e;
  line-height: 1.7;
  min-height: 100vh;
}

a {
  color: #4f46e5;
  text-decoration: none;
  transition: color 0.2s;
}

/* ===== Header ===== */
.site-header {
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.02);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 18px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo a {
  font-size: 22px;
  font-weight: 800;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

.nav-links a {
  margin-left: 28px;
  color: #64748b;
  font-size: 15px;
  font-weight: 500;
  position: relative;
  padding: 4px 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  border-radius: 1px;
  transition: width 0.25s ease;
}

.nav-links a:hover::after,
.nav-links a.router-link-exact-active::after {
  width: 100%;
}

.nav-links a:hover,
.nav-links a.router-link-exact-active {
  color: #4f46e5;
}

/* ===== Main content ===== */
.main-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 28px 80px;
}

/* ===== Post list ===== */
.blog-list h2 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 8px;
  color: #1a1a2e;
  letter-spacing: -0.8px;
}

.blog-list .subtitle {
  color: #94a3b8;
  font-size: 15px;
  margin-bottom: 36px;
  font-weight: 500;
}

.post-card {
  background: #fff;
  border-radius: 16px;
  padding: 32px 36px;
  margin-bottom: 20px;
  border: 1px solid rgba(226, 232, 240, 0.6);
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.post-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(135deg, #4f46e5, #7c3aed, #ec4899);
  opacity: 0;
  transition: opacity 0.3s;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(79, 70, 229, 0.1), 0 4px 12px rgba(0,0,0,0.05);
  border-color: rgba(79, 70, 229, 0.15);
}

.post-card:hover::before {
  opacity: 1;
}

.post-card .post-title {
  font-size: 21px;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.3px;
}

.post-card .post-title a {
  color: #1e293b;
}

.post-card .post-title a:hover {
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.post-card .post-meta {
  font-size: 13px;
  color: #94a3b8;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.post-card .tag {
  display: inline-block;
  background: linear-gradient(135deg, #eef2ff, #f3e8ff);
  color: #6d28d9;
  font-size: 12px;
  font-weight: 600;
  padding: 3px 12px;
  border-radius: 20px;
}

.post-card p {
  color: #64748b;
  line-height: 1.7;
  font-size: 15px;
}

.read-more {
  display: inline-block;
  margin-top: 14px;
  font-size: 14px;
  font-weight: 600;
  color: #4f46e5;
  transition: transform 0.2s;
}

.read-more:hover {
  transform: translateX(4px);
}

/* ===== Post detail ===== */
.post-detail {
  background: #fff;
  border-radius: 20px;
  padding: 48px 44px;
  border: 1px solid rgba(226, 232, 240, 0.6);
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.post-detail .post-header {
  margin-bottom: 36px;
  padding-bottom: 28px;
  border-bottom: 2px solid #f1f5f9;
}

.post-detail h2 {
  font-size: 34px;
  font-weight: 800;
  color: #1a1a2e;
  margin-bottom: 14px;
  line-height: 1.3;
  letter-spacing: -0.8px;
}

.post-detail .post-meta {
  font-size: 14px;
  color: #94a3b8;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.post-detail .tag {
  display: inline-block;
  background: linear-gradient(135deg, #eef2ff, #f3e8ff);
  color: #6d28d9;
  font-size: 12px;
  font-weight: 600;
  padding: 3px 12px;
  border-radius: 20px;
}

.post-detail .post-body {
  font-size: 17px;
  color: #334155;
  line-height: 1.9;
}

.post-detail .post-body h3 {
  font-size: 24px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 36px 0 14px;
  letter-spacing: -0.4px;
}

.post-detail .post-body p {
  margin-bottom: 18px;
}

.post-detail .post-body pre {
  background: linear-gradient(135deg, #1e293b, #0f172a);
  border-radius: 12px;
  padding: 20px 24px;
  overflow-x: auto;
  font-size: 14px;
  font-family: "SF Mono", "Fira Code", "Cascadia Code", monospace;
  margin-bottom: 20px;
  color: #e2e8f0;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.2);
}

.post-detail .post-body code {
  background: #f1f5f9;
  color: #e11d48;
  padding: 2px 7px;
  border-radius: 5px;
  font-size: 0.9em;
  font-weight: 500;
}

.post-detail .post-body pre code {
  background: transparent;
  color: #e2e8f0;
  padding: 0;
  border-radius: 0;
}

.post-detail .post-body blockquote {
  border-left: 4px solid #818cf8;
  padding: 16px 20px;
  color: #475569;
  margin: 20px 0;
  font-style: italic;
  background: #f8fafc;
  border-radius: 0 10px 10px 0;
  font-size: 16px;
}

.post-detail .back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 40px;
  font-size: 14px;
  font-weight: 600;
  color: #4f46e5;
  padding: 10px 20px;
  border-radius: 10px;
  background: #eef2ff;
  transition: all 0.2s;
}

.post-detail .back-link:hover {
  background: #e0e7ff;
  transform: translateX(-3px);
}

/* Not found state */
.not-found {
  text-align: center;
  padding: 60px 20px;
}

.not-found h2 {
  font-size: 48px;
  font-weight: 800;
  color: #e2e8f0;
  margin-bottom: 12px;
}

.not-found p {
  color: #94a3b8;
  margin-bottom: 24px;
}

.not-found a {
  font-weight: 600;
}

/* ===== About page ===== */
.about-page {
  background: #fff;
  border-radius: 20px;
  padding: 48px 44px;
  border: 1px solid rgba(226, 232, 240, 0.6);
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.about-page h2 {
  font-size: 30px;
  font-weight: 800;
  margin-bottom: 24px;
  color: #1a1a2e;
  letter-spacing: -0.6px;
}

.about-page p {
  color: #475569;
  margin-bottom: 16px;
  font-size: 16px;
}

.about-page ul {
  margin: 12px 0 20px 24px;
}

.about-page li {
  color: #475569;
  margin-bottom: 8px;
  font-size: 15px;
  padding-left: 4px;
}

.about-page li::marker {
  color: #818cf8;
}

/* ===== Footer ===== */
.site-footer {
  text-align: center;
  padding: 28px;
  color: #94a3b8;
  font-size: 13px;
  border-top: 1px solid rgba(226, 232, 240, 0.6);
  background: rgba(255,255,255,0.5);
}

/* ===== Responsive ===== */
@media (max-width: 640px) {
  .header-inner {
    padding: 14px 16px;
  }

  .logo a {
    font-size: 18px;
  }

  .main-content {
    padding: 24px 14px 50px;
  }

  .post-card {
    padding: 22px 20px;
    border-radius: 14px;
  }

  .post-detail,
  .about-page {
    padding: 28px 20px;
    border-radius: 16px;
  }

  .post-detail h2 {
    font-size: 26px;
  }

  .blog-list h2 {
    font-size: 26px;
  }
}
