:root {
  --color-bg: #f8fafc;
  --color-panel: #ffffff;
  --color-text: #111827;
  --color-muted: #6b7280;
  --color-soft: #f3f4f6;
  --color-border: #e5e7eb;
  --color-orange: #ea580c;
  --color-orange-dark: #c2410c;
  --color-red: #dc2626;
  --color-gold: #f59e0b;
  --shadow-soft: 0 10px 30px rgba(15, 23, 42, 0.08);
  --shadow-hover: 0 18px 45px rgba(15, 23, 42, 0.16);
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--color-text);
  background: var(--color-bg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  color: #ffffff;
  background: linear-gradient(90deg, #ea580c, #dc2626);
  box-shadow: 0 10px 30px rgba(194, 65, 12, 0.22);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.brand-text {
  font-size: 24px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-link {
  position: relative;
  font-weight: 600;
  opacity: 0.92;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  opacity: 1;
  transform: translateY(-1px);
}

.nav-link.active::after {
  position: absolute;
  right: 0;
  bottom: -12px;
  left: 0;
  height: 3px;
  content: "";
  border-radius: 999px;
  background: #ffffff;
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 9px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
}

.mobile-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 999px;
  background: #ffffff;
}

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

.mobile-link {
  display: block;
  padding: 11px 14px;
  border-radius: 12px;
  font-weight: 600;
}

.mobile-link:hover,
.mobile-link.active {
  background: rgba(255, 255, 255, 0.13);
}

.hero {
  position: relative;
  height: 560px;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(135deg, #7c2d12, #991b1b);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 900ms ease;
}

.hero-slide.active {
  opacity: 1;
}

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 15%, rgba(251, 146, 60, 0.28), transparent 34%),
    linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.28) 48%, rgba(0, 0, 0, 0.52));
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  height: 100%;
  padding-bottom: 70px;
}

.hero-copy {
  max-width: 760px;
}

.hero-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  margin-bottom: 18px;
  border-radius: 999px;
  background: #dc2626;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 14px 30px rgba(220, 38, 38, 0.34);
}

.hero h1,
.hero h2 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.hero p {
  max-width: 700px;
  margin: 0 0 26px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}

.btn-primary,
.btn-secondary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border: 0;
  border-radius: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  color: #ffffff;
  background: var(--color-orange);
  box-shadow: 0 12px 28px rgba(234, 88, 12, 0.28);
}

.btn-primary:hover {
  background: var(--color-orange-dark);
  transform: translateY(-2px);
}

.btn-secondary {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.17);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.26);
  transform: translateY(-2px);
}

.btn-ghost {
  color: var(--color-orange);
  background: #fff7ed;
}

.btn-ghost:hover {
  background: #ffedd5;
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.3);
}

.hero-arrow.prev {
  left: 22px;
}

.hero-arrow.next {
  right: 22px;
}

.hero-dots {
  position: absolute;
  z-index: 5;
  right: 0;
  bottom: 30px;
  left: 0;
  display: flex;
  justify-content: center;
  gap: 9px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.active {
  width: 34px;
  background: #ffffff;
}

.section {
  padding: 54px 0;
}

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

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

.section-eyebrow {
  color: var(--color-orange);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section h2,
.page-title {
  margin: 0;
  color: var(--color-text);
  font-size: clamp(26px, 3.2vw, 40px);
  line-height: 1.18;
}

.section-intro,
.page-desc {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--color-muted);
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.movie-grid.small {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.movie-card {
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-panel);
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  border-color: rgba(234, 88, 12, 0.32);
  box-shadow: var(--shadow-hover);
  transform: translateY(-4px);
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #111827;
}

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

.movie-card:hover .movie-cover img {
  transform: scale(1.07);
}

.movie-cover::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), transparent 42%);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.movie-card:hover .movie-cover::after {
  opacity: 1;
}

.type-badge,
.score-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 2px 9px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.type-badge {
  top: 10px;
  left: 10px;
  background: rgba(234, 88, 12, 0.92);
}

.score-badge {
  right: 10px;
  bottom: 10px;
  background: rgba(17, 24, 39, 0.82);
}

.rank-badge {
  top: 10px;
  right: 10px;
  background: rgba(220, 38, 38, 0.94);
}

.movie-card-body {
  padding: 16px;
}

.movie-card-title {
  display: -webkit-box;
  min-height: 48px;
  overflow: hidden;
  color: #111827;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.42;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-card-title:hover {
  color: var(--color-orange);
}

.movie-card-desc {
  display: -webkit-box;
  min-height: 44px;
  margin: 10px 0 12px;
  overflow: hidden;
  color: var(--color-muted);
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.tag-row span {
  padding: 3px 8px;
  border-radius: 999px;
  color: #9a3412;
  background: #fff7ed;
  font-size: 12px;
  font-weight: 700;
}

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

.category-card {
  display: block;
  padding: 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at top right, rgba(249, 115, 22, 0.12), transparent 42%),
    #ffffff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-card h3 {
  margin: 0 0 8px;
  font-size: 21px;
}

.category-card p {
  margin: 0 0 16px;
  color: var(--color-muted);
}

.category-count {
  color: var(--color-orange);
  font-weight: 800;
}

.page-hero {
  padding: 68px 0;
  color: #ffffff;
  background:
    radial-gradient(circle at 15% 20%, rgba(251, 146, 60, 0.35), transparent 28%),
    linear-gradient(90deg, #ea580c, #dc2626);
}

.page-hero .page-title {
  color: #ffffff;
}

.page-hero .page-desc {
  color: rgba(255, 255, 255, 0.88);
}

.filter-panel {
  padding: 22px;
  margin-top: -30px;
  border: 1px solid rgba(229, 231, 235, 0.86);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
}

.filter-grid {
  display: grid;
  grid-template-columns: 1fr 210px 210px;
  gap: 16px;
}

.filter-grid label {
  display: grid;
  gap: 8px;
  color: #374151;
  font-size: 14px;
  font-weight: 800;
}

.filter-grid input,
.filter-grid select {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  color: #111827;
  background: #ffffff;
  font: inherit;
}

.filter-grid input:focus,
.filter-grid select:focus {
  border-color: var(--color-orange);
  outline: 3px solid rgba(234, 88, 12, 0.14);
}

.filter-count {
  margin: 14px 0 0;
  color: var(--color-muted);
  font-size: 14px;
}

.ranking-list {
  display: grid;
  gap: 16px;
}

.ranking-row {
  display: grid;
  grid-template-columns: 58px 110px 1fr;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.ranking-number {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #ea580c, #dc2626);
  font-weight: 900;
}

.ranking-thumb {
  display: block;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  background: #111827;
}

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

.ranking-title {
  display: inline-block;
  margin-bottom: 6px;
  font-size: 20px;
  font-weight: 900;
}

.ranking-title:hover {
  color: var(--color-orange);
}

.ranking-info p {
  margin: 0 0 10px;
  color: var(--color-muted);
}

.breadcrumb {
  padding: 20px 0;
  color: var(--color-muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--color-orange);
  font-weight: 700;
}

.detail-shell {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 34px;
  align-items: start;
  padding: 34px;
  border: 1px solid var(--color-border);
  border-radius: 26px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.detail-poster {
  overflow: hidden;
  border-radius: 22px;
  background: #111827;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.detail-title {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.12;
}

.detail-subtitle {
  margin: 0 0 20px;
  color: var(--color-muted);
  font-size: 18px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 22px;
}

.detail-meta span {
  padding: 7px 12px;
  border-radius: 999px;
  color: #374151;
  background: var(--color-soft);
  font-weight: 700;
}

.content-card {
  padding: 28px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.content-card h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.content-card p {
  margin: 0 0 14px;
  color: #374151;
  font-size: 16px;
}

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #050505;
  box-shadow: var(--shadow-hover);
}

.player-card video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #050505;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #ffffff;
  background:
    linear-gradient(0deg, rgba(0, 0, 0, 0.68), rgba(0, 0, 0, 0.15)),
    radial-gradient(circle at center, rgba(234, 88, 12, 0.22), transparent 44%);
  text-align: center;
}

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

.play-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 0 26px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: var(--color-orange);
  box-shadow: 0 20px 45px rgba(234, 88, 12, 0.34);
  font-size: 18px;
  font-weight: 900;
  cursor: pointer;
}

.player-status {
  position: absolute;
  right: 18px;
  bottom: 16px;
  left: 18px;
  z-index: 3;
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  text-align: center;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 26px;
  align-items: start;
}

.side-panel {
  display: grid;
  gap: 16px;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.stat-card {
  padding: 24px;
  border-radius: var(--radius-lg);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
  text-align: center;
}

.stat-number {
  color: var(--color-orange);
  font-size: 32px;
  font-weight: 900;
}

.stat-label {
  color: var(--color-muted);
  font-weight: 700;
}

.site-footer {
  margin-top: 54px;
  color: #d1d5db;
  background: #111827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1.2fr;
  gap: 28px;
  padding: 44px 0;
}

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

.site-footer p {
  margin: 0;
  color: #9ca3af;
}

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

.site-footer li {
  margin: 7px 0;
}

.site-footer a:hover {
  color: #fb923c;
}

.footer-brand {
  margin-bottom: 12px;
  color: #ffffff;
}

.empty-state {
  display: none;
  padding: 34px;
  border-radius: var(--radius-lg);
  color: var(--color-muted);
  background: #ffffff;
  text-align: center;
  box-shadow: var(--shadow-soft);
}

@media (max-width: 1080px) {
  .movie-grid,
  .movie-grid.small {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .detail-shell,
  .two-column {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    max-width: 360px;
  }

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

@media (max-width: 780px) {
  .desktop-nav {
    display: none;
  }

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

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

  .hero {
    height: 560px;
  }

  .hero-arrow {
    display: none;
  }

  .hero-content {
    padding-bottom: 78px;
  }

  .movie-grid,
  .movie-grid.small,
  .category-grid,
  .stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .ranking-row {
    grid-template-columns: 44px 86px 1fr;
    gap: 12px;
  }

  .ranking-title {
    font-size: 17px;
  }

  .detail-shell,
  .content-card {
    padding: 20px;
  }

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

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

  .brand-text {
    font-size: 20px;
  }

  .hero h1,
  .hero h2 {
    font-size: 34px;
  }

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

  .movie-grid,
  .movie-grid.small,
  .category-grid,
  .stat-grid {
    grid-template-columns: 1fr;
  }

  .section-header {
    display: block;
  }

  .ranking-row {
    grid-template-columns: 1fr;
  }

  .ranking-number {
    width: 42px;
  }
}
