:root {
  --primary-blue: #00A1D6;
  --primary-pink: #FB7299;
  --text-dark: #222;
  --text-gray: #666;
  --bg-light: #f8f9fa;
  --border-color: #e1e4e8;
  --card-shadow: 0 2px 8px rgba(0,0,0,0.08);
  --card-shadow-hover: 0 4px 16px rgba(0,0,0,0.12);
  --transition: all 0.3s ease;
  --spacing: 8px;
}

* {
  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: var(--text-dark);
  background: var(--bg-light);
}

body.ui-style-14 {
  --primary-color: #00A1D6;
  --accent-color: #FB7299;
  --success-color: #52c41a;
  --warning-color: #faad14;
  --error-color: #f5222d;
}

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

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

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 calc(var(--spacing) * 2);
}

.logo {
  font-size: 24px;
  font-weight: 600;
  color: var(--primary-blue);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: calc(var(--spacing) * 1);
}

.nav {
  display: flex;
  gap: calc(var(--spacing) * 1);
  flex-wrap: nowrap;
  overflow: visible;
}

.nav a {
  color: var(--text-dark);
  text-decoration: none;
  padding: calc(var(--spacing) * 1) calc(var(--spacing) * 2);
  border-radius: calc(var(--spacing) * 1);
  transition: var(--transition);
  white-space: nowrap;
  font-size: 14px;
}

.nav a:hover {
  background: var(--bg-light);
  color: var(--primary-blue);
}

main {
  min-height: calc(100vh - 200px);
  padding: calc(var(--spacing) * 3) 0;
}

.hero {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 6) calc(var(--spacing) * 4);
  margin-bottom: calc(var(--spacing) * 4);
  box-shadow: var(--card-shadow);
  text-align: center;
}

.hero h1 {
  font-size: 36px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) * 2);
  line-height: 1.2;
  color: var(--text-dark);
}

.hero p {
  font-size: 16px;
  color: var(--text-gray);
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.8;
}

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

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: calc(var(--spacing) * 3);
}

.section-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-dark);
}

.section-more {
  color: var(--primary-blue);
  text-decoration: none;
  font-size: 14px;
  transition: var(--transition);
}

.section-more:hover {
  color: var(--primary-pink);
}

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

.video-card {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: var(--transition);
  cursor: pointer;
}

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

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

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

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

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

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

.video-title {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: calc(var(--spacing) * 1);
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.video-meta {
  display: flex;
  gap: calc(var(--spacing) * 2);
  font-size: 12px;
  color: var(--text-gray);
  margin-top: calc(var(--spacing) * 1);
}

.page-header {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 4);
  margin-bottom: calc(var(--spacing) * 3);
  box-shadow: var(--card-shadow);
}

.page-title {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) * 2);
}

.page-description {
  font-size: 15px;
  color: var(--text-gray);
  line-height: 1.8;
}

.page--top .top-list__items {
  list-style: none;
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 2);
  box-shadow: var(--card-shadow);
}

.page--top .top-item {
  display: flex;
  align-items: center;
  gap: calc(var(--spacing) * 3);
  padding: calc(var(--spacing) * 2);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.page--top .top-item:last-child {
  border-bottom: none;
}

.page--top .top-item:hover {
  background: var(--bg-light);
}

.top-rank {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 700;
  border-radius: calc(var(--spacing) * 1);
}

.top-item:nth-child(1) .top-rank {
  background: linear-gradient(135deg, #FFD700, #FFA500);
  color: #fff;
}

.top-item:nth-child(2) .top-rank {
  background: linear-gradient(135deg, #C0C0C0, #A9A9A9);
  color: #fff;
}

.top-item:nth-child(3) .top-rank {
  background: linear-gradient(135deg, #CD7F32, #8B4513);
  color: #fff;
}

.top-item:nth-child(n+4) .top-rank {
  background: var(--bg-light);
  color: var(--text-gray);
}

.top-cover {
  flex-shrink: 0;
  width: 80px;
  height: 112px;
  border-radius: calc(var(--spacing) * 1);
  overflow: hidden;
  background: var(--bg-light);
}

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

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

.top-title {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: calc(var(--spacing) * 1);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-desc {
  font-size: 13px;
  color: var(--text-gray);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.5;
}

.video-player-section {
  margin-bottom: calc(var(--spacing) * 4);
}

.video-player {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  overflow: hidden;
  box-shadow: var(--card-shadow);
}

.video-player-inner {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.player-play-btn {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  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: 32px;
  color: var(--primary-blue);
  margin-left: 4px;
}

.detail-header {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 4);
  margin-bottom: calc(var(--spacing) * 3);
  box-shadow: var(--card-shadow);
}

.detail-title {
  font-size: 32px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) * 3);
  line-height: 1.3;
}

.detail-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 3);
  background: var(--bg-light);
  border-radius: calc(var(--spacing) * 2);
}

.meta-item {
  display: flex;
  gap: calc(var(--spacing) * 1);
  font-size: 14px;
}

.meta-label {
  color: var(--text-gray);
  font-weight: 500;
}

.meta-value {
  color: var(--text-dark);
}

.detail-section {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 4);
  margin-bottom: calc(var(--spacing) * 3);
  box-shadow: var(--card-shadow);
}

.detail-section-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) * 2);
  padding-bottom: calc(var(--spacing) * 2);
  border-bottom: 2px solid var(--primary-blue);
}

.detail-section-content {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-dark);
}

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

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--spacing) * 1);
}

.tag {
  padding: calc(var(--spacing) * 1) calc(var(--spacing) * 2);
  background: var(--bg-light);
  border-radius: calc(var(--spacing) * 4);
  font-size: 13px;
  color: var(--text-dark);
  transition: var(--transition);
}

.tag:hover {
  background: var(--primary-blue);
  color: #fff;
}

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

.video-card--related {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  overflow: hidden;
  transition: var(--transition);
}

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

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

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

.video-card--related .video-title {
  font-size: 14px;
  margin-bottom: calc(var(--spacing) * 1);
}

.video-card--related .video-one-line {
  font-size: 12px;
}

footer {
  background: #fff;
  border-top: 1px solid var(--border-color);
  padding: calc(var(--spacing) * 4) 0;
  margin-top: calc(var(--spacing) * 6);
  text-align: center;
  color: var(--text-gray);
  font-size: 14px;
}

.back-to-top {
  position: fixed;
  bottom: calc(var(--spacing) * 4);
  right: calc(var(--spacing) * 4);
  width: 48px;
  height: 48px;
  background: var(--primary-blue);
  color: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transition: var(--transition);
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.back-to-top.show {
  display: flex;
}

.back-to-top:hover {
  background: var(--primary-pink);
  transform: translateY(-4px);
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 24px;
  }

  .hero p {
    font-size: 14px;
  }

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

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

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

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

  .video-one-line {
    font-size: 12px;
    -webkit-line-clamp: 1;
  }

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

  .nav {
    gap: 0;
    font-size: 13px;
  }

  .nav a {
    padding: calc(var(--spacing) * 0.5) calc(var(--spacing) * 1);
    font-size: 13px;
  }

  .logo {
    font-size: 18px;
  }

  .header-inner {
    height: 56px;
  }

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

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

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: calc(var(--spacing) * 2);
  }

  .page--top .top-item {
    gap: calc(var(--spacing) * 2);
  }

  .top-cover {
    width: 60px;
    height: 84px;
  }

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

  .top-desc {
    font-size: 12px;
  }
}

.intro-section {
  background: #fff;
  border-radius: calc(var(--spacing) * 2);
  padding: calc(var(--spacing) * 4);
  margin-bottom: calc(var(--spacing) * 4);
  box-shadow: var(--card-shadow);
}

.intro-section h2 {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: calc(var(--spacing) * 2);
  color: var(--text-dark);
}

.intro-section p {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-dark);
  margin-bottom: calc(var(--spacing) * 2);
}

.pagination {
  display: flex;
  justify-content: center;
  gap: calc(var(--spacing) * 1);
  margin-top: calc(var(--spacing) * 4);
  padding: calc(var(--spacing) * 3) 0;
}

.pagination a,
.pagination span {
  padding: calc(var(--spacing) * 1) calc(var(--spacing) * 2);
  background: #fff;
  border-radius: calc(var(--spacing) * 1);
  text-decoration: none;
  color: var(--text-dark);
  transition: var(--transition);
  box-shadow: var(--card-shadow);
}

.pagination a:hover {
  background: var(--primary-blue);
  color: #fff;
}

.pagination .current {
  background: var(--primary-blue);
  color: #fff;
}
