/* ============================================
   51视频 - 原创样式表
   品牌定位：国内影视传媒公司+动漫社区
   配色方案：深海蓝 #0a1628 / 星空紫 #2d1b69 / 活力橙 #ff6b35 / 樱花粉 #ff8fa3 / 冰蓝 #64dfdf
   ============================================ */

/* --- CSS Variables --- */
:root {
  --brand-dark: #0a1628;
  --brand-purple: #2d1b69;
  --brand-orange: #ff6b35;
  --brand-pink: #ff8fa3;
  --brand-cyan: #64dfdf;
  --brand-gold: #ffd166;
  --text-primary: #e8e8e8;
  --text-secondary: #a0a8b8;
  --bg-card: rgba(18, 25, 45, 0.85);
  --bg-glass: rgba(45, 27, 105, 0.3);
  --border-glow: rgba(100, 223, 223, 0.2);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3);
  --radius-lg: 16px;
  --radius-md: 10px;
  --radius-sm: 6px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", "Noto Sans CJK SC", sans-serif;
  background: var(--brand-dark);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  min-height: 100vh;
}

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

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

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

ul, ol {
  list-style: none;
}

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

/* --- Header & Navigation --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: linear-gradient(180deg, rgba(10, 22, 40, 0.98) 0%, rgba(10, 22, 40, 0.92) 100%);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glow);
  transition: var(--transition);
}

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

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 2px solid var(--brand-cyan);
}

.brand-logo h1 {
  font-size: 1.4rem;
  background: linear-gradient(135deg, var(--brand-cyan), var(--brand-orange));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
  letter-spacing: 1px;
}

.main-nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  gap: 6px;
}

.nav-list li a {
  display: block;
  padding: 8px 16px;
  color: var(--text-secondary);
  font-size: 0.92rem;
  border-radius: var(--radius-sm);
  position: relative;
  font-weight: 500;
}

.nav-list li a:hover,
.nav-list li a.active {
  color: var(--brand-cyan);
  background: var(--bg-glass);
}

.nav-list li a::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 60%;
  height: 2px;
  background: var(--brand-orange);
  border-radius: 2px;
  transition: transform 0.3s ease;
}

.nav-list li a:hover::after,
.nav-list li a.active::after {
  transform: translateX(-50%) scaleX(1);
}

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

.mobile-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}

/* --- Search Bar --- */
.search-bar-wrap {
  background: linear-gradient(135deg, var(--brand-purple), rgba(10, 22, 40, 0.9));
  padding: 14px 0;
  border-bottom: 1px solid var(--border-glow);
  margin-top: 68px;
}

.search-form {
  display: flex;
  max-width: 620px;
  margin: 0 auto;
  position: relative;
}

.search-form input {
  flex: 1;
  padding: 12px 20px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(100, 223, 223, 0.3);
  border-radius: 30px 0 0 30px;
  color: var(--text-primary);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}

.search-form input:focus {
  border-color: var(--brand-cyan);
  background: rgba(255, 255, 255, 0.12);
}

.search-form input::placeholder {
  color: var(--text-secondary);
}

.search-form button {
  padding: 12px 28px;
  background: linear-gradient(135deg, var(--brand-orange), #ff8f35);
  border: none;
  border-radius: 0 30px 30px 0;
  color: #fff;
  font-size: 0.95rem;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
}

.search-form button:hover {
  background: linear-gradient(135deg, #ff8f35, var(--brand-orange));
  transform: scale(1.02);
}

/* --- Hero Banner --- */
.hero-banner {
  position: relative;
  height: 520px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-banner .hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.55);
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 20px;
}

.hero-content h2 {
  font-size: 2.8rem;
  font-weight: 900;
  margin-bottom: 16px;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.hero-content h2 .highlight {
  background: linear-gradient(135deg, var(--brand-cyan), var(--brand-orange));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-content p {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 28px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.hero-btns {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-block;
  padding: 12px 32px;
  background: linear-gradient(135deg, var(--brand-orange), #ff8f35);
  color: #fff;
  border-radius: 30px;
  font-weight: 700;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 4px 20px rgba(255, 107, 53, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(255, 107, 53, 0.5);
  color: #fff;
}

.btn-secondary {
  display: inline-block;
  padding: 12px 32px;
  background: transparent;
  color: var(--brand-cyan);
  border: 2px solid var(--brand-cyan);
  border-radius: 30px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
}

.btn-secondary:hover {
  background: var(--brand-cyan);
  color: var(--brand-dark);
  transform: translateY(-2px);
}

/* --- Section Common --- */
.section {
  padding: 70px 0;
}

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-header h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.section-header h2 .accent {
  color: var(--brand-orange);
}

.section-header h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--brand-cyan);
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1rem;
  max-width: 640px;
  margin: 0 auto;
}

.section-alt {
  background: linear-gradient(180deg, rgba(45, 27, 105, 0.15) 0%, rgba(10, 22, 40, 0) 100%);
}

/* --- Video Card Grid --- */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.video-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-glow);
  transition: var(--transition);
  cursor: pointer;
}

.video-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(100, 223, 223, 0.15);
  border-color: var(--brand-cyan);
}

.video-thumb {
  position: relative;
  padding-top: 56.25%;
  overflow: hidden;
}

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

.video-card:hover .video-thumb img {
  transform: scale(1.08);
}

.play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  width: 60px;
  height: 60px;
  background: rgba(255, 107, 53, 0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  box-shadow: 0 4px 20px rgba(255, 107, 53, 0.4);
}

.play-btn::after {
  content: '';
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 10px 0 10px 18px;
  border-color: transparent transparent transparent #fff;
  margin-left: 3px;
}

.video-card:hover .play-btn {
  transform: translate(-50%, -50%) scale(1);
}

.video-duration {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.75);
  color: #fff;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
}

.video-info {
  padding: 16px;
}

.video-info h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
}

.video-meta {
  display: flex;
  gap: 14px;
  color: var(--text-secondary);
  font-size: 0.82rem;
}

.video-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

.video-tags {
  display: flex;
  gap: 6px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.video-tags span {
  padding: 2px 10px;
  background: var(--bg-glass);
  border-radius: 20px;
  font-size: 0.75rem;
  color: var(--brand-cyan);
  border: 1px solid rgba(100, 223, 223, 0.15);
}

/* --- Feature Modules --- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 30px 24px;
  border: 1px solid var(--border-glow);
  transition: var(--transition);
  text-align: center;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--brand-orange);
  box-shadow: 0 8px 30px rgba(255, 107, 53, 0.1);
}

.feature-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  background: linear-gradient(135deg, var(--brand-purple), rgba(100, 223, 223, 0.2));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
}

.feature-card h4 {
  font-size: 1.1rem;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* --- Expert Section --- */
.expert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
}

.expert-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border-glow);
  text-align: center;
  transition: var(--transition);
}

.expert-card:hover {
  border-color: var(--brand-pink);
  box-shadow: 0 8px 30px rgba(255, 143, 163, 0.12);
}

.expert-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  margin: 0 auto 16px;
  border: 3px solid var(--brand-cyan);
  object-fit: cover;
}

.expert-card h4 {
  font-size: 1.15rem;
  margin-bottom: 4px;
}

.expert-card .expert-title {
  color: var(--brand-orange);
  font-size: 0.88rem;
  margin-bottom: 12px;
}

.expert-card .expert-desc {
  color: var(--text-secondary);
  font-size: 0.88rem;
  line-height: 1.6;
  margin-bottom: 16px;
}

.expert-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.expert-actions a {
  padding: 6px 18px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

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

.faq-item {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  border: 1px solid var(--border-glow);
  overflow: hidden;
}

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

.faq-question:hover {
  color: var(--brand-cyan);
}

.faq-question .faq-toggle {
  font-size: 1.4rem;
  color: var(--brand-orange);
  transition: transform 0.3s ease;
  min-width: 24px;
  text-align: center;
}

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

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

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

.faq-answer-inner {
  padding: 0 24px 18px;
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.7;
}

/* --- Reviews Section --- */
.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.review-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--border-glow);
  transition: var(--transition);
}

.review-card:hover {
  border-color: var(--brand-gold);
}

.review-stars {
  color: var(--brand-gold);
  font-size: 1rem;
  margin-bottom: 12px;
  letter-spacing: 2px;
}

.review-text {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.7;
  margin-bottom: 14px;
  font-style: italic;
}

.review-author {
  display: flex;
  align-items: center;
  gap: 10px;
}

.review-author-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-purple), var(--brand-cyan));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: #fff;
}

.review-author-info span {
  display: block;
}

.review-author-info .author-name {
  font-weight: 600;
  font-size: 0.9rem;
}

.review-author-info .author-date {
  color: var(--text-secondary);
  font-size: 0.78rem;
}

/* --- Partner Logos --- */
.partner-wall {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: center;
  align-items: center;
}

.partner-item {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 18px 30px;
  border: 1px solid var(--border-glow);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
  transition: var(--transition);
}

.partner-item:hover {
  border-color: var(--brand-cyan);
  color: var(--brand-cyan);
}

/* --- Contact Section --- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}

.contact-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border-glow);
  text-align: center;
}

.contact-card h4 {
  font-size: 1.05rem;
  margin-bottom: 12px;
  color: var(--brand-cyan);
}

.contact-card p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
}

.qr-placeholder {
  width: 120px;
  height: 120px;
  margin: 14px auto;
  background: linear-gradient(135deg, var(--bg-glass), rgba(100, 223, 223, 0.1));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 0.8rem;
  border: 1px dashed var(--border-glow);
}

/* --- How-To Guide --- */
.howto-steps {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 24px;
  counter-reset: step;
}

.howto-step {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  border: 1px solid var(--border-glow);
  position: relative;
  counter-increment: step;
}

.howto-step::before {
  content: counter(step);
  position: absolute;
  top: -14px;
  left: 24px;
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--brand-orange), #ff8f35);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  color: #fff;
}

.howto-step h4 {
  margin-bottom: 8px;
  font-size: 1rem;
}

.howto-step p {
  color: var(--text-secondary);
  font-size: 0.88rem;
  line-height: 1.6;
}

/* --- Social Share --- */
.social-share {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  border-radius: 24px;
  font-size: 0.88rem;
  font-weight: 600;
  border: 1px solid var(--border-glow);
  background: var(--bg-card);
  color: var(--text-primary);
  transition: var(--transition);
  cursor: pointer;
}

.social-btn:hover {
  border-color: var(--brand-cyan);
  color: var(--brand-cyan);
  transform: translateY(-2px);
}

/* --- Breadcrumb --- */
.breadcrumb {
  padding: 14px 0;
  margin-top: 68px;
  background: rgba(45, 27, 105, 0.1);
  border-bottom: 1px solid var(--border-glow);
}

.breadcrumb-list {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

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

.breadcrumb-list a:hover {
  color: var(--brand-cyan);
}

.breadcrumb-list .sep {
  color: var(--text-secondary);
  opacity: 0.5;
}

.breadcrumb-list .current {
  color: var(--brand-orange);
}

/* --- Footer --- */
.site-footer {
  background: linear-gradient(180deg, rgba(10, 22, 40, 0.95) 0%, #060d18 100%);
  border-top: 1px solid var(--border-glow);
  padding: 50px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 36px;
  margin-bottom: 36px;
}

.footer-col h4 {
  font-size: 1.05rem;
  margin-bottom: 16px;
  color: var(--brand-cyan);
  font-weight: 700;
}

.footer-col p,
.footer-col a {
  color: var(--text-secondary);
  font-size: 0.88rem;
  line-height: 2;
  display: block;
}

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

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.footer-brand img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
}

.footer-brand span {
  font-size: 1.2rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--brand-cyan), var(--brand-orange));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.footer-bottom {
  border-top: 1px solid var(--border-glow);
  padding: 20px 0;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.footer-bottom a {
  color: var(--brand-cyan);
}

/* --- Inner Page Content --- */
.page-content {
  padding: 40px 0 70px;
}

.page-content h2 {
  font-size: 1.8rem;
  margin-bottom: 20px;
}

.page-content h3 {
  font-size: 1.3rem;
  margin: 28px 0 14px;
  color: var(--brand-cyan);
}

.page-content p {
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.8;
}

.content-banner {
  width: 100%;
  border-radius: var(--radius-lg);
  margin-bottom: 28px;
  max-height: 400px;
  object-fit: cover;
}

/* --- Lazy Load Placeholder --- */
img[data-src] {
  opacity: 0;
  transition: opacity 0.5s ease;
}

img[data-src].loaded {
  opacity: 1;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .header-inner {
    height: 56px;
  }

  .brand-logo h1 {
    font-size: 1.1rem;
  }

  .brand-logo img {
    width: 34px;
    height: 34px;
  }

  .main-nav {
    position: fixed;
    top: 56px;
    left: 0;
    width: 100%;
    background: rgba(10, 22, 40, 0.98);
    backdrop-filter: blur(20px);
    padding: 20px;
    transform: translateY(-120%);
    transition: transform 0.3s ease;
    border-bottom: 1px solid var(--border-glow);
  }

  .main-nav.open {
    transform: translateY(0);
  }

  .nav-list {
    flex-direction: column;
    gap: 4px;
  }

  .nav-list li a {
    padding: 12px 16px;
  }

  .mobile-toggle {
    display: flex;
  }

  .search-bar-wrap {
    margin-top: 56px;
  }

  .hero-banner {
    height: 380px;
  }

  .hero-content h2 {
    font-size: 1.8rem;
  }

  .hero-content p {
    font-size: 0.95rem;
  }

  .section {
    padding: 48px 0;
  }

  .section-header h2 {
    font-size: 1.5rem;
  }

  .video-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
  }

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

  .breadcrumb {
    margin-top: 56px;
  }
}

@media (max-width: 480px) {
  .hero-banner {
    height: 300px;
  }

  .hero-content h2 {
    font-size: 1.4rem;
  }

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

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

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

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

.animate-in {
  animation: fadeInUp 0.6s ease forwards;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--brand-dark);
}

::-webkit-scrollbar-thumb {
  background: var(--brand-purple);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--brand-cyan);
}
