/* ===== 基础重置与变量定义 ===== */
:root {
  --header-bg: rgba(0, 0, 0, 0.95);
  --header-text: #ffffff;
  --header-accent: #00ff88;
  --header-highlight: rgba(255, 255, 255, 0.1);
  --transition-speed: 0.3s;
  --icon-color: #ffd700; /* 设置图标颜色为金色 */
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

/* ===== 核心导航结构 ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  z-index: 1000;
  background: linear-gradient(180deg, #003366, #0077CC, #00AAFF); /* 上深下浅的渐变 */
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              background var(--transition-speed),
              box-shadow var(--transition-speed);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(8px);
}

/* ===== 桌面版样式 ===== */
.header nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  height: 100%;
  margin: 0 auto;
  padding: 0 2rem;
}

.logo-container {
  display: flex;
  align-items: center;
  height: 100%;
}

.logo {
  height: calc(72px * 0.6);
  width: auto;
  transition: transform 0.4s ease-out;
}

.nav-center {
  display: flex;
  gap: 2rem;
}

.nav__link {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--header-text);
  font-size: 1.05rem;
  font-weight: 500;
  text-decoration: none;
  transition: color var(--transition-speed);
}

.nav__link i {
  font-size: 1.2rem;
  color: var(--icon-color);
}

.nav__link:hover,
.nav__link:focus {
  color: var(--header-accent);
}

.nav__link:hover i,
.nav__link:focus i {
  color: var(--icon-color);
}

.nav-right {
  display: flex;
  gap: 1.2rem;
}

.btn--icon {
  --size: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--size);
  height: var(--size);
  border-radius: 50%;
  border: 1px solid var(--header-highlight);
  transition: all var(--transition-speed);
  text-decoration: none;
}

.btn--icon i {
  font-size: 1.6rem;
  color: #ffffff;
}

.btn--icon:hover {
  transform: translateY(-2px) scale(1.08);
  border-color: #ffd700;
}

.btn--icon:hover i {
  color: #ffd700;
}

/* ===== 移动端样式 ===== */
.header.mobile .nav-center {
  flex-direction: row; /* 确保导航文字横向显示 */
  justify-content: space-around;
  align-items: center;
  gap: 1rem; /* 控制导航项间距 */
}

.header.mobile .nav__link {
  font-size: 1rem;
  padding: 0 10px;
  flex-direction: row; /* 确保移动端文字横向排列 */
}

/* 隐藏移动端社交按钮 */
.header.mobile .nav-right {
  display: none;
}

/* ===== 交互状态 ===== */
.header.hidden {
  transform: translateY(-100%);
}

.header.scrolled {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

/* ===== 响应式调整 ===== */
@media (max-width: 1024px) {
  .header {
    height: 72px;
  }
  .logo {
    height: calc(72px * 0.8);
  }
}

@media (max-width: 768px) {
  .header {
    height: 72px;
  }
  .nav-center {
    gap: 1.5rem;
  }

  .content-section {
    flex-direction: column; /* 确保内容在移动端保持纵向排列 */
    padding: 20px 15px;
  }

  .content-left, .content-right {
    max-width: 100%;
    padding-top: 20px;
  }

  .hero {
    padding: 20px;
    height: auto;
  }
}

@media (max-width: 480px) {
  .header {
    height: 72px;
  }
  .nav-center {
    gap: 1rem;
  }
}

/* Y9 brand fit overrides */
.y9-logo,
.section-logo {
  width: min(220px, 46vw) !important;
  max-width: 220px !important;
  max-height: 220px !important;
  height: auto !important;
  object-fit: contain !important;
}
.hero-content {
  max-width: 320px !important;
}
.footer-logo {
  max-width: 220px !important;
  max-height: 120px !important;
  object-fit: contain !important;
}
@media (max-width: 768px) {
  .y9-logo,
  .section-logo {
    width: min(150px, 38vw) !important;
    max-width: 150px !important;
    max-height: 150px !important;
  }
  .logo {
    height: 56px !important;
    max-width: 76px !important;
    object-fit: contain !important;
  }
  .header.mobile .nav-center {
    gap: .32rem !important;
  }
  .header.mobile .nav__link {
    font-size: .82rem !important;
    padding: 0 3px !important;
    white-space: nowrap !important;
  }
}

/* Y9 UI structure fixes */
.header { overflow: hidden !important; }
.header nav { max-width: 100% !important; }
.nav__link span { white-space: nowrap !important; word-break: keep-all !important; line-height: 1.15 !important; }
.hero-content { z-index: 20 !important; margin-top: 36px !important; }
.game-icon { z-index: 3 !important; opacity: .86 !important; }
.game-icon img { filter: none !important; }
.features { padding-top: 78px !important; }
.feature-card { background: rgba(2, 12, 30, .86) !important; }
@media (max-width: 900px) {
  .header { height: 66px !important; }
  .header nav { padding: 0 8px !important; gap: 6px !important; justify-content: flex-start !important; }
  .nav-left { flex: 0 0 auto !important; }
  .logo { height: 52px !important; width: 52px !important; max-width: 52px !important; border-radius: 14px !important; object-fit: contain !important; }
  .nav-center { flex: 1 1 auto !important; min-width: 0 !important; display: flex !important; justify-content: space-around !important; gap: 4px !important; }
  .header.mobile .nav__link, .nav__link { flex-direction: column !important; gap: 2px !important; padding: 0 2px !important; min-width: 42px !important; font-size: 12px !important; line-height: 1.05 !important; }
  .nav__link i { font-size: 16px !important; }
  .nav__link span { display: block !important; max-width: 3.8em !important; white-space: normal !important; word-break: keep-all !important; text-align: center !important; line-height: 1.1 !important; }
  .nav-right { display: none !important; }
  .hero { min-height: 100svh !important; padding: 86px 14px 92px !important; align-items: flex-start !important; }
  .hero-content { margin-top: 76px !important; gap: 14px !important; }
  .y9-logo { width: min(210px, 62vw) !important; max-width: 210px !important; max-height: 150px !important; }
  .start-game-btn { margin-top: 8px !important; }
  .game-icon { opacity: .72 !important; }
  .features { min-height: 100svh !important; padding: 92px 12px 92px !important; }
  .featurescontainer { gap: 16px !important; }
  .feature-card { min-height: 150px !important; padding: 16px 12px !important; }
  .mobile-nav, .powered-by { z-index: 1200 !important; }
}
@media (min-width: 901px) {
  .header.mobile .nav__link, .nav__link { flex-direction: row !important; }
  .nav__link span { max-width: none !important; }
  .hero { padding-top: 110px !important; }
}

/* Y9 button/link interaction fixes */
.anchor-target{position:absolute;top:0;left:0;width:1px;height:1px;pointer-events:none}#games,#sports,#esports,#live,#slots,#chess,#lottery,#fishing,#seo-guide,#faq,#security{scroll-margin-top:90px}.nav__link.is-active,.btn--icon.is-active{color:#ffd700!important;filter:drop-shadow(0 0 8px rgba(255,215,0,.5))}.image-link,.nav-link,.quick-links a,.start-game-btn{cursor:pointer}.image-link:active,.nav-link:active,.quick-links a:active,.start-game-btn:active{transform:scale(.98)}.carousel-item{scroll-margin-top:110px}.carousel-item:target .image-wrapper{outline:3px solid rgba(255,217,74,.75);outline-offset:6px;border-radius:18px}

/* Y9 final responsive hero carousel fix */
body #app main > .hero.hero-cover-carousel{box-sizing:border-box!important;position:relative!important;width:100vw!important;max-width:100vw!important;height:auto!important;min-height:0!important;aspect-ratio:718/304!important;margin:80px 0 0 calc(50% - 50vw)!important;padding:0!important;display:block!important;overflow:hidden!important;background:#050b18!important}.hero-cover-carousel .hero-slider{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;overflow:hidden!important}.hero-cover-carousel .hero-slide{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;display:block!important;object-fit:cover!important;object-position:center center!important;border:0!important;border-radius:0!important;margin:0!important;padding:0!important;opacity:0;transform:none!important;transition:opacity .35s ease!important}.hero-cover-carousel .hero-slide.is-active{opacity:1!important}.hero-cover-carousel .hero-cover-overlay{position:absolute!important;inset:0!important;background:linear-gradient(180deg,rgba(0,0,0,.04),rgba(0,0,0,.16))!important;pointer-events:none!important}.hero-cover-carousel .hero-cta-only{position:absolute!important;left:0!important;right:0!important;bottom:clamp(10px,2.4vw,26px)!important;top:auto!important;z-index:4!important;display:flex!important;justify-content:center!important;align-items:center!important;margin:0!important;padding:0!important;transform:none!important}.hero-cover-carousel .start-game-btn{margin:0!important;min-width:clamp(160px,24vw,260px)!important;padding:clamp(9px,1.4vw,15px) clamp(20px,3vw,38px)!important;font-size:clamp(18px,2.4vw,30px)!important;line-height:1.15!important;background:rgba(2,10,24,.38)!important;backdrop-filter:blur(4px)!important}.hero-cover-carousel::before,.hero-cover-carousel .y9-starfield{display:none!important}@media(max-width:900px){body #app main > .hero.hero-cover-carousel{margin-top:66px!important;aspect-ratio:718/304!important}.hero-cover-carousel .hero-cta-only{bottom:8px!important}.hero-cover-carousel .start-game-btn{min-width:150px!important;font-size:18px!important;padding:8px 18px!important}}@media(max-width:420px){body #app main > .hero.hero-cover-carousel{margin-top:66px!important}.hero-cover-carousel .hero-cta-only{bottom:6px!important}.hero-cover-carousel .start-game-btn{min-width:136px!important;font-size:16px!important;padding:7px 16px!important}}

/* Y9 button below hero cover */
body #app main > .hero.hero-cover-carousel{display:flex!important;flex-direction:column!important;height:auto!important;aspect-ratio:auto!important;margin:80px 0 0 calc(50% - 50vw)!important;padding:0 0 clamp(14px,2vw,24px)!important;background:#050b18!important;overflow:visible!important}.hero-cover-carousel .hero-slider{position:relative!important;inset:auto!important;width:100%!important;height:auto!important;aspect-ratio:718/304!important;overflow:hidden!important;flex:0 0 auto!important}.hero-cover-carousel .hero-cover-overlay{display:none!important}.hero-cover-carousel .hero-cta-only{position:relative!important;left:auto!important;right:auto!important;bottom:auto!important;top:auto!important;z-index:4!important;width:100%!important;margin:clamp(10px,1.8vw,18px) 0 0!important;padding:0!important;display:flex!important;justify-content:center!important;align-items:center!important;transform:none!important}.hero-cover-carousel .hero-cta-only .start-game-btn{position:relative!important;margin:0!important;background:rgba(2,10,24,.86)!important;backdrop-filter:none!important;box-shadow:0 0 0 2px rgba(255,217,74,.9),0 10px 28px rgba(0,0,0,.25)!important}@media(max-width:900px){body #app main > .hero.hero-cover-carousel{margin-top:66px!important;padding-bottom:14px!important}.hero-cover-carousel .hero-cta-only{margin-top:10px!important}}@media(max-width:420px){body #app main > .hero.hero-cover-carousel{padding-bottom:12px!important}.hero-cover-carousel .hero-cta-only{margin-top:8px!important}}

/* Y9 centered CTA below carousel */
body #app main > .hero.hero-cover-carousel > .hero-cta-only{box-sizing:border-box!important;position:relative!important;left:50%!important;right:auto!important;bottom:auto!important;top:auto!important;width:100vw!important;max-width:100vw!important;margin:clamp(10px,1.8vw,18px) 0 0!important;padding:0 12px!important;transform:translateX(-50%)!important;display:flex!important;justify-content:center!important;align-items:center!important;text-align:center!important}.hero-cover-carousel > .hero-cta-only > .start-game-btn{display:inline-flex!important;align-items:center!important;justify-content:center!important;text-align:center!important;white-space:nowrap!important;margin-left:auto!important;margin-right:auto!important;min-width:clamp(150px,24vw,260px)!important;width:auto!important;max-width:calc(100vw - 32px)!important}@media(max-width:480px){body #app main > .hero.hero-cover-carousel > .hero-cta-only{padding:0 10px!important;margin-top:8px!important}.hero-cover-carousel > .hero-cta-only > .start-game-btn{min-width:150px!important;max-width:calc(100vw - 24px)!important}}

/* Y9 remove X decoration and compact band */
.band{height:auto!important;min-height:0!important;padding:clamp(36px,6vw,72px) clamp(16px,5vw,56px)!important;background:linear-gradient(180deg,#020814,#06142d)!important}.band-container{width:min(1180px,100%)!important;height:auto!important;min-height:0!important;display:grid!important;grid-template-columns:minmax(180px,.75fr) minmax(280px,1.25fr)!important;gap:clamp(18px,4vw,48px)!important;align-items:center!important;padding:0!important}.band-center,.x-text,.diagonal,.diagonal-left,.diagonal-right{display:none!important}.band-left{position:relative!important;z-index:2!important}.band-right{position:relative!important;z-index:2!important}.band-right p{max-width:760px!important;margin:0!important;line-height:1.75!important}@media(max-width:768px){.band{padding:34px 16px!important}.band-container{grid-template-columns:1fr!important;gap:18px!important;text-align:left!important}.band-left h2{font-size:clamp(24px,7vw,36px)!important}.band-right p{font-size:15px!important;line-height:1.75!important}}
