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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  line-height: 1.6;
  color: #333;
  background: #f5f5f5;
}

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

.site-header {
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}

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

.site-logo a {
  font-size: 24px;
  font-weight: bold;
  color: #2c3e50;
  text-decoration: none;
}

.site-nav {
  display: flex;
  gap: 5px;
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.site-nav::-webkit-scrollbar {
  display: none;
}

.nav-link {
  padding: 8px 16px;
  color: #555;
  text-decoration: none;
  white-space: nowrap;
  border-radius: 6px;
  transition: all 0.3s;
  font-size: 15px;
}

.nav-link:hover,
.nav-link.active {
  background: #e8f4ff;
  color: #1890ff;
}

.main-content {
  min-height: calc(100vh - 200px);
  padding: 20px 0;
}

.hero-section {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 60px 0;
  margin-bottom: 40px;
  border-radius: 12px;
}

.page-title {
  font-size: 32px;
  margin-bottom: 20px;
  line-height: 1.4;
}

.site-intro {
  font-size: 16px;
  line-height: 1.8;
  opacity: 0.95;
}

.section-title {
  font-size: 26px;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 3px solid #1890ff;
  color: #2c3e50;
}

.horizontal-scroll {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding-bottom: 20px;
  margin-bottom: 40px;
  -webkit-overflow-scrolling: touch;
}

.horizontal-scroll::-webkit-scrollbar {
  height: 8px;
}

.horizontal-scroll::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

.horizontal-scroll::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}

.scroll-item {
  flex: 0 0 280px;
}

.poster-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.poster-link img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transition: transform 0.3s;
}

.poster-link:hover img {
  transform: scale(1.05);
}

.poster-info {
  margin-top: 12px;
}

.poster-info h3 {
  font-size: 18px;
  font-weight: 600;
}

.video-grid-section {
  margin-bottom: 50px;
}

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

.video-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  transition: transform 0.3s, box-shadow 0.3s;
}

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

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

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

.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: white;
}

.video-info {
  padding: 16px;
}

.video-title {
  font-size: 18px;
  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;
  line-height: 1.5;
}

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

.video-player-section {
  background: #000;
  padding: 40px 0;
  margin-bottom: 40px;
}

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

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

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

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

.player-play-icon {
  font-size: 32px;
  color: #000;
}

.video-detail {
  background: white;
  padding: 40px;
  border-radius: 12px;
  margin-bottom: 40px;
}

.detail-title {
  font-size: 36px;
  margin-bottom: 30px;
  color: #2c3e50;
}

.detail-info {
  margin-bottom: 40px;
}

.module-title {
  font-size: 22px;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #eee;
  color: #2c3e50;
}

.info-list {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 12px;
  font-size: 16px;
}

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

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

.detail-module {
  margin-bottom: 40px;
}

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

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

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag {
  display: inline-block;
  padding: 6px 16px;
  background: #e8f4ff;
  color: #1890ff;
  border-radius: 20px;
  font-size: 14px;
}

.page--grid,
.page--with-sidebar,
.page--top,
.page--grouped {
  background: white;
  padding: 40px;
  border-radius: 12px;
}

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

.page-header h1 {
  font-size: 32px;
  color: #2c3e50;
  margin-bottom: 12px;
}

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

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

.layout__side--filters {
  padding: 20px;
  background: #f9f9f9;
  border-radius: 8px;
}

.layout__side--filters h3 {
  font-size: 18px;
  margin-bottom: 12px;
}

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

.top-item {
  display: flex;
  gap: 20px;
  padding: 20px;
  margin-bottom: 20px;
  background: #fafafa;
  border-radius: 12px;
  transition: background 0.3s;
}

.top-item:hover {
  background: #f0f0f0;
}

.top-rank {
  font-size: 32px;
  font-weight: bold;
  color: #1890ff;
  min-width: 50px;
}

.top-item-link {
  display: flex;
  gap: 20px;
  text-decoration: none;
  color: inherit;
  flex: 1;
}

.top-cover {
  width: 120px;
  height: 160px;
  object-fit: cover;
  border-radius: 8px;
}

.top-info {
  flex: 1;
}

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

.top-meta {
  color: #999;
  font-size: 14px;
  margin-bottom: 8px;
}

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

.group {
  margin-bottom: 50px;
}

.group__title {
  font-size: 24px;
  margin-bottom: 20px;
  color: #2c3e50;
}

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

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

.back-to-top {
  position: fixed;
  bottom: 40px;
  right: 40px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: #1890ff;
  color: white;
  border: none;
  font-size: 24px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  z-index: 999;
}

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

.back-to-top:hover {
  background: #096dd9;
  transform: translateY(-3px);
}

body.ui-style-7 {
  --primary-color: #00C75A;
  --primary-hover: #00B04E;
}

body.ui-style-7 .hero-section {
  background: linear-gradient(135deg, #00C75A 0%, #00E068 100%);
}

body.ui-style-7 .nav-link:hover,
body.ui-style-7 .nav-link.active {
  background: #e6f9f0;
  color: #00C75A;
}

body.ui-style-7 .section-title {
  border-bottom-color: #00C75A;
}

body.ui-style-7 .back-to-top {
  background: #00C75A;
}

body.ui-style-7 .back-to-top:hover {
  background: #00B04E;
}

body.ui-style-7 .tag {
  background: #e6f9f0;
  color: #00C75A;
}

@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: 12px;
  }

  .site-nav {
    width: 100%;
    justify-content: flex-start;
  }

  .nav-link {
    padding: 6px 12px;
    font-size: 14px;
  }

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

  .hero-section {
    padding: 30px 0;
  }

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

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

  .video-title {
    font-size: 16px;
  }

  .video-one-line {
    font-size: 13px;
    -webkit-line-clamp: 2;
  }

  .horizontal-scroll {
    gap: 12px;
  }

  .scroll-item {
    flex: 0 0 200px;
  }

  .poster-link img {
    height: 280px;
  }

  .video-detail {
    padding: 20px;
  }

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

  .info-list {
    grid-template-columns: 80px 1fr;
    font-size: 14px;
  }

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

  .layout__side--filters {
    order: 2;
  }

  .top-item {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .top-item-link {
    flex-direction: column;
    align-items: center;
  }

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

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
    font-size: 20px;
  }
}

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

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

  .scroll-item {
    flex: 0 0 160px;
  }

  .poster-link img {
    height: 240px;
  }
}
