/* ============================================
   博豪的个人博客 - Modern Blog Stylesheet
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-card: #1e293b;
  --bg-card-hover: #263548;
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --accent: #38bdf8;
  --accent-hover: #7dd3fc;
  --accent-gradient: linear-gradient(135deg, #38bdf8, #818cf8);
  --border: #334155;
  --code-bg: #0d1117;
  --shadow: 0 4px 24px rgba(0,0,0,0.3);
  --shadow-lg: 0 12px 48px rgba(0,0,0,0.4);
  --radius: 16px;
  --radius-sm: 10px;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans SC', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;
  --max-width: 1200px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg-primary: #f8fafc;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f1f5f9;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --accent: #0284c7;
  --accent-hover: #0369a1;
  --border: #e2e8f0;
  --code-bg: #f1f5f9;
  --shadow: 0 4px 24px rgba(0,0,0,0.08);
  --shadow-lg: 0 12px 48px rgba(0,0,0,0.12);
}

/* --- Reset & Base --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  min-height: 100vh;
  transition: background var(--transition), color var(--transition);
}

a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-hover); }

img { max-width: 100%; height: auto; display: block; }

::selection { background: var(--accent); color: var(--bg-primary); }

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* --- Navigation --- */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(51, 65, 85, 0.5);
  transition: all var(--transition);
}

[data-theme="light"] .navbar {
  background: rgba(248, 250, 252, 0.85);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.navbar-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-logo .logo-icon {
  width: 32px; height: 32px;
  background: var(--accent-gradient);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: #fff;
  font-weight: 800;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
  background: rgba(56, 189, 248, 0.1);
}

.nav-links a.active { color: var(--accent); }

.theme-toggle {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  width: 40px; height: 40px;
  border-radius: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all var(--transition);
}

.theme-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: rotate(30deg);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.25rem;
}

/* --- Hero Section --- */
.hero {
  padding: 140px 2rem 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(ellipse at 30% 20%, rgba(56, 189, 248, 0.08) 0%, transparent 50%),
              radial-gradient(ellipse at 70% 80%, rgba(129, 140, 248, 0.06) 0%, transparent 50%);
  pointer-events: none;
  animation: heroGlow 12s ease-in-out infinite alternate;
}

@keyframes heroGlow {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-2%, 2%) scale(1.05); }
}

.hero-content { position: relative; max-width: 720px; margin: 0 auto; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 100px;
  font-size: 0.85rem;
  color: var(--accent);
  margin-bottom: 1.5rem;
  font-weight: 500;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
}

.hero h1 .gradient-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto 2rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
}

.btn-primary {
  background: var(--accent-gradient);
  color: #fff;
  box-shadow: 0 4px 16px rgba(56, 189, 248, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(56, 189, 248, 0.4);
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* --- Section --- */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4rem 2rem;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-title .icon {
  width: 28px; height: 28px;
  background: var(--accent-gradient);
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  color: #fff;
}

.section-link {
  font-size: 0.9rem;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-weight: 500;
}

.section-link:hover { gap: 0.5rem; }

/* --- Post Cards Grid --- */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.5rem;
}

.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}

.post-card:hover {
  border-color: rgba(56, 189, 248, 0.3);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.post-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-bottom: 1px solid var(--border);
}

.post-card-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.post-tag {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  background: rgba(56, 189, 248, 0.1);
  color: var(--accent);
  border: 1px solid rgba(56, 189, 248, 0.15);
}

.post-date {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.post-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-card h3 a { color: var(--text-primary); }
.post-card h3 a:hover { color: var(--accent); }

.post-card p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-card-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.read-time {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.read-more {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.read-more:hover { gap: 0.5rem; }

/* --- Featured Post (Large) --- */
.featured-card {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 360px;
}

.featured-card .post-card-img {
  height: 100%;
  border-bottom: none;
  border-right: 1px solid var(--border);
}

.featured-card .post-card-body {
  padding: 2rem;
}

.featured-card .post-card-body h3 { font-size: 1.4rem; }

/* --- About Section --- */
.about-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  align-items: start;
}

.about-avatar {
  width: 240px;
  height: 240px;
  border-radius: var(--radius);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 5rem;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.about-avatar::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(255,255,255,0.1) 100%);
}

.about-info h2 {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.about-info .subtitle {
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
}

.about-info p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
  line-height: 1.8;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.skill-tag {
  padding: 0.4rem 0.9rem;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
  transition: all var(--transition);
}

.skill-tag:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(56, 189, 248, 0.15);
}

/* --- Article Page --- */
.article-hero {
  padding: 120px 2rem 40px;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.article-hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 1rem;
}

.article-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  flex-wrap: wrap;
}

.article-meta span { display: flex; align-items: center; gap: 0.3rem; }

.article-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem 2rem 4rem;
}

.article-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 2.5rem 0 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  color: var(--text-primary);
}

.article-content h2:first-child { border-top: none; padding-top: 0; margin-top: 0; }

.article-content h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 2rem 0 0.75rem;
  color: var(--text-primary);
}

.article-content p {
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  line-height: 1.85;
}

.article-content ul, .article-content ol {
  color: var(--text-secondary);
  margin: 0 0 1.25rem 1.5rem;
  line-height: 1.85;
}

.article-content li { margin-bottom: 0.4rem; }

.article-content strong { color: var(--text-primary); font-weight: 600; }

.article-content a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: rgba(56, 189, 248, 0.3);
  text-underline-offset: 3px;
}

.article-content a:hover { text-decoration-color: var(--accent); }

.article-content blockquote {
  border-left: 3px solid var(--accent);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  background: rgba(56, 189, 248, 0.05);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--text-secondary);
  font-style: italic;
}

.article-content img {
  border-radius: var(--radius-sm);
  margin: 1.5rem 0;
  border: 1px solid var(--border);
}

.article-content code:not(pre code) {
  background: var(--code-bg);
  padding: 0.15rem 0.45rem;
  border-radius: 5px;
  font-family: var(--font-mono);
  font-size: 0.85em;
  color: var(--accent);
  border: 1px solid var(--border);
}

.article-content pre {
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
  overflow-x: auto;
  position: relative;
}

.article-content pre code {
  font-family: var(--font-mono);
  font-size: 0.88rem;
  line-height: 1.7;
  color: #e2e8f0;
}

.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9rem;
}

.article-content th, .article-content td {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  text-align: left;
}

.article-content th {
  background: var(--bg-secondary);
  font-weight: 600;
  color: var(--text-primary);
}

.article-content td { color: var(--text-secondary); }

/* --- Article Navigation --- */
.article-nav {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 2rem 4rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.article-nav-item {
  padding: 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.article-nav-item:hover {
  border-color: rgba(56, 189, 248, 0.3);
  transform: translateY(-2px);
}

.article-nav-item .label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.article-nav-item .title {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.95rem;
}

.article-nav-item.next { text-align: right; }

/* --- TOC (Table of Contents) --- */
.toc {
  position: fixed;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  max-width: 220px;
  max-height: 60vh;
  overflow-y: auto;
  z-index: 100;
  display: none;
}

.toc-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
}

.toc a {
  display: block;
  padding: 0.3rem 0;
  font-size: 0.82rem;
  color: var(--text-muted);
  border-left: 2px solid transparent;
  padding-left: 0.75rem;
  transition: all var(--transition);
}

.toc a:hover, .toc a.active {
  color: var(--accent);
  border-left-color: var(--accent);
}

@media (min-width: 1400px) { .toc { display: block; } }

/* --- Project Cards --- */
.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}

.project-card:hover {
  border-color: rgba(56, 189, 248, 0.3);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.project-card-banner {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-bottom: 1px solid var(--border);
}

.project-card-body {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.project-card-body h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.project-card-body h3 a { color: var(--text-primary); }
.project-card-body h3 a:hover { color: var(--accent); }

.project-card-body p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  flex: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 1rem;
}

.project-tag {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 5px;
  background: rgba(56, 189, 248, 0.08);
  color: var(--text-muted);
  border: 1px solid rgba(56, 189, 248, 0.12);
}

/* --- Project Detail Page --- */
.project-hero {
  padding: 120px 2rem 2rem;
  text-align: center;
  position: relative;
}

.project-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 300px;
  background: var(--accent-gradient);
  opacity: 0.06;
  pointer-events: none;
}

.project-hero-content { position: relative; max-width: 800px; margin: 0 auto; }

.project-hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.project-hero .project-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.project-hero-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* --- TapTap Widget --- */
.taptap-widget {
  max-width: 800px;
  margin: 2rem auto;
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.taptap-widget-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.taptap-logo {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #2ca1e2, #1e88c7);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: #fff;
  font-weight: 800;
  flex-shrink: 0;
}

.taptap-widget-header h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.15rem;
}

.taptap-widget-header p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.taptap-widget-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

.taptap-game-info {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.taptap-game-cover {
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: var(--radius-sm);
  object-fit: cover;
  border: 1px solid var(--border);
  background: var(--bg-primary);
}

.taptap-game-meta {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.taptap-game-meta .meta-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
}

.taptap-game-meta .meta-label {
  color: var(--text-muted);
  min-width: 60px;
}

.taptap-game-meta .meta-value {
  color: var(--text-primary);
  font-weight: 500;
}

.taptap-download-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.taptap-download-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  background: linear-gradient(135deg, #2ca1e2, #1a7fc4);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  font-family: var(--font-sans);
}

.taptap-download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(44, 161, 226, 0.35);
  color: #fff;
}

.taptap-download-btn .taptap-icon {
  font-size: 1.3rem;
}

.taptap-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.8rem;
  background: rgba(44, 161, 226, 0.1);
  border: 1px solid rgba(44, 161, 226, 0.2);
  border-radius: 8px;
  font-size: 0.82rem;
  color: #2ca1e2;
  font-weight: 500;
  width: fit-content;
}

.taptap-rating {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.taptap-stars {
  color: #f59e0b;
  font-size: 1rem;
  letter-spacing: 1px;
}

.taptap-score {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.taptap-rating-label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* --- Reward Table --- */
.reward-table-wrapper {
  max-width: 800px;
  margin: 2rem auto;
}

.reward-table-wrapper h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.reward-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.reward-table th, .reward-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.reward-table th {
  background: rgba(56, 189, 248, 0.06);
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.reward-table td {
  color: var(--text-secondary);
  line-height: 1.6;
}

.reward-table tr:last-child td { border-bottom: none; }

.reward-table .lv-highlight {
  font-weight: 700;
  color: var(--accent);
}

.reward-table .lv-no {
  color: #ef4444;
  font-weight: 600;
}

/* --- Steps --- */
.steps-section {
  max-width: 800px;
  margin: 2rem auto;
}

.steps-section h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.step-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.step-item:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 19px;
  top: 40px;
  bottom: -8px;
  width: 2px;
  background: var(--border);
}

.step-number {
  width: 40px;
  height: 40px;
  background: var(--accent-gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  flex-shrink: 0;
}

.step-content h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.3rem;
}

.step-content p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* --- Notes Section --- */
.notes-section {
  max-width: 800px;
  margin: 2rem auto;
  padding: 1.5rem;
  background: rgba(245, 158, 11, 0.05);
  border: 1px solid rgba(245, 158, 11, 0.15);
  border-radius: var(--radius-sm);
}

.notes-section h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #f59e0b;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.notes-section ul {
  margin: 0;
  padding-left: 1.25rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.8;
}

.notes-section li { margin-bottom: 0.3rem; }

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border);
  padding: 3rem 2rem;
  margin-top: 2rem;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
}

.footer-brand .logo {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.7;
}

.footer-col h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.footer-col a {
  display: block;
  color: var(--text-muted);
  font-size: 0.9rem;
  padding: 0.3rem 0;
  transition: color var(--transition);
}

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

.footer-bottom {
  max-width: var(--max-width);
  margin: 2rem auto 0;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.icp-number {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.icp-number a {
  color: var(--text-muted);
  transition: color var(--transition);
}

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

/* --- Tags Page --- */
.tags-header { padding: 120px 2rem 2rem; text-align: center; }
.tags-header h1 { font-size: 2rem; font-weight: 800; margin-bottom: 0.5rem; }
.tags-header p { color: var(--text-secondary); }

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 3rem;
  padding: 0 2rem;
}

.tag-pill {
  padding: 0.5rem 1.2rem;
  border-radius: 100px;
  border: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
  background: transparent;
  font-weight: 500;
}

.tag-pill:hover, .tag-pill.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(56, 189, 248, 0.08);
}

/* --- Back to Top --- */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 44px;
  height: 44px;
  background: var(--accent-gradient);
  color: #fff;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(20px);
  transition: all var(--transition);
  z-index: 999;
  box-shadow: 0 4px 16px rgba(56, 189, 248, 0.3);
}

.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
}

.back-to-top:hover { transform: translateY(-3px); }

/* --- Animations --- */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-in {
  opacity: 0;
  animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }

/* --- Search Box --- */
.search-box {
  max-width: 480px;
  margin: 0 auto 3rem;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: 0.85rem 1.25rem 0.85rem 3rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: var(--font-sans);
  transition: all var(--transition);
}

.search-box input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.15);
}

.search-box input::placeholder { color: var(--text-muted); }

.search-box .search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .navbar-inner { padding: 0 1rem; }

  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0; right: 0;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 1rem;
  }

  .nav-links.open { display: flex; }
  .mobile-menu-btn { display: block; }

  .hero { padding: 120px 1.5rem 60px; }
  .hero h1 { font-size: 2rem; }

  .posts-grid { grid-template-columns: 1fr; }

  .featured-card { grid-template-columns: 1fr; }
  .featured-card .post-card-img {
    height: 220px;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .about-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .about-avatar { margin: 0 auto; width: 180px; height: 180px; font-size: 3.5rem; }
  .skill-tags { justify-content: center; }

  .footer-inner { grid-template-columns: 1fr; gap: 2rem; }
  .footer-bottom { flex-direction: column; text-align: center; }

  .article-nav { grid-template-columns: 1fr; }

  .section { padding: 2.5rem 1.5rem; }
}

@media (max-width: 480px) {
  .hero-actions { flex-direction: column; }
  .btn { width: 100%; justify-content: center; }

  .game-hero-actions { flex-direction: column; }
  .btn-game-download { width: 100%; }
  .download-qr-grid { grid-template-columns: 1fr; }
  .game-features-grid { grid-template-columns: 1fr; }
  .game-section-header h2 { font-size: 1.4rem; }
}

/* ====================================================================
   GAME DOWNLOAD PAGE — Modern Game Studio Layout
   ==================================================================== */

/* --- Game Hero --- */
.game-hero {
  position: relative;
  padding: 8rem 1.5rem 4rem;
  text-align: center;
  overflow: hidden;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.game-hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 30%, rgba(56, 189, 248, 0.15) 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 20% 80%, rgba(129, 140, 248, 0.1) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 80% 70%, rgba(244, 114, 182, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.game-hero-inner {
  position: relative;
  max-width: 700px;
  margin: 0 auto;
}

@keyframes floatIcon {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.game-hero-title {
  font-size: clamp(1.8rem, 5vw, 2.8rem);
  font-weight: 800;
  margin-bottom: 0.75rem;
  background: linear-gradient(135deg, #38bdf8, #818cf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.game-hero-tagline {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.game-hero-badges {
  display: flex;
  justify-content: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.game-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 0.9rem;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: 100px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.game-hero-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* --- Game Download Buttons --- */
.btn-game-download {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.9rem 1.8rem;
  background: linear-gradient(135deg, #2ca1e2, #1a7fc4);
  color: #fff;
  border-radius: 14px;
  text-decoration: none;
  font-family: var(--font-sans);
  transition: all var(--transition);
  border: 1px solid transparent;
  min-width: 200px;
}

.btn-game-download:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 36px rgba(44, 161, 226, 0.35);
  color: #fff;
}

.btn-game-download--outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-primary);
}

.btn-game-download--outline:hover {
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 8px 24px rgba(56, 189, 248, 0.15);
  color: var(--text-primary);
}


.btn-game-label {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.2;
}

.btn-game-sub {
  display: block;
  font-size: 0.78rem;
  opacity: 0.75;
  font-weight: 400;
  margin-top: 0.15rem;
}

/* --- Game Section --- */
.game-section {
  padding: 4rem 1.5rem;
}

.game-section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.game-section-header h2 {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
  border-top: none;
  padding-top: 0;
}

.game-section-header p {
  font-size: 1rem;
  color: var(--text-muted);
}

/* --- Download QR Grid --- */
.download-qr-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 2.5rem;
  max-width: 750px;
  margin: 0 auto;
  align-items: start;
}

.download-qr-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
}

.download-qr-img-wrap {
  background: #fff;
  border-radius: 12px;
  padding: 1rem;
  display: inline-block;
  margin-bottom: 1rem;
}

.download-qr-img {
  width: 220px;
  height: 220px;
  display: block;
  image-rendering: pixelated;
}

.download-qr-tip {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* --- Download Info Card --- */
.download-info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem 1.5rem;
  display: flex;
  gap: 0.8rem;
  align-items: center;
}

.download-info-text {
  flex: 1;
  min-width: 0;
}

.download-info-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.download-info-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0.15rem 0 0 0;
}

.download-info-btn {
  flex-shrink: 0;
  padding: 0.6rem 1.2rem;
  background: linear-gradient(135deg, #2ca1e2, #1a7fc4);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  font-family: var(--font-sans);
  transition: all var(--transition);
  white-space: nowrap;
}

.download-info-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(44, 161, 226, 0.35);
  color: #fff;
}

/* --- Game Features Grid --- */
.game-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  max-width: 1000px;
  margin: 0 auto;
}

.game-feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  text-align: center;
  transition: all var(--transition);
}

.game-feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(56, 189, 248, 0.3);
  box-shadow: 0 8px 32px rgba(56, 189, 248, 0.1);
}

.game-feature-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: block;
}

.game-feature-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: var(--text-primary);
}

.game-feature-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* --- Afdian (爱发电) Section --- */
.afdian-wrapper {
  max-width: 660px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.2rem;
}

.afdian-wrapper iframe {
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-card);
  max-width: 100%;
}

.afdian-fallback {
  text-align: center;
}

.afdian-btn {
  display: inline-block;
  transition: all var(--transition);
}

.afdian-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.1);
}

.afdian-btn img {
  border-radius: var(--radius-sm);
}

/* --- Responsive: Tablet --- */
@media (max-width: 768px) {
  .game-hero {
    padding: 5.5rem 1.2rem 2.5rem;
    min-height: auto;
  }

  .game-hero-title {
    font-size: 1.8rem;
  }

  .game-hero-tagline {
    font-size: 0.95rem;
    margin-bottom: 1rem;
  }

  .game-hero-badges {
    gap: 0.4rem;
    margin-bottom: 1.5rem;
  }

  .game-badge {
    padding: 0.3rem 0.7rem;
    font-size: 0.75rem;
  }

  .game-hero-actions {
    flex-direction: column;
    gap: 0.7rem;
    align-items: stretch;
  }

  .btn-game-download {
    min-width: auto;
    padding: 0.85rem 1.2rem;
    justify-content: center;
  }

  .game-section {
    padding: 2.5rem 1rem;
  }

  .game-section-header {
    margin-bottom: 1.5rem;
  }

  .game-section-header h2 {
    font-size: 1.35rem;
  }

  .game-section-header p {
    font-size: 0.88rem;
  }

  /* Download QR - 卡片式竖排 */
  .download-qr-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
    max-width: 100%;
  }

  .download-qr-card {
    padding: 1.2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
  }

  .download-qr-img-wrap {
    margin-bottom: 0;
    padding: 0.5rem;
    flex-shrink: 0;
  }

  .download-qr-img {
    width: 100px;
    height: 100px;
  }

  .download-qr-tip {
    text-align: left;
    font-size: 0.8rem;
  }

  .download-info-card {
    padding: 1rem;
    gap: 0.6rem;
  }

  .download-info-title {
    font-size: 0.95rem;
  }

  .download-info-btn {
    padding: 0.55rem 1rem;
    font-size: 0.85rem;
  }

  /* Features */
  .game-features-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
  }

  .game-feature-card {
    padding: 1.2rem 1rem;
  }

  .game-feature-icon {
    font-size: 2rem;
    margin-bottom: 0.6rem;
  }

  .game-feature-card h3 {
    font-size: 0.95rem;
    margin-bottom: 0.4rem;
  }

  .game-feature-card p {
    font-size: 0.8rem;
    line-height: 1.55;
  }

  /* TapTap widget */
  .taptap-widget-body {
    grid-template-columns: 1fr;
  }

  .taptap-widget {
    padding: 1.2rem;
  }

  /* Afdian */
  .afdian-wrapper iframe {
    height: 180px;
  }
}

/* --- Responsive: Mobile Small --- */
@media (max-width: 480px) {
  .game-hero {
    padding: 5rem 1rem 2rem;
  }

  .game-hero-title {
    font-size: 1.5rem;
  }

  .game-hero-tagline {
    font-size: 0.88rem;
  }

  .game-features-grid {
    grid-template-columns: 1fr;
  }
}
