﻿/* =============================================
   星露谷物语攻略站 V4 · 内容型攻略站
   风格：清新田园风 · SEO友好 · 内容优先
   ============================================= */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;500;600;700&display=swap');

:root {
  --green-dark: #2d5a27;
  --green-primary: #4a8c3f;
  --green-light: #6db35a;
  --green-bg: #f0f7ec;
  --gold: #e8b84b;
  --gold-light: #f5d97a;
  --cream: #fdf8f0;
  --card-bg: #ffffff;
  --text-dark: #2c2c2c;
  --text-muted: #6b6b6b;
  --text-light: #f5f0e8;
  --border: #e0d8cc;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.08);
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --max-width: 1200px;
  --font: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--green-bg);
  color: var(--text-dark);
  line-height: 1.7;
  min-height: 100vh;
}

a { color: var(--green-primary); text-decoration: none; }
a:hover { color: var(--green-dark); text-decoration: underline; }

/* ===== Top Bar ===== */
.top-bar {
  background: var(--green-dark);
  color: rgba(255,255,255,0.85);
  font-size: 13px;
  padding: 6px 0;
  text-align: center;
}
.top-bar span { color: var(--gold); font-weight: 600; }

/* ===== Header ===== */
.site-header {
  background: var(--card-bg);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 700;
  color: var(--green-dark);
  text-decoration: none;
}
.logo img { height: 32px; }

.nav-links { display: flex; gap: 4px; align-items: center; }
.nav-links a {
  color: var(--text-dark);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
  white-space: nowrap;
}
.nav-links a:hover, .nav-links a.active { background: var(--green-bg); color: var(--green-primary); }

/* 搜索框 */
.search-box {
  display: flex;
  align-items: center;
  background: var(--green-bg);
  border-radius: 20px;
  padding: 0 12px;
  margin-left: 12px;
}
.search-box input {
  border: none;
  background: none;
  padding: 8px 6px;
  font-size: 13px;
  width: 160px;
  outline: none;
  font-family: var(--font);
}
.search-box button {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 16px;
  color: var(--text-muted);
  padding: 4px;
}

.mobile-toggle { display: none; background: none; border: none; font-size: 28px; cursor: pointer; color: var(--text-dark); }

@media (max-width: 768px) {
  .search-box input { width: 100px; }
  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--card-bg);
    flex-direction: column;
    padding: 16px;
    gap: 4px;
    box-shadow: var(--shadow-md);
    border-top: 1px solid var(--border);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 16px; width: 100%; }
  .search-box { margin-left: 0; margin-top: 8px; width: 100%; }
  .search-box input { width: 100%; }
  .mobile-toggle { display: block; }
}

/* ===== Hero Banner ===== */
.hero {
  position: relative;
  height: 360px;
  overflow: hidden;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  margin: 0 16px;
}
.hero img { width: 100%; height: 100%; object-fit: cover; }
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 30%, rgba(0,0,0,0.7));
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 48px;
}
.hero-overlay h1 { color: white; font-size: 36px; font-weight: 700; margin-bottom: 8px; text-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.hero-overlay p { color: rgba(255,255,255,0.9); font-size: 16px; max-width: 600px; line-height: 1.5; }
.hero-overlay .hero-tag { display: inline-block; background: var(--gold); color: var(--text-dark); font-size: 12px; font-weight: 600; padding: 4px 12px; border-radius: 4px; margin-bottom: 12px; width: fit-content; }

@media (max-width: 640px) {
  .hero { height: 240px; margin: 0 8px; }
  .hero-overlay { padding: 24px; }
  .hero-overlay h1 { font-size: 24px; }
  .hero-overlay p { font-size: 14px; }
}

/* ===== Announcement Banner ===== */
.announcement {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  padding: 12px 20px;
  text-align: center;
  font-size: 15px;
  font-weight: 500;
  margin: 20px auto;
  max-width: var(--max-width);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}
.announcement a { color: var(--green-dark); font-weight: 700; }
.announcement a:hover { text-decoration: underline; }

/* ===== Quick Entry Grid ===== */
.quick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  max-width: var(--max-width);
  margin: 0 auto 32px;
  padding: 0 20px;
}
.quick-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: var(--card-bg);
  padding: 20px 12px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: var(--text-dark);
  transition: all 0.2s;
  cursor: pointer;
}
.quick-item:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); text-decoration: none; color: var(--green-primary); }
.quick-item img { width: 36px; height: 36px; }
.quick-item span { font-size: 14px; font-weight: 600; text-align: center; }

/* ===== Container ===== */
.container { max-width: var(--max-width); margin: 0 auto; padding: 32px 20px; }

/* ===== Section Title ===== */
.section-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--green-dark);
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--green-light);
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title .more {
  margin-left: auto;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
}

/* ===== Card Grid (攻略卡片) ===== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}
.card {
  background: var(--card-bg);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card-img { width: 100%; height: 180px; object-fit: cover; }
.card-body { padding: 20px; }
.card-body .card-cat {
  display: inline-block;
  background: var(--green-bg);
  color: var(--green-primary);
  font-size: 12px;
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 10px;
  margin-bottom: 8px;
}
.card-body h3 { font-size: 18px; font-weight: 700; color: var(--text-dark); margin-bottom: 8px; }
.card-body h3 a { color: var(--text-dark); }
.card-body h3 a:hover { color: var(--green-primary); }
.card-body p { font-size: 14px; color: var(--text-muted); line-height: 1.6; margin-bottom: 12px; }
.card-body .card-meta { font-size: 12px; color: var(--text-muted); display: flex; gap: 16px; }

/* ===== Two Column ===== */
.two-col {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
  margin-bottom: 40px;
}
@media (max-width: 768px) { .two-col { grid-template-columns: 1fr; } }

/* ===== Sidebar Widget ===== */
.widget {
  background: var(--card-bg);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
}
.widget h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--green-dark);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--green-bg);
}
.widget ul { list-style: none; }
.widget ul li { padding: 8px 0; border-bottom: 1px solid var(--green-bg); }
.widget ul li:last-child { border-bottom: none; }
.widget ul li a { font-size: 14px; color: var(--text-dark); display: flex; justify-content: space-between; }
.widget ul li a:hover { color: var(--green-primary); }
.widget ul li .count { color: var(--text-muted); font-size: 12px; }

/* ===== Hot Tags ===== */
.hot-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.hot-tags a {
  display: inline-block;
  background: var(--green-bg);
  color: var(--green-primary);
  font-size: 13px;
  padding: 4px 12px;
  border-radius: 14px;
  font-weight: 500;
}
.hot-tags a:hover { background: var(--green-primary); color: white; text-decoration: none; }

/* ===== Subpage Content ===== */
.content-section {
  background: var(--card-bg);
  border-radius: var(--radius-md);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}
.content-section h1 { font-size: 28px; color: var(--green-dark); margin-bottom: 16px; }
.content-section h2 { font-size: 22px; color: var(--green-dark); margin: 24px 0 12px; }
.content-section h3 { font-size: 18px; color: var(--green-primary); margin: 20px 0 10px; }
.content-section p { margin-bottom: 14px; line-height: 1.8; }
.content-section ul, .content-section ol { padding-left: 24px; margin-bottom: 16px; }
.content-section li { margin-bottom: 8px; line-height: 1.7; }
.content-section .tips {
  background: var(--green-bg);
  border-left: 4px solid var(--green-primary);
  padding: 16px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 16px 0;
}

/* ===== Data Table ===== */
.data-table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 14px; }
.data-table thead { background: var(--green-dark); color: white; }
.data-table th { padding: 10px 14px; text-align: left; font-weight: 600; font-size: 13px; }
.data-table td { padding: 9px 14px; border-bottom: 1px solid var(--border); }
.data-table tr:nth-child(even) { background: #fafaf5; }
.data-table tr:hover { background: var(--green-bg); }

/* ===== Breadcrumb ===== */
.breadcrumb { font-size: 13px; color: var(--text-muted); margin-bottom: 20px; }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--green-primary); }
.breadcrumb span { margin: 0 6px; }

/* ===== Footer ===== */
.site-footer {
  background: var(--green-dark);
  color: rgba(255,255,255,0.8);
  padding: 40px 20px 20px;
  margin-top: 40px;
}
.footer-inner { max-width: var(--max-width); margin: 0 auto; }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 24px;
  margin-bottom: 24px;
}
.footer-grid h4 { font-size: 15px; font-weight: 600; color: var(--gold); margin-bottom: 12px; }
.footer-grid a { display: block; font-size: 13px; color: rgba(255,255,255,0.7); padding: 4px 0; }
.footer-grid a:hover { color: white; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
  font-size: 13px;
  text-align: center;
  color: rgba(255,255,255,0.5);
  line-height: 1.8;
}
.footer-bottom a { color: var(--gold); }
.footer-bottom .copyright {
  background: rgba(0,0,0,0.2);
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  margin-top: 12px;
  font-size: 12px;
  line-height: 1.7;
}

/* ===== 404 ===== */
.not-found { text-align: center; padding: 80px 20px; }
.not-found h1 { font-size: 64px; color: var(--green-primary); margin-bottom: 16px; }

/* ===== Utility ===== */
.btn {
  display: inline-block;
  background: var(--green-primary);
  color: white;
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  transition: background 0.2s;
  border: none;
  cursor: pointer;
  font-family: var(--font);
  font-size: 14px;
}
.btn:hover { background: var(--green-dark); text-decoration: none; }
.btn-gold { background: var(--gold); color: var(--text-dark); }
.btn-gold:hover { background: #d4a530; }

.text-center { text-align: center; }
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }

/* ===== 中英双语切换 ===== */
.lang-switch { display: flex; gap: 4px; align-items: center; margin-left: 8px; }
.lang-btn {
  background: none; border: 2px solid var(--green-primary); color: var(--green-primary);
  padding: 4px 10px; border-radius: 4px; cursor: pointer; font-size: 12px; font-weight: 600;
  transition: all .2s; font-family: var(--font);
}
.lang-btn:hover { background: var(--green-bg); }
.lang-btn.active { background: var(--green-primary); color: white; }

