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

:root {
  --primary-color: #00C75A;
  --text-color: #333;
  --bg-color: #fff;
  --border-color: #eee;
  --hover-color: #f8f8f8;
  --shadow: 0 2px 8px rgba(0,0,0,0.1);
}

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

body.ui-style-7 {
  --primary-color: #0099FF;
  --text-color: #2c3e50;
  --bg-color: #f5f7fa;
}

.site-header {
  background: var(--bg-color);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow);
}

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

.logo a {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-color);
  text-decoration: none;
}

.main-nav {
  display: flex;
  gap: 30px;
  white-space: nowrap;
  overflow: visible;
}

.main-nav a {
  color: var(--text-color);
  text-decoration: none;
  font-weight: 500;
  padding: 8px 12px;
  border-radius: 4px;
  transition: all 0.3s;
}

.main-nav a:hover,
.main-nav a.active {
  background: var(--primary-color);
  color: #fff;
}

.home-page,
.list-page,
.detail-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

.hero-section {
  height: 500px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-align: center;
  border-radius: 12px;
  margin-bottom: 40px;
  padding: 40px 20px;
}

.hero-content {
  max-width: 800px;
}

.hero-title {
  font-size: 36px;
  margin-bottom: 20px;
  line-height: 1.3;
}

.hero-subtitle {
  font-size: 18px;
  margin-bottom: 30px;
  opacity: 0.95;
}

.hero-btn {
  display: inline-block;
  padding: 12px 32px;
  background: var(--primary-color);
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.3s;
}

.hero-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.intro-section {
  background: #fff;
  padding: 40px;
  border-radius: 12px;
  margin-bottom: 40px;
  box-shadow: var(--shadow);
}

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

.content-module {
  margin-bottom: 50px;
}

.module-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--primary-color);
}

.module-header h2 {
  font-size: 28px;
  font-weight: 700;
}

.more-link {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s;
}

.more-link:hover {
  opacity: 0.8;
}

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

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

.video-card {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s;
  box-shadow: var(--shadow);
}

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

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

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

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

.video-info {
  padding: 16px;
}

.video-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.video-one-line {
  font-size: 14px;
  color: #666;
  margin-bottom: 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.video-meta {
  display: flex;
  gap: 12px;
  font-size: 13px;
  color: #999;
}

.page-header {
  margin-bottom: 30px;
}

.page-header h1 {
  font-size: 36px;
  margin-bottom: 12px;
}

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

.page--grid,
.page--with-sidebar,
.page--top,
.page--grouped {
  background: #fff;
  padding: 40px;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.page--with-sidebar {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 40px;
}

.layout__side--filters h2 {
  font-size: 18px;
  margin-bottom: 16px;
}

.filter-group {
  margin-bottom: 20px;
}

.filter-group h3 {
  font-size: 14px;
  margin-bottom: 8px;
  color: #666;
}

.filter-tag {
  display: inline-block;
  padding: 6px 12px;
  background: var(--hover-color);
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s;
}

.filter-tag:hover {
  background: var(--primary-color);
  color: #fff;
}

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

.top-list__item {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: #fff;
  border-bottom: 1px solid var(--border-color);
  transition: all 0.3s;
}

.top-list__item:hover {
  background: var(--hover-color);
}

.top-rank {
  font-size: 32px;
  font-weight: 700;
  color: var(--primary-color);
  min-width: 50px;
  text-align: center;
}

.top-list__item:nth-child(1) .top-rank,
.top-list__item:nth-child(2) .top-rank,
.top-list__item:nth-child(3) .top-rank {
  color: #ff6b6b;
}

.top-cover {
  width: 120px;
  height: 180px;
  overflow: hidden;
  border-radius: 6px;
  flex-shrink: 0;
}

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

.top-info {
  flex: 1;
}

.top-info h3 {
  font-size: 18px;
  margin-bottom: 8px;
}

.top-info h3 a {
  color: var(--text-color);
  text-decoration: none;
  transition: all 0.3s;
}

.top-info h3 a:hover {
  color: var(--primary-color);
}

.top-info p {
  font-size: 14px;
  color: #666;
  margin-bottom: 8px;
  line-height: 1.5;
}

.group {
  margin-bottom: 40px;
}

.group__title {
  font-size: 24px;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--primary-color);
}

.group__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.video-player-section {
  margin-bottom: 30px;
}

.video-player {
  max-width: 900px;
  margin: 0 auto;
}

.video-player-inner {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
}

.player-play-btn {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background: rgba(255,255,255,0.9);
  border: none;
  border-radius: 50%;
  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);
  margin-left: 4px;
}

.detail-header {
  text-align: center;
  margin-bottom: 30px;
}

.detail-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--text-color);
}

.detail-module {
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  margin-bottom: 30px;
  box-shadow: var(--shadow);
}

.detail-module h2 {
  font-size: 24px;
  margin-bottom: 20px;
  color: var(--text-color);
  border-left: 4px solid var(--primary-color);
  padding-left: 16px;
}

.module-content {
  font-size: 16px;
  line-height: 1.8;
  color: #555;
}

.module-content p {
  margin-bottom: 16px;
}

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

.info-item {
  padding: 12px;
  background: var(--hover-color);
  border-radius: 6px;
}

.info-label {
  font-weight: 600;
  color: #666;
  margin-right: 8px;
}

.info-value {
  color: var(--text-color);
}

.tags-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.tag {
  display: inline-block;
  padding: 8px 16px;
  background: var(--primary-color);
  color: #fff;
  border-radius: 20px;
  font-size: 14px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.video-card--related {
  border: 1px solid var(--border-color);
}

.site-footer {
  background: #2c3e50;
  color: #fff;
  text-align: center;
  padding: 30px 20px;
  margin-top: 60px;
}

.back-to-top {
  position: fixed;
  bottom: 40px;
  right: 40px;
  width: 50px;
  height: 50px;
  background: var(--primary-color);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  transition: all 0.3s;
  z-index: 999;
}

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

.back-to-top.show {
  display: flex;
}

@media (max-width: 768px) {
  .header-container {
    padding: 0 15px;
    height: 56px;
  }

  .logo a {
    font-size: 20px;
  }

  .main-nav {
    gap: 12px;
    font-size: 14px;
  }

  .main-nav a {
    padding: 6px 10px;
  }

  .hero-section {
    height: 300px;
  }

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

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

  .intro-section {
    padding: 20px;
  }

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

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

  .page--with-sidebar {
    grid-template-columns: 1fr;
  }

  .layout__side--filters {
    margin-bottom: 20px;
  }

  .top-list__item {
    flex-wrap: wrap;
    gap: 12px;
  }

  .top-cover {
    width: 100px;
    height: 150px;
  }

  .detail-module {
    padding: 20px;
  }

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

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
  }
}
