/* ============ Tokens ============ */
:root {
  --pink: #ff4e8a;
  --hot:  #ff3d7f;
  --yellow: #ffcd3c;
  --orange: #ff8a3c;
  --cyan: #2ec5f1;
  --blue: #4d6dff;
  --purple: #a060ff;
  --lime: #7ed957;
  --cream: #fff8ec;
  --ink: #2b1a3d;
  --ink-soft: #5a4a6e;
  --shadow: 0 10px 30px rgba(43, 26, 61, 0.12);
  --shadow-lg: 0 20px 60px rgba(43, 26, 61, 0.18);
  --radius: 22px;
  --maxw: 1140px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ============ Header ============ */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 248, 236, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(43, 26, 61, 0.06);
}
.nav-wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px; position: relative;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-size: 22px; font-weight: 700;
  color: var(--ink); text-decoration: none;
}
.logo-emoji { font-size: 30px; line-height: 1; }
.logo-text strong { color: var(--pink); font-weight: 800; }

.main-nav { display: flex; gap: 6px; }
.main-nav a {
  text-decoration: none;
  color: var(--ink-soft);
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 600;
  transition: all 0.2s ease;
}
.main-nav a:hover {
  color: var(--pink);
  background: rgba(255, 78, 138, 0.1);
}

.nav-toggle {
  display: none;
  background: none; border: 0; cursor: pointer;
  flex-direction: column; gap: 5px; padding: 8px;
}
.nav-toggle span {
  width: 26px; height: 3px; background: var(--ink);
  border-radius: 2px; transition: 0.3s;
}

/* ============ Hero ============ */
.hero {
  position: relative;
  background: linear-gradient(135deg, #ff4e8a 0%, #a060ff 45%, #2ec5f1 100%);
  color: #fff;
  padding: 140px 0 160px;
  overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 205, 60, 0.35), transparent 42%),
    radial-gradient(circle at 82% 70%, rgba(126, 217, 87, 0.32), transparent 45%);
  pointer-events: none;
}
.hero-inner { position: relative; text-align: center; }
.hero-emoji {
  font-size: 88px; line-height: 1;
  animation: bounce 2.2s ease-in-out infinite;
  filter: drop-shadow(0 12px 30px rgba(0,0,0,0.2));
}
@keyframes bounce {
  0%, 100% { transform: translateY(0) rotate(-6deg); }
  50%      { transform: translateY(-18px) rotate(6deg); }
}
.hero-title {
  font-size: clamp(48px, 8vw, 92px);
  font-weight: 900;
  letter-spacing: -2px;
  margin: 18px 0 14px;
  line-height: 1;
  text-shadow: 0 6px 0 rgba(0,0,0,0.08);
}
.hero-title span {
  background: linear-gradient(180deg, #ffe57a, #ff8a3c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-tagline {
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 700;
  margin-bottom: 14px;
}
.hero-sub {
  font-size: 16px;
  max-width: 620px;
  margin: 0 auto 32px;
  opacity: 0.94;
}
.hero-cta {
  display: flex; gap: 14px; justify-content: center; flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  cursor: pointer; border: 0;
  font-size: 16px;
  font-family: inherit;
}
.btn-primary {
  background: linear-gradient(135deg, #ffcd3c, #ff8a3c);
  color: #2b1a3d;
  box-shadow: 0 10px 24px rgba(255, 138, 60, 0.5);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(255, 138, 60, 0.6); }
.btn-ghost {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.5);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.28); transform: translateY(-3px); }

.hero-wave {
  position: absolute; left: 0; right: 0; bottom: -1px;
  line-height: 0;
}
.hero-wave svg { width: 100%; height: 80px; display: block; }
.hero-wave path { fill: var(--cream); }

/* ============ Confetti ============ */
.confetti-layer { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.confetti-piece {
  position: absolute; top: -20px;
  width: 10px; height: 14px;
  opacity: 0.9;
  animation: confetti-fall linear forwards;
}
@keyframes confetti-fall {
  0%   { transform: translateY(0) rotate(0); opacity: 1; }
  100% { transform: translateY(110vh) rotate(720deg); opacity: 0; }
}

/* ============ Section heads ============ */
.section-head { text-align: center; max-width: 720px; margin: 0 auto 56px; }
.section-eyebrow {
  display: inline-block;
  background: rgba(255, 78, 138, 0.1);
  color: var(--pink);
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 14px; font-weight: 700;
  margin-bottom: 14px;
}
.section-eyebrow.light {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
}
.section-head h2 {
  font-size: clamp(32px, 4.5vw, 46px);
  font-weight: 900;
  letter-spacing: -1px;
  margin-bottom: 12px;
}
.section-head p { color: var(--ink-soft); font-size: 17px; }

/* ============ Games ============ */
.games { padding: 100px 0; }
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 28px;
}
.game-card {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  border: 3px solid transparent;
}
.game-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(255, 78, 138, 0.3);
}
.game-cover {
  height: 160px;
  background: linear-gradient(135deg, var(--c1), var(--c2));
  display: flex; align-items: center; justify-content: center;
  font-size: 72px;
  position: relative;
}
.game-cover::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 70% 20%, rgba(255,255,255,0.35), transparent 60%);
}
.game-cover span { position: relative; filter: drop-shadow(0 6px 12px rgba(0,0,0,0.2)); }
.game-body { padding: 24px; }
.game-genre {
  display: inline-block;
  background: rgba(43, 26, 61, 0.06);
  color: var(--ink-soft);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.game-body h3 {
  font-size: 22px; font-weight: 800;
  margin-bottom: 8px;
}
.game-body p { color: var(--ink-soft); font-size: 15px; }
.games-foot { text-align: center; margin-top: 48px; color: var(--ink-soft); font-weight: 600; }

/* ============ About ============ */
.about {
  padding: 100px 0;
  background: linear-gradient(180deg, #fff 0%, var(--cream) 100%);
}
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 60px;
  align-items: center;
}
.about-text .section-eyebrow { margin-bottom: 18px; }
.about-text h2 {
  font-size: clamp(30px, 4vw, 42px);
  font-weight: 900;
  margin-bottom: 18px;
  letter-spacing: -1px;
  line-height: 1.2;
}
.about-text p {
  color: var(--ink-soft);
  margin-bottom: 16px;
  font-size: 16px;
}
.about-visual {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}
.value-card {
  border-radius: 18px;
  padding: 24px;
  box-shadow: var(--shadow);
}
.value-card:nth-child(1) { background: linear-gradient(135deg, #fff5cc, #ffe1a8); }
.value-card:nth-child(2) { background: linear-gradient(135deg, #ffd1e0, #ffb3d1); transform: translateY(20px); }
.value-card:nth-child(3) {
  background: linear-gradient(135deg, #d4f5c8, #b8eba0);
  grid-column: span 2;
}
.value-card .ico { font-size: 36px; line-height: 1; }
.value-card h4 { font-size: 17px; margin: 10px 0 6px; font-weight: 800; }
.value-card p { font-size: 13px; color: var(--ink-soft); margin: 0; }

/* ============ Contact ============ */
.contact { padding: 100px 0; }
.contact-card {
  background: linear-gradient(135deg, #ff4e8a 0%, #a060ff 60%, #2ec5f1 100%);
  border-radius: 32px;
  padding: 60px 40px;
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.contact-card::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 15% 20%, rgba(255,205,60,0.32), transparent 42%),
    radial-gradient(circle at 85% 80%, rgba(126,217,87,0.32), transparent 42%);
}
.contact-card > * { position: relative; }
.contact-card h2 {
  font-size: clamp(30px, 4vw, 42px);
  font-weight: 900;
  margin-bottom: 14px;
  letter-spacing: -1px;
}
.contact-card > p { font-size: 17px; opacity: 0.95; margin-bottom: 28px; }
.contact-email {
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff;
  color: var(--pink);
  font-size: clamp(16px, 2.4vw, 22px);
  font-weight: 800;
  padding: 16px 32px;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 14px 30px rgba(0,0,0,0.2);
  transition: transform 0.15s ease;
  word-break: break-all;
}
.contact-email:hover { transform: translateY(-3px); }
.contact-socials {
  display: flex; gap: 14px; justify-content: center;
  margin-top: 28px;
  flex-wrap: wrap;
}
.contact-socials a {
  width: 46px; height: 46px;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.18);
  border: 2px solid rgba(255,255,255,0.4);
  border-radius: 50%;
  color: #fff; text-decoration: none;
  font-size: 20px;
  transition: 0.2s;
}
.contact-socials a:hover {
  background: #fff; color: var(--pink); transform: translateY(-3px);
}

/* ============ Footer ============ */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.7);
  padding: 40px 0;
}
.footer-inner {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 16px;
}
.footer-brand {
  color: #fff; font-weight: 800;
  display: flex; align-items: center; gap: 10px;
}
.footer-links {
  display: flex; gap: 22px;
  font-size: 14px;
}
.footer-links a {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s ease;
}
.footer-links a:hover { color: #fff; }

/* ============ Responsive ============ */
@media (max-width: 820px) {
  .nav-toggle { display: flex; }
  .main-nav {
    position: absolute; top: 72px; left: 0; right: 0;
    background: var(--cream);
    flex-direction: column;
    padding: 16px;
    gap: 4px;
    border-bottom: 1px solid rgba(43, 26, 61, 0.08);
    transform: translateY(-160%);
    transition: transform 0.3s ease;
    box-shadow: 0 12px 30px rgba(43,26,61,0.08);
  }
  .main-nav.open { transform: translateY(0); }
  .main-nav a { padding: 14px 18px; }
  .about-grid { grid-template-columns: 1fr; gap: 36px; }
}
@media (max-width: 540px) {
  .hero { padding: 90px 0 130px; }
  .games, .about, .contact { padding: 70px 0; }
  .contact-card { padding: 44px 22px; }
  .footer-inner { flex-direction: column; text-align: center; }
}

/* ============ Legal pages ============ */
.page-hero {
  background: linear-gradient(135deg, #ff4e8a 0%, #a060ff 45%, #2ec5f1 100%);
  color: #fff;
  padding: 90px 0 70px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(255,205,60,0.3), transparent 45%),
    radial-gradient(circle at 80% 70%, rgba(126,217,87,0.28), transparent 45%);
}
.page-hero > .container { position: relative; }
.page-hero h1 {
  font-size: clamp(36px, 6vw, 56px);
  font-weight: 900;
  letter-spacing: -1px;
  margin: 10px 0 8px;
}
.page-hero .meta { opacity: 0.92; font-size: 15px; }

.legal { padding: 70px 0 90px; background: var(--cream); }
.legal-inner { max-width: 820px; }
.legal .lead {
  font-size: 17px;
  color: var(--ink);
  padding: 18px 22px;
  background: rgba(255, 78, 138, 0.07);
  border-left: 4px solid var(--pink);
  border-radius: 10px;
  margin-bottom: 24px;
}
.legal h2 {
  font-size: 24px;
  font-weight: 800;
  margin: 36px 0 12px;
  color: var(--ink);
  letter-spacing: -0.3px;
}
.legal h2:first-child { margin-top: 0; }
.legal h3 {
  font-size: 18px;
  font-weight: 700;
  margin: 22px 0 10px;
  color: var(--ink);
}
.legal p, .legal li {
  color: var(--ink-soft);
  font-size: 16px;
  margin-bottom: 12px;
}
.legal ul, .legal ol { padding-left: 22px; margin-bottom: 16px; }
.legal li { margin-bottom: 6px; }
.legal a {
  color: var(--pink);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.legal a:hover { color: var(--hot); }
.legal strong { color: var(--ink); }
.legal-back {
  display: inline-block;
  margin-top: 30px;
  padding: 12px 24px;
  background: var(--ink);
  color: #fff;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  transition: transform 0.15s ease, background 0.15s ease;
}
.legal-back:hover { transform: translateX(-3px); background: var(--pink); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
