/* 每日大赛官网 - 暗黑赛博风格CSS */

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

:root {
  --primary-color: #1a1a2e;
  --secondary-color: #16213e;
  --accent-gold: #d4af37;
  --accent-purple: #9d4edd;
  --accent-cyan: #00d9ff;
  --text-light: #e0e0e0;
  --text-dark: #1a1a2e;
  --border-color: #2a2a4e;
  --gradient-primary: linear-gradient(135deg, #d4af37 0%, #9d4edd 50%, #00d9ff 100%);
}

html, body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: var(--primary-color);
  color: var(--text-light);
  overflow-x: hidden;
}

/* 顶部导航 */
header {
  background-color: var(--secondary-color);
  border-bottom: 2px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(212, 175, 55, 0.1);
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo {
  font-size: 24px;
  font-weight: bold;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 30px;
  flex-wrap: wrap;
}

nav a {
  color: var(--text-light);
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s ease;
  position: relative;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width 0.3s ease;
}

nav a:hover::after {
  width: 100%;
}

/* 搜索框 */
.search-bar {
  position: relative;
  width: 200px;
}

.search-bar input {
  width: 100%;
  padding: 10px 15px;
  background-color: rgba(212, 175, 55, 0.1);
  border: 1px solid var(--accent-gold);
  border-radius: 25px;
  color: var(--text-light);
  font-size: 13px;
  outline: none;
  transition: all 0.3s ease;
}

.search-bar input::placeholder {
  color: rgba(224, 224, 224, 0.5);
}

.search-bar input:focus {
  box-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
  background-color: rgba(212, 175, 55, 0.15);
}

/* Hero Banner */
.hero {
  position: relative;
  height: 600px;
  background: linear-gradient(rgba(26, 26, 46, 0.7), rgba(26, 26, 46, 0.7)), url('../images/hero_banner.jpg') center/cover;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 20% 50%, rgba(212, 175, 55, 0.1) 0%, transparent 50%),
              radial-gradient(circle at 80% 80%, rgba(157, 78, 221, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 800px;
}

.hero h1 {
  font-size: 48px;
  margin-bottom: 20px;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 0 30px rgba(212, 175, 55, 0.3);
  animation: fadeInDown 1s ease;
}

.hero p {
  font-size: 18px;
  margin-bottom: 30px;
  color: rgba(224, 224, 224, 0.8);
  animation: fadeInUp 1s ease 0.2s both;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  animation: fadeInUp 1s ease 0.4s both;
}

.btn {
  padding: 12px 30px;
  border: 2px solid var(--accent-gold);
  background: transparent;
  color: var(--accent-gold);
  font-size: 14px;
  font-weight: bold;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

.btn:hover {
  background: var(--accent-gold);
  color: var(--text-dark);
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.5);
}

.btn-primary {
  background: var(--gradient-primary);
  border: none;
  color: var(--text-dark);
}

.btn-primary:hover {
  box-shadow: 0 0 30px rgba(212, 175, 55, 0.7);
}

/* 内容容器 */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 80px 0;
  border-bottom: 1px solid var(--border-color);
}

.section-title {
  font-size: 36px;
  margin-bottom: 15px;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-subtitle {
  font-size: 16px;
  color: rgba(224, 224, 224, 0.7);
  margin-bottom: 50px;
}

/* 视频卡片 */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.video-card {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  background-color: var(--secondary-color);
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
  cursor: pointer;
}

.video-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(212, 175, 55, 0.2);
  border-color: var(--accent-gold);
}

.video-thumbnail {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.1), rgba(157, 78, 221, 0.1));
  overflow: hidden;
}

.video-thumbnail img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background: rgba(212, 175, 55, 0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 10;
}

.play-button::after {
  content: '';
  width: 0;
  height: 0;
  border-left: 15px solid var(--text-dark);
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  margin-left: 3px;
}

.video-card:hover .play-button {
  opacity: 1;
}

.video-info {
  padding: 20px;
}

.video-title {
  font-size: 16px;
  margin-bottom: 10px;
  font-weight: bold;
  color: var(--text-light);
}

.video-stats {
  display: flex;
  gap: 15px;
  font-size: 12px;
  color: rgba(224, 224, 224, 0.6);
}

/* 社区模块 */
.community-topics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 40px;
}

.topic-card {
  background-color: var(--secondary-color);
  padding: 20px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.topic-card:hover {
  border-color: var(--accent-gold);
  box-shadow: 0 5px 20px rgba(212, 175, 55, 0.1);
}

.topic-name {
  color: var(--accent-gold);
  font-weight: bold;
  margin-bottom: 10px;
}

.topic-posts {
  font-size: 12px;
  color: rgba(224, 224, 224, 0.6);
}

/* AI模块 */
.ai-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 40px;
}

.ai-feature {
  background-color: var(--secondary-color);
  padding: 30px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  text-align: center;
  transition: all 0.3s ease;
}

.ai-feature:hover {
  border-color: var(--accent-purple);
  box-shadow: 0 10px 30px rgba(157, 78, 221, 0.2);
  transform: translateY(-5px);
}

.ai-feature img {
  width: 60px;
  height: 60px;
  margin-bottom: 15px;
}

.ai-feature-name {
  font-weight: bold;
  color: var(--text-light);
}

/* 专家模块 */
.experts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.expert-card {
  text-align: center;
  background-color: var(--secondary-color);
  padding: 30px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.expert-card:hover {
  border-color: var(--accent-cyan);
  box-shadow: 0 10px 30px rgba(0, 217, 255, 0.2);
}

.expert-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 20px;
  border: 3px solid var(--accent-gold);
  object-fit: cover;
}

.expert-name {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 5px;
}

.expert-role {
  font-size: 13px;
  color: rgba(224, 224, 224, 0.6);
}

/* 用户评价 */
.testimonials {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.testimonial-card {
  background-color: var(--secondary-color);
  padding: 30px;
  border-radius: 10px;
  border-left: 4px solid var(--accent-gold);
  transition: all 0.3s ease;
}

.testimonial-card:hover {
  box-shadow: 0 10px 30px rgba(212, 175, 55, 0.2);
}

.testimonial-text {
  font-size: 14px;
  margin-bottom: 20px;
  line-height: 1.6;
  color: rgba(224, 224, 224, 0.9);
}

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

.testimonial-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent-gold);
}

.testimonial-info {
  font-weight: bold;
  font-size: 14px;
}

/* FAQ */
.faq-items {
  margin-top: 40px;
}

.faq-item {
  background-color: var(--secondary-color);
  margin-bottom: 15px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: var(--accent-gold);
}

.faq-question {
  padding: 20px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: bold;
  color: var(--text-light);
}

.faq-question::after {
  content: '+';
  font-size: 24px;
  color: var(--accent-gold);
  transition: transform 0.3s ease;
}

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

.faq-answer {
  padding: 0 20px;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s ease;
  color: rgba(224, 224, 224, 0.8);
  line-height: 1.6;
}

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

/* 页脚 */
footer {
  background-color: var(--secondary-color);
  border-top: 1px solid var(--border-color);
  padding: 60px 0 20px;
  margin-top: 80px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-section h3 {
  color: var(--accent-gold);
  margin-bottom: 15px;
  font-size: 16px;
}

.footer-section p, .footer-section a {
  font-size: 13px;
  color: rgba(224, 224, 224, 0.7);
  line-height: 1.8;
  text-decoration: none;
  transition: color 0.3s ease;
}

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

.qr-codes {
  display: flex;
  gap: 30px;
  justify-content: center;
  margin-bottom: 30px;
}

.qr-code {
  text-align: center;
}

.qr-code img {
  width: 120px;
  height: 120px;
  border: 2px solid var(--accent-gold);
  border-radius: 5px;
  margin-bottom: 10px;
}

.qr-code-label {
  font-size: 12px;
  color: rgba(224, 224, 224, 0.6);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
  font-size: 12px;
  color: rgba(224, 224, 224, 0.5);
}

.social-links {
  display: flex;
  gap: 15px;
  justify-content: center;
  margin-bottom: 15px;
}

.social-links a {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  background-color: rgba(212, 175, 55, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.social-links a:hover {
  background-color: var(--accent-gold);
  color: var(--text-dark);
}

/* 响应式设计 */
@media (max-width: 768px) {
  .header-container {
    flex-direction: column;
    height: auto;
    padding: 15px 20px;
  }

  nav ul {
    gap: 15px;
    font-size: 12px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .hero p {
    font-size: 14px;
  }

  .hero-buttons {
    flex-direction: column;
  }

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

  .section {
    padding: 50px 0;
  }

  .section-title {
    font-size: 24px;
  }
}

/* 动画 */
@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 懒加载占位符 */
.lazy-load {
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.1) 25%, rgba(157, 78, 221, 0.1) 50%, rgba(212, 175, 55, 0.1) 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}
