/* 全局重置与基础样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg-gradient);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.7;
  transition: background 0.4s ease, color 0.4s ease;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

a:hover {
  color: var(--accent-light);
}

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

/* 容器 */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* 主题变量 */
:root {
  --primary: #0a0e27;
  --primary-light: #1a1f45;
  --accent: #f0b429;
  --accent-light: #f7d56e;
  --accent-dark: #c9940a;
  --text: #ffffff;
  --text-muted: #b0b5c9;
  --glass: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.1);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  --radius: 20px;
  --radius-sm: 12px;
  --transition: 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --bg-gradient: linear-gradient(135deg, #0a0e27 0%, #1a1f45 50%, #0f142e 100%);
  --card-bg: rgba(255, 255, 255, 0.04);
  --nav-bg: rgba(10, 14, 39, 0.85);
}

[data-theme="light"] {
  --primary: #f5f7fa;
  --primary-light: #ffffff;
  --text: #1a1f45;
  --text-muted: #5a6075;
  --glass: rgba(0, 0, 0, 0.04);
  --glass-border: rgba(0, 0, 0, 0.08);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  --bg-gradient: linear-gradient(135deg, #f5f7fa 0%, #ffffff 50%, #eef1f5 100%);
  --card-bg: rgba(0, 0, 0, 0.02);
  --nav-bg: rgba(245, 247, 250, 0.9);
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--glass-border);
  transition: background 0.4s ease, border-color 0.4s ease;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 24px;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: 1px;
}

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

nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

nav a {
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative;
}

nav a:hover,
nav a.active {
  color: var(--accent);
  background: var(--glass);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 8px;
}

.nav-toggle span {
  width: 28px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.mobile-menu {
  display: none;
  position: fixed;
  top: 72px;
  left: 0;
  right: 0;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  padding: 24px;
  flex-direction: column;
  gap: 12px;
  border-bottom: 1px solid var(--glass-border);
  z-index: 999;
}

.mobile-menu a {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 16px;
}

.theme-toggle {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  color: var(--text);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  font-size: 18px;
}

.theme-toggle:hover {
  background: var(--glass-border);
}

/* Hero */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 72px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg svg {
  width: 100%;
  height: 100%;
}

.hero-content {
  position: relative;
  z-index: 1;
  width: 100%;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-text h1 {
  font-size: 56px;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 24px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-text p {
  font-size: 18px;
  color: var(--text-muted);
  margin-bottom: 32px;
  max-width: 540px;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: var(--primary);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(240, 180, 41, 0.3);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--glass-border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

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

.hero-visual svg {
  width: 100%;
  max-width: 500px;
  height: auto;
  filter: drop-shadow(0 20px 60px rgba(240, 180, 41, 0.15));
}

/* Sections */
section {
  padding: 100px 0;
  position: relative;
}

.section-title {
  text-align: center;
  margin-bottom: 60px;
}

.section-title h2 {
  font-size: 40px;
  font-weight: 800;
  margin-bottom: 16px;
}

.section-title p {
  color: var(--text-muted);
  font-size: 16px;
  max-width: 600px;
  margin: 0 auto;
}

.section-tag {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 50px;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent);
  margin-bottom: 16px;
}

/* Cards */
.card {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 32px;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  backdrop-filter: blur(10px);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

.card-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--glass);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.card-icon svg {
  width: 28px;
  height: 28px;
}

.card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
}

.card p {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.7;
}

/* Grids */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.grid-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 32px;
}

.grid-4 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 24px;
}

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

.stat-card {
  text-align: center;
  padding: 40px 24px;
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
}

.stat-number {
  font-size: 48px;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 8px;
}

.stat-label {
  color: var(--text-muted);
  font-size: 14px;
}

/* Banner Carousel */
.carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
}

.carousel-track {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.carousel-slide {
  min-width: 100%;
  padding: 60px 40px;
  display: flex;
  align-items: center;
  gap: 40px;
}

.carousel-slide-content {
  flex: 1;
}

.carousel-slide-content h3 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 16px;
}

.carousel-slide-content p {
  color: var(--text-muted);
  margin-bottom: 20px;
}

.carousel-slide-visual {
  flex: 1;
  display: flex;
  justify-content: center;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 20px;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--glass-border);
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  border: none;
}

.carousel-dot.active {
  background: var(--accent);
  width: 30px;
  border-radius: 5px;
}

/* FAQ */
.faq-item {
  border-bottom: 1px solid var(--glass-border);
  padding: 16px 0;
}

.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  padding: 8px 0;
  background: none;
  border: none;
  color: var(--text);
  width: 100%;
  text-align: left;
}

.faq-question svg {
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  width: 20px;
  height: 20px;
}

.faq-item.open .faq-question svg {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.8;
}

.faq-item.open .faq-answer {
  max-height: 300px;
  padding: 8px 0 16px;
}

/* Testimonials */
.testimonial-card {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 32px;
}

.testimonial-stars {
  color: var(--accent);
  margin-bottom: 12px;
  font-size: 18px;
}

.testimonial-text {
  font-style: italic;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.testimonial-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--glass);
  display: flex;
  align-items: center;
  justify-content: center;
}

.testimonial-name {
  font-weight: 600;
  font-size: 14px;
}

.testimonial-role {
  font-size: 12px;
  color: var(--text-muted);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.contact-info h3 {
  font-size: 24px;
  margin-bottom: 16px;
}

.contact-info p {
  color: var(--text-muted);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--glass-border);
  background: var(--card-bg);
  color: var(--text);
  font-size: 14px;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  margin-bottom: 16px;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.contact-form textarea {
  min-height: 120px;
  resize: vertical;
}

/* Footer */
footer {
  background: var(--primary);
  border-top: 1px solid var(--glass-border);
  padding: 60px 0 30px;
}

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

.footer-brand p {
  color: var(--text-muted);
  font-size: 13px;
  margin-top: 12px;
}

.footer-col h4 {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-col a {
  display: block;
  padding: 4px 0;
  font-size: 13px;
  color: var(--text-muted);
}

.footer-col a:hover {
  color: var(--accent);
}

.footer-bottom {
  border-top: 1px solid var(--glass-border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 12px;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

/* Breadcrumb */
.breadcrumb {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 16px 0;
  font-size: 13px;
  color: var(--text-muted);
}

.breadcrumb a {
  color: var(--text-muted);
}

.breadcrumb a:hover {
  color: var(--accent);
}

.breadcrumb span {
  color: var(--accent);
}

/* Search */
.search-bar {
  display: flex;
  align-items: center;
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  padding: 4px 4px 4px 20px;
  max-width: 400px;
}

.search-bar input {
  flex: 1;
  background: none;
  border: none;
  color: var(--text);
  font-size: 14px;
  padding: 10px 0;
  outline: none;
}

.search-bar button {
  background: var(--accent);
  border: none;
  border-radius: 50px;
  padding: 10px 24px;
  color: var(--primary);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  font-size: 14px;
}

.search-bar button:hover {
  background: var(--accent-light);
}

/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--primary);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  z-index: 999;
  box-shadow: 0 4px 20px rgba(240, 180, 41, 0.3);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  transform: translateY(-4px);
}

/* Animations */
.fade-up {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

/* Responsive */
@media (max-width: 1024px) {
  .grid-4 {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }

  .hero-text h1 {
    font-size: 36px;
  }

  .hero-text p {
    margin: 0 auto 32px;
  }

  .hero-buttons {
    justify-content: center;
  }

  .hero-visual {
    display: none;
  }

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

  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }

  .section-title h2 {
    font-size: 28px;
  }

  .carousel-slide {
    flex-direction: column;
    text-align: center;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  nav a {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .mobile-menu.active {
    display: flex;
  }

  header .theme-toggle {
    display: none;
  }

  .mobile-menu .theme-toggle {
    display: flex;
    margin-top: 8px;
  }

  .search-bar {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .hero-text h1 {
    font-size: 28px;
  }

  section {
    padding: 60px 0;
  }
}