/* UI Style 5 - Layout C */

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  color: #2c3e50;
  background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf1 100%);
  min-height: 100vh;
}

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

/* Header & Navigation */
header {
  background: linear-gradient(to right, #2c3e50, #34495e);
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  font-size: 24px;
  font-weight: bold;
  color: #fff;
  text-decoration: none;
  letter-spacing: 1px;
}

nav ul {
  display: flex;
  flex-wrap: nowrap;
  list-style: none;
  gap: 5px;
  align-items: center;
}

nav ul li a {
  color: #ecf0f1;
  text-decoration: none;
  padding: 8px 15px;
  border-radius: 5px;
  transition: all 0.3s ease;
  display: block;
  white-space: nowrap;
  font-size: 15px;
}

nav ul li a:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
}

/* Main Content */
main {
  padding: 40px 0;
}

section {
  background: white;
  border-radius: 10px;
  padding: 30px;
  margin-bottom: 30px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

h1 {
  font-size: 32px;
  color: #2c3e50;
  margin-bottom: 20px;
  line-height: 1.3;
  border-left: 5px solid #3498db;
  padding-left: 15px;
}

h2 {
  font-size: 24px;
  color: #34495e;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid #ecf0f1;
}

h3 {
  font-size: 20px;
  color: #2c3e50;
  margin-bottom: 10px;
}

p {
  margin-bottom: 15px;
  color: #555;
  line-height: 1.8;
}

/* Video Cards */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 25px;
  margin-top: 20px;
}

.video-card {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
  border: 1px solid #e8ecf1;
}

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

.video-card-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 15px;
  font-weight: bold;
  font-size: 16px;
}

.video-card-body {
  padding: 15px;
}

.video-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 13px;
  color: #7f8c8d;
}

.meta-item {
  background: #ecf0f1;
  padding: 3px 10px;
  border-radius: 3px;
}

.video-desc {
  color: #555;
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 15px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn {
  display: inline-block;
  padding: 10px 20px;
  background: #3498db;
  color: white;
  text-decoration: none;
  border-radius: 5px;
  transition: all 0.3s ease;
  font-size: 14px;
}

.btn:hover {
  background: #2980b9;
  transform: translateY(-2px);
}

/* List Styles */
.video-list {
  list-style: none;
}

.video-list-item {
  border-bottom: 1px solid #ecf0f1;
  padding: 20px 0;
}

.video-list-item:last-child {
  border-bottom: none;
}

.video-list-title {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 10px;
}

.video-list-title a {
  color: #2c3e50;
  text-decoration: none;
  transition: color 0.3s ease;
}

.video-list-title a:hover {
  color: #3498db;
}

/* Detail Page */
.detail-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 40px;
  border-radius: 10px;
  margin-bottom: 30px;
}

.detail-title {
  font-size: 36px;
  margin-bottom: 20px;
  color: white;
  border: none;
  padding: 0;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 15px;
  margin: 20px 0;
}

.info-item {
  background: #f8f9fa;
  padding: 15px;
  border-radius: 5px;
  border-left: 3px solid #3498db;
}

.info-label {
  font-weight: bold;
  color: #2c3e50;
  margin-bottom: 5px;
  font-size: 14px;
}

.info-value {
  color: #555;
  font-size: 14px;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.tag {
  background: #e8ecf1;
  color: #34495e;
  padding: 5px 12px;
  border-radius: 15px;
  font-size: 13px;
}

.summary-box {
  background: #f8f9fa;
  padding: 20px;
  border-radius: 8px;
  border-left: 4px solid #3498db;
  margin: 20px 0;
}

.review-box {
  background: #fff9e6;
  padding: 20px;
  border-radius: 8px;
  border-left: 4px solid #f39c12;
  margin: 20px 0;
}

/* Related Videos */
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.related-card {
  background: #f8f9fa;
  padding: 15px;
  border-radius: 8px;
  border: 1px solid #e8ecf1;
  transition: all 0.3s ease;
}

.related-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  transform: translateY(-3px);
}

.related-card h4 {
  font-size: 16px;
  margin-bottom: 8px;
}

.related-card h4 a {
  color: #2c3e50;
  text-decoration: none;
}

.related-card h4 a:hover {
  color: #3498db;
}

.related-desc {
  font-size: 13px;
  color: #666;
  line-height: 1.5;
}

/* Footer */
footer {
  background: #2c3e50;
  color: #ecf0f1;
  text-align: center;
  padding: 20px;
  margin-top: 40px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: 15px;
    padding: 12px 15px;
  }

  .logo {
    font-size: 20px;
  }

  nav ul {
    width: 100%;
    justify-content: space-between;
    gap: 2px;
  }

  nav ul li {
    flex: 1 1 0;
    min-width: 0;
  }

  nav ul li a {
    padding: 6px 8px;
    font-size: 13px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  h1 {
    font-size: 24px;
  }

  h2 {
    font-size: 20px;
  }

  .video-grid {
    grid-template-columns: 1fr;
  }

  .detail-header {
    padding: 25px 20px;
  }

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

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

  section {
    padding: 20px 15px;
  }
}

@media (max-width: 480px) {
  nav ul li a {
    padding: 5px 4px;
    font-size: 12px;
  }

  .container {
    padding: 0 15px;
  }
}
