/* 乐动·LDSports (中国)体育官网 - style.css */
/* 全局重置与基础样式 */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-dark: #1a2a6c;
  --primary-red: #b21f1f;
  --primary-gold: #fdbb2d;
  --bg-light: #f5f7fa;
  --bg-dark: #1a1a2e;
  --text-light: #333;
  --text-dark: #e0e0e0;
  --card-bg-light: rgba(255, 255, 255, 0.8);
  --card-bg-dark: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.2);
  --shadow-light: 0 8px 32px rgba(0, 0, 0, 0.1);
  --shadow-dark: 0 8px 32px rgba(0, 0, 0, 0.3);
  --transition-speed: 0.3s;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-light);
  background: var(--bg-light);
  transition: background var(--transition-speed), color var(--transition-speed);
}

body.dark-mode {
  background: var(--bg-dark);
  color: var(--text-dark);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 60px 0;
}

.bg-dark {
  background: #f0f2f5;
}

body.dark-mode .bg-dark {
  background: #16213e;
}

/* 标题样式 */
h1 {
  font-size: 2.5rem;
  margin-bottom: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 2rem;
  margin-bottom: 30px;
  text-align: center;
  position: relative;
  font-weight: 700;
}

h2::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-dark), var(--primary-red));
  margin: 10px auto;
  border-radius: 2px;
}

h3 {
  font-size: 1.5rem;
  margin-bottom: 15px;
  font-weight: 600;
}

p {
  margin-bottom: 15px;
}

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

a:hover {
  color: var(--primary-red);
}

/* 卡片组件 - 毛玻璃效果 & 圆角 */
.card {
  background: var(--card-bg-light);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 16px;
  padding: 30px;
  box-shadow: var(--shadow-light);
  transition: transform var(--transition-speed), box-shadow var(--transition-speed);
  border: 1px solid var(--glass-border);
}

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

body.dark-mode .card {
  background: var(--card-bg-dark);
  box-shadow: var(--shadow-dark);
}

.glass {
  border: 1px solid var(--glass-border);
}

/* 头部导航 - 固定 + 毛玻璃 */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

body.dark-mode header {
  background: rgba(26, 26, 46, 0.95);
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-dark);
}

body.dark-mode .nav-brand {
  color: var(--text-dark);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 20px;
}

.nav-menu a {
  padding: 8px 12px;
  border-radius: 8px;
  transition: background var(--transition-speed);
  font-weight: 500;
}

.nav-menu a:hover,
.nav-menu a.active {
  background: rgba(26, 42, 108, 0.1);
}

body.dark-mode .nav-menu a:hover,
body.dark-mode .nav-menu a.active {
  background: rgba(255, 255, 255, 0.1);
}

.nav-actions {
  display: flex;
  gap: 10px;
}

.nav-actions button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: background var(--transition-speed);
  color: var(--text-light);
  display: flex;
  align-items: center;
  justify-content: center;
}

body.dark-mode .nav-actions button {
  color: var(--text-dark);
}

.nav-actions button:hover {
  background: rgba(0, 0, 0, 0.05);
}

body.dark-mode .nav-actions button:hover {
  background: rgba(255, 255, 255, 0.1);
}

#menuToggle {
  display: none;
}

/* 响应式导航 - 手机端 */
@media (max-width: 768px) {
  .nav-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  }

  body.dark-mode .nav-menu {
    background: rgba(26, 26, 46, 0.98);
  }

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

  #menuToggle {
    display: block;
  }
}

/* Hero Banner - 渐变 + 圆角 */
.hero {
  padding-top: 80px;
  position: relative;
}

.hero-banner {
  position: relative;
  overflow: hidden;
  border-radius: 0 0 30px 30px;
}

.banner-slide {
  display: none;
  position: relative;
}

.banner-slide.active {
  display: block;
  animation: fadeIn 0.8s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.banner-svg {
  width: 100%;
  height: auto;
  display: block;
}

.banner-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: white;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  width: 90%;
}

.banner-text h1,
.banner-text h2 {
  font-size: 2.5rem;
  margin-bottom: 10px;
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.banner-text p {
  font-size: 1.2rem;
  opacity: 0.9;
}

.banner-controls {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 20px;
}

.dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ccc;
  cursor: pointer;
  transition: background var(--transition-speed), transform var(--transition-speed);
}

.dot.active {
  background: var(--primary-dark);
  transform: scale(1.2);
}

body.dark-mode .dot {
  background: #555;
}

body.dark-mode .dot.active {
  background: var(--primary-red);
}

/* 网格布局 */
.about-grid,
.product-grid,
.service-grid,
.cases-grid,
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 30px;
}

/* 产品优势 */
.product-advantage {
  margin-top: 40px;
  padding: 30px;
  background: var(--card-bg-light);
  border-radius: 16px;
  backdrop-filter: blur(10px);
}

body.dark-mode .product-advantage {
  background: var(--card-bg-dark);
}

.product-advantage ul {
  list-style: none;
  padding: 0;
}

.product-advantage li {
  padding: 10px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  position: relative;
  padding-left: 20px;
}

.product-advantage li::before {
  content: '✦';
  position: absolute;
  left: 0;
  color: var(--primary-gold);
}

body.dark-mode .product-advantage li {
  border-color: rgba(255, 255, 255, 0.1);
}

/* 客户评价 */
.testimonials {
  margin-top: 40px;
}

.testimonials blockquote {
  font-style: italic;
  padding: 20px;
  border-left: 4px solid var(--primary-dark);
  margin-bottom: 20px;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 0 12px 12px 0;
  position: relative;
}

.testimonials blockquote::before {
  content: '"';
  font-size: 3rem;
  position: absolute;
  left: 10px;
  top: -10px;
  color: var(--primary-dark);
  opacity: 0.3;
}

body.dark-mode .testimonials blockquote {
  background: rgba(255, 255, 255, 0.05);
}

/* 阅读更多按钮 */
.read-more {
  display: inline-block;
  padding: 10px 20px;
  background: linear-gradient(90deg, var(--primary-dark), var(--primary-red));
  color: white;
  border-radius: 25px;
  transition: opacity var(--transition-speed), transform var(--transition-speed);
  font-weight: 500;
}

.read-more:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  color: white;
}

/* 相关推荐 */
.related-posts {
  margin-top: 40px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 16px;
  backdrop-filter: blur(10px);
}

body.dark-mode .related-posts {
  background: rgba(255, 255, 255, 0.05);
}

.related-posts ul {
  list-style: none;
}

.related-posts li {
  padding: 8px 0;
}

.related-posts a {
  font-weight: 500;
}

/* FAQ 折叠面板 */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

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

body.dark-mode .faq-item {
  background: var(--card-bg-dark);
}

.faq-question {
  width: 100%;
  padding: 18px 20px;
  background: none;
  border: none;
  text-align: left;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background var(--transition-speed);
  color: inherit;
  font-weight: 500;
}

.faq-question:hover {
  background: rgba(0, 0, 0, 0.02);
}

body.dark-mode .faq-question:hover {
  background: rgba(255, 255, 255, 0.05);
}

.faq-icon {
  font-size: 1.5rem;
  transition: transform var(--transition-speed);
  font-weight: 300;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
  padding: 0 20px;
}

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

/* 联系我们网格 */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-top: 30px;
}

/* 页脚 */
footer {
  background: var(--primary-dark);
  color: white;
  padding: 40px 20px 20px;
  margin-top: 60px;
}

body.dark-mode footer {
  background: #0f0f23;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-section h3 {
  margin-bottom: 15px;
  font-size: 1.2rem;
  position: relative;
  padding-bottom: 10px;
}

.footer-section h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 2px;
  background: var(--primary-gold);
}

.footer-section ul {
  list-style: none;
}

.footer-section li {
  margin-bottom: 8px;
}

.footer-section a {
  color: #ccc;
  transition: color var(--transition-speed);
}

.footer-section a:hover {
  color: white;
}

.footer-bottom {
  text-align: center;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  position: relative;
}

/* 返回顶部按钮 */
#backToTop {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: linear-gradient(90deg, var(--primary-dark), var(--primary-red));
  color: white;
  border: none;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: opacity var(--transition-speed), transform var(--transition-speed);
  z-index: 999;
}

#backToTop.show {
  display: flex;
}

#backToTop:hover {
  opacity: 0.9;
  transform: translateY(-3px);
}

/* 搜索模态框 */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

.modal.active {
  display: flex;
  animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content {
  background: white;
  padding: 30px;
  border-radius: 16px;
  max-width: 500px;
  width: 90%;
  display: flex;
  gap: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

body.dark-mode .modal-content {
  background: #1a1a2e;
}

.modal-content input {
  flex: 1;
  padding: 12px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color var(--transition-speed);
}

.modal-content input:focus {
  outline: none;
  border-color: var(--primary-dark);
}

body.dark-mode .modal-content input {
  background: #2a2a4e;
  border-color: #555;
  color: white;
}

.modal-content button {
  padding: 12px 20px;
  background: var(--primary-dark);
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: opacity var(--transition-speed);
  font-weight: 500;
}

.modal-content button:hover {
  opacity: 0.9;
}

/* 滚动动画 - 卡片渐入 */
.card {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* 响应式调整 */
@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.6rem;
  }

  .banner-text h1,
  .banner-text h2 {
    font-size: 1.8rem;
  }

  .banner-text p {
    font-size: 1rem;
  }

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

  .section {
    padding: 40px 0;
  }

  .card {
    padding: 20px;
  }

  .hero-banner {
    border-radius: 0 0 20px 20px;
  }
}

/* 小屏优化 */
@media (max-width: 480px) {
  .banner-text h1,
  .banner-text h2 {
    font-size: 1.4rem;
  }

  .about-grid,
  .product-grid,
  .service-grid,
  .cases-grid,
  .news-grid {
    grid-template-columns: 1fr;
  }
}

/* 打印样式 */
@media print {
  header,
  #backToTop,
  .banner-controls,
  .nav-actions {
    display: none !important;
  }

  .hero {
    padding-top: 0;
  }

  .card {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ddd;
  }
}

/* 自定义滚动条 */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--primary-dark), var(--primary-red));
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-red);
}

/* 选中文本样式 */
::selection {
  background: var(--primary-dark);
  color: white;
}

body.dark-mode ::selection {
  background: var(--primary-red);
  color: white;
}

/* 暗黑模式下的图片/图标适配 */
body.dark-mode svg text {
  fill: var(--text-dark) !important;
}

/* 额外动画 - 脉冲效果 */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.dot.active {
  animation: pulse 2s infinite;
}

/* 链接悬停下划线动画 */
.nav-menu a::after {
  content: '';
  display: block;
  width: 0;
  height: 2px;
  background: var(--primary-red);
  transition: width var(--transition-speed);
  margin-top: 2px;
}

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

/* 按钮通用样式 */
button {
  cursor: pointer;
  font-family: inherit;
}

/* 无障碍焦点样式 */
a:focus,
button:focus,
input:focus {
  outline: 2px solid var(--primary-dark);
  outline-offset: 2px;
}

body.dark-mode a:focus,
body.dark-mode button:focus,
body.dark-mode input:focus {
  outline-color: var(--primary-gold);
}