:root {
  --color-amber: #f59e0b;
  --color-amber-dark: #d97706;
  --color-green: #16a34a;
  --color-green-dark: #166534;
  --color-ink: #1f2937;
  --color-muted: #6b7280;
  --color-soft: #fff7ed;
  --color-panel: #ffffff;
  --shadow-card: 0 12px 30px rgba(31, 41, 55, 0.10);
  --shadow-hover: 0 22px 46px rgba(31, 41, 55, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--color-ink);
  background: linear-gradient(180deg, #fffbeb 0%, #f0fdf4 46%, #eff6ff 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.68;
}

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

img {
  display: block;
  max-width: 100%;
}

.container {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(255, 251, 235, 0.96), rgba(240, 253, 244, 0.96));
  border-bottom: 1px solid rgba(245, 158, 11, 0.18);
  backdrop-filter: blur(16px);
  box-shadow: 0 8px 24px rgba(31, 41, 55, 0.08);
}

.navbar {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 21px;
  letter-spacing: 0.02em;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-amber), var(--color-green));
  box-shadow: 0 10px 22px rgba(245, 158, 11, 0.28);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 14px;
  font-weight: 700;
}

.nav-links a {
  padding: 22px 0 18px;
  border-bottom: 3px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--color-amber-dark);
  border-bottom-color: var(--color-amber);
}

.nav-search {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-search input {
  width: 245px;
  border: 1px solid rgba(107, 114, 128, 0.25);
  border-radius: 999px;
  padding: 10px 16px 10px 40px;
  background: rgba(255, 255, 255, 0.82);
  outline: none;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.nav-search input:focus {
  border-color: var(--color-amber);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.nav-search span {
  position: absolute;
  left: 14px;
  color: #9ca3af;
}

.mobile-toggle {
  display: none;
  border: 0;
  border-radius: 12px;
  background: rgba(245, 158, 11, 0.12);
  padding: 10px 12px;
  font-size: 18px;
}

.mobile-menu {
  display: none;
  padding: 0 0 16px;
}

.mobile-menu.open {
  display: block;
}

.mobile-menu a {
  display: block;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 700;
}

.mobile-menu a:hover,
.mobile-menu a.active {
  color: var(--color-amber-dark);
  background: rgba(245, 158, 11, 0.12);
}

.hero {
  position: relative;
  min-height: 600px;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: #ffffff;
  background: #1f2937;
}

.hero-bg {
  position: absolute;
  inset: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.1);
  transform: scale(1.02);
}

.hero-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(circle at 82% 26%, rgba(245, 158, 11, 0.34), transparent 28%),
    linear-gradient(90deg, rgba(120, 53, 15, 0.96) 0%, rgba(20, 83, 45, 0.86) 52%, rgba(15, 23, 42, 0.68) 100%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.72fr);
  align-items: center;
  gap: 36px;
  padding: 64px 0 84px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  color: #fde68a;
  font-weight: 800;
}

.hero h1 {
  margin: 22px 0 18px;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 1.04;
  letter-spacing: -0.05em;
  text-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
}

.hero-desc {
  max-width: 720px;
  margin: 0 0 28px;
  color: #ffedd5;
  font-size: clamp(18px, 2vw, 24px);
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 28px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: #ffffff;
  background: var(--color-amber);
  box-shadow: 0 14px 28px rgba(245, 158, 11, 0.34);
}

.btn-primary:hover {
  background: var(--color-amber-dark);
}

.btn-ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(12px);
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 12px;
  color: #92400e;
  background: rgba(254, 243, 199, 0.95);
  font-size: 13px;
  font-weight: 800;
}

.hero-card {
  border-radius: 28px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

.hero-card-image {
  position: relative;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #f59e0b, #16a34a);
}

.hero-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-card-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 28%, rgba(0, 0, 0, 0.62));
}

.hero-card-body {
  padding: 22px;
}

.hero-card-title {
  margin: 0 0 10px;
  font-size: 24px;
  line-height: 1.25;
}

.hero-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #fde68a;
  font-size: 13px;
  font-weight: 800;
}

.hero-wave {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  z-index: 2;
  line-height: 0;
}

.section {
  padding: 58px 0;
}

.section.compact {
  padding: 34px 0;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.section-title {
  margin: 0;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.2;
}

.section-note {
  margin: 8px 0 0;
  color: var(--color-muted);
}

.link-more {
  color: var(--color-amber-dark);
  font-weight: 800;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: -32px;
  position: relative;
  z-index: 3;
}

.stat-card {
  padding: 22px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-card);
  border: 1px solid rgba(245, 158, 11, 0.18);
}

.stat-card strong {
  display: block;
  color: var(--color-amber-dark);
  font-size: 30px;
  line-height: 1;
}

.stat-card span {
  color: var(--color-muted);
  font-size: 13px;
  font-weight: 700;
}

.grid {
  display: grid;
  gap: 22px;
}

.grid.cards-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.grid.cards-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.movie-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow-card);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.poster {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #fef3c7, #bbf7d0);
}

.poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.movie-card:hover .poster img {
  transform: scale(1.08);
}

.poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 48%, rgba(0, 0, 0, 0.58));
  opacity: 0.9;
}

.badge {
  position: absolute;
  z-index: 2;
  left: 12px;
  top: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(245, 158, 11, 0.95);
  font-size: 12px;
  font-weight: 800;
}

.rating {
  position: absolute;
  z-index: 2;
  right: 12px;
  bottom: 12px;
  color: #fde68a;
  font-weight: 900;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.42);
}

.card-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-title {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
  color: var(--color-muted);
  font-size: 13px;
}

.card-desc {
  color: #4b5563;
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
}

.category-box {
  min-height: 150px;
  padding: 22px;
  border-radius: 24px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-amber), var(--color-green));
  box-shadow: 0 18px 38px rgba(22, 163, 74, 0.18);
  transition: transform 0.2s ease;
}

.category-box:hover {
  transform: translateY(-5px);
}

.category-box strong {
  display: block;
  font-size: 22px;
  margin-bottom: 8px;
}

.category-box span {
  color: rgba(255, 255, 255, 0.88);
  font-weight: 700;
}

.rank-list {
  display: grid;
  gap: 14px;
}

.rank-item {
  display: grid;
  grid-template-columns: 54px 96px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 12px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: var(--shadow-card);
}

.rank-number {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-amber), var(--color-green));
  font-size: 20px;
  font-weight: 900;
}

.rank-thumb {
  aspect-ratio: 16 / 10;
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(135deg, #fef3c7, #dcfce7);
}

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

.rank-title {
  margin: 0;
  font-size: 18px;
}

.rank-desc {
  margin: 4px 0 0;
  color: var(--color-muted);
  font-size: 14px;
}

.page-hero {
  color: #ffffff;
  padding: 56px 0;
  background:
    radial-gradient(circle at 76% 16%, rgba(253, 230, 138, 0.28), transparent 26%),
    linear-gradient(90deg, #b45309, #15803d);
}

.page-hero h1 {
  margin: 0 0 10px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.15;
}

.page-hero p {
  margin: 0;
  color: #ffedd5;
  font-size: 18px;
}

.toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 18px;
  margin-bottom: 28px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-card);
}

.toolbar input,
.toolbar select {
  width: 100%;
  min-height: 44px;
  border: 1px solid rgba(107, 114, 128, 0.25);
  border-radius: 14px;
  padding: 0 14px;
  background: #ffffff;
  outline: none;
}

.toolbar input:focus,
.toolbar select:focus {
  border-color: var(--color-amber);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 24px 0;
  color: var(--color-muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--color-amber-dark);
  font-weight: 800;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 28px;
}

.detail-panel,
.side-panel {
  border-radius: 26px;
  background: #ffffff;
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.video-shell {
  position: relative;
  background: #111827;
}

.video-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #111827;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background:
    radial-gradient(circle at center, rgba(245, 158, 11, 0.32), transparent 32%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.62));
  cursor: pointer;
}

.play-overlay.hidden {
  display: none;
}

.play-button {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(245, 158, 11, 0.92);
  box-shadow: 0 18px 38px rgba(245, 158, 11, 0.34);
  font-size: 38px;
  line-height: 1;
}

.detail-body {
  padding: 28px;
}

.detail-title {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.2;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.detail-meta span,
.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 12px;
  background: #fef3c7;
  color: #92400e;
  font-size: 13px;
  font-weight: 800;
}

.content-block {
  margin-top: 28px;
}

.content-block h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.content-block p {
  margin: 0;
  color: #374151;
}

.side-panel {
  padding: 18px;
}

.side-panel h2 {
  margin: 4px 0 14px;
  font-size: 22px;
}

.side-link {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid #f3f4f6;
}

.side-link:first-of-type {
  border-top: 0;
}

.side-link img {
  width: 82px;
  height: 52px;
  object-fit: cover;
  border-radius: 12px;
  background: #fef3c7;
}

.side-link strong {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 14px;
}

.side-link span {
  color: var(--color-muted);
  font-size: 12px;
}

.site-footer {
  margin-top: 60px;
  color: #d1d5db;
  background: linear-gradient(90deg, #1f2937, #111827);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 0.8fr;
  gap: 30px;
  padding: 44px 0;
}

.footer-inner h3 {
  margin: 0 0 12px;
  color: #ffffff;
}

.footer-inner p,
.footer-inner li {
  color: #9ca3af;
  font-size: 14px;
}

.footer-inner ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-inner li {
  margin: 8px 0;
}

.footer-bottom {
  padding: 18px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #9ca3af;
  font-size: 13px;
}

.no-results {
  display: none;
  padding: 42px;
  text-align: center;
  color: var(--color-muted);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow-card);
}

.cover-fallback {
  background: linear-gradient(135deg, #f59e0b, #16a34a);
}

@media (max-width: 980px) {
  .nav-links,
  .nav-search {
    display: none;
  }

  .mobile-toggle {
    display: inline-flex;
  }

  .hero-inner,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .stats-grid,
  .grid.cards-4,
  .grid.cards-3,
  .category-grid,
  .footer-inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 640px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .logo {
    font-size: 18px;
  }

  .hero-inner {
    padding: 44px 0 76px;
  }

  .hero h1 {
    letter-spacing: -0.03em;
  }

  .stats-grid,
  .grid.cards-4,
  .grid.cards-3,
  .category-grid,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .section-head {
    align-items: start;
    flex-direction: column;
  }

  .rank-item {
    grid-template-columns: 42px 78px minmax(0, 1fr);
  }

  .rank-score {
    grid-column: 3;
  }
}
