/* ============================================================
   Phoenixes 中文官网 — 烈焰重生 凤凰涅盘 主题
   ============================================================ */

/* === 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');

/* === CSS VARIABLES === */
:root {
  /* Palette: 烈焰重生 */
  --phoenix-red: #E53935;
  --phoenix-red-dk: #C62828;
  --phoenix-red-bright: #EF5350;
  --gold-flame: #FFC107;
  --gold-dk: #F9A825;
  --gold-light: #FFE082;
  --ash-grey: #78909C;
  --ash-light: #B0BEC5;
  --ash-pale: #ECEFF1;
  --bg: #FFFAFA;
  --bg-warm: #FFF3E0;
  --bg-card: #FFFFFF;
  --text: #263238;
  --text-soft: #546E7A;
  --text-muted: #90A4AE;
  --navy-dk: #1A237E;
  --white: #FFFFFF;
  --shadow: rgba(229, 57, 53, 0.10);
  --shadow-lg: rgba(229, 57, 53, 0.15);

  /* Typography */
  --font-serif: 'Noto Serif SC', 'Songti SC', serif;
  --font-sans: 'Noto Sans SC', 'PingFang SC', sans-serif;

  /* Layout */
  --max-width: 1200px;
  --header-h: 64px;
  --radius: 12px;
  --radius-sm: 8px;
}

/* === RESET === */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

/* === SCREEN READER ONLY === */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -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: linear-gradient(135deg, #1A1A2E, #16213E);
  border-bottom: 3px solid var(--phoenix-red);
  height: var(--header-h);
  display: flex;
  align-items: center;
}

.header-inner {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.header-logo img {
  height: 36px;
  width: auto;
}

.header-logo-text {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 900;
  color: var(--white);
  letter-spacing: 0.05em;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}

.header-nav a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ash-light);
  text-decoration: none;
  transition: color 0.2s;
  position: relative;
}

.header-nav a:hover,
.header-nav a.active {
  color: var(--gold-flame);
}

.header-nav a.active::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gold-flame);
  border-radius: 1px;
}

.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 22px;
  background: linear-gradient(135deg, var(--phoenix-red), var(--phoenix-red-dk));
  color: var(--white);
  font-weight: 700;
  font-size: 0.92rem;
  border-radius: 24px;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
  border: none;
  cursor: pointer;
}

.header-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(229, 57, 53, 0.4);
}

/* === HERO SECTION (INDEX) === */
.hero {
  position: relative;
  background: linear-gradient(135deg, #1A1A2E 0%, #3E1F1F 40%, #16213E 100%);
  padding: 60px 24px 80px;
  text-align: center;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(229, 57, 53, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 60%, rgba(255, 193, 7, 0.08) 0%, transparent 50%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(to top, var(--bg), transparent);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: var(--max-width);
  margin: 0 auto;
}

.hero-title-main {
  font-family: var(--font-serif);
  font-size: 2.8rem;
  font-weight: 900;
  color: var(--white);
  text-shadow: 0 2px 12px rgba(229, 57, 53, 0.5);
  margin-bottom: 12px;
  line-height: 1.3;
}

.hero-title-main .en-subtitle {
  display: block;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 400;
  color: var(--gold-light);
  margin-top: 6px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-tagline {
  font-size: 1.15rem;
  color: var(--ash-light);
  max-width: 640px;
  margin: 0 auto 32px;
  line-height: 1.8;
}

.hero-image-wrap {
  max-width: 800px;
  margin: 0 auto;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 8px 40px rgba(0,0,0,0.3);
}

.hero-image-wrap img {
  width: 100%;
  height: auto;
  display: block;
}

/* === HERO SUB-PAGE === */
.hero-subpage {
  padding: 40px 24px 48px;
}

.hero-subpage-title {
  font-size: 2rem;
  font-weight: 700;
}

/* === CONTENT SECTION === */
.content-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px 24px;
}

.section-alt {
  background: var(--bg-warm);
}

.section-no-padding {
  padding: 0;
}

/* === SECTION HEADINGS === */
.section-heading {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  color: var(--phoenix-red);
  margin-bottom: 8px;
}

.section-heading-alt {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  color: var(--phoenix-red);
  margin-bottom: 20px;
}

.section-subtext {
  text-align: center;
  color: var(--text-soft);
  margin-bottom: 24px;
}

.content-section h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
}

/* === PROSE CENTERED === */
.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;
}

/* === GAME INFO GRID === */
.game-info-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 12px;
}

.game-info-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 24px 16px;
  text-align: center;
  box-shadow: 0 2px 12px var(--shadow);
  border-top: 3px solid var(--phoenix-red);
}

.game-info-card .info-value {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--phoenix-red);
  display: block;
}

.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;
}

/* === FEATURE CARDS === */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 32px;
}

.feature-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 28px 22px;
  box-shadow: 0 2px 16px var(--shadow);
  border-left: 4px solid var(--phoenix-red);
  transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 28px var(--shadow-lg);
}

.feature-card .feature-icon {
  font-size: 2rem;
  margin-bottom: 12px;
  display: block;
}

.feature-card h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

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

/* === SCREENSHOT GALLERY === */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 32px;
}

.gallery-item {
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s;
  box-shadow: 0 2px 12px var(--shadow);
}

.gallery-item:hover {
  transform: scale(1.03);
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
}

/* === REVIEWS === */
.review-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 32px;
}

.review-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 2px 12px var(--shadow);
  position: relative;
}

.review-card::before {
  content: '"';
  position: absolute;
  top: 12px;
  left: 16px;
  font-family: var(--font-serif);
  font-size: 3rem;
  color: var(--phoenix-red);
  opacity: 0.2;
  line-height: 1;
}

.review-card .review-text {
  font-size: 0.92rem;
  color: var(--text-soft);
  line-height: 1.7;
  font-style: italic;
  margin-bottom: 16px;
  padding-top: 12px;
}

.review-card .review-author {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--phoenix-red);
}

.review-card .review-stars {
  color: var(--gold-flame);
  font-size: 0.9rem;
  margin-bottom: 4px;
}

/* === CTA BANNER (INDEX ONLY) === */
.cta-banner {
  background: linear-gradient(135deg, var(--phoenix-red), var(--phoenix-red-dk));
  padding: 48px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(255, 193, 7, 0.12) 0%, transparent 50%);
  pointer-events: none;
}

.cta-banner-inner {
  position: relative;
  z-index: 2;
  max-width: 700px;
  margin: 0 auto;
}

.cta-banner h2 {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 900;
  color: var(--white);
  margin-bottom: 12px;
}

.cta-banner p {
  font-size: 1rem;
  color: rgba(255,255,255,0.85);
  margin-bottom: 28px;
  line-height: 1.7;
}

.cta-btn {
  display: inline-block;
  padding: 14px 48px;
  background: var(--gold-flame);
  color: #1A1A2E;
  font-weight: 900;
  font-size: 1.1rem;
  border-radius: 28px;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
  border: none;
  cursor: pointer;
  font-family: var(--font-sans);
}

.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(255, 193, 7, 0.5);
}

/* === FOOTER === */
.site-footer {
  background: #1A1A2E;
  padding: 20px 24px;
  text-align: center;
}

.site-footer p {
  font-size: 0.85rem;
  color: var(--ash-light);
}

/* === CONTENT LIST === */
.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);
}

/* === COLORED STRONG === */
.strong-red { color: var(--phoenix-red); }
.strong-gold { color: var(--gold-dk); }
.strong-muted { color: var(--text-muted); }
.strong-navy { color: var(--navy-dk); }

/* === TABLE HIGHLIGHT === */
.td-highlight {
  color: var(--phoenix-red);
  font-weight: 700;
}

/* === SYSTEM REQUIREMENTS === */
.sys-reqs-h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy-dk);
  margin-top: 24px;
  margin-bottom: 12px;
}

.sys-reqs-h3:first-of-type {
  margin-top: 8px;
}

/* === SECTION SUBHEADING === */
.section-subheading {
  text-align: center;
  margin: 40px 0 24px;
}

/* === CHAPTER TITLE === */
.chapter-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--phoenix-red);
  margin-top: 24px;
  margin-bottom: 10px;
}

/* === TABLE SCROLL === */
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* === GUIDE INTRO === */
.guide-intro {
  font-size: 1rem;
  color: var(--text-soft);
  line-height: 1.85;
  margin-bottom: 16px;
  max-width: 800px;
}

.guide-intro-top {
  margin-top: 8px;
}

/* === ROUTE DESC & HEADING === */
.route-desc {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.8;
  margin-bottom: 12px;
}

.route-heading {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--phoenix-red);
  margin-top: 28px;
  margin-bottom: 12px;
}

/* === FAQ === */
.faq-intro {
  color: var(--text-soft);
  margin-bottom: 32px;
}

.faq-note {
  margin-top: 16px;
}

.faq-item {
  border-bottom: 1px solid var(--ash-pale);
  padding: 16px 0;
}

.faq-question {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 0;
}

.faq-question::after {
  content: '+';
  font-size: 1.3rem;
  color: var(--phoenix-red);
  font-weight: 700;
  transition: transform 0.2s;
  flex-shrink: 0;
  margin-left: 12px;
}

.faq-item.open .faq-question::after {
  content: '−';
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 2000px;
}

.faq-answer-inner {
  padding: 8px 0 16px;
  color: var(--text-soft);
  line-height: 1.8;
  font-size: 0.95rem;
}

/* === SYSTEM REQUIREMENTS TABLE === */
.sys-table {
  width: 100%;
  border-collapse: collapse;
  margin: 4px 0 16px;
  font-size: 0.9rem;
}

.sys-table th {
  background: var(--phoenix-red);
  color: var(--white);
  padding: 10px 14px;
  text-align: left;
  font-weight: 700;
}

.sys-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--ash-pale);
  color: var(--text-soft);
}

.sys-table tr:nth-child(even) td {
  background: var(--bg-warm);
}

.sys-note {
  margin-top: 20px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* === CHARACTER CARDS === */
.char-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 32px;
}

.char-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 2px 16px var(--shadow);
  transition: transform 0.2s;
}

.char-card:hover {
  transform: translateY(-4px);
}

.char-card-img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  display: block;
  background: linear-gradient(135deg, var(--ash-pale), var(--bg-warm));
}

.char-card-body {
  padding: 18px;
}

.char-card-body h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.char-card-body .char-role {
  font-size: 0.85rem;
  color: var(--phoenix-red);
  font-weight: 700;
  margin-bottom: 8px;
  display: block;
}

.char-card-body p {
  font-size: 0.88rem;
  color: var(--text-soft);
  line-height: 1.65;
}

.char-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.char-tag {
  display: inline-block;
  padding: 2px 10px;
  background: var(--bg-warm);
  color: var(--phoenix-red-dk);
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 12px;
  border: 1px solid var(--gold-light);
}

/* === GUIDE STEPS === */
.guide-steps-wrapper {
  counter-reset: guide-step;
}

.guide-step {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin-bottom: 16px;
  box-shadow: 0 2px 10px var(--shadow);
  border-left: 4px solid var(--gold-flame);
}

.guide-step h3 {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.guide-step h3::before {
  counter-increment: guide-step;
  content: '#' counter(guide-step) ' ';
  color: var(--phoenix-red);
  font-weight: 900;
}

.guide-step p {
  font-size: 0.92rem;
  color: var(--text-soft);
  line-height: 1.75;
}

/* === TIP BOX === */
.tip-box {
  background: var(--bg-warm);
  border-left: 4px solid var(--gold-flame);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 20px 0;
}

.tip-box h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--gold-dk);
  margin-bottom: 6px;
}

.tip-box p {
  font-size: 0.9rem;
  color: var(--text-soft);
  line-height: 1.7;
}

/* === STORY CONTENT === */
.story-block {
  margin-bottom: 32px;
}

.story-block p {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.85;
  margin-bottom: 12px;
  text-indent: 2em;
}

.story-block p:first-of-type {
  text-indent: 0;
}

/* === DECORATIVE DIVIDERS === */
.divider-fire {
  text-align: center;
  margin: 40px 0;
  position: relative;
}

.divider-fire::before,
.divider-fire::after {
  content: '🔥';
  font-size: 1.5rem;
  margin: 0 10px;
}

.divider-fire::before {
  opacity: 0.4;
}

.divider-fire::after {
  opacity: 0.4;
}

.divider-fire span {
  display: inline-block;
  width: 60px;
  height: 2px;
  background: linear-gradient(to right, transparent, var(--phoenix-red), transparent);
  vertical-align: middle;
}

/* === LIGHTBOX === */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,0.9);
  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: 0 4px 30px rgba(0,0,0,0.5);
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 2rem;
  color: var(--white);
  cursor: pointer;
  background: none;
  border: none;
  padding: 10px;
}

/* === RESPONSIVE: 768px === */
@media (max-width: 768px) {
  html { font-size: 15px; }
  :root { --header-h: 56px; }

  .header-nav {
    gap: 16px;
  }

  .header-nav a {
    font-size: 0.82rem;
  }

  .header-cta {
    padding: 6px 14px;
    font-size: 0.82rem;
  }

  .header-logo-text {
    font-size: 1.1rem;
  }

  .hero {
    padding: 40px 16px 56px;
  }

  .hero-title-main {
    font-size: 2rem;
  }

  .hero-subpage {
    padding: 32px 16px 40px;
  }

  .hero-subpage-title {
    font-size: 1.6rem;
  }

  .content-section {
    padding: 48px 16px;
  }

  .game-info-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

  .char-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* === RESPONSIVE: 480px === */
@media (max-width: 480px) {
  html { font-size: 14px; }
  :root { --header-h: 50px; }

  .header-nav {
    gap: 10px;
  }

  .header-nav a {
    font-size: 0.75rem;
  }

  .header-cta {
    padding: 5px 10px;
    font-size: 0.75rem;
  }

  .header-logo-text {
    font-size: 1rem;
  }

  .header-logo img {
    height: 28px;
  }

  .hero {
    padding: 32px 12px 48px;
  }

  .hero-title-main {
    font-size: 1.6rem;
  }

  .hero-subpage {
    padding: 28px 12px 36px;
  }

  .hero-subpage-title {
    font-size: 1.4rem;
  }

  .hero-tagline {
    font-size: 0.95rem;
  }

  .content-section {
    padding: 36px 12px;
  }

  .game-info-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

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

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

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

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

  .cta-banner h2 {
    font-size: 1.5rem;
  }

  .cta-btn {
    padding: 12px 36px;
    font-size: 1rem;
  }
}
