:root {
  --emerald-50: #ecfdf5;
  --emerald-100: #d1fae5;
  --emerald-500: #10b981;
  --emerald-600: #059669;
  --emerald-700: #047857;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-500: #6b7280;
  --gray-700: #374151;
  --gray-900: #111827;
  --ink: #0f172a;
  --white: #ffffff;
  --shadow-soft: 0 20px 60px rgba(15, 23, 42, 0.12);
  --shadow-card: 0 18px 45px rgba(15, 23, 42, 0.10);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, var(--gray-50), #ffffff 45%, var(--emerald-50));
  min-height: 100vh;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid rgba(229, 231, 235, 0.88);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  max-width: 1240px;
  height: 68px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand {
  font-size: 22px;
  color: var(--gray-900);
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 13px;
  color: white;
  background: linear-gradient(135deg, var(--emerald-500), var(--emerald-700));
  box-shadow: 0 12px 28px rgba(16, 185, 129, 0.32);
  font-size: 14px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  color: var(--gray-700);
  font-size: 15px;
  font-weight: 700;
}

.main-nav a {
  transition: color 0.2s ease;
}

.main-nav a:hover {
  color: var(--emerald-600);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--gray-100);
  color: var(--gray-900);
}

.hero-carousel {
  position: relative;
  max-width: 1240px;
  margin: 28px auto 0;
  padding: 0 22px;
}

.hero-track {
  position: relative;
  min-height: 590px;
  overflow: hidden;
  border-radius: 34px;
  box-shadow: var(--shadow-soft);
  background: #020617;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 34px;
  align-items: center;
  padding: 64px;
  color: white;
  transition: opacity 0.55s ease;
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.65), rgba(2, 6, 23, 0.32)), var(--hero-image);
  background-position: center;
  background-size: cover;
  transform: scale(1.04);
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: auto -10% -25% 25%;
  height: 280px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.42), transparent 66%);
}

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

.hero-copy,
.hero-poster {
  position: relative;
  z-index: 2;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 8px 13px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--emerald-100);
  background: rgba(16, 185, 129, 0.14);
  border: 1px solid rgba(16, 185, 129, 0.30);
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 20px 0 18px;
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.06em;
}

.hero-copy p,
.page-hero p,
.detail-copy p {
  margin: 0;
  max-width: 760px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 18px;
  line-height: 1.85;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 5px 10px;
  color: var(--emerald-700);
  background: var(--emerald-50);
  font-size: 12px;
  font-weight: 800;
}

.hero-tags span {
  color: white;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.btn,
.quick-search button,
.filter-bar button,
.full-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 12px 20px;
  border: 1px solid transparent;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover,
.quick-search button:hover,
.filter-bar button:hover,
.full-link:hover {
  transform: translateY(-2px);
}

.btn.primary,
.quick-search button,
.filter-bar button,
.full-link {
  color: white;
  background: linear-gradient(135deg, var(--emerald-500), var(--emerald-700));
  box-shadow: 0 16px 32px rgba(16, 185, 129, 0.28);
}

.btn.ghost {
  color: white;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.24);
}

.btn.soft {
  color: var(--emerald-100);
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(16, 185, 129, 0.22);
}

.hero-poster {
  width: min(100%, 360px);
  justify-self: center;
  padding: 12px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(14px);
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 20px;
}

.hero-dots {
  position: absolute;
  left: 44px;
  right: 44px;
  bottom: 22px;
  z-index: 5;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.hero-dot {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
  color: rgba(255, 255, 255, 0.78);
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(10px);
}

.hero-dot.is-active {
  color: white;
  background: rgba(16, 185, 129, 0.36);
  border-color: rgba(16, 185, 129, 0.58);
}

.hero-dot img {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  object-fit: cover;
}

.hero-dot span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  font-weight: 900;
}

.section-wrap,
.search-panel {
  max-width: 1240px;
  margin: 0 auto;
  padding: 56px 22px;
}

.compact-panel {
  padding-top: 34px;
  padding-bottom: 20px;
}

.search-panel h2 {
  margin: 0 0 18px;
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.04em;
}

.quick-search,
.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
}

.filter-bar {
  grid-template-columns: minmax(200px, 1fr) minmax(140px, auto) minmax(140px, auto) auto;
  margin-top: 26px;
}

.quick-search input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--gray-200);
  border-radius: 999px;
  padding: 0 18px;
  outline: none;
  background: white;
  color: var(--gray-900);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.quick-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--emerald-500);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.14);
}

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

.section-heading h2 {
  margin: 10px 0 0;
  font-size: clamp(28px, 3.5vw, 44px);
  letter-spacing: -0.05em;
}

.section-kicker {
  color: var(--emerald-700);
  background: var(--emerald-50);
}

.section-heading > a {
  color: var(--emerald-700);
  font-weight: 900;
}

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

.category-tile,
.category-overview-card a {
  display: block;
  min-height: 158px;
  padding: 24px;
  border: 1px solid rgba(16, 185, 129, 0.14);
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, #ffffff, var(--emerald-50));
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.category-overview-card a:hover,
.movie-card:hover,
.top-rank-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 28px 60px rgba(15, 23, 42, 0.14);
}

.category-tile span,
.category-overview-card span {
  font-size: 20px;
  font-weight: 950;
  letter-spacing: -0.03em;
}

.category-tile p,
.category-overview-card p {
  margin: 12px 0 0;
  color: var(--gray-500);
  line-height: 1.7;
}

.category-overview-card b {
  display: inline-block;
  margin-top: 16px;
  color: var(--emerald-700);
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: white;
  border: 1px solid rgba(229, 231, 235, 0.92);
  box-shadow: 0 14px 38px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.poster-link {
  position: relative;
  overflow: hidden;
  display: block;
  background: var(--gray-100);
}

.poster-link img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.poster-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  border-radius: 999px;
  padding: 6px 10px;
  color: white;
  background: rgba(5, 150, 105, 0.88);
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(10px);
}

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

.movie-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--gray-500);
  font-size: 12px;
  font-weight: 800;
}

.movie-card h3 {
  margin: 8px 0;
  font-size: 18px;
  letter-spacing: -0.03em;
  line-height: 1.3;
}

.movie-card h3 a:hover {
  color: var(--emerald-700);
}

.movie-card p {
  margin: 0;
  color: var(--gray-500);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 74px;
  line-height: 1.65;
  font-size: 14px;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

.ranking-card,
.ranking-page-list {
  border-radius: var(--radius-lg);
  padding: 24px;
  background: #0f172a;
  color: white;
  box-shadow: var(--shadow-soft);
}

.ranking-card h2 {
  margin: 0 0 18px;
  font-size: 28px;
}

.rank-list,
.ranking-page-list {
  display: grid;
  gap: 12px;
}

.rank-item {
  display: grid;
  grid-template-columns: 44px 56px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.06);
  transition: background 0.2s ease, transform 0.2s ease;
}

.rank-item:hover {
  transform: translateX(4px);
  background: rgba(16, 185, 129, 0.18);
}

.rank-item strong {
  color: var(--emerald-500);
  font-size: 18px;
}

.rank-item img {
  width: 56px;
  height: 72px;
  border-radius: 12px;
  object-fit: cover;
}

.rank-item span {
  min-width: 0;
}

.rank-item b,
.rank-item em {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rank-item em {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.56);
  font-style: normal;
  font-size: 13px;
}

.full-link {
  width: 100%;
  margin-top: 18px;
}

.page-hero,
.detail-hero {
  max-width: 1240px;
  margin: 28px auto 0;
  border-radius: 34px;
  color: white;
  background: radial-gradient(circle at top right, rgba(16, 185, 129, 0.38), transparent 35%), linear-gradient(135deg, #0f172a, #064e3b);
  box-shadow: var(--shadow-soft);
}

.page-hero {
  padding: 68px;
}

.page-hero p {
  color: rgba(255, 255, 255, 0.76);
}

.slim-hero,
.category-hero,
.search-hero,
.rank-hero {
  margin-left: auto;
  margin-right: auto;
}

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

.top-rank-card a {
  position: relative;
  display: grid;
  min-height: 360px;
  overflow: hidden;
  border-radius: var(--radius-xl);
  color: white;
  box-shadow: var(--shadow-card);
}

.top-rank-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.top-rank-card a::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.88));
}

.top-rank-card strong,
.top-rank-card span,
.top-rank-card em {
  position: relative;
  z-index: 2;
  align-self: end;
  margin: 0 22px;
}

.top-rank-card strong {
  align-self: start;
  justify-self: start;
  margin-top: 20px;
  width: 52px;
  height: 52px;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--emerald-600);
  font-size: 24px;
}

.top-rank-card span {
  font-size: 24px;
  font-weight: 950;
}

.top-rank-card em {
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.72);
  font-style: normal;
  line-height: 1.6;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  background: #020617;
}

.detail-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.44)), var(--hero-image);
  background-size: cover;
  background-position: center;
  filter: saturate(1.08);
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  padding: 42px;
}

.crumb,
.crumb-sep {
  color: rgba(255, 255, 255, 0.72);
  font-weight: 800;
}

.detail-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 36px;
  align-items: center;
  margin-top: 30px;
}

.detail-poster {
  width: 280px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 24px;
  border: 10px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 24px 55px rgba(0, 0, 0, 0.38);
}

.detail-copy h1 {
  font-size: clamp(34px, 5vw, 68px);
}

.tag-row.large span {
  min-height: 34px;
  padding: 7px 12px;
}

.detail-section {
  padding-bottom: 24px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: var(--shadow-soft);
}

.movie-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 0;
  color: white;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.28), rgba(2, 6, 23, 0.50) 58%);
  cursor: pointer;
}

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

.play-overlay span {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--emerald-500), var(--emerald-700));
  box-shadow: 0 18px 45px rgba(16, 185, 129, 0.35);
  font-size: 28px;
}

.play-overlay b {
  font-size: 18px;
}

.content-section {
  padding-top: 12px;
  padding-bottom: 24px;
}

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

.detail-article h2 {
  margin: 0 0 14px;
  font-size: 30px;
  letter-spacing: -0.04em;
}

.detail-article p {
  color: var(--gray-700);
  line-height: 2;
  font-size: 17px;
}

.detail-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0 26px;
}

.detail-meta div {
  padding: 16px;
  border-radius: 16px;
  background: var(--gray-50);
}

.detail-meta dt {
  color: var(--gray-500);
  font-size: 12px;
  font-weight: 900;
}

.detail-meta dd {
  margin: 6px 0 0;
  font-weight: 900;
}

.site-footer {
  margin-top: 58px;
  padding: 46px 22px 28px;
  color: rgba(255, 255, 255, 0.72);
  background: #0f172a;
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 0.7fr);
  gap: 30px;
}

.footer-brand {
  color: white;
  font-size: 24px;
}

.footer-inner p {
  max-width: 680px;
  line-height: 1.8;
}

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

.footer-links a:hover {
  color: var(--emerald-500);
}

.copyright {
  max-width: 1240px;
  margin: 26px auto 0;
  color: rgba(255, 255, 255, 0.48);
  font-size: 14px;
}

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

@media (max-width: 1040px) {
  .hero-slide,
  .detail-layout,
  .split-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-slide {
    padding: 44px;
  }

  .hero-poster {
    display: none;
  }

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

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

@media (max-width: 760px) {
  .nav-wrap {
    height: auto;
    min-height: 64px;
    flex-wrap: wrap;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .main-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-bottom: 12px;
  }

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

  .main-nav a {
    padding: 12px 0;
    border-top: 1px solid var(--gray-200);
  }

  .hero-carousel,
  .page-hero,
  .detail-hero {
    margin-top: 16px;
  }

  .hero-track {
    min-height: 620px;
    border-radius: 24px;
  }

  .hero-slide {
    padding: 28px;
  }

  .hero-dots {
    left: 24px;
    right: 24px;
    grid-template-columns: 1fr;
  }

  .hero-dot:not(.is-active) {
    display: none;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 34px;
  }

  .page-hero,
  .detail-hero-inner {
    padding: 30px 22px;
    border-radius: 24px;
  }

  .section-wrap,
  .search-panel {
    padding: 36px 16px;
  }

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

  .quick-search,
  .filter-bar {
    grid-template-columns: 1fr;
  }

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

  .detail-poster {
    width: 100%;
    max-width: 260px;
  }

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

  .detail-article {
    padding: 24px;
  }

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