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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  color: #333;
  background: #f5f5f5;
}

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

.site-nav {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
}

.nav-brand {
  font-size: 1.5rem;
  font-weight: bold;
  color: #2c3e50;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

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

.nav-links a {
  color: #555;
  text-decoration: none;
  white-space: nowrap;
  padding: 0.5rem 0;
  transition: color 0.3s;
  flex-shrink: 0;
}

.nav-links a:hover,
.nav-links a.active {
  color: #3498db;
}

main {
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
  min-height: calc(100vh - 200px);
}

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

.hero-title {
  font-size: 2rem;
  margin-bottom: 1rem;
  line-height: 1.4;
}

.hero-subtitle {
  font-size: 1.1rem;
  opacity: 0.95;
  max-width: 800px;
  margin: 0 auto;
}

.intro-section {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 3rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.intro-content p {
  line-height: 1.8;
  color: #555;
}

.video-module {
  margin-bottom: 3rem;
}

.module-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.module-title {
  font-size: 1.5rem;
  color: #2c3e50;
}

.module-more {
  color: #3498db;
  text-decoration: none;
  font-size: 0.95rem;
}

.module-more:hover {
  text-decoration: underline;
}

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

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

.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%;
  background: #e0e0e0;
  overflow: hidden;
}

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

.video-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-overlay {
  opacity: 1;
}

.play-icon {
  font-size: 3rem;
  color: white;
}

.video-info {
  padding: 1rem;
}

.video-title {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: #2c3e50;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.video-meta {
  font-size: 0.85rem;
  color: #7f8c8d;
  margin-bottom: 0.5rem;
}

.video-one-line {
  font-size: 0.9rem;
  color: #555;
  line-height: 1.5;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.page-header {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 2rem;
}

.page-header h1 {
  font-size: 2rem;
  color: #2c3e50;
  margin-bottom: 0.5rem;
}

.page-header p {
  color: #7f8c8d;
}

.page--grid {
  max-width: 100%;
}

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

.layout__side--filters {
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  height: fit-content;
  position: sticky;
  top: 100px;
}

.layout__side--filters h3 {
  margin-bottom: 1rem;
  color: #2c3e50;
}

.layout__side--filters p {
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 0.5rem;
  line-height: 1.8;
}

.page--top {
  background: white;
  padding: 2rem;
  border-radius: 8px;
}

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

.top-item {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem;
  border-bottom: 1px solid #eee;
  transition: background 0.3s;
}

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

.top-rank {
  font-size: 1.5rem;
  font-weight: bold;
  color: #bdc3c7;
  min-width: 40px;
}

.top-rank.rank-1,
.top-rank.rank-2,
.top-rank.rank-3 {
  color: #f39c12;
}

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

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

.top-info {
  flex: 1;
}

.top-info h3 {
  margin-bottom: 0.5rem;
}

.top-info h3 a {
  color: #2c3e50;
  text-decoration: none;
}

.top-info h3 a:hover {
  color: #3498db;
}

.top-meta {
  font-size: 0.85rem;
  color: #7f8c8d;
  margin-bottom: 0.5rem;
}

.top-desc {
  font-size: 0.9rem;
  color: #555;
}

.page--grouped {
  max-width: 100%;
}

.group {
  margin-bottom: 3rem;
}

.group-title {
  font-size: 1.5rem;
  color: #2c3e50;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #3498db;
}

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

.video-player-section {
  margin-bottom: 2rem;
}

.video-player {
  background: #000;
  border-radius: 8px;
  overflow: hidden;
}

.video-player-inner {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
}

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

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

.player-play-icon {
  font-size: 2rem;
  color: white;
  margin-left: 5px;
}

.detail-header {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

.detail-header h1 {
  font-size: 2rem;
  color: #2c3e50;
}

.detail-info,
.detail-module {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

.detail-info h2,
.detail-module h2 {
  font-size: 1.3rem;
  color: #2c3e50;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #ecf0f1;
}

.detail-info dl {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 0.8rem 1rem;
}

.detail-info dt {
  font-weight: bold;
  color: #7f8c8d;
}

.detail-info dd {
  color: #2c3e50;
}

.detail-module p {
  line-height: 1.8;
  color: #555;
  margin-bottom: 1rem;
}

.tags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  background: #ecf0f1;
  color: #2c3e50;
  border-radius: 4px;
  font-size: 0.85rem;
}

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

.video-card--related .video-cover {
  padding-top: 56.25%;
}

.video-card--related .video-info {
  padding: 0.8rem;
}

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

.video-card--related .video-one-line {
  font-size: 0.85rem;
  -webkit-line-clamp: 2;
}

.site-footer {
  background: #2c3e50;
  color: white;
  text-align: center;
  padding: 2rem;
  margin-top: 3rem;
}

.site-footer p {
  margin: 0.5rem 0;
  opacity: 0.9;
}

@media (max-width: 768px) {
  .site-nav {
    padding: 1rem;
  }

  .nav-brand {
    font-size: 1.2rem;
  }

  .nav-links {
    gap: 1rem;
  }

  .nav-links a {
    font-size: 0.9rem;
  }

  main {
    padding: 1rem;
  }

  .hero-section {
    padding: 2rem 1rem;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

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

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

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

  .layout__side--filters {
    position: static;
  }

  .top-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

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

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

  .detail-info dl {
    grid-template-columns: 80px 1fr;
    gap: 0.5rem;
  }

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

.ui-style-5 {
  --primary-color: #000;
  --accent-color: #FF6700;
  --bg-color: #f5f5f5;
}

.ui-style-5 .hero-section {
  background: linear-gradient(135deg, #000 0%, #333 100%);
}

.ui-style-5 .nav-links a:hover,
.ui-style-5 .nav-links a.active {
  color: var(--accent-color);
}

.ui-style-5 .video-card:hover {
  box-shadow: 0 6px 20px rgba(255, 103, 0, 0.2);
}

.ui-style-5 .module-more {
  color: var(--accent-color);
}

.ui-style-5 .player-play-btn {
  border-color: var(--accent-color);
}

.ui-style-5 .player-play-btn:hover {
  background: rgba(255, 103, 0, 0.2);
}

.ui-style-5 .group-title {
  border-bottom-color: var(--accent-color);
}

.ui-style-5 .top-rank.rank-1,
.ui-style-5 .top-rank.rank-2,
.ui-style-5 .top-rank.rank-3 {
  color: var(--accent-color);
}
