/* 韵光影视 - UI Style: modern-14 - Layout: E */

:root {
  --primary-color: #1e40af;
  --secondary-color: #06b6d4;
  --accent-color: #f59e0b;
  --text-color: #1f2937;
  --text-light: #6b7280;
  --bg-color: #ffffff;
  --bg-secondary: #f9fafb;
  --border-color: #e5e7eb;
  --spacing: 8px;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  line-height: 1.6;
  color: var(--text-color);
  background: var(--bg-secondary);
  font-size: 16px;
}

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

/* Header */
.site-header {
  background: var(--bg-color);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 60px;
  gap: calc(var(--spacing) * 2);
}

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

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

.site-header nav {
  flex: 1;
}

.site-header nav ul {
  list-style: none;
  display: flex;
  flex-wrap: nowrap;
  gap: 0;
  justify-content: flex-end;
  align-items: center;
  margin: 0;
  padding: 0;
}

.site-header nav li {
  flex: 0 1 auto;
  min-width: 0;
}

.site-header nav a {
  display: block;
  padding: calc(var(--spacing) * 1.5) calc(var(--spacing) * 2);
  color: var(--text-color);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.2s, background 0.2s;
  font-size: 0.95rem;
}

.site-header nav a:hover {
  color: var(--primary-color);
  background: var(--bg-secondary);
}

/* Mobile nav - single row, no wrap, no scroll */
@media (max-width: 768px) {
  .site-header .container {
    flex-direction: column;
    padding: calc(var(--spacing) * 1.5) calc(var(--spacing) * 2);
    gap: calc(var(--spacing) * 1.5);
  }

  .logo {
    font-size: 1.25rem;
  }

  .site-header nav {
    width: 100%;
  }

  .site-header nav ul {
    justify-content: space-between;
    flex-wrap: nowrap;
    overflow: visible;
  }

  .site-header nav li {
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
  }

  .site-header nav a {
    padding: calc(var(--spacing) * 1) calc(var(--spacing) * 0.5);
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .site-header nav a {
    font-size: 0.75rem;
    padding: calc(var(--spacing) * 1) calc(var(--spacing) * 0.25);
  }
}

/* Main Content */
.main-content {
  min-height: calc(100vh - 200px);
  padding: calc(var(--spacing) * 4) 0;
}

h1 {
  font-size: 2rem;
  margin-bottom: calc(var(--spacing) * 3);
  color: var(--primary-color);
  line-height: 1.2;
}

h2 {
  font-size: 1.5rem;
  margin: calc(var(--spacing) * 4) 0 calc(var(--spacing) * 2);
  color: var(--text-color);
}

h3 {
  font-size: 1.25rem;
  margin-bottom: calc(var(--spacing) * 1);
}

p {
  margin-bottom: calc(var(--spacing) * 2);
}

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

a:hover {
  color: var(--secondary-color);
  text-decoration: underline;
}

/* Hero */
.hero {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: white;
  padding: calc(var(--spacing) * 6) 0;
  margin-bottom: calc(var(--spacing) * 4);
  border-radius: calc(var(--spacing) * 1);
}

.hero h1 {
  color: white;
  margin: 0;
  text-align: center;
}

/* Sections */
section {
  margin-bottom: calc(var(--spacing) * 6);
}

.site-intro,
.intro {
  background: white;
  padding: calc(var(--spacing) * 3);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

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

.video-card {
  background: white;
  padding: calc(var(--spacing) * 3);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  transition: transform 0.2s, box-shadow 0.2s;
}

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

.video-card h3 {
  margin-bottom: calc(var(--spacing) * 1.5);
}

.video-card .meta {
  display: flex;
  gap: calc(var(--spacing) * 1);
  flex-wrap: wrap;
  margin-bottom: calc(var(--spacing) * 1.5);
  font-size: 0.875rem;
  color: var(--text-light);
}

.video-card .meta span {
  padding: calc(var(--spacing) * 0.5) calc(var(--spacing) * 1);
  background: var(--bg-secondary);
  border-radius: calc(var(--spacing) * 0.5);
}

.video-card .oneline {
  color: var(--text-light);
  font-size: 0.95rem;
  margin: 0;
}

/* Video List */
.video-list {
  display: flex;
  flex-direction: column;
  gap: calc(var(--spacing) * 2);
}

.video-item {
  background: white;
  padding: calc(var(--spacing) * 3);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.video-item h3 {
  margin-bottom: calc(var(--spacing) * 1);
}

.video-item .meta {
  display: flex;
  gap: calc(var(--spacing) * 1.5);
  flex-wrap: wrap;
  margin-bottom: calc(var(--spacing) * 1.5);
  font-size: 0.875rem;
  color: var(--text-light);
}

/* Portal Grid */
.portal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: calc(var(--spacing) * 3);
}

.portal-card {
  background: white;
  padding: calc(var(--spacing) * 4);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

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

/* Ranking List */
.ranking-list {
  display: flex;
  flex-direction: column;
  gap: calc(var(--spacing) * 2);
}

.ranking-item {
  background: white;
  padding: calc(var(--spacing) * 3);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  display: flex;
  gap: calc(var(--spacing) * 3);
  align-items: flex-start;
}

.rank-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent-color);
  min-width: 50px;
  text-align: center;
  flex-shrink: 0;
}

.ranking-content {
  flex: 1;
}

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

.tag {
  padding: calc(var(--spacing) * 0.5) calc(var(--spacing) * 1.5);
  background: var(--bg-secondary);
  border-radius: calc(var(--spacing) * 3);
  font-size: 0.875rem;
  color: var(--text-light);
}

.recommend {
  color: var(--text-light);
  line-height: 1.8;
  margin: 0;
}

/* Topic List */
.topic-list {
  display: flex;
  flex-direction: column;
  gap: calc(var(--spacing) * 3);
}

.topic-item {
  background: white;
  padding: calc(var(--spacing) * 4);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.topic-intro {
  margin-top: calc(var(--spacing) * 2);
}

.topic-intro p {
  margin-bottom: calc(var(--spacing) * 1.5);
  line-height: 1.8;
}

.topic-intro .review {
  color: var(--text-light);
  font-style: italic;
  background: var(--bg-secondary);
  padding: calc(var(--spacing) * 2);
  border-left: 3px solid var(--accent-color);
  margin: 0;
}

/* Latest List */
.latest-list {
  display: flex;
  flex-direction: column;
  gap: calc(var(--spacing) * 2);
}

.latest-item {
  background: white;
  padding: calc(var(--spacing) * 3);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  display: flex;
  gap: calc(var(--spacing) * 3);
  align-items: flex-start;
}

.date-mark {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent-color);
  min-width: 100px;
  padding: calc(var(--spacing) * 1) calc(var(--spacing) * 1.5);
  background: var(--bg-secondary);
  border-radius: calc(var(--spacing) * 0.5);
  text-align: center;
  flex-shrink: 0;
}

.latest-content {
  flex: 1;
}

/* Year Group */
.year-group {
  margin-bottom: calc(var(--spacing) * 5);
}

.year-group h2 {
  background: var(--primary-color);
  color: white;
  padding: calc(var(--spacing) * 2);
  border-radius: calc(var(--spacing) * 1);
  margin-bottom: calc(var(--spacing) * 3);
}

/* Detail Page */
.detail-page .video-info dl {
  background: white;
  padding: calc(var(--spacing) * 3);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: calc(var(--spacing) * 2);
}

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

.detail-page .video-info dd {
  margin: 0;
}

.detail-page section {
  background: white;
  padding: calc(var(--spacing) * 3);
  border-radius: calc(var(--spacing) * 1);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  margin-bottom: calc(var(--spacing) * 3);
}

.detail-page section h2 {
  margin-top: 0;
  padding-bottom: calc(var(--spacing) * 2);
  border-bottom: 2px solid var(--border-color);
}

.detail-page .video-summary p,
.detail-page .video-review p {
  line-height: 1.8;
  text-align: justify;
}

/* Footer */
.site-footer {
  background: var(--text-color);
  color: white;
  padding: calc(var(--spacing) * 4) 0;
  margin-top: calc(var(--spacing) * 8);
}

.footer-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: calc(var(--spacing) * 3);
  margin-bottom: calc(var(--spacing) * 3);
}

.footer-nav a {
  color: white;
  text-decoration: none;
  transition: opacity 0.2s;
}

.footer-nav a:hover {
  opacity: 0.8;
  text-decoration: underline;
}

.copyright {
  text-align: center;
  color: rgba(255,255,255,0.7);
  font-size: 0.875rem;
  margin: 0;
}

/* Responsive */
@media (max-width: 768px) {
  .container {
    padding: 0 calc(var(--spacing) * 2);
  }

  h1 {
    font-size: 1.5rem;
  }

  h2 {
    font-size: 1.25rem;
  }

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

  .ranking-item,
  .latest-item {
    flex-direction: column;
  }

  .rank-number {
    font-size: 1.5rem;
  }

  .date-mark {
    min-width: auto;
  }

  .detail-page .video-info dl {
    grid-template-columns: 1fr;
    gap: calc(var(--spacing) * 1);
  }
}