/* ========== CSS VARIABLES & FONTS ========== */
@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@400;700;900&family=Noto+Sans+SC:wght@300;400;500;700&display=swap');

:root {
  --font-serif: 'Noto Serif SC', 'SimSun', 'STSong', serif;
  --font-sans: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;

  /* City night palette */
  --navy-deep: #1A237E;
  --navy-dark: #283593;
  --silver: #B0BEC5;
  --silver-light: #CFD8DC;
  --bg: #F5F5F5;
  --bg-card: #FFFFFF;
  --text: #212121;
  --text-soft: #616161;
  --text-muted: #9E9E9E;
  --amber-cta: #FF8F00;
  --amber-dark: #E65100;
  --amber-light: #FFE0B2;
  --accent-gold: #FF8F00;
  --danger-red: #D32F2F;
  --pink-fierce: #C2185B;
  --steel-light: #B0BEC5;
  --uniform-navy: #1A237E;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
  --radius: 8px;
  --radius-lg: 12px;
  --transition: 0.25s ease;
}

/* ========== RESET ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

/* ========== SCREEN READER ONLY ========== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ========== HEADER ========== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--navy-deep);
  border-bottom: 3px solid var(--amber-cta);
  box-shadow: var(--shadow-md);
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 64px;
}
.header-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.header-logo img {
  width: 36px;
  height: 36px;
  border-radius: 4px;
}
.header-logo span {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.03em;
}
.header-nav { display: flex; align-items: center; gap: 4px; }
.header-nav a {
  color: var(--silver-light);
  text-decoration: none;
  padding: 8px 16px;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 500;
  transition: all var(--transition);
}
.header-nav a:hover,
.header-nav a.active {
  color: #fff;
  background: rgba(255,255,255,0.12);
}
.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--amber-cta);
  color: #fff;
  padding: 8px 20px;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all var(--transition);
  white-space: nowrap;
}
.header-cta:hover {
  background: var(--amber-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255,143,0,0.35);
}
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
}

/* ========== HERO SECTION ========== */
.hero {
  background: linear-gradient(135deg, #1A237E 0%, #283593 40%, #3949AB 100%);
  color: #fff;
  padding: 60px 24px 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../img/hero-banner.jpg') center/cover no-repeat;
  opacity: 0.15;
  z-index: 0;
}
.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
}
.hero-title-main {
  font-family: var(--font-serif);
  font-size: 2.8rem;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0,0,0,0.4);
  margin-bottom: 12px;
  line-height: 1.3;
}
.hero-tagline {
  font-size: 1.1rem;
  color: var(--silver-light);
  max-width: 600px;
  margin: 0 auto 24px;
  line-height: 1.7;
}
.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--amber-cta);
  color: #fff;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  transition: all var(--transition);
}
.btn-primary:hover {
  background: var(--amber-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255,143,0,0.4);
}
.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.15);
  color: #fff;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1.05rem;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.25);
  transition: all var(--transition);
}
.btn-secondary:hover {
  background: rgba(255,255,255,0.25);
  border-color: rgba(255,255,255,0.4);
}

/* Sub-page hero */
.hero-subpage {
  padding: 40px 24px 48px;
}
.hero-subpage-title {
  font-size: 2rem;
  font-weight: 700;
}

/* ========== SECTIONS ========== */
.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 24px;
}
.section-alt {
  background: #fff;
}
.section-no-padding { padding: 0; }
.section-header {
  text-align: center;
  margin-bottom: 40px;
}
.section-header h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--navy-deep);
  margin-bottom: 8px;
}
.section-header p {
  color: var(--text-soft);
  font-size: 1rem;
  max-width: 600px;
  margin: 0 auto;
}

/* ========== GAME INFO CARDS (index.html) ========== */
.game-info-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 8px;
}
.game-info-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 24px 16px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  border-left: 3px solid var(--amber-cta);
  transition: all var(--transition);
}
.game-info-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.game-info-card .info-icon {
  font-size: 1.8rem;
  margin-bottom: 8px;
}
.game-info-card .info-value {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--navy-deep);
  line-height: 1.2;
}
.game-info-card .info-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 4px;
}
.game-info-desc {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 0;
}

/* ========== FEATURES GRID (index.html) ========== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--amber-cta);
  transition: all var(--transition);
}
.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.feature-card .feature-number {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 900;
  color: var(--amber-cta);
  line-height: 1;
  margin-bottom: 12px;
}
.feature-card h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy-deep);
  margin-bottom: 8px;
}
.feature-card p {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.7;
}

/* ========== SCREENSHOT GALLERY ========== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.gallery-grid img {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: all var(--transition);
}
.gallery-grid img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

/* ========== REVIEWS ========== */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.review-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  border-top: 3px solid var(--navy-deep);
}
.review-card .review-stars {
  color: var(--amber-cta);
  font-size: 1rem;
  margin-bottom: 12px;
}
.review-card p {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.7;
  font-style: italic;
}
.review-card .review-author {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 12px;
  font-style: normal;
}

/* ========== CTA BANNER (index.html only) ========== */
.cta-banner {
  background: linear-gradient(135deg, var(--navy-deep), var(--navy-dark));
  color: #fff;
  text-align: center;
  padding: 60px 24px;
}
.cta-banner h2 {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 900;
  margin-bottom: 12px;
}
.cta-banner p {
  font-size: 1.05rem;
  color: var(--silver-light);
  margin-bottom: 28px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}
.cta-banner .btn-primary {
  font-size: 1.15rem;
  padding: 14px 36px;
}

/* ========== CONTENT PAGES ========== */
.content-section {
  max-width: 900px;
  margin: 0 auto;
  padding: 60px 24px;
}
.content-section h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
}
.content-section > p {
  color: var(--text-soft);
  font-size: 1rem;
  line-height: 1.85;
  margin-bottom: 24px;
}

/* Card (guide, story, characters) */
.content-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
  border-left: 4px solid var(--amber-cta);
}
.content-card h3 {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--navy-deep);
  margin-bottom: 12px;
}
.content-card p {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.8;
  margin-bottom: 10px;
}
.content-card p:last-child { margin-bottom: 0; }

/* Character card grid */
.char-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.char-card {
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}
.char-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.char-card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
}
.char-card-body {
  padding: 20px;
}
.char-card-body h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy-deep);
  margin-bottom: 4px;
}
.char-card-body .char-role {
  font-size: 0.85rem;
  color: var(--amber-cta);
  font-weight: 600;
  margin-bottom: 10px;
}
.char-card-body p {
  font-size: 0.9rem;
  color: var(--text-soft);
  line-height: 1.6;
}
.char-traits {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}
.char-traits span {
  background: var(--amber-light);
  color: var(--amber-dark);
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
}

/* ========== FAQ ACCORDION ========== */
.faq-list { margin-top: 24px; }
.faq-item {
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq-question {
  width: 100%;
  background: none;
  border: none;
  padding: 18px 24px;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  color: var(--navy-deep);
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.faq-question:hover { background: #f9f9f9; }
.faq-question .faq-icon {
  font-size: 0.8rem;
  color: var(--amber-cta);
  transition: transform var(--transition);
  flex-shrink: 0;
}
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}
.faq-item.open .faq-answer {
  max-height: 600px;
}
.faq-answer-inner {
  padding: 0 24px 20px;
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.8;
}
.faq-intro {
  color: var(--text-soft);
  margin-bottom: 32px;
}
.faq-note {
  margin-top: 16px;
}

/* ========== SYSTEM REQUIREMENTS TABLE ========== */
.sys-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  font-size: 0.95rem;
}
.sys-table th,
.sys-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #e0e0e0;
  text-align: left;
}
.sys-table th {
  background: var(--navy-deep);
  color: #fff;
  font-weight: 600;
}
.sys-table tr:nth-child(even) td {
  background: #fafafa;
}
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.sys-reqs-h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--uniform-navy);
  margin-top: 24px;
  margin-bottom: 12px;
}
.sys-reqs-h3:first-of-type { margin-top: 8px; }
.sys-note {
  margin-top: 20px;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.td-highlight {
  color: var(--pink-fierce);
  font-weight: 700;
}

/* ========== TIP BOX (guide.html) ========== */
.tip-box {
  background: var(--amber-light);
  border-left: 4px solid var(--amber-cta);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 16px 0;
}
.tip-box strong {
  color: var(--amber-dark);
  font-weight: 700;
}
.tip-box p {
  font-size: 0.95rem;
  color: var(--text-soft);
  margin: 0;
}

/* ========== STORY CHAPTERS ========== */
.chapter-block {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}
.chapter-title {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy-deep);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--amber-cta);
}

/* ========== GUIDE STEPS ========== */
.guide-steps-wrapper { counter-reset: guide-step; }
.guide-step {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 16px;
  position: relative;
  padding-left: 72px;
}
.guide-step::before {
  counter-increment: guide-step;
  content: '#' counter(guide-step);
  position: absolute;
  left: 20px;
  top: 24px;
  font-family: var(--font-serif);
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--amber-cta);
  line-height: 1;
}
.guide-step h3 {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--navy-deep);
  margin-bottom: 6px;
}
.guide-step p {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.75;
}
.guide-intro {
  font-size: 1rem;
  color: var(--text-soft);
  line-height: 1.8;
  margin-bottom: 20px;
}
.route-desc {
  font-size: 1rem;
  color: var(--text-soft);
  line-height: 1.8;
  margin-bottom: 20px;
}
.route-heading {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy-deep);
  margin-top: 24px;
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 2px solid var(--silver-light);
}

/* ========== PROSE CENTERED (index.html) ========== */
.prose-centered {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 32px;
  color: var(--text-soft);
  line-height: 1.85;
  font-size: 0.95rem;
}
.prose-centered:last-of-type { margin-bottom: 40px; }

/* ========== COLORED STRONG ========== */
.strong-pink { color: var(--pink-fierce); }
.strong-red { color: var(--danger-red); }
.strong-gold { color: var(--accent-gold); }
.strong-muted { color: var(--text-muted); }
.strong-navy { color: var(--uniform-navy); }

/* ========== CONTENT LISTS ========== */
.content-list { list-style: disc; padding-left: 20px; }
.content-list-num { list-style: decimal; padding-left: 24px; }
.content-li { margin-bottom: 5px; color: var(--text-soft); }
.content-li-sm { margin-bottom: 4px; color: var(--text-soft); }
.content-li-md { margin-bottom: 8px; color: var(--text-soft); }
.content-li-lg { margin-bottom: 10px; color: var(--text-soft); }

/* ========== SECTION TITLE GROUP ========== */
.section-title-group-spaced { margin-top: 48px; }
.section-subheading {
  text-align: center;
  margin: 40px 0 24px;
}

/* ========== LIGHTBOX ========== */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.9);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}
.lightbox-overlay.active { display: flex; }
.lightbox-overlay img {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  z-index: 1;
}

/* ========== FOOTER ========== */
.site-footer {
  background: var(--navy-deep);
  color: var(--silver-light);
  text-align: center;
  padding: 28px 24px;
  font-size: 0.9rem;
}

/* ========== RESPONSIVE: 768px ========== */
@media (max-width: 768px) {
  .hero-title-main { font-size: 2rem; }
  .hero-subpage-title { font-size: 1.6rem; }
  .section { padding: 40px 20px; }
  .game-info-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: 1fr 1fr; }
  .gallery-grid { grid-template-columns: 1fr; }
  .reviews-grid { grid-template-columns: 1fr; }
  .char-grid { grid-template-columns: 1fr; }
  .content-section { padding: 40px 20px; }
  .content-section h2 { font-size: 1.8rem; }
  .section-header h2 { font-size: 1.8rem; }
  .header-nav a { padding: 6px 10px; font-size: 0.85rem; }
  .header-cta { padding: 6px 14px; font-size: 0.85rem; }
}

/* ========== RESPONSIVE: 480px ========== */
@media (max-width: 480px) {
  .hero-title-main { font-size: 1.6rem; }
  .hero-subpage-title { font-size: 1.4rem; }
  .hero-tagline { font-size: 0.95rem; }
  .section { padding: 32px 16px; }
  .game-info-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .game-info-card { padding: 16px 10px; }
  .game-info-card .info-value { font-size: 1.2rem; }
  .features-grid { grid-template-columns: 1fr; }
  .content-card { padding: 20px; }
  .content-section h2 { font-size: 1.5rem; }
  .section-header h2 { font-size: 1.5rem; }
  .header-inner { height: 56px; padding: 0 12px; }
  .header-logo span { font-size: 1rem; }
  .header-nav { display: none; }
  .header-nav.open { display: flex; flex-direction: column; position: absolute; top: 64px; left: 0; right: 0; background: var(--navy-deep); padding: 12px; gap: 4px; }
  .mobile-menu-toggle { display: block; }
  .cta-banner h2 { font-size: 1.5rem; }
  .hero-subpage { padding: 32px 16px 36px; }
  .guide-step { padding-left: 24px; padding-top: 16px; }
  .guide-step::before { position: static; display: block; margin-bottom: 8px; }
  .char-card img { height: 180px; }
}
