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

:root {
  --primary-color: #ff0000;
  --secondary-color: #fff;
  --text-color: #333;
  --bg-color: #fff;
  --border-color: #e0e0e0;
  --hover-color: #ff3333;
  --card-bg: #fff;
}

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);
}

.ui-style-4 {
  --primary-color: #ff0000;
  --secondary-color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

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

.site-header {
  background: var(--secondary-color);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
}

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

.site-nav {
  display: flex;
  gap: 5px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.site-nav a {
  padding: 8px 15px;
  text-decoration: none;
  color: var(--text-color);
  border-radius: 4px;
  transition: all 0.2s;
  font-size: 14px;
}

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

.hero-section {
  background: linear-gradient(135deg, #fff 0%, #f5f5f5 100%);
  padding: 60px 0;
  text-align: center;
}

.hero-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-color);
  margin-bottom: 20px;
  line-height: 1.4;
}

.hero-desc {
  font-size: 16px;
  color: #666;
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.8;
}

.intro-section {
  padding: 40px 0;
  background: var(--bg-color);
}

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

.video-section {
  padding: 40px 0;
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 24px;
  color: var(--text-color);
  border-left: 4px solid var(--primary-color);
  padding-left: 12px;
}

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

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

.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: #f5f5f5;
  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;
  color: var(--text-color);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.video-meta {
  font-size: 13px;
  color: #888;
  margin-bottom: 8px;
}

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

.page-header {
  padding: 40px 0 20px;
  text-align: center;
}

.page-header h1 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-color);
}

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

.top-list-section {
  padding: 20px 0;
}

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

.top-list__item {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  margin-bottom: 16px;
  background: var(--card-bg);
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

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

.top-list__item .video-cover {
  width: 160px;
  flex-shrink: 0;
  padding-top: 90px;
}

.top-list__item .video-info {
  flex: 1;
  padding: 0;
}

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

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

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

.layout__with-sidebar {
  display: flex;
  gap: 30px;
  padding: 20px 0;
}

.layout__side--filters {
  width: 240px;
  flex-shrink: 0;
  background: var(--card-bg);
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.layout__main {
  flex: 1;
}

.page--grouped {
  padding: 20px 0;
}

.group {
  margin-bottom: 40px;
}

.group__title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--text-color);
  border-left: 4px solid var(--primary-color);
  padding-left: 12px;
}

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

.detail-page {
  padding: 20px 0 40px;
}

.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: 8px;
  overflow: hidden;
}

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

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

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

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

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

.detail-info,
.detail-module,
.related-section {
  margin-bottom: 30px;
  background: var(--card-bg);
  padding: 24px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.detail-info h2,
.detail-module h2,
.related-section h2 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-color);
  border-left: 4px solid var(--primary-color);
  padding-left: 12px;
}

.info-list {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px 20px;
  line-height: 1.8;
}

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

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

.detail-module p {
  font-size: 15px;
  line-height: 1.8;
  color: #555;
}

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

.tag {
  display: inline-block;
  padding: 6px 14px;
  background: #f5f5f5;
  color: var(--text-color);
  border-radius: 20px;
  font-size: 14px;
  border: 1px solid var(--border-color);
}

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

.video-card--related {
  box-shadow: 0 1px 4px rgba(0,0,0,0.1);
}

.site-footer {
  background: #f5f5f5;
  padding: 30px 0;
  text-align: center;
  margin-top: 60px;
  border-top: 1px solid var(--border-color);
}

.site-footer p {
  color: #888;
  font-size: 14px;
}

@media (max-width: 768px) {
  .site-header .container {
    flex-direction: column;
    gap: 10px;
  }

  .site-nav {
    width: 100%;
    justify-content: space-between;
    gap: 3px;
  }

  .site-nav a {
    padding: 6px 8px;
    font-size: 13px;
  }

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

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

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

  .video-info {
    padding: 12px;
  }

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

  .top-list__item {
    flex-direction: column;
    align-items: flex-start;
  }

  .top-list__item .video-cover {
    width: 100%;
  }

  .layout__with-sidebar {
    flex-direction: column;
  }

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

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

  .site-nav a {
    padding: 5px 6px;
    font-size: 12px;
  }
}
