:root {
  --color-blue: #2563eb;
  --color-blue-dark: #1d4ed8;
  --color-cyan: #06b6d4;
  --color-slate: #111827;
  --color-gray: #4b5563;
  --color-soft: #f8fafc;
  --shadow-card: 0 10px 30px rgba(15, 23, 42, 0.12);
  --shadow-card-hover: 0 18px 42px rgba(15, 23, 42, 0.18);
  --radius-card: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--color-slate);
  background: linear-gradient(135deg, #f9fafb 0%, #eff6ff 100%);
  line-height: 1.6;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 6px 24px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(14px);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(90deg, var(--color-blue), var(--color-cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.28);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
}

.nav-link {
  font-weight: 650;
  color: #374151;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--color-blue);
}

.search-form {
  position: relative;
  width: 248px;
}

.search-form input {
  width: 100%;
  height: 42px;
  border: 1px solid #d1d5db;
  border-radius: 999px;
  padding: 0 18px 0 42px;
  outline: none;
  background: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-form input:focus {
  border-color: var(--color-blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.search-form::before {
  content: "⌕";
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: #9ca3af;
  font-size: 18px;
  line-height: 1;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: #111827;
  background: #f3f4f6;
  cursor: pointer;
}

.hero {
  position: relative;
  height: 600px;
  color: #ffffff;
  overflow: hidden;
  background: linear-gradient(100deg, #111827 0%, #1e3a8a 52%, #0e7490 100%);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.9s ease;
}

.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

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

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.52) 48%, rgba(0, 0, 0, 0.08) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
}

.hero-text {
  max-width: 680px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--color-blue);
  color: #ffffff;
  font-size: 14px;
  font-weight: 750;
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.35);
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(40px, 6vw, 64px);
  line-height: 1.06;
  font-weight: 850;
  letter-spacing: -0.05em;
}

.hero p {
  margin: 0 0 26px;
  font-size: clamp(18px, 2.2vw, 22px);
  color: #e5e7eb;
  max-width: 680px;
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 30px;
  color: #e5e7eb;
}

.hero-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.pill-light {
  padding: 5px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
}

.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  font-weight: 760;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary {
  color: #ffffff;
  background: var(--color-blue);
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.34);
}

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

.btn-secondary {
  color: var(--color-blue);
  background: #ffffff;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.08);
}

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

.hero-control {
  position: absolute;
  z-index: 5;
  top: 50%;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.13);
  backdrop-filter: blur(12px);
  cursor: pointer;
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-control:hover {
  background: rgba(255, 255, 255, 0.24);
}

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

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

.hero-dots {
  position: absolute;
  z-index: 5;
  left: 50%;
  bottom: 30px;
  display: flex;
  gap: 9px;
  transform: translateX(-50%);
}

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

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

.section-wrap {
  padding: 66px 0;
}

.section-wrap.tight {
  padding-top: 38px;
}

.section-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 28px;
}

.section-kicker {
  margin: 0 0 8px;
  color: var(--color-blue);
  font-weight: 800;
}

.section-title {
  margin: 0;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  font-weight: 850;
  letter-spacing: -0.04em;
}

.section-lead {
  max-width: 760px;
  margin: 12px 0 0;
  color: #64748b;
  font-size: 17px;
}

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

.category-card {
  min-height: 150px;
  padding: 24px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-icon {
  width: 50px;
  height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 22px;
  font-weight: 850;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
}

.category-card h3 {
  margin: 0 0 8px;
  font-size: 20px;
  line-height: 1.2;
}

.category-card p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
}

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: var(--radius-card);
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.09);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.movie-poster {
  position: relative;
  height: 212px;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #2563eb);
}

.movie-poster.large {
  height: 330px;
}

.movie-poster.compact {
  width: 160px;
  height: 98px;
  flex: 0 0 160px;
}

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

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

.movie-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 12px;
  border-radius: 999px;
  color: #ffffff;
  background: var(--color-blue);
  font-size: 12px;
  font-weight: 760;
}

.movie-content {
  padding: 20px;
}

.movie-content h3,
.movie-content h2 {
  margin: 0 0 10px;
  font-size: 19px;
  line-height: 1.32;
  font-weight: 820;
  transition: color 0.2s ease;
}

.movie-card:hover h3,
.movie-card:hover h2 {
  color: var(--color-blue);
}

.movie-desc {
  margin: 0 0 14px;
  color: #64748b;
  font-size: 14px;
}

.movie-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #6b7280;
  font-size: 13px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #f1f5f9;
}

.tag-row span,
.detail-tag {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  color: #475569;
  background: #f1f5f9;
  font-size: 12px;
  font-weight: 650;
}

.line-clamp-1,
.line-clamp-2,
.line-clamp-3 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-1 {
  -webkit-line-clamp: 1;
}

.line-clamp-2 {
  -webkit-line-clamp: 2;
}

.line-clamp-3 {
  -webkit-line-clamp: 3;
}

.gradient-panel {
  margin: 66px 0;
  padding: clamp(28px, 4vw, 48px);
  border-radius: 30px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
  box-shadow: 0 18px 50px rgba(37, 99, 235, 0.2);
}

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

.rank-item {
  display: flex;
  align-items: stretch;
  gap: 18px;
  padding: 14px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.rank-number {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  font-weight: 850;
}

.rank-content {
  min-width: 0;
  padding: 4px 0;
}

.rank-content h3 {
  margin: 0 0 8px;
  font-size: 18px;
}

.rank-content p {
  margin: 0 0 10px;
  color: #64748b;
  font-size: 14px;
}

.page-hero {
  padding: 70px 0;
  color: #ffffff;
  background: linear-gradient(100deg, var(--color-blue), var(--color-cyan));
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(36px, 5vw, 54px);
  line-height: 1.1;
  font-weight: 850;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: #dbeafe;
  font-size: 19px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: #e0f2fe;
  font-size: 14px;
}

.breadcrumbs a:hover {
  color: #ffffff;
}

.filter-panel {
  margin-bottom: 28px;
  padding: 20px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.filter-panel input {
  width: 100%;
  height: 48px;
  border: 1px solid #d1d5db;
  border-radius: 999px;
  padding: 0 20px;
  outline: none;
}

.filter-panel input:focus {
  border-color: var(--color-blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 30px;
  align-items: start;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  background: #000000;
  box-shadow: 0 22px 55px rgba(15, 23, 42, 0.28);
  aspect-ratio: 16 / 9;
}

.player-box video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-position: center;
  background-size: cover;
  cursor: pointer;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

.player-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.38);
}

.player-cover.is-hidden {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.play-button {
  position: relative;
  z-index: 2;
  width: 82px;
  height: 82px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: var(--color-blue);
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.34);
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.play-button:hover {
  background: var(--color-blue-dark);
  transform: scale(1.06);
}

.detail-card,
.related-panel {
  border-radius: 20px;
  background: #ffffff;
  box-shadow: var(--shadow-card);
}

.detail-card {
  margin-top: 28px;
  padding: clamp(24px, 4vw, 36px);
}

.detail-card h1 {
  margin: 0 0 16px;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.15;
  font-weight: 850;
  letter-spacing: -0.04em;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  margin-bottom: 26px;
  color: #64748b;
}

.detail-card h2 {
  margin: 28px 0 14px;
  font-size: 25px;
}

.detail-card p {
  color: #374151;
  font-size: 17px;
}

.review-box {
  margin-top: 18px;
  padding: 22px;
  border-radius: 18px;
  background: linear-gradient(135deg, #eff6ff, #ecfeff);
}

.related-panel {
  position: sticky;
  top: 92px;
  padding: 22px;
}

.related-panel h2 {
  margin: 0 0 18px;
  font-size: 22px;
}

.related-list {
  display: grid;
  gap: 18px;
}

.related-card {
  display: block;
}

.related-card .movie-poster {
  height: 160px;
  border-radius: 14px;
}

.related-card h3 {
  margin: 10px 0 6px;
  font-size: 16px;
  line-height: 1.35;
}

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

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  padding: 50px 0;
}

.footer-title {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: 22px;
  font-weight: 800;
}

.footer-grid p {
  margin: 0;
  color: #cbd5e1;
}

.footer-grid h3 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 16px;
}

.footer-links {
  display: grid;
  gap: 10px;
  color: #cbd5e1;
  font-size: 14px;
}

.footer-links a:hover {
  color: #60a5fa;
}

.footer-bottom {
  padding: 22px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: #94a3b8;
  font-size: 14px;
}

.empty-state {
  padding: 70px 20px;
  border-radius: 22px;
  background: #ffffff;
  text-align: center;
  box-shadow: var(--shadow-card);
}

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

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

  .related-panel {
    position: static;
  }

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

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    position: absolute;
    left: 0;
    right: 0;
    top: 68px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 20px 24px 24px;
    background: #ffffff;
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.12);
  }

  .nav-links.is-open {
    display: flex;
  }

  .search-form {
    width: 100%;
  }

  .hero {
    height: 560px;
  }

  .hero-control {
    display: none;
  }

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

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

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

  .logo {
    font-size: 21px;
  }

  .hero {
    height: 520px;
  }

  .hero h1 {
    font-size: 38px;
  }

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

  .movie-poster {
    height: 230px;
  }

  .rank-item {
    flex-direction: column;
  }

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