:root {
  --primary-color: #3498db;
  --secondary-color: #2c3e50;
  --accent-color: #e74c3c;
  --success-color: #27ae60;
  --warning-color: #f39c12;
  --text-color: #333;
  --text-light: #7f8c8d;
  --bg-color: #f5f5f5;
  --card-bg: #ffffff;
  --border-color: #ecf0f1;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background: var(--bg-color);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

h1, h2, h3, h4, h5, h6 {
  line-height: 1.2;
  font-weight: 600;
}

h1 {
  font-size: 2rem;
}

h2 {
  font-size: 1.5rem;
}

h3 {
  font-size: 1.25rem;
}

p {
  line-height: 1.8;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: #2980b9;
  text-decoration: underline;
}

nav {
  background: var(--secondary-color);
  padding: 1rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 1000;
}

nav ul {
  list-style: none;
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

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

nav a {
  color: white;
  text-decoration: none;
  padding: 0.5rem 1rem;
  display: block;
  border-radius: 4px;
  transition: background 0.3s ease;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}

nav a:hover {
  background: #34495e;
  text-decoration: none;
}

.video-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

footer {
  background: var(--secondary-color);
  color: white;
  text-align: center;
  padding: 2rem;
  margin-top: 3rem;
}

.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--primary-color);
  color: white;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 999;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: #2980b9;
  transform: translateY(-4px);
}

@media (max-width: 768px) {
  nav ul {
    flex-wrap: nowrap;
    overflow-x: hidden;
    padding: 0;
  }

  nav ul li {
    font-size: 0.85rem;
    padding: 0.25rem;
  }

  nav a {
    padding: 0.4rem 0.5rem;
    font-size: 0.85rem;
  }

  h1 {
    font-size: 1.5rem;
  }

  h2 {
    font-size: 1.25rem;
  }

  main {
    padding: 0 1rem;
  }

  .back-to-top {
    width: 40px;
    height: 40px;
    bottom: 1rem;
    right: 1rem;
  }
}

@media (max-width: 480px) {
  nav a {
    padding: 0.3rem 0.3rem;
    font-size: 0.75rem;
  }

  h1 {
    font-size: 1.25rem;
  }
}

.ui-style-0 {
  --primary-color: #3498db;
  --accent-color: #e74c3c;
}

.ui-style-1 {
  --primary-color: #2ecc71;
  --accent-color: #f39c12;
}

.ui-style-2 {
  --primary-color: #9b59b6;
  --accent-color: #e74c3c;
}

.ui-style-3 {
  --primary-color: #1abc9c;
  --accent-color: #e67e22;
}

.ui-style-4 {
  --primary-color: #34495e;
  --accent-color: #3498db;
}

.ui-style-5 {
  --primary-color: #c0392b;
  --accent-color: #f39c12;
}

.ui-style-6 {
  --primary-color: #16a085;
  --accent-color: #d35400;
}

.ui-style-7 {
  --primary-color: #2c3e50;
  --accent-color: #e74c3c;
  --bg-color: #ecf0f1;
}

.ui-style-8 {
  --primary-color: #3498db;
  --accent-color: #2ecc71;
}

.ui-style-9 {
  --primary-color: #e67e22;
  --accent-color: #3498db;
}

.ui-style-10 {
  --primary-color: #95a5a6;
  --accent-color: #2980b9;
}

.ui-style-11 {
  --primary-color: #f39c12;
  --accent-color: #c0392b;
}

.ui-style-12 {
  --primary-color: #8e44ad;
  --accent-color: #16a085;
}

.ui-style-13 {
  --primary-color: #27ae60;
  --accent-color: #2c3e50;
}

.ui-style-14 {
  --primary-color: #2980b9;
  --accent-color: #8e44ad;
}

.ui-style-15 {
  --primary-color: #16a085;
  --accent-color: #27ae60;
}
