/* =============================================================
   He Maid Her Fall 中文官网 — 样式表
   设计主题：法式甜点 × 女仆咖啡
   色彩方案：薰衣草紫 #9575CD · 玫瑰粉 #F06292 · 奶油白 #FFF8E1 · 薄荷绿 #81C784
   ============================================================= */

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

/* ========== CSS VARIABLES ========== */
:root {
  /* Primary palette — French dessert inspired */
  --lavender: #9575CD;
  --lavender-dark: #7B5EA7;
  --lavender-light: #B39DDB;
  --rose: #F06292;
  --rose-dark: #D9457B;
  --rose-light: #F48FB1;
  --cream: #FFF8E1;
  --cream-dark: #F5E6CC;
  --mint: #81C784;
  --mint-dark: #5BA85A;
  --mint-light: #A5D6A7;

  /* Semantic colors */
  --bg: #FDFAF3;
  --bg-alt: #FFF8E1;
  --bg-card: #FFFFFF;
  --text: #3E2A35;
  --text-soft: #6D5D6B;
  --text-muted: #9E8B9A;
  --heading: #4A2040;
  --accent: #9575CD;
  --accent-alt: #F06292;
  --border: #E8DDE5;
  --border-light: #F2EAF0;
  --shadow: rgba(149, 117, 205, 0.10);
  --shadow-lg: rgba(149, 117, 205, 0.18);
  --overlay: rgba(74, 32, 64, 0.55);

  /* Typography */
  --font-serif: 'Noto Serif SC', 'Source Han Serif SC', 'SimSun', serif;
  --font-sans: 'Noto Sans SC', 'Source Han Sans SC', 'Microsoft YaHei', sans-serif;

  /* Layout */
  --max-width: 1160px;
  --header-height: 64px;
  --radius: 10px;
  --radius-lg: 16px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========== RESET ========== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  font-size: 16px;
  scroll-behavior: smooth;
}
body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a {
  color: var(--lavender);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover {
  color: var(--lavender-dark);
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ========== ACCESSIBILITY ========== */
.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: linear-gradient(135deg, #4A2040 0%, #3E1A35 100%);
  border-bottom: 3px solid var(--rose);
  box-shadow: 0 2px 16px var(--shadow-lg);
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.header-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
}
.header-logo img {
  width: 36px;
  height: 36px;
  border-radius: 6px;
}
.header-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}
.header-nav a {
  color: rgba(255,255,255,0.85);
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.92rem;
  font-weight: 500;
  transition: background var(--transition), color var(--transition);
}
.header-nav a:hover,
.header-nav a.active {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.header-cta {
  background: var(--rose);
  color: #fff !important;
  padding: 8px 20px !important;
  border-radius: 22px !important;
  font-weight: 700 !important;
  font-size: 0.92rem;
  transition: background var(--transition), transform var(--transition);
  white-space: nowrap;
}
.header-cta:hover {
  background: var(--rose-dark) !important;
  transform: translateY(-1px);
}

/* ========== HERO SECTION ========== */
.hero {
  position: relative;
  background: linear-gradient(150deg, #4A2040 0%, #5E3560 30%, #7B5EA7 70%, #9575CD 100%);
  padding: 60px 24px 80px;
  text-align: center;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    radial-gradient(ellipse at 20% 80%, rgba(240, 98, 146, 0.18) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(129, 199, 132, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 50%, rgba(255, 248, 225, 0.08) 0%, transparent 60%);
  pointer-events: none;
}
.hero::after {
  content: '♡';
  position: absolute;
  bottom: -40px;
  right: 5%;
  font-size: 12rem;
  color: rgba(255,255,255,0.04);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
}
.hero-title-main {
  font-family: var(--font-serif);
  font-size: 2.8rem;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0,0,0,0.35);
  margin-bottom: 12px;
  line-height: 1.3;
}
.hero-title-main .en-subtitle {
  display: block;
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--rose-light);
  margin-top: 6px;
  letter-spacing: 0.06em;
  font-family: var(--font-sans);
}
.hero-tagline {
  font-size: 1.08rem;
  color: rgba(255,255,255,0.85);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.8;
}
.hero-tagline strong {
  color: var(--rose-light);
}

/* ========== HERO — SUBPAGE variant ========== */
.hero-subpage {
  padding: 40px 24px 48px;
}
.hero-subpage-title {
  font-size: 2rem;
  font-weight: 700;
}

/* ========== CTA BANNER (index-only) ========== */
.cta-banner {
  background: linear-gradient(135deg, var(--rose) 0%, var(--rose-dark) 100%);
  padding: 48px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -30%;
  width: 160%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
  pointer-events: none;
}
.cta-banner h2 {
  font-family: var(--font-serif);
  font-size: 1.9rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}
.cta-banner p {
  color: rgba(255,255,255,0.9);
  font-size: 1rem;
  margin-bottom: 24px;
}
.cta-btn {
  display: inline-block;
  background: #fff;
  color: var(--rose) !important;
  padding: 14px 40px;
  border-radius: 30px;
  font-weight: 700;
  font-size: 1.1rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  transition: transform var(--transition), box-shadow var(--transition);
}
.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(0,0,0,0.25);
}

/* ========== SECTIONS ========== */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px 24px;
}
.section-alt {
  background: var(--cream);
}
.section-no-padding {
  padding: 0;
}
.section-title {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--heading);
  text-align: center;
  margin-bottom: 10px;
}
.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 40px;
}
.section-title-group {
  margin-bottom: 32px;
}
.section-title-group-spaced {
  margin-top: 48px;
}

/* ========== GAME INFO CARDS ========== */
.info-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 24px;
}
.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 20px 16px;
  text-align: center;
  box-shadow: 0 2px 8px var(--shadow);
  transition: box-shadow var(--transition);
}
.info-card:hover {
  box-shadow: 0 4px 16px var(--shadow-lg);
}
.info-card .info-icon {
  font-size: 1.8rem;
  margin-bottom: 8px;
}
.info-card .info-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.info-card .info-value {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--heading);
  font-family: var(--font-serif);
}

/* ========== FEATURE CARDS ========== */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 16px;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--lavender);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 2px 8px var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
}
.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px var(--shadow-lg);
}
.feature-card h3 {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--heading);
  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: 14px;
  margin-top: 16px;
}
.gallery-item {
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 2px 10px var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
}
.gallery-item:hover {
  transform: scale(1.03);
  box-shadow: 0 6px 20px var(--shadow-lg);
}
.gallery-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

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

/* ========== REVIEWS ========== */
.review-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 16px;
}
.review-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--rose);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 2px 8px var(--shadow);
}
.review-text {
  font-style: italic;
  color: var(--text-soft);
  font-size: 0.93rem;
  line-height: 1.8;
  margin-bottom: 12px;
}
.review-author {
  font-weight: 700;
  color: var(--rose);
  font-size: 0.88rem;
}

/* ========== CONTENT PAGE STYLES ========== */
.content-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 48px 24px 64px;
}
.content-section h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 12px;
}
.content-section h3 {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--heading);
  margin-top: 32px;
  margin-bottom: 12px;
  border-left: 4px solid var(--lavender);
  padding-left: 14px;
}
.content-section p {
  color: var(--text-soft);
  margin-bottom: 14px;
  line-height: 1.85;
}

/* ========== CHAPTER STYLE ========== */
.chapter-title {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--heading);
  margin-top: 28px;
  margin-bottom: 8px;
}
.story-chapter {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--rose);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px var(--shadow);
}
.story-chapter h3 {
  margin-top: 0;
  border-left: none;
  padding-left: 0;
  color: var(--rose);
}

/* ========== GUIDE STEP STYLES ========== */
.guide-steps-wrapper {
  counter-reset: guide-step;
}
.guide-step {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--lavender);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px var(--shadow);
}
.guide-step h3 {
  margin-top: 0;
  border-left: none;
  padding-left: 0;
  counter-increment: guide-step;
}
.guide-step h3::before {
  content: '第' counter(guide-step) '步：';
  color: var(--lavender);
}
.guide-tip {
  background: linear-gradient(135deg, #F3E5F5, #EDE7F6);
  border: 1px solid var(--lavender-light);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-top: 16px;
  font-size: 0.92rem;
  color: var(--text-soft);
}
.guide-tip strong {
  color: var(--lavender);
}
.guide-intro {
  font-size: 0.95rem;
  color: var(--text-soft);
  margin-bottom: 24px;
  line-height: 1.85;
}
.route-heading {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--heading);
  margin-top: 28px;
  margin-bottom: 8px;
}
.route-desc {
  color: var(--text-soft);
  margin-bottom: 12px;
}

/* ========== CHARACTER CARDS ========== */
.char-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  margin-top: 24px;
}
.char-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 2px 10px var(--shadow);
  transition: transform var(--transition);
}
.char-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px var(--shadow-lg);
}
.char-card-img {
  height: 240px;
  background: linear-gradient(135deg, var(--lavender-light), var(--rose-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
}
.char-card-img img {
  width: 100%;
  height: 100%;
  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(--heading);
  margin-top: 0;
  margin-bottom: 4px;
  border-left: none;
  padding-left: 0;
}
.char-card-body .char-role {
  font-size: 0.82rem;
  color: var(--rose);
  font-weight: 600;
  margin-bottom: 10px;
}
.char-traits {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}
.char-tag {
  display: inline-block;
  background: var(--cream);
  color: var(--lavender-dark);
  font-size: 0.78rem;
  padding: 3px 10px;
  border-radius: 14px;
  font-weight: 500;
  border: 1px solid var(--border-light);
}
.char-card-body p {
  font-size: 0.88rem;
  color: var(--text-soft);
  line-height: 1.7;
}

/* ========== FAQ ACCORDION ========== */
.faq-intro {
  color: var(--text-soft);
  margin-bottom: 32px;
}
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}
.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  margin-bottom: 10px;
  overflow: hidden;
  box-shadow: 0 1px 4px var(--shadow);
}
.faq-question {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 18px 24px;
  font-family: var(--font-serif);
  font-size: 1rem;
  font-weight: 700;
  color: var(--heading);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.faq-question:hover {
  background: var(--cream);
}
.faq-question::after {
  content: '+';
  font-size: 1.4rem;
  color: var(--lavender);
  font-weight: 400;
  transition: transform 0.3s;
  flex-shrink: 0;
}
.faq-item.open .faq-question::after {
  content: '−';
}
.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;
  color: var(--text-soft);
  font-size: 0.92rem;
  line-height: 1.8;
}

/* ========== TABLE STYLES ========== */
.req-table {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0;
  font-size: 0.9rem;
}
.req-table thead {
  background: linear-gradient(135deg, var(--lavender), var(--lavender-dark));
  color: #fff;
}
.req-table th {
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
}
.req-table td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-light);
}
.req-table tbody tr:hover {
  background: var(--cream);
}
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.td-highlight {
  color: var(--rose);
  font-weight: 700;
}
.sys-note {
  margin-top: 20px;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.faq-note {
  margin-top: 16px;
}

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

/* ========== CONTENT LIST CLASSES ========== */
.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-pink { color: var(--rose); }
.strong-red { color: #D32F2F; }
.strong-gold { color: #F9A825; }
.strong-muted { color: var(--text-muted); }
.strong-navy { color: var(--heading); }

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

/* ========== 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 DESC ========== */
.game-info-desc {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 0;
}

/* ========== FOOTER ========== */
.site-footer {
  background: linear-gradient(135deg, #4A2040 0%, #3E1A35 100%);
  color: rgba(255,255,255,0.7);
  text-align: center;
  padding: 24px;
  font-size: 0.88rem;
}
.site-footer p {
  color: rgba(255,255,255,0.7);
}

/* ========== RESPONSIVE — 768px ========== */
@media (max-width: 768px) {
  .hero-title-main {
    font-size: 2rem;
  }
  .hero-title-main .en-subtitle {
    font-size: 0.9rem;
  }
  .hero-subpage-title {
    font-size: 1.6rem;
  }
  .header-nav a {
    padding: 6px 10px;
    font-size: 0.82rem;
  }
  .header-cta {
    padding: 6px 14px !important;
    font-size: 0.82rem !important;
  }
  .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(auto-fill, minmax(240px, 1fr));
  }
  .section {
    padding: 40px 20px;
  }
  .content-section {
    padding: 32px 20px 48px;
  }
  .content-section h2 {
    font-size: 1.7rem;
  }
  .cta-banner h2 {
    font-size: 1.5rem;
  }
  .section-title {
    font-size: 1.6rem;
  }
}

/* ========== RESPONSIVE — 480px ========== */
@media (max-width: 480px) {
  .hero-title-main {
    font-size: 1.6rem;
  }
  .hero-subpage-title {
    font-size: 1.35rem;
  }
  .hero-tagline {
    font-size: 0.92rem;
  }
  .header-inner {
    flex-wrap: wrap;
    height: auto;
    padding: 10px 16px;
    gap: 8px;
  }
  .header-nav {
    flex-wrap: wrap;
    gap: 2px;
  }
  .header-nav a {
    padding: 5px 8px;
    font-size: 0.78rem;
  }
  .header-cta {
    padding: 5px 12px !important;
    font-size: 0.78rem !important;
  }
  .info-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  .char-grid {
    grid-template-columns: 1fr;
  }
  .section {
    padding: 32px 16px;
  }
  .content-section {
    padding: 28px 16px 40px;
  }
  .content-section h2 {
    font-size: 1.4rem;
  }
  .cta-banner {
    padding: 36px 16px;
  }
  .cta-banner h2 {
    font-size: 1.3rem;
  }
  .cta-btn {
    padding: 12px 30px;
    font-size: 1rem;
  }
  .section-title {
    font-size: 1.35rem;
  }
  .story-chapter,
  .guide-step {
    padding: 16px;
  }
  .req-table th,
  .req-table td {
    padding: 8px 10px;
    font-size: 0.82rem;
  }
}
