/* ========================================
   91 修车改装视频社区 - 主样式表
   设计理念：深沉工业风 + 运动激情
   色彩系统：深灰蓝 + 炽橙红 + 电光蓝
   ======================================== */

:root {
  --primary-dark: #1a2332;
  --accent-orange: #ff5722;
  --accent-blue: #00d4ff;
  --bg-white: #ffffff;
  --bg-light: #f5f5f5;
  --text-dark: #333333;
  --border-light: #e0e0e0;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Source Han Sans CN', 'PingFang SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text-dark);
  background-color: var(--bg-white);
  line-height: 1.6;
}

/* ========== 通用样式 ========== */

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

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 1rem;
  color: var(--primary-dark);
}

h1 {
  font-size: 2.5rem;
}

h2 {
  font-size: 2rem;
  border-bottom: 3px solid var(--accent-orange);
  padding-bottom: 0.5rem;
  display: inline-block;
}

h3 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1rem;
  font-size: 1rem;
}

a {
  color: var(--accent-orange);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

/* ========== 头部导航 ========== */

header {
  background-color: var(--primary-dark);
  color: var(--bg-white);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--bg-white);
}

.logo img {
  height: 40px;
  width: auto;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
  flex-wrap: wrap;
}

nav a {
  color: var(--bg-white);
  font-weight: 500;
  position: relative;
  transition: color 0.3s ease;
}

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

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

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

/* ========== 搜索框 ========== */

.search-container {
  display: flex;
  align-items: center;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 25px;
  padding: 0.5rem 1rem;
  margin-top: 1rem;
}

.search-input {
  background: none;
  border: none;
  color: var(--bg-white);
  font-size: 0.9rem;
  width: 200px;
  outline: none;
}

.search-input::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.search-btn {
  background: none;
  border: none;
  color: var(--accent-orange);
  cursor: pointer;
  font-size: 1.2rem;
  transition: color 0.3s ease;
}

.search-btn:hover {
  color: var(--accent-blue);
}

/* ========== Banner 区 ========== */

.banner {
  position: relative;
  height: 500px;
  background: linear-gradient(135deg, var(--primary-dark) 0%, #2a3a4f 100%);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg-white);
  text-align: center;
}

.banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url('https://d2xsxph8kpxj0f.cloudfront.net/310519663735472748/desAgfJwuY9GjgKfw6autM/banner_hero-DXV4bRbcJVELiQj6autM.webp');
  background-size: cover;
  background-position: center;
  opacity: 0.4;
  z-index: 1;
}

.banner-content {
  position: relative;
  z-index: 2;
  max-width: 600px;
}

.banner h1 {
  font-size: 3rem;
  color: var(--bg-white);
  margin-bottom: 1rem;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
}

.banner p {
  font-size: 1.3rem;
  color: var(--accent-blue);
  margin-bottom: 2rem;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
}

.banner-btn {
  display: inline-block;
  padding: 12px 30px;
  background-color: var(--accent-orange);
  color: var(--bg-white);
  border: none;
  border-radius: 5px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow);
}

.banner-btn:hover {
  background-color: var(--accent-blue);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

/* ========== 内容模块 ========== */

section {
  padding: 4rem 0;
  border-bottom: 1px solid var(--border-light);
}

section:last-child {
  border-bottom: none;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title h2 {
  display: inline-block;
  margin-bottom: 0.5rem;
}

.section-title p {
  color: #666;
  font-size: 1.1rem;
}

/* ========== 视频卡片 ========== */

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.video-card {
  background-color: var(--bg-white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  cursor: pointer;
}

.video-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.video-thumbnail {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  background-color: var(--primary-dark);
  overflow: hidden;
}

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

.video-card:hover .video-thumbnail img {
  transform: scale(1.05);
}

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

.play-button::after {
  content: '▶';
  color: var(--bg-white);
  font-size: 1.5rem;
  margin-left: 4px;
}

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

.video-info {
  padding: 1.5rem;
}

.video-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--primary-dark);
}

.video-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: #999;
  margin-bottom: 0.5rem;
}

.video-stats {
  display: flex;
  gap: 1rem;
  font-size: 0.85rem;
  color: #666;
}

/* ========== 专家展示 ========== */

.expert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.expert-card {
  background-color: var(--bg-light);
  border-radius: 8px;
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.expert-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.expert-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 1rem;
  background-color: var(--primary-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-orange);
  font-size: 3rem;
  overflow: hidden;
}

.expert-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.expert-name {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--primary-dark);
}

.expert-title {
  color: var(--accent-orange);
  font-weight: 600;
  margin-bottom: 1rem;
}

.expert-bio {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 1rem;
}

.expert-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.expert-links a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: var(--accent-orange);
  color: var(--bg-white);
  border-radius: 5px;
  font-size: 0.85rem;
  transition: all 0.3s ease;
}

.expert-links a:hover {
  background-color: var(--accent-blue);
}

/* ========== FAQ ========== */

.faq-item {
  background-color: var(--bg-light);
  border-left: 4px solid var(--accent-orange);
  padding: 1.5rem;
  margin-bottom: 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.faq-item:hover {
  box-shadow: var(--shadow);
  background-color: var(--bg-white);
}

.faq-question {
  font-weight: 600;
  color: var(--primary-dark);
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.faq-toggle {
  display: inline-block;
  width: 20px;
  height: 20px;
  background-color: var(--accent-orange);
  color: var(--bg-white);
  border-radius: 50%;
  text-align: center;
  line-height: 20px;
  font-size: 0.8rem;
  transition: transform 0.3s ease;
}

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

.faq-answer {
  color: #666;
  font-size: 0.95rem;
  display: none;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-light);
}

.faq-item.active .faq-answer {
  display: block;
}

/* ========== 用户评论 ========== */

.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.review-card {
  background-color: var(--bg-light);
  border-radius: 8px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.review-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.review-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: var(--accent-orange);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg-white);
  font-weight: 700;
  font-size: 1.2rem;
}

.review-author {
  font-weight: 600;
  color: var(--primary-dark);
}

.review-rating {
  color: var(--accent-orange);
  font-size: 0.9rem;
}

.review-text {
  color: #666;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ========== 联系信息 ========== */

.contact-section {
  background-color: var(--primary-dark);
  color: var(--bg-white);
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.contact-card {
  background-color: rgba(255, 255, 255, 0.1);
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s ease;
}

.contact-card:hover {
  background-color: rgba(255, 255, 255, 0.15);
  border-color: var(--accent-orange);
}

.contact-card h3 {
  color: var(--accent-orange);
  margin-bottom: 1rem;
}

.contact-info {
  font-size: 0.95rem;
  line-height: 1.8;
}

.contact-info a {
  color: var(--accent-blue);
}

.contact-info a:hover {
  color: var(--accent-orange);
}

/* ========== 二维码 ========== */

.qrcode-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.qrcode-item {
  text-align: center;
}

.qrcode-item img {
  width: 150px;
  height: 150px;
  border: 2px solid var(--accent-orange);
  border-radius: 8px;
  margin-bottom: 1rem;
}

.qrcode-label {
  font-weight: 600;
  color: var(--accent-orange);
}

/* ========== 页脚 ========== */

footer {
  background-color: var(--primary-dark);
  color: var(--bg-white);
  padding: 3rem 0 1rem;
  text-align: center;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 20px;
}

.footer-section h4 {
  color: var(--accent-orange);
  margin-bottom: 1rem;
  font-size: 1rem;
}

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

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section a {
  color: var(--bg-white);
  font-size: 0.9rem;
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
}

.footer-bottom a {
  color: var(--accent-blue);
}

/* ========== 响应式设计 ========== */

@media (max-width: 768px) {
  .banner h1 {
    font-size: 2rem;
  }

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

  h1 {
    font-size: 1.8rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  nav ul {
    gap: 1rem;
  }

  .search-input {
    width: 120px;
  }

  .video-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
  }

  .expert-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }

  section {
    padding: 2rem 0;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 15px;
  }

  .banner {
    height: 300px;
  }

  .banner h1 {
    font-size: 1.5rem;
  }

  nav ul {
    flex-direction: column;
    gap: 0.5rem;
  }

  .header-container {
    flex-direction: column;
    gap: 1rem;
  }

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

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

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

/* ========== 加载动画 ========== */

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

.fade-in {
  animation: fadeIn 0.6s ease-out;
}

/* ========== 实用类 ========== */

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

.text-orange {
  color: var(--accent-orange);
}

.text-blue {
  color: var(--accent-blue);
}

.mt-2 {
  margin-top: 2rem;
}

.mb-2 {
  margin-bottom: 2rem;
}

.py-4 {
  padding: 4rem 0;
}
