:root {
  --gold: #ffc000;
  --gold-hover: #ffd633;
  --gold-deep: #7d4d15;
  --text: #111111;
  --muted: #555555;
  --footer: #999999;
  --bg: #fafafa;
  --card: rgba(255, 255, 255, 0.55);
  --radius: 20px;
  --container: 1200px;
  --header-h: 72px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

body.menu-open {
  overflow: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: 0;
  background: none;
}

.container {
  width: min(100% - 40px, var(--container));
  margin: 0 auto;
}

/* Header */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.6) 42%, rgba(0, 0, 0, 0));
  transition: background 0.25s ease;
}

.header.scrolled {
  background: rgba(18, 18, 22, 0.92);
  backdrop-filter: blur(12px);
}

.header-inner {
  height: 100%;
  width: min(100% - 32px, 1400px);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 700;
  font-size: 18px;
  white-space: nowrap;
}

.logo img {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}

.nav {
  flex: 1;
  display: flex;
  justify-content: center;
  gap: 8px;
}

.nav a {
  color: #fff;
  font-size: 15px;
  padding: 8px 16px;
  position: relative;
  opacity: 0.92;
}

.nav a::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 2px;
  height: 0;
  background: var(--gold);
  transition: height 0.2s;
}

.nav a:hover::after,
.nav a:focus-visible::after {
  height: 3px;
}

.header-download {
  white-space: nowrap;
  height: 40px;
  min-width: 118px;
  padding: 0 18px;
  border: 1px solid #fff;
  border-radius: 20px;
  color: #fff;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: 0.25s;
}

.header-download:hover {
  background: #2b8cff;
  border-color: #2b8cff;
  color: #fff;
}

.menu-btn {
  display: none;
  width: 40px;
  height: 40px;
  position: relative;
}

.menu-btn span {
  position: absolute;
  left: 10px;
  right: 10px;
  height: 2px;
  background: #fff;
  transition: 0.2s;
  transform-origin: center;
}

.menu-btn span:nth-child(1) { top: 13px; }
.menu-btn span:nth-child(2) { top: 19px; }
.menu-btn span:nth-child(3) { top: 25px; }

.menu-btn.open span:nth-child(1) {
  top: 19px;
  transform: rotate(45deg);
}

.menu-btn.open span:nth-child(2) {
  opacity: 0;
}

.menu-btn.open span:nth-child(3) {
  top: 19px;
  transform: rotate(-45deg);
}

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  background: #111;
  overflow: hidden;
}

.hero-bg,
.hero-bg picture,
.hero-bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-bg img {
  object-fit: cover;
  object-position: center;
}

.hero-mask {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 320px;
  background: linear-gradient(180deg, rgba(250, 250, 250, 0), var(--bg));
  z-index: 1;
  pointer-events: none;
}

.game-card {
  position: absolute;
  left: 50%;
  bottom: 140px;
  transform: translateX(-50%);
  width: min(100% - 32px, 1200px);
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.6);
  padding: 40px;
  backdrop-filter: blur(20px);
  box-shadow: 0 4px 40px rgba(0, 0, 0, 0.05);
  z-index: 2;
}

.game-card-row {
  display: flex;
  align-items: center;
  gap: 28px;
}

.game-icon {
  width: 127px;
  height: 127px;
  border-radius: 30px;
  flex-shrink: 0;
  object-fit: cover;
}

.game-meta {
  flex: 1;
  min-width: 0;
}

.game-name {
  font-size: 38px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.game-tags span {
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 4px;
  font-size: 16px;
  color: var(--muted);
}

.game-features {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 28px;
  flex-wrap: wrap;
}

.game-features span {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  color: #333;
}

.game-features img {
  width: 33px;
  height: 32px;
}

.scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 40px;
  transform: translateX(-50%);
  z-index: 2;
  width: 36px;
  animation: bounce 1.6s infinite;
}

.scroll-hint img {
  width: 36px;
  height: 54px;
  object-fit: contain;
}

@keyframes bounce {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 8px); }
}

/* Download / play button */
.btn-download {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 180px;
  height: 72px;
  padding: 0 28px;
  border-radius: 18px;
  background: linear-gradient(180deg, #5eb4ff 0%, #2b8cff 48%, #1570d8 100%);
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.04em;
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.45),
    0 4px 0 #0d5bb8,
    0 10px 20px rgba(21, 112, 216, 0.35);
  transition: 0.2s transform, 0.2s filter;
}

.btn-download:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.btn-download:active {
  transform: translateY(2px);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.35),
    0 2px 0 #0d5bb8;
}

.btn-download-lg {
  min-width: 220px;
  height: 84px;
  font-size: 24px;
}

/* Content */
.section {
  position: relative;
  padding: 24px 0 80px;
  background: var(--bg);
}

#intro {
  margin-top: -100px;
  z-index: 3;
}

#intro,
#gallery,
#guide,
#download {
  scroll-margin-top: calc(var(--header-h) + 16px);
}

.section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 24px;
  font-weight: 700;
}

.section-title::before {
  content: "";
  width: 6px;
  height: 22px;
  border-radius: 2px;
  background: linear-gradient(180deg, #ffd54a, #c48a00);
}

.intro-wrap {
  padding: 20px 0 28px;
}

.intro-text {
  font-size: 16px;
  line-height: 28px;
  color: var(--muted);
  max-height: 84px;
  overflow: hidden;
}

.intro-text.expanded {
  max-height: none;
  overflow: visible;
}

.intro-more {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
  font-size: 16px;
  position: relative;
  z-index: 3;
  cursor: pointer;
}

.intro-more {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
  font-size: 16px;
}

.intro-more svg {
  transition: transform 0.2s;
}

.intro-more.open svg {
  transform: rotate(180deg);
}

/* Gallery */
.gallery {
  position: relative;
}

.swiper {
  overflow: hidden;
}

.swiper-track {
  display: flex;
  gap: 16px;
  transition: transform 0.35s ease;
}

.slide {
  flex: 0 0 calc((100% - 32px) / 3);
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  background: #e8e8e8;
}

.slide img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: transform 0.4s;
}

.slide:hover img {
  transform: scale(1.06);
}

.swiper-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 66px;
  background: rgba(250, 250, 250, 0.85);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.swiper-btn::before {
  content: "";
  width: 10px;
  height: 10px;
  border-top: 2px solid #333;
  border-right: 2px solid #333;
  opacity: 0.75;
}

.swiper-btn.prev {
  left: 0;
  border-radius: 0 8px 8px 0;
}

.swiper-btn.prev::before {
  transform: rotate(-135deg);
  margin-left: 4px;
}

.swiper-btn.next {
  right: 0;
  border-radius: 8px 0 0 8px;
}

.swiper-btn.next::before {
  transform: rotate(45deg);
  margin-right: 4px;
}

.swiper-btn:hover::before {
  opacity: 1;
}

.swiper-btn:disabled {
  opacity: 0.45;
  cursor: default;
}

/* Steps */
.guide-title {
  margin-top: 80px;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 40px;
  position: relative;
}

.steps::before {
  content: "";
  position: absolute;
  left: 16.6%;
  right: 16.6%;
  top: calc(200px + 18px);
  height: 2px;
  background-image: linear-gradient(90deg, transparent 0 6px, #d7b56a 6px 18px, transparent 18px 24px);
  background-size: 24px 2px;
  pointer-events: none;
}

.step {
  text-align: center;
}

.step-visual {
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.illus {
  width: 100%;
  max-width: 320px;
  height: 180px;
  position: relative;
}

.illus-folder,
.illus-window,
.illus-monitor {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.illus-download .illus-folder {
  position: absolute;
  left: 18%;
  right: 18%;
  top: 28px;
  height: 108px;
}

.illus-download .illus-folder::before {
  content: "";
  position: absolute;
  left: 12px;
  top: -16px;
  width: 70px;
  height: 24px;
  background: #f3f3f3;
  border-radius: 10px 10px 0 0;
}

.illus-download .illus-icon {
  position: absolute;
  width: 58px;
  height: 58px;
  border-radius: 16px;
  left: 50%;
  top: 18px;
  transform: translateX(-50%);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
}

.illus-arrow {
  position: absolute;
  right: 26%;
  bottom: 36px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(180deg, #ffe566, #ffc000);
  color: #7d4d15;
  font-size: 22px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 14px rgba(255, 192, 0, 0.4);
}

.illus-window {
  position: absolute;
  inset: 10px 12px 8px;
  padding: 14px 16px 16px;
}

.illus-bar {
  font-size: 13px;
  color: var(--gold-deep);
  font-weight: 600;
  text-align: left;
  margin-bottom: 12px;
}

.illus-searchbox {
  height: 36px;
  border-radius: 18px;
  background: #f4f4f4;
  display: flex;
  align-items: center;
  padding: 0 14px;
  font-size: 13px;
  color: var(--gold-deep);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.illus-result {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.illus-result img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.illus-install {
  background: linear-gradient(180deg, #ffe566, #ffc000);
  color: #7d4d15;
  font-size: 13px;
  font-weight: 700;
  border-radius: 16px;
  padding: 8px 18px;
}

.illus-monitor {
  position: absolute;
  left: 22%;
  right: 22%;
  top: 10px;
  height: 118px;
  border-radius: 16px 16px 8px 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.illus-monitor::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -28px;
  width: 36px;
  height: 18px;
  background: #eee;
  transform: translateX(-50%);
  border-radius: 0 0 6px 6px;
}

.illus-monitor img {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
}

.step-num {
  margin-top: 8px;
  font-family: Arial Black, Anton, Impact, sans-serif;
  font-size: 34px;
  letter-spacing: 0.06em;
  background: linear-gradient(180deg, #ab790e 22%, #6c4a00 78%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  position: relative;
  z-index: 1;
}

.step-text {
  margin-top: 8px;
  font-size: 18px;
  color: var(--gold-deep);
  padding: 0 8px;
}

.bottom-download {
  margin-top: 28px;
  display: flex;
  justify-content: center;
}

/* Footer */
.footer {
  background: #f9f9f9;
  padding: 40px 0 48px;
  text-align: center;
  font-size: 12px;
  line-height: 22px;
  color: var(--footer);
  box-shadow: inset 0 1px rgba(0, 0, 0, 0.06);
}

.footer p + p {
  margin-top: 12px;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.footer-links a:hover {
  color: var(--gold);
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.82);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 80px;
}

.lightbox[hidden] {
  display: none;
}

.lightbox img {
  max-width: min(1200px, 100%);
  max-height: 80vh;
  border-radius: 8px;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 28px;
  color: #fff;
  font-size: 40px;
  line-height: 1;
  opacity: 0.85;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  width: 48px;
  height: 80px;
  background: rgba(0, 0, 0, 0.55);
  border-radius: 8px;
  transform: translateY(-50%);
}

.lightbox-nav::before {
  content: "";
  display: block;
  width: 12px;
  height: 12px;
  border-top: 2px solid #fff;
  border-right: 2px solid #fff;
  margin: 0 auto;
  opacity: 0.85;
}

.lightbox-nav.prev {
  left: 20px;
}

.lightbox-nav.prev::before {
  transform: rotate(-135deg);
}

.lightbox-nav.next {
  right: 20px;
}

.lightbox-nav.next::before {
  transform: rotate(45deg);
}

/* Tablet */
@media (max-width: 1024px) {
  .game-name {
    font-size: 28px;
  }

  .game-icon {
    width: 96px;
    height: 96px;
    border-radius: 22px;
  }

  .game-card {
    padding: 24px;
    bottom: 100px;
  }

  .slide {
    flex-basis: calc((100% - 16px) / 2);
  }

  .steps::before {
    display: none;
  }
}

/* Mobile */
@media (max-width: 768px) {
  :root {
    --header-h: 56px;
  }

  .menu-btn {
    display: block;
    margin-left: auto;
  }

  .header-inner {
    gap: 12px;
  }

  .logo span {
    font-size: 15px;
  }

  .header-download {
    height: 32px;
    min-width: 88px;
    font-size: 13px;
    padding: 0 12px;
  }

  .nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: rgba(18, 18, 22, 0.96);
    flex-direction: column;
    align-items: stretch;
    padding: 12px 16px 20px;
    gap: 0;
    display: none;
  }

  .nav.open {
    display: flex;
  }

  .nav a {
    padding: 14px 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .hero {
    min-height: 100svh;
  }

  .game-card {
    bottom: 120px;
    padding: 16px;
    border-radius: 16px;
  }

  .game-card-row {
    flex-wrap: wrap;
    gap: 12px;
  }

  .game-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
  }

  .game-meta {
    width: calc(100% - 80px);
  }

  .game-name {
    font-size: 22px;
  }

  .game-tags {
    margin-top: 8px;
  }

  .game-tags span {
    padding: 4px 8px;
    font-size: 12px;
  }

  .btn-download {
    width: 100%;
    height: 52px;
    min-width: 0;
    font-size: 18px;
    border-radius: 14px;
  }

  .game-features {
    margin-top: 14px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 8px;
  }

  .game-features span {
    font-size: 13px;
  }

  .game-features img {
    width: 22px;
    height: 22px;
  }

  .scroll-hint {
    bottom: 12px;
    width: 24px;
  }

  .scroll-hint img {
    width: 24px;
    height: 36px;
  }

  .hero-mask {
    height: 180px;
  }

  .section {
    padding: 8px 0 48px;
  }

  .section-title,
  .guide-title {
    font-size: 20px;
    margin-top: 28px;
  }

  .intro-text {
    font-size: 14px;
    line-height: 24px;
    max-height: 72px;
  }

  .slide {
    flex-basis: 82%;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .step-visual {
    height: 160px;
  }

  .step-num {
    font-size: 26px;
  }

  .step-text {
    font-size: 15px;
    margin-bottom: 16px;
  }

  .btn-download-lg {
    height: 56px;
    font-size: 18px;
  }

  .lightbox {
    padding: 60px 16px;
  }

  .lightbox-nav {
    display: none;
  }
}

@media (max-width: 480px) {
  .container {
    width: min(100% - 24px, var(--container));
  }

  .logo span {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}
