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

:root {
  --primary-color: #00C75A;
  --secondary-color: #111;
  --text-color: #333;
  --text-light: #666;
  --bg-color: #fff;
  --bg-alt: #f5f5f5;
  --border-color: #e0e0e0;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.15);
  --radius: 8px;
  --spacing: 8px;
}

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

.ui-style-8 {
  --primary-color: #00C75A;
  --secondary-color: #1a1a1a;
}

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

.site-header {
  background: var(--secondary-color);
  color: #fff;
  padding: calc(var(--spacing) * 2) 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.main-nav {
  display: flex;
  gap: calc(var(--spacing) * 3);
  white-space: nowrap;
  overflow-x: auto;
}

.main-nav a {
  color: #fff;
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s;
}

.main-nav a:hover {
  color: var(--primary-color);
}

.main-content {
  min-height: 60vh;
}

.hero-section {
  background: linear-gradient(135deg, var(--primary-color) 0%, #008f42 100%);
  color: #fff;
  padding: calc(var(--spacing) * 8) 0;
  text-align: center;
}

.page-title {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: calc(var(--spacing) * 2);
}

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

.site-intro {
  padding: calc(var(--spacing) * 6) 0;
  background: var(--bg-alt);
}

.intro-content p {
  font-size: 16px;
  line-height: 1.8;
  color: var(--text-light);
  max-width: 900px;
  margin: 0 auto;
}

.content-section {
  padding: calc(var(--spacing) * 6) 0;
}

.content-section.alt {
  background: var(--bg-alt);
}

.section-title {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: calc(var(--spacing) * 4);
  color: var(--secondary-color);
}

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

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

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

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

.video-cover {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: var(--bg-alt);
  overflow: hidden;
}

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

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

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

.video-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing));
  color: var(--secondary-color);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.video-meta {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: calc(var(--spacing));
}

.video-one-line {
  font-size: 14px;
  color: var(--text-light);
  line-height: 1.5;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.section-more {
  text-align: center;
  margin-top: calc(var(--spacing) * 4);
}

.btn-more {
  display: inline-block;
  padding: calc(var(--spacing) * 1.5) calc(var(--spacing) * 4);
  background: var(--primary-color);
  color: #fff;
  text-decoration: none;
  border-radius: var(--radius);
  font-weight: 600;
  transition: background 0.2s;
}

.btn-more:hover {
  background: #009748;
}

.list-page {
  padding: calc(var(--spacing) * 6) 0;
}

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

.list-page .page-title {
  color: var(--secondary-color);
  font-size: 36px;
}

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

.top-list__item {
  display: flex;
  align-items: center;
  gap: calc(var(--spacing) * 2);
  background: #fff;
  padding: calc(var(--spacing) * 2);
  margin-bottom: calc(var(--spacing) * 2);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: box-shadow 0.3s;
}

.top-list__item:hover {
  box-shadow: var(--shadow-hover);
}

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

.top-cover {
  width: 120px;
  height: 68px;
  flex-shrink: 0;
  border-radius: calc(var(--radius) / 2);
  overflow: hidden;
}

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

.top-info {
  flex: 1;
  min-width: 0;
}

.top-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) / 2);
}

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

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

.top-meta {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: calc(var(--spacing) / 2);
}

.top-one-line {
  font-size: 14px;
  color: var(--text-light);
  line-height: 1.5;
}

.detail-page {
  padding-bottom: calc(var(--spacing) * 8);
}

.video-player-section {
  background: #000;
  padding: calc(var(--spacing) * 4) 0;
}

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

.video-player-inner {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: linear-gradient(135deg, #222 0%, #111 100%);
  border-radius: var(--radius);
  overflow: hidden;
}

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

.player-play-btn:hover {
  background: rgba(0, 199, 90, 1);
  transform: translate(-50%, -50%) scale(1.1);
}

.player-play-icon {
  font-size: 32px;
  color: #fff;
  margin-left: 4px;
}

.detail-header {
  padding: calc(var(--spacing) * 4) 0 calc(var(--spacing) * 2);
}

.detail-title {
  font-size: 36px;
  font-weight: 700;
  color: var(--secondary-color);
  line-height: 1.3;
}

.detail-info {
  padding: calc(var(--spacing) * 3) 0;
  background: var(--bg-alt);
}

.info-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) * 2);
  color: var(--secondary-color);
}

.info-list {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: calc(var(--spacing) * 1.5);
  max-width: 800px;
}

.info-list dt {
  font-weight: 600;
  color: var(--text-light);
}

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

.detail-module {
  padding: calc(var(--spacing) * 4) 0;
  border-bottom: 1px solid var(--border-color);
}

.detail-module:last-of-type {
  border-bottom: none;
}

.module-title {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) * 3);
  color: var(--secondary-color);
}

.module-content {
  font-size: 16px;
  line-height: 1.8;
  color: var(--text-color);
  max-width: 900px;
}

.module-content p {
  margin-bottom: calc(var(--spacing) * 2);
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--spacing));
}

.tag {
  display: inline-block;
  padding: calc(var(--spacing) / 2) calc(var(--spacing) * 1.5);
  background: var(--primary-color);
  color: #fff;
  border-radius: calc(var(--radius) / 2);
  font-size: 14px;
}

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

.video-card--related {
  font-size: 14px;
}

.video-card--related .video-title {
  font-size: 16px;
  -webkit-line-clamp: 1;
}

.site-footer {
  background: var(--secondary-color);
  color: #fff;
  text-align: center;
  padding: calc(var(--spacing) * 4) 0;
  margin-top: calc(var(--spacing) * 6);
}

.site-footer p {
  font-size: 14px;
  opacity: 0.8;
}

.back-to-top {
  position: fixed;
  bottom: calc(var(--spacing) * 4);
  right: calc(var(--spacing) * 4);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--primary-color);
  color: #fff;
  border: none;
  font-size: 24px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  box-shadow: var(--shadow-hover);
}

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

.back-to-top:hover {
  background: #009748;
  transform: translateY(-2px);
}

@media (max-width: 768px) {
  .hero-section {
    padding: calc(var(--spacing) * 5) 0;
  }

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

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

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

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

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

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

  .top-list__item {
    flex-wrap: wrap;
  }

  .top-rank {
    min-width: 40px;
    font-size: 24px;
  }

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

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

  .info-list {
    grid-template-columns: 80px 1fr;
    gap: calc(var(--spacing));
  }

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

  .back-to-top {
    width: 45px;
    height: 45px;
    bottom: calc(var(--spacing) * 2);
    right: calc(var(--spacing) * 2);
  }
}

@media (max-width: 480px) {
  .video-grid {
    grid-template-columns: 1fr;
  }

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .top-list__item {
    padding: calc(var(--spacing) * 1.5);
  }

  .top-info {
    width: 100%;
  }
}
