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

:root {
  --primary-color: #00A1D6;
  --secondary-color: #FB7299;
  --text-color: #333;
  --bg-color: #fff;
  --border-color: #e5e5e5;
  --hover-color: #f5f5f5;
  --spacing: 8px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background: var(--bg-color);
}

body.ui-style-0 { --primary-color: #000; --secondary-color: #FF2D55; }
body.ui-style-1 { --primary-color: #1a1a1a; --secondary-color: #FF6B35; }
body.ui-style-2 { --primary-color: #fff; --secondary-color: #FF6500; }
body.ui-style-3 { --primary-color: #fff; --secondary-color: #FF2442; }
body.ui-style-4 { --primary-color: #fff; --secondary-color: #E50914; }
body.ui-style-5 { --primary-color: #141414; --secondary-color: #E50914; }
body.ui-style-6 { --primary-color: #0F1B2E; --secondary-color: #0063E5; }
body.ui-style-7 { --primary-color: #0F171E; --secondary-color: #00A8E1; }
body.ui-style-8 { --primary-color: #1E2126; --secondary-color: #00ED82; }
body.ui-style-9 { --primary-color: #000; --secondary-color: #fff; }
body.ui-style-10 { --primary-color: #fff; --secondary-color: #00C75A; }
body.ui-style-11 { --primary-color: #fff; --secondary-color: #0099FF; }
body.ui-style-12 { --primary-color: #fff; --secondary-color: #FF6700; }
body.ui-style-13 { --primary-color: #fff; --secondary-color: #00A1D6; }
body.ui-style-14 { --primary-color: #fff; --secondary-color: #1E50AE; }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 calc(var(--spacing) * 2);
}

.main-nav {
  background: var(--primary-color);
  color: #fff;
  padding: calc(var(--spacing) * 2) 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 calc(var(--spacing) * 2);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo a {
  font-size: 24px;
  font-weight: bold;
  color: #fff;
  text-decoration: none;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: calc(var(--spacing) * 3);
  align-items: center;
  flex-wrap: nowrap;
}

.nav-links a {
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  transition: opacity 0.3s;
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active {
  opacity: 0.8;
}

.main-content {
  min-height: 60vh;
  padding: calc(var(--spacing) * 4) 0;
}

.hero-section {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: #fff;
  padding: calc(var(--spacing) * 8) calc(var(--spacing) * 2);
  text-align: center;
  margin-bottom: calc(var(--spacing) * 6);
  border-radius: calc(var(--spacing) * 2);
}

.hero-title {
  font-size: 32px;
  font-weight: bold;
  margin-bottom: calc(var(--spacing) * 2);
  line-height: 1.4;
}

.hero-description {
  font-size: 18px;
  line-height: 1.8;
  max-width: 800px;
  margin: 0 auto;
  opacity: 0.95;
}

.site-intro {
  margin-bottom: calc(var(--spacing) * 6);
}

.site-intro h2 {
  font-size: 24px;
  margin-bottom: calc(var(--spacing) * 2);
  color: var(--primary-color);
}

.site-intro p {
  font-size: 16px;
  line-height: 1.8;
  color: #666;
}

.video-section {
  margin-bottom: calc(var(--spacing) * 6);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: calc(var(--spacing) * 3);
}

.section-title {
  font-size: 24px;
  font-weight: bold;
  color: var(--primary-color);
}

.section-more {
  color: var(--secondary-color);
  text-decoration: none;
  font-size: 16px;
  transition: opacity 0.3s;
}

.section-more:hover {
  opacity: 0.7;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: calc(var(--spacing) * 3);
}

.video-card {
  border-radius: calc(var(--spacing) * 1);
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.video-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.video-card__link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.video-cover {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  overflow: hidden;
  background: #f0f0f0;
}

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

.video-cover-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s;
}

.video-card:hover .video-cover-overlay {
  opacity: 1;
}

.play-icon {
  font-size: 48px;
  color: #fff;
}

.video-info {
  padding: calc(var(--spacing) * 2);
}

.video-title {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: calc(var(--spacing) * 1);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.video-meta {
  font-size: 14px;
  color: #999;
  margin-bottom: calc(var(--spacing) * 1);
}

.video-one-line {
  font-size: 14px;
  color: #666;
  line-height: 1.5;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.page-header {
  margin-bottom: calc(var(--spacing) * 4);
}

.page-header h1 {
  font-size: 32px;
  color: var(--primary-color);
  margin-bottom: calc(var(--spacing) * 2);
}

.page-description {
  font-size: 16px;
  color: #666;
  line-height: 1.8;
}

.page--with-sidebar {
  display: flex;
  gap: calc(var(--spacing) * 4);
}

.layout__side--filters {
  width: 250px;
  flex-shrink: 0;
}

.filter-box {
  background: #f5f5f5;
  padding: calc(var(--spacing) * 2);
  border-radius: calc(var(--spacing) * 1);
}

.filter-box h3 {
  font-size: 18px;
  margin-bottom: calc(var(--spacing) * 2);
  color: var(--primary-color);
}

.list-content {
  flex: 1;
}

.top-list__items {
  list-style: none;
}

.top-list__item {
  display: flex;
  gap: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 2);
  background: #fff;
  border-radius: calc(var(--spacing) * 1);
  margin-bottom: calc(var(--spacing) * 2);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: transform 0.3s;
}

.top-list__item:hover {
  transform: translateX(4px);
}

.top-rank {
  font-size: 32px;
  font-weight: bold;
  color: var(--secondary-color);
  width: 50px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.top-cover {
  width: 120px;
  height: 68px;
  flex-shrink: 0;
  border-radius: calc(var(--spacing) * 1);
  overflow: hidden;
  background: #f0f0f0;
}

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

.top-info {
  flex: 1;
}

.top-title {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: calc(var(--spacing) * 1);
}

.top-title a {
  color: var(--text-color);
  text-decoration: none;
}

.top-title a:hover {
  color: var(--secondary-color);
}

.top-meta {
  font-size: 14px;
  color: #999;
  margin-bottom: calc(var(--spacing) * 1);
}

.top-desc {
  font-size: 14px;
  color: #666;
  line-height: 1.5;
}

.group {
  margin-bottom: calc(var(--spacing) * 5);
}

.group__title {
  font-size: 24px;
  color: var(--primary-color);
  margin-bottom: calc(var(--spacing) * 3);
  padding-bottom: calc(var(--spacing) * 1);
  border-bottom: 2px solid var(--secondary-color);
}

.group__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: calc(var(--spacing) * 3);
}

.detail-page {
  max-width: 900px;
  margin: 0 auto;
}

.video-player-section {
  margin-bottom: calc(var(--spacing) * 4);
}

.video-player {
  border-radius: calc(var(--spacing) * 2);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.video-player-inner {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: #000;
}

.player-play-btn {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.player-play-btn:hover {
  background: #fff;
  transform: translate(-50%, -50%) scale(1.1);
}

.player-play-icon {
  font-size: 32px;
  color: var(--primary-color);
}

.detail-header {
  margin-bottom: calc(var(--spacing) * 4);
}

.detail-title {
  font-size: 36px;
  font-weight: bold;
  color: var(--primary-color);
  line-height: 1.4;
}

.detail-module {
  margin-bottom: calc(var(--spacing) * 4);
  padding: calc(var(--spacing) * 3);
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.detail-module h2 {
  font-size: 24px;
  color: var(--primary-color);
  margin-bottom: calc(var(--spacing) * 2);
  padding-bottom: calc(var(--spacing) * 1);
  border-bottom: 2px solid var(--secondary-color);
}

.info-list {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: calc(var(--spacing) * 2);
  font-size: 16px;
  line-height: 1.8;
}

.info-list dt {
  font-weight: bold;
  color: #666;
}

.info-list dd {
  color: #333;
}

.highlight-text {
  font-size: 18px;
  color: var(--secondary-color);
  font-weight: 500;
  line-height: 1.8;
}

.summary-text p {
  font-size: 16px;
  line-height: 1.8;
  color: #333;
  margin-bottom: calc(var(--spacing) * 2);
}

.review-text p {
  font-size: 16px;
  line-height: 1.8;
  color: #333;
}

.tags-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--spacing) * 1);
  margin-bottom: calc(var(--spacing) * 2);
}

.tag {
  display: inline-block;
  padding: calc(var(--spacing) * 1) calc(var(--spacing) * 2);
  background: var(--hover-color);
  color: var(--text-color);
  border-radius: calc(var(--spacing) * 3);
  font-size: 14px;
}

.tags-note {
  font-size: 14px;
  color: #666;
}

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

.site-footer {
  background: #f5f5f5;
  padding: calc(var(--spacing) * 4) 0;
  margin-top: calc(var(--spacing) * 8);
  text-align: center;
  color: #666;
  font-size: 14px;
}

.back-to-top {
  position: fixed;
  right: calc(var(--spacing) * 3);
  bottom: calc(var(--spacing) * 3);
  width: 50px;
  height: 50px;
  background: var(--secondary-color);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

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

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

@media (max-width: 768px) {
  .nav-container {
    flex-direction: column;
    gap: calc(var(--spacing) * 2);
    align-items: flex-start;
  }

  .nav-links {
    gap: calc(var(--spacing) * 2);
    font-size: 14px;
  }

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

  .hero-description {
    font-size: 16px;
  }

  .video-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: calc(var(--spacing) * 2);
  }

  .page--with-sidebar {
    flex-direction: column;
  }

  .layout__side--filters {
    width: 100%;
  }

  .top-list__item {
    flex-direction: column;
  }

  .top-rank {
    width: 100%;
    justify-content: flex-start;
  }

  .top-cover {
    width: 100%;
    height: auto;
    padding-top: 56.25%;
    position: relative;
  }

  .top-cover img {
    position: absolute;
    top: 0;
    left: 0;
  }

  .detail-title {
    font-size: 28px;
  }

  .video-cover {
    padding-top: 45%;
  }

  .video-info {
    padding: calc(var(--spacing) * 1.5);
  }

  .video-title {
    font-size: 16px;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    line-height: 1.4;
    max-height: 2.8em;
  }
}
