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

:root {
  --primary-color: #1a73e8;
  --text-dark: #202124;
  --text-light: #5f6368;
  --bg-light: #f8f9fa;
  --border-color: #dadce0;
  --shadow: 0 2px 8px rgba(0,0,0,0.1);
  --spacing: 1rem;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text-dark);
  background: #fff;
}

.ui-style-0 { --primary-color: #ff4444; }
.ui-style-1 { --primary-color: #ff6600; }
.ui-style-2 { --primary-color: #4CAF50; }
.ui-style-3 { --primary-color: #e91e63; }
.ui-style-4 { --primary-color: #2196F3; }
.ui-style-5 { --primary-color: #e50914; }
.ui-style-6 { --primary-color: #0099ff; }
.ui-style-7 { --primary-color: #00a8e1; }
.ui-style-8 { --primary-color: #00b140; }
.ui-style-9 { --primary-color: #000; }
.ui-style-10 { --primary-color: #00C75A; }
.ui-style-11 { --primary-color: #0099FF; }
.ui-style-12 { --primary-color: #FF6700; }
.ui-style-13 { --primary-color: #00A1D6; }
.ui-style-14 { --primary-color: #003d79; }

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

.site-header {
  background: #fff;
  border-bottom: 1px solid var(--border-color);
  padding: var(--spacing) 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.site-logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
  white-space: nowrap;
}

.site-logo a {
  color: inherit;
  text-decoration: none;
}

.main-nav {
  display: flex;
  gap: 1rem;
  white-space: nowrap;
}

.main-nav a {
  color: var(--text-dark);
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: all 0.2s;
  white-space: nowrap;
}

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

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

.hero-section {
  background: linear-gradient(135deg, var(--primary-color) 0%, rgba(26, 115, 232, 0.8) 100%);
  color: #fff;
  padding: 3rem 0;
  text-align: center;
}

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

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

.intro-section {
  padding: 2rem 0;
  background: var(--bg-light);
}

.intro-section p {
  line-height: 1.8;
  color: var(--text-light);
  font-size: 1rem;
}

.video-section {
  padding: 2rem 0;
}

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

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

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

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

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

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

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

.video-info {
  padding: 1rem;
}

.video-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.video-one-line {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.4;
  margin-bottom: 0.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.video-meta {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.85rem;
  color: var(--text-light);
}

.video-meta span {
  background: var(--bg-light);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.page-header {
  padding: 2rem 0;
  border-bottom: 2px solid var(--primary-color);
  margin-bottom: 2rem;
}

.page-header h1 {
  font-size: 2rem;
  color: var(--text-dark);
}

.top-list__items {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.top-list__item {
  display: flex;
  gap: 1rem;
  background: #fff;
  border-radius: 8px;
  padding: 1rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s;
}

.top-list__item:hover {
  transform: translateX(4px);
}

.rank-badge {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: var(--primary-color);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
}

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

.top-item-link img {
  width: 120px;
  height: 68px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}

.top-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.top-item-info h3 {
  font-size: 1.1rem;
  font-weight: 600;
}

.top-item-info p {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.top-item-info .meta {
  font-size: 0.85rem;
  color: var(--text-light);
}

.video-player-section {
  background: #000;
  padding: 2rem 0;
}

.video-player {
  max-width: 1000px;
  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;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  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: 2rem;
  color: var(--primary-color);
  margin-left: 4px;
}

.detail-page {
  padding-bottom: 2rem;
}

.detail-header {
  padding: 2rem 0 1rem;
}

.detail-header h1 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-dark);
}

.detail-info {
  background: var(--bg-light);
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 2rem;
}

.detail-info h2 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

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

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

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

.detail-module {
  margin-bottom: 2rem;
}

.detail-module h2 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-dark);
  padding-left: 0.5rem;
  border-left: 4px solid var(--primary-color);
}

.detail-module p {
  line-height: 1.8;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  background: var(--primary-color);
  color: #fff;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
}

.related-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 2px solid var(--border-color);
}

.site-footer {
  background: var(--text-dark);
  color: #fff;
  padding: 2rem 0;
  margin-top: 3rem;
  text-align: center;
}

.site-footer p {
  opacity: 0.8;
}

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

  .main-nav {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

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

  .main-nav a {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }

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

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

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

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

  .video-info {
    padding: 0.75rem;
  }

  .video-title {
    font-size: 1rem;
  }

  .video-one-line {
    font-size: 0.85rem;
    -webkit-line-clamp: 1;
  }

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

  .top-item-link img {
    width: 100%;
    height: auto;
  }

  .detail-header h1 {
    font-size: 1.5rem;
  }

  .detail-info dl {
    grid-template-columns: 1fr;
  }

  .detail-info dt {
    margin-top: 0.5rem;
  }

  .detail-info dt:first-child {
    margin-top: 0;
  }

  .player-play-btn {
    width: 60px;
    height: 60px;
  }

  .player-play-icon {
    font-size: 1.5rem;
  }
}

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