:root {
  --teal-900: #134e4a;
  --teal-800: #115e59;
  --teal-700: #0f766e;
  --teal-600: #0d9488;
  --teal-500: #14b8a6;
  --amber-500: #f59e0b;
  --red-600: #dc2626;
  --gray-950: #030712;
  --gray-900: #111827;
  --gray-800: #1f2937;
  --gray-700: #374151;
  --gray-600: #4b5563;
  --gray-500: #6b7280;
  --gray-300: #d1d5db;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --gray-50: #f9fafb;
  --white: #ffffff;
  --shadow-soft: 0 14px 34px rgba(15, 23, 42, 0.12);
  --shadow-card: 0 8px 20px rgba(15, 23, 42, 0.10);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, var(--gray-50) 0%, var(--white) 46%, #ecfeff 100%);
  color: var(--gray-800);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--teal-700) 0%, var(--teal-900) 100%);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.20);
}

.nav-bar {
  width: min(1200px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand {
  font-size: 22px;
}

.brand-icon {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--teal-800);
  background: var(--white);
  box-shadow: inset 0 0 0 3px rgba(20, 184, 166, 0.16);
  font-size: 15px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
  font-weight: 650;
}

.nav-links a,
.mobile-menu a {
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: #ccfbf1;
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  cursor: pointer;
}

.menu-button span {
  display: block;
  width: 21px;
  height: 2px;
  margin: 5px auto;
  background: var(--white);
  border-radius: 999px;
}

.mobile-menu {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

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

.mobile-menu > a,
.mobile-cats a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
}

.mobile-menu > a:hover,
.mobile-menu > a.active,
.mobile-cats a:hover {
  background: rgba(255, 255, 255, 0.12);
}

.mobile-cats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin-top: 8px;
}

.page-shell {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 10px;
}

.hero-carousel {
  position: relative;
  height: 600px;
  overflow: hidden;
  border-radius: var(--radius-xl);
  margin-bottom: 46px;
  background: var(--gray-900);
  box-shadow: var(--shadow-soft);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.54) 48%, rgba(0, 0, 0, 0.08) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  width: min(680px, 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 54px;
  color: var(--white);
}

.hero-labels,
.hero-tags,
.detail-meta,
.tag-list,
.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
}

.hero-labels span,
.hero-tags span,
.detail-meta span,
.tag-list span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 14px;
}

.hero-labels span:first-child {
  background: var(--teal-600);
}

.hero-labels span:last-child {
  background: var(--amber-500);
}

.hero-tags span {
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
}

.hero-content h1 {
  margin: 18px 0 14px;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1.08;
}

.hero-content p {
  margin: 0 0 24px;
  color: #e5e7eb;
  font-size: 19px;
}

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

.primary-button,
.ghost-button,
.quick-search button,
.filter-reset {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border-radius: 999px;
  padding: 0 24px;
  font-weight: 750;
  border: 0;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.primary-button,
.quick-search button {
  color: var(--white);
  background: var(--teal-600);
  box-shadow: 0 12px 24px rgba(13, 148, 136, 0.35);
}

.primary-button:hover,
.quick-search button:hover,
.filter-reset:hover {
  transform: translateY(-2px) scale(1.02);
  background: var(--teal-700);
}

.ghost-button {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.ghost-button:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.24);
}

.hero-dots {
  position: absolute;
  right: 26px;
  bottom: 24px;
  display: flex;
  gap: 9px;
}

.hero-dots button {
  width: 10px;
  height: 10px;
  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-dots button.is-active {
  width: 34px;
  background: var(--white);
}

.quick-search {
  margin: -12px 0 48px;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.quick-search form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: end;
}

.quick-search label,
.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--gray-600);
  font-weight: 700;
  font-size: 14px;
}

.quick-search input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 48px;
  border: 1px solid var(--gray-200);
  border-radius: 14px;
  padding: 0 15px;
  color: var(--gray-800);
  background: var(--white);
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.quick-search input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--teal-500);
  box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.16);
}

.content-section {
  margin-bottom: 64px;
}

.section-heading,
.section-row {
  margin-bottom: 24px;
}

.section-heading h2,
.section-row h2,
.rank-column h2,
.detail-content h2 {
  margin: 0;
  color: var(--gray-800);
  font-size: clamp(26px, 4vw, 34px);
  line-height: 1.2;
}

.section-heading p,
.section-row p {
  margin: 8px 0 0;
  color: var(--gray-500);
}

.section-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
}

.section-row > a {
  color: var(--teal-700);
  font-weight: 750;
  white-space: nowrap;
}

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

.poster-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 20px;
}

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-card);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.18);
}

.cover-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--gray-900);
}

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

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

.cover-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.72) 100%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

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

.play-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--white);
  background: var(--teal-600);
  transform: translate(-50%, -50%) scale(0.72);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.movie-card:hover .play-badge {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.year-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  border-radius: 999px;
  padding: 4px 10px;
  color: var(--white);
  background: var(--amber-500);
  font-size: 13px;
  font-weight: 800;
}

.card-body {
  display: grid;
  gap: 8px;
  padding: 16px;
}

.card-body strong {
  min-height: 48px;
  display: -webkit-box;
  overflow: hidden;
  color: var(--gray-800);
  font-size: 17px;
  line-height: 1.4;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  transition: color 0.2s ease;
}

.movie-card:hover .card-body strong {
  color: var(--teal-700);
}

.card-body em {
  min-height: 44px;
  display: -webkit-box;
  overflow: hidden;
  color: var(--gray-600);
  font-size: 14px;
  font-style: normal;
  line-height: 1.55;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  justify-content: space-between;
  color: var(--gray-500);
  font-size: 12px;
}

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

.category-tile,
.category-card {
  display: grid;
  gap: 10px;
  border-radius: var(--radius-lg);
  padding: 22px;
  background: linear-gradient(135deg, rgba(20, 184, 166, 0.13), rgba(245, 158, 11, 0.12));
  border: 1px solid rgba(20, 184, 166, 0.18);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-tile strong,
.category-card strong {
  color: var(--gray-800);
  font-size: 20px;
}

.category-tile span,
.category-card em {
  color: var(--gray-600);
  font-style: normal;
  font-size: 14px;
}

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

.category-card {
  padding: 18px;
  background: var(--white);
}

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

.category-covers img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 12px;
  background: var(--gray-900);
}

.inner-hero {
  margin-bottom: 30px;
  border-radius: var(--radius-xl);
  padding: 52px;
  color: var(--white);
  background: radial-gradient(circle at 20% 0%, rgba(20, 184, 166, 0.95), transparent 34%), linear-gradient(135deg, var(--teal-900), var(--gray-950));
  box-shadow: var(--shadow-soft);
}

.inner-hero span,
.eyebrow {
  display: inline-flex;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 12px;
  color: #ccfbf1;
  background: rgba(255, 255, 255, 0.13);
  font-size: 14px;
  font-weight: 800;
}

.inner-hero h1 {
  max-width: 760px;
  margin: 16px 0 10px;
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.12;
}

.inner-hero p {
  max-width: 760px;
  margin: 0;
  color: #d1fae5;
  font-size: 18px;
}

.filter-panel {
  margin-bottom: 28px;
  border-radius: var(--radius-lg);
  padding: 20px;
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.filter-title {
  margin-bottom: 14px;
  color: var(--gray-800);
  font-size: 19px;
  font-weight: 850;
}

.filter-controls {
  display: grid;
  grid-template-columns: 1.7fr 1fr 1fr 1fr auto;
  gap: 14px;
  align-items: end;
}

.filter-reset {
  color: var(--white);
  background: var(--teal-600);
}

.movie-card.is-hidden {
  display: none;
}

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

.rank-column {
  min-width: 0;
}

.rank-column h2 {
  margin-bottom: 18px;
  font-size: 26px;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 42px 96px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-width: 0;
  border-radius: var(--radius-md);
  padding: 12px;
  background: var(--white);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.rank-num {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--white);
  background: var(--red-600);
  font-weight: 900;
}

.rank-item img {
  width: 96px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 12px;
  background: var(--gray-900);
}

.rank-info {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.rank-info strong,
.rank-info em,
.rank-info span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-info strong {
  color: var(--gray-800);
}

.rank-info em,
.rank-info span {
  color: var(--gray-500);
  font-size: 13px;
  font-style: normal;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: var(--gray-500);
  font-size: 14px;
}

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

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.8fr);
  gap: 26px;
  margin-bottom: 40px;
}

.player-panel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: var(--gray-950);
  box-shadow: var(--shadow-soft);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  background: var(--gray-950);
}

.play-layer {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  cursor: pointer;
  color: var(--white);
  background: radial-gradient(circle at center, rgba(13, 148, 136, 0.36), rgba(0, 0, 0, 0.58));
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.play-layer span {
  width: 92px;
  height: 92px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--teal-600);
  box-shadow: 0 18px 34px rgba(13, 148, 136, 0.38);
  font-size: 36px;
}

.play-layer.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  border-radius: var(--radius-xl);
  padding: 30px;
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.detail-info h1 {
  margin: 0;
  color: var(--gray-800);
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.16;
}

.detail-info p {
  margin: 0;
  color: var(--gray-600);
  font-size: 17px;
}

.detail-meta span,
.tag-list span {
  color: var(--teal-800);
  background: #ccfbf1;
  font-weight: 750;
}

.tag-list span {
  color: var(--gray-700);
  background: var(--gray-100);
}

.detail-content article {
  border-radius: var(--radius-xl);
  padding: 34px;
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.detail-content h2 {
  margin-top: 0;
  font-size: 26px;
}

.detail-content p {
  margin: 0 0 26px;
  color: var(--gray-700);
  font-size: 17px;
}

.detail-content p:last-child {
  margin-bottom: 0;
}

.site-footer {
  margin-top: 80px;
  color: var(--gray-300);
  background: var(--gray-900);
}

.footer-grid {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0 30px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 34px;
}

.footer-brand {
  color: var(--white);
  font-size: 22px;
}

.footer-grid p {
  max-width: 420px;
  color: var(--gray-300);
}

.footer-grid h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 18px;
}

.footer-grid ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 9px;
}

.footer-grid a:hover {
  color: var(--teal-500);
}

.footer-bottom {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--gray-500);
  text-align: center;
}

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

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

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

  .rank-columns,
  .detail-hero,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

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

  .menu-button {
    display: block;
  }

  .brand {
    font-size: 18px;
  }

  .page-shell {
    width: min(100% - 24px, 1200px);
    padding-top: 22px;
  }

  .hero-carousel {
    height: 520px;
    border-radius: 18px;
  }

  .hero-content {
    padding: 28px;
  }

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

  .quick-search form,
  .filter-controls,
  .ranking-list.compact,
  .category-overview {
    grid-template-columns: 1fr;
  }

  .movie-grid,
  .all-grid,
  .related-grid,
  .poster-strip,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

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

  .inner-hero,
  .detail-content article,
  .detail-info {
    padding: 24px;
  }

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

  .rank-item img {
    width: 82px;
  }
}

@media (max-width: 480px) {
  .movie-grid,
  .all-grid,
  .related-grid,
  .poster-strip,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .hero-carousel {
    height: 560px;
  }

  .hero-actions {
    display: grid;
  }

  .hero-dots {
    right: 18px;
    bottom: 18px;
  }
}
