/*
 * Main CSS - F-type Immersive Theme moban-8-2-38
 * Layout: L09 | Nav: N06 | Shape: S01 | Density: D05 | Hierarchy: H04
 * Colors: Primary #FF006E | Secondary #00F5D4 | BG #0D1117
 * Fonts: Quicksand / Nunito
 */

:root {
  --primary: #FF006E;
  --secondary: #00F5D4;
  --bg: #0D1117;
  --text: #E0E0E0;
  --text-muted: #9E9E9E;
  --card-bg: rgba(255,255,255,0.08);
  --overlay-bg: rgba(0,0,0,0.7);
  --header-bg: rgba(18,18,18,0.85);
  --border: rgba(255,255,255,0.1);
  --radius: 16px;
  --card-radius: 20px;
  --font-heading: 'Quicksand', sans-serif;
  --font-body: 'Nunito', sans-serif;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
}
h1,h2,h3,h4,h5,h6 { font-family: var(--font-heading); font-weight: 700; line-height: 1.2; }
a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--secondary); }
img { max-width: 100%; height: auto; }

/* ===== HEADER ===== */
.site-header.f-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 16px 32px;
  background:rgba(18,18,18,0.85);backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);
  transition: var(--transition);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1400px;
  margin: 0 auto;
}
.site-logo .logo-img { height: 40px; width: auto; }
.header-actions { display: flex; gap: 12px; align-items: center; }
.header-actions .btn {
  padding: 8px 20px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font-body);
  transition: var(--transition);
}
.btn-download-sm {
  background: var(--primary);
  color: #fff;
}
.btn-download-sm:hover { background: var(--secondary); color: #fff; }
.btn-login {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-login:hover { border-color: var(--primary); color: var(--primary); }
.btn-register {
  background: var(--secondary);
  color: #fff;
}
.btn-register:hover { background: var(--primary); color: #fff; }

/* ===== HAMBURGER ===== */
.hamburger-btn {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 1100;
}
.hamburger-line {
  display: block;
  width: 28px;
  height: 2px;
  background: var(--text);
  transition: var(--transition);
}
.hamburger-btn.active .hamburger-line:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger-btn.active .hamburger-line:nth-child(2) { opacity: 0; }
.hamburger-btn.active .hamburger-line:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ===== FULLSCREEN OVERLAY (N06) ===== */
.fullscreen-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.95);
  z-index: 1050;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}
.fullscreen-overlay.active { opacity: 1; visibility: visible; }
.overlay-close {
  position: absolute;
  top: 24px;
  right: 32px;
  background: none;
  border: none;
  color: #fff;
  font-size: 48px;
  cursor: pointer;
}
.overlay-menu {
  list-style: none;
  text-align: center;
}
.overlay-menu li { margin: 16px 0; }
.overlay-menu a {
  color: #fff;
  font-size: 2rem;
  font-family: var(--font-heading);
  font-weight: 700;
  transition: var(--transition);
}
.overlay-menu a:hover { color: var(--primary); }

/* ===== FLOATING DOT NAV (N08) ===== */
.dot-nav {
  position: fixed;
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 999;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.dot-nav-item {
  display: flex;
  align-items: center;
  position: relative;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--text-muted);
  background: transparent;
  transition: var(--transition);
  cursor: pointer;
}
.dot-nav-item.active,
.dot-nav-item:hover {
  border-color: var(--primary);
  background: var(--primary);
  box-shadow: 0 0 12px var(--primary);
}
.dot-label {
  position: absolute;
  right: 24px;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  background: var(--card-bg);
  backdrop-filter: blur(8px);
  padding: 4px 12px;
  border-radius: 4px;
  opacity: 0;
  transform: translateX(8px);
  transition: var(--transition);
  pointer-events: none;
}
.dot-nav-item:hover .dot-label { opacity: 1; transform: translateX(0); }

/* ===== BOTTOM TAB NAV (N05) ===== */
.bottom-tab-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  padding: 8px 0 env(safe-area-inset-bottom, 8px);
  border-top: 1px solid var(--border);
  background: var(--header-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.tab-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 6px 4px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  transition: var(--transition);
  text-decoration: none;
}
.tab-item.active { color: var(--primary); }
.tab-item:hover { color: var(--primary); }
.tab-download { color: var(--secondary); }
.tab-item svg { width: 22px; height: 22px; }


/* ===== FULLSCREEN SECTIONS (L09) ===== */
.scroll-snap-container {
  scroll-snap-type: y mandatory;
  overflow-y: scroll;
  height: 100vh;
}
.f-section {
  min-height: 100vh;
  scroll-snap-align: start;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 32px;
  overflow: hidden;
}
.f-section-overlay {
  position: absolute;
  inset: 0;
  background: var(--overlay-bg);
  z-index: 1;
}
.f-section-overlay.light-overlay {
  background: rgba(0,0,0,0.3);
}
.f-section-content {
  position: relative;
  z-index: 2;
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
}

/* Parallax BG */
.parallax-bg {
  position: absolute;
  inset: -20%;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  z-index: 0;
}

/* ===== SINGLE COLUMN (L01) ===== */
.f-single-col .f-section-inline {
  position: relative;
  padding: 80px 32px;
  overflow: hidden;
}
.f-single-col .f-section-inline .parallax-bg {
  position: absolute;
  inset: -20%;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  z-index: 0;
}
.f-single-col .f-section-inline .f-section-overlay {
  position: absolute;
  inset: 0;
  background: var(--overlay-bg);
  z-index: 1;
}
.f-single-col .f-section-inline .f-section-content {
  position: relative;
  z-index: 2;
  max-width: 1100px;
  margin: 0 auto;
}
.f-single-col .section-container {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

/* ===== HERO ===== */
.hero-badge {
  display: inline-block;
  padding: 8px 20px;
  border-radius: var(--radius);
  background: var(--card-bg);
  backdrop-filter: blur(8px);
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 24px;
  border: 1px solid var(--border);
}
.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  margin-bottom: 20px;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}
.gradient-text {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--text-muted);
  max-width: 600px;
  margin-bottom: 32px;
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 40px; }
.hero-stats {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
}
.stat-item { text-align: center; }
.stat-num {
  display: block;
  font-size: 2rem;
  font-weight: 800;
  font-family: var(--font-heading);
  color: var(--primary);
}
.stat-label {
  font-size: 13px;
  color: var(--text-muted);
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  animation: bounceDown 2s infinite;
}
.scroll-arrow { font-size: 2rem; color: var(--primary); }
@keyframes bounceDown {
  0%,100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(12px); }
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block;
  padding: 10px 24px;
  border-radius: var(--radius);
  font-weight: 600;
  font-family: var(--font-body);
  text-decoration: none;
  transition: var(--transition);
  cursor: pointer;
  border: none;
  font-size: 15px;
}
.btn-primary-lg {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  padding: 16px 36px;
  font-size: 16px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}
.btn-primary-lg:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0,0,0,0.3); color: #fff; }
.btn-outline-lg {
  background: transparent;
  color: var(--text);
  border: 2px solid var(--primary);
  padding: 14px 36px;
  font-size: 16px;
}
.btn-outline-lg:hover { background: var(--primary); color: #fff; }
.btn-primary-sm {
  background: var(--primary);
  color: #fff;
  padding: 12px 28px;
}
.btn-primary-sm:hover { background: var(--secondary); color: #fff; }
.btn-outline-sm {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
}
.btn-outline-sm:hover { background: var(--primary); color: #fff; }
.btn-sm {
  padding: 8px 20px;
  font-size: 13px;
  background: var(--primary);
  color: #fff;
}
.btn-sm:hover { background: var(--secondary); color: #fff; }

/* ===== SECTION TITLES ===== */
.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  margin-bottom: 40px;
  text-align: center;
  position: relative;
}
.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  margin: 16px auto 0;
  border-radius: 2px;
}

/* ===== STORY SECTION ===== */
.story-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}
.story-text p { margin-bottom: 16px; font-size: 1.05rem; line-height: 1.8; }
.story-img { border-radius: var(--card-radius); width: 100%; }

/* ===== HORIZONTAL SCROLL ===== */
.hscroll-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 -32px; padding: 0 32px; }
.hscroll-wrapper::-webkit-scrollbar { height: 6px; }
.hscroll-wrapper::-webkit-scrollbar-track { background: var(--border); border-radius: 3px; }
.hscroll-wrapper::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 3px; }
.hscroll-track {
  display: flex;
  gap: var(--card-gap, 24px);
  padding: 16px 0 24px;
  min-width: max-content;
}

/* ===== FEATURE CARDS ===== */
.feature-card {
  min-width: 260px;
  max-width: 300px;
  padding: 32px 24px;
  border-radius: var(--card-radius);
  text-align: center;
  transition: var(--transition);
  background:rgba(255,255,255,0.08);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border:1px solid rgba(255,255,255,0.1);
}
.feature-card:hover { transform: translateY(-4px); }
.feature-icon { font-size: 2.5rem; margin-bottom: 16px; }
.feature-card h3 { font-size: 1.1rem; margin-bottom: 8px; color: var(--primary); }
.feature-card p { font-size: 0.9rem; color: var(--text-muted); }

/* ===== GAME CARDS WITH HOVER OVERLAY ===== */
.games-grid-masonry {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--card-gap, 24px);
}
.game-card-hover {
  position: relative;
  border-radius: var(--card-radius);
  overflow: hidden;
  aspect-ratio: 3/4;
  cursor: pointer;
}
.game-card-hover .game-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.game-card-hover:hover .game-img { transform: scale(1.1); }
.hover-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  opacity: 0;
  transition: var(--transition);
}
.hover-overlay h3 { color: #fff; font-size: 1rem; text-align: center; padding: 0 12px; }
.game-card-hover:hover .hover-overlay { opacity: 1; }

/* ===== NEWS GRID ===== */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--card-gap, 24px);
}
.news-card {
  border-radius: var(--card-radius);
  overflow: hidden;
  transition: var(--transition);
  background:rgba(255,255,255,0.08);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border:1px solid rgba(255,255,255,0.1);
}
.news-card:hover { transform: translateY(-4px); }
.news-link { display: block; color: inherit; text-decoration: none; }
.news-thumb { overflow: hidden; aspect-ratio: 16/9; }
.news-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.news-card:hover .news-thumb img { transform: scale(1.05); }
.news-info { padding: 16px; }
.news-info h3 { font-size: 1rem; margin-bottom: 8px; line-height: 1.4; }
.news-date, .news-author { font-size: 12px; color: var(--text-muted); margin-right: 12px; }
.news-excerpt { padding: 0 16px 16px; font-size: 0.85rem; color: var(--text-muted); }

/* ===== DOWNLOAD SECTION ===== */
.f-download, .f-download-inline { text-align: center; }
.download-desc { font-size: 1.15rem; color: var(--text-muted); max-width: 600px; margin: 0 auto 32px; }
.download-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ===== FOOTER ===== */
.site-footer.f-footer {
  background: var(--bg);
  border-top: 1px solid var(--border);
  padding: 48px 32px 24px;
}
.footer-inner { max-width: 1100px; margin: 0 auto; }
.footer-widgets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; margin-bottom: 32px; }
.footer-bottom { text-align: center; padding-top: 24px; border-top: 1px solid var(--border); }
.disclaimer-text { font-size: 13px; color: var(--text-muted); margin-top: 16px; line-height: 1.6; }

/* ===== SCROLL ANIMATIONS ===== */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}
.animate-on-scroll.delay-1 { transition-delay: 0.15s; }
.animate-on-scroll.delay-2 { transition-delay: 0.3s; }
.animate-on-scroll.delay-3 { transition-delay: 0.45s; }
.animate-on-scroll.delay-4 { transition-delay: 0.6s; }

/* ===== PAGE LAYOUTS ===== */
.f-page-main { padding-top: 80px; min-height: 100vh; }
.f-page-section { padding: 48px 32px; }
.section-container { max-width: 1100px; margin: 0 auto; }
.full-grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }

/* ===== SINGLE POST ===== */
.f-single-post { max-width: 800px; margin: 0 auto; padding: 120px 32px 48px; }
.single-title { font-size: clamp(1.5rem, 4vw, 2.5rem); margin-bottom: 16px; }
.single-meta { display: flex; gap: 16px; color: var(--text-muted); font-size: 14px; margin-bottom: 24px; flex-wrap: wrap; }
.single-thumb { border-radius: var(--card-radius); overflow: hidden; margin-bottom: 32px; }
.single-thumb img { width: 100%; }
.single-body { line-height: 1.8; }
.single-body p { margin-bottom: 16px; }
.single-body h2, .single-body h3 { margin: 24px 0 12px; }
.single-body img { border-radius: var(--radius); margin: 16px 0; }
.f-related { padding: 48px 32px; }
.archive-title { font-size: 2rem; margin-bottom: 32px; }
.page-title { font-size: 2rem; margin-bottom: 24px; }

/* ===== DARK/LIGHT TOGGLE (for F7 moban-8-2-43) ===== */
.theme-toggle-btn {
  position: fixed;
  bottom: 80px;
  right: 24px;
  z-index: 999;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  border: none;
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  transition: var(--transition);
}
.theme-toggle-btn:hover { transform: scale(1.1); }
body.light-mode {
  --bg: #FAFAFA;
  --text: #1A1A2E;
  --text-muted: #555;
  --card-bg: rgba(255,255,255,0.9);
  --overlay-bg: rgba(0,0,0,0.5);
  --header-bg: rgba(255,255,255,0.9);
  --border: rgba(0,0,0,0.1);
}

/* Text center utility */
.text-center { text-align: center; }
.no-posts { text-align: center; padding: 48px; color: var(--text-muted); }
