/* ===== 九游体育 (JIUYOU) 完整样式表 ===== */
/* 作者: 资深UI设计师 / 前端工程师 */
/* 版本: 1.0 (响应式 + 暗色模式 + 动画) */

/* === 基础重置与变量 === */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* 主色调 - 深蓝 + 红 + 金渐变 */
  --primary: #1a2a6c;
  --secondary: #b21f1f;
  --accent: #fdbb2d;
  --bg: #f4f7fc;
  --card-bg: #ffffff;
  --text: #1f2937;
  --text-light: #6b7280;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  --radius: 20px;
  --glass: rgba(255, 255, 255, 0.6);
  --glass-border: rgba(255, 255, 255, 0.3);
  --gradient: linear-gradient(135deg, #1a2a6c, #b21f1f, #fdbb2d);
  --gradient-hero: linear-gradient(135deg, #1a2a6c 0%, #b21f1f 50%, #fdbb2d 100%);
  --nav-bg: rgba(26, 42, 108, 0.95);
  --footer-bg: #0f172a;
  --badge-bg: #eef2ff;
  --transition: 0.3s ease;
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* 暗色模式 */
body.dark {
  --bg: #0f172a;
  --card-bg: #1e293b;
  --text: #e2e8f0;
  --text-light: #94a3b8;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  --glass: rgba(30, 41, 59, 0.7);
  --glass-border: rgba(255, 255, 255, 0.1);
  --nav-bg: rgba(15, 23, 42, 0.95);
  --badge-bg: #1e293b;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  transition: background var(--transition), color var(--transition);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--secondary);
}

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

ul {
  list-style: none;
}

/* === 工具类 === */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 80px 0;
}

.section-title {
  font-size: 2.2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 15px;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-subtitle {
  text-align: center;
  color: var(--text-light);
  max-width: 700px;
  margin: 0 auto 50px;
  font-size: 1.1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 15px rgba(26, 42, 108, 0.3);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(26, 42, 108, 0.4);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
  box-shadow: none;
}

.btn-outline:hover {
  background: var(--primary);
  color: #fff;
}

.glass {
  background: var(--glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
}

.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 30px;
  transition: all var(--transition);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.text-gradient {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.badge {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 500;
  background: var(--badge-bg);
  color: var(--primary);
  margin-bottom: 12px;
}

/* === 导航栏 === */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--nav-bg);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  transition: background var(--transition);
}

nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.logo {
  font-size: 1.8rem;
  font-weight: 800;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo svg {
  width: 36px;
  height: 36px;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 30px;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 6px 0;
  position: relative;
  transition: color var(--transition);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
  color: #fff;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 15px;
}

.theme-toggle {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #fff;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: background var(--transition);
}

.theme-toggle:hover {
  background: rgba(255, 255, 255, 0.25);
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
}

/* === Hero 区域 === */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background: var(--gradient-hero);
  padding-top: 70px;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 320'%3E%3Cpath fill='rgba(255,255,255,0.05)' d='M0,160L60,176C120,192,240,224,360,213.3C480,203,600,149,720,138.7C840,128,960,160,1080,176C1200,192,1320,192,1380,192L1440,192L1440,320L1380,320C1320,320,1200,320,1080,320C960,320,840,320,720,320C600,320,480,320,360,320C240,320,120,320,60,320L0,320Z'/%3E%3C/svg%3E") no-repeat bottom;
  background-size: cover;
  opacity: 0.3;
}

.hero .container {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 20px;
  line-height: 1.2;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

.hero h1 span {
  display: block;
  font-size: 1.2rem;
  font-weight: 400;
  opacity: 0.9;
  margin-top: 10px;
}

.hero p {
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto 40px;
  opacity: 0.9;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-buttons .btn {
  background: #fff;
  color: var(--primary);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.hero-buttons .btn:hover {
  background: var(--accent);
  color: #1a2a6c;
}

.hero-buttons .btn-outline {
  border-color: #fff;
  color: #fff;
  background: transparent;
}

.hero-buttons .btn-outline:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

/* === Banner 轮播 === */
.banner-carousel {
  position: relative;
  width: 100%;
  max-width: 1000px;
  margin: 40px auto 0;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.banner-slides {
  display: flex;
  transition: transform 0.6s ease;
}

.banner-slide {
  min-width: 100%;
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient);
  color: #fff;
  padding: 40px;
  text-align: center;
}

.banner-slide h3 {
  font-size: 2rem;
  margin-bottom: 15px;
}

.banner-slide p {
  font-size: 1.1rem;
  max-width: 500px;
}

.banner-dots {
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 20px;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
}

.banner-dots span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all var(--transition);
}

.banner-dots span.active {
  background: #fff;
  transform: scale(1.3);
}

/* === About / Intro === */
.about-intro {
  background: var(--bg);
}

.about-intro .grid-2 {
  align-items: center;
}

.about-intro .card {
  padding: 40px;
}

.about-intro h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}

.about-intro p {
  color: var(--text-light);
  margin-bottom: 20px;
}

/* === Stats 统计 === */
.stats {
  background: var(--gradient);
  color: #fff;
  padding: 60px 0;
}

.stats .grid-4 {
  text-align: center;
}

.stats .stat-item h3 {
  font-size: 2.8rem;
  font-weight: 800;
  margin-bottom: 5px;
}

.stats .stat-item p {
  opacity: 0.85;
  font-size: 1rem;
}

/* === Products 产品 === */
.products .grid-3 .card {
  text-align: center;
}

.products .card svg {
  width: 60px;
  height: 60px;
  margin-bottom: 20px;
}

.products .card h3 {
  font-size: 1.4rem;
  margin-bottom: 12px;
}

.products .card p {
  color: var(--text-light);
  font-size: 0.95rem;
}

/* === Advantages 优势 === */
.advantages .grid-2 {
  align-items: center;
}

.advantages .card {
  padding: 40px;
}

.advantages ul {
  list-style: none;
}

.advantages ul li {
  padding: 10px 0;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.advantages ul li:last-child {
  border-bottom: none;
}

.advantages ul li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 700;
  font-size: 1.2rem;
}

/* === Team 团队 === */
.team .grid-4 .card {
  text-align: center;
}

.team .card .avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--gradient);
  margin: 0 auto 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: #fff;
  font-weight: 700;
}

.team .card h4 {
  margin-bottom: 5px;
}

.team .card p {
  color: var(--text-light);
  font-size: 0.9rem;
}

/* === Testimonials 评价 === */
.testimonials {
  background: var(--bg);
}

.testimonials .grid-3 .card {
  position: relative;
}

.testimonials .card::before {
  content: '"';
  font-size: 4rem;
  position: absolute;
  top: 10px;
  left: 20px;
  color: var(--accent);
  opacity: 0.2;
  font-family: Georgia, serif;
}

.testimonials .card p {
  font-style: italic;
  margin-bottom: 15px;
  color: var(--text-light);
}

.testimonials .card .author {
  font-weight: 600;
  color: var(--text);
}

/* === FAQ === */
.faq .faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--card-bg);
  border-radius: 12px;
  margin-bottom: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  overflow: hidden;
  transition: all var(--transition);
}

.faq-item .faq-question {
  padding: 18px 24px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  font-size: 1.05rem;
}

.faq-item .faq-question span {
  transition: transform var(--transition);
}

.faq-item.active .faq-question span {
  transform: rotate(180deg);
}

.faq-item .faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s ease;
  padding: 0 24px;
  color: var(--text-light);
}

.faq-item.active .faq-answer {
  max-height: 300px;
  padding: 0 24px 18px;
}

/* === Contact 联系 === */
.contact .grid-2 {
  align-items: start;
}

.contact .card {
  padding: 40px;
}

.contact .info-item {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
  align-items: center;
}

.contact .info-item svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--primary);
}

/* === Footer 页脚 === */
footer {
  background: var(--footer-bg);
  color: rgba(255, 255, 255, 0.7);
  padding: 60px 0 30px;
}

footer .grid-4 h4 {
  color: #fff;
  margin-bottom: 20px;
  font-size: 1.1rem;
}

footer ul {
  list-style: none;
}

footer ul li {
  margin-bottom: 10px;
}

footer ul li a {
  color: rgba(255, 255, 255, 0.6);
  transition: color var(--transition);
}

footer ul li a:hover {
  color: var(--accent);
}

footer .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 40px;
  padding-top: 20px;
  text-align: center;
  font-size: 0.9rem;
}

/* === Scroll to top === */
.scroll-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  border: none;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  z-index: 999;
  transition: all var(--transition);
}

.scroll-top.show {
  display: flex;
}

.scroll-top:hover {
  transform: scale(1.1);
}

/* === Search Modal === */
.search-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(10px);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
}

.search-modal.active {
  display: flex;
}

.search-modal .search-box {
  background: var(--card-bg);
  padding: 30px;
  border-radius: var(--radius);
  width: 90%;
  max-width: 500px;
}

.search-modal input {
  width: 100%;
  padding: 15px 20px;
  border: 2px solid var(--primary);
  border-radius: 12px;
  font-size: 1.1rem;
  background: var(--bg);
  color: var(--text);
  outline: none;
}

.search-modal .search-results {
  margin-top: 20px;
  max-height: 300px;
  overflow-y: auto;
}

.search-modal .search-results div {
  padding: 12px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  cursor: pointer;
  transition: background var(--transition);
}

.search-modal .search-results div:hover {
  background: var(--badge-bg);
}

.search-modal .close-search {
  position: absolute;
  top: 20px;
  right: 30px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
}

/* === 滚动动画 === */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.delay-1 {
  transition-delay: 0.1s;
}

.delay-2 {
  transition-delay: 0.2s;
}

.delay-3 {
  transition-delay: 0.3s;
}

.delay-4 {
  transition-delay: 0.4s;
}

/* === 响应式布局 === */
@media (max-width: 992px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }

  .hero h1 {
    font-size: 2.5rem;
  }
}

@media (max-width: 768px) {
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: var(--nav-bg);
    flex-direction: column;
    padding: 20px;
    gap: 15px;
  }

  .nav-links.active {
    display: flex;
  }

  .mobile-toggle {
    display: block;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero h1 span {
    font-size: 1rem;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .stats .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .banner-slide {
    min-height: 250px;
    padding: 20px;
  }

  .banner-slide h3 {
    font-size: 1.4rem;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.6rem;
  }

  .container {
    padding: 0 15px;
  }

  .section {
    padding: 50px 0;
  }

  .btn {
    padding: 12px 24px;
    font-size: 0.9rem;
  }
}