:root {
  --page: #f6f8fc;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --text: #111827;
  --muted: #64748b;
  --line: #e5e7eb;
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --rose: #e11d48;
  --purple: #7c3aed;
  --amber: #f59e0b;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: radial-gradient(circle at top left, rgba(37, 99, 235, 0.12), transparent 28rem), var(--page);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

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;
  background: rgba(255, 255, 255, 0.86);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(18px);
}

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

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--rose));
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.28);
}

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

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

.nav-link,
.mobile-link {
  border-radius: 999px;
  color: #475569;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link {
  padding: 10px 16px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--blue-dark);
  background: rgba(37, 99, 235, 0.1);
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  padding: 9px;
  border: 0;
  border-radius: 12px;
  background: #eef2ff;
  cursor: pointer;
}

.menu-button span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 999px;
  background: #1e293b;
}

.mobile-panel {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
}

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

.mobile-panel nav,
.mobile-cats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.mobile-link,
.mobile-cats a {
  padding: 11px 14px;
  background: #ffffff;
  border: 1px solid var(--line);
}

.mobile-cats {
  margin-top: 10px;
}

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

.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a 0%, #1d4ed8 46%, #e11d48 100%);
  color: #ffffff;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  pointer-events: none;
}

.hero::before {
  width: 560px;
  height: 560px;
  right: -160px;
  top: -160px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.24), transparent 64%);
}

.hero::after {
  width: 420px;
  height: 420px;
  left: -150px;
  bottom: -220px;
  background: radial-gradient(circle, rgba(244, 63, 94, 0.4), transparent 66%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: min(1200px, calc(100% - 32px));
  min-height: 640px;
  margin: 0 auto;
  padding: 64px 0 72px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.72fr);
  gap: 38px;
  align-items: center;
}

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

.hero-pill,
.kicker,
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  border-radius: 999px;
  font-weight: 800;
}

.hero-pill {
  padding: 9px 14px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero h1 {
  margin: 18px 0 16px;
  font-size: clamp(38px, 6vw, 76px);
  line-height: 1.04;
  letter-spacing: -0.055em;
}

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

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

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

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

.btn-primary {
  color: #0f172a;
  background: #ffffff;
  box-shadow: 0 18px 32px rgba(15, 23, 42, 0.24);
}

.btn-ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.hero-search {
  width: min(650px, 100%);
  margin: 28px 0 0;
  display: flex;
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(18px);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  height: 44px;
  padding: 0 16px;
  color: #ffffff;
  border: 0;
  outline: 0;
  background: transparent;
}

.hero-search input::placeholder {
  color: rgba(255, 255, 255, 0.72);
}

.hero-search button {
  height: 44px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--rose), var(--amber));
  font-weight: 900;
  cursor: pointer;
}

.hero-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.hero-tabs a {
  padding: 8px 13px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.88);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.hero-showcase {
  position: relative;
}

.hero-slider {
  position: relative;
  min-height: 470px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  border-radius: 34px;
  opacity: 0;
  transform: scale(0.98) translateY(14px);
  transition: opacity 0.55s ease, transform 0.55s ease;
  background: rgba(15, 23, 42, 0.36);
  box-shadow: 0 30px 70px rgba(2, 6, 23, 0.36);
}

.hero-slide.is-active {
  position: relative;
  opacity: 1;
  transform: scale(1) translateY(0);
}

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

.hero-slide-body {
  padding: 24px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.72), rgba(15, 23, 42, 0.94));
}

.hero-slide-body h2 {
  margin: 0 0 9px;
  font-size: 29px;
  line-height: 1.18;
}

.hero-slide-body p {
  margin: 0 0 16px;
  color: rgba(255, 255, 255, 0.8);
}

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

.hero-tags span,
.tag-row span,
.meta-chip {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.hero-tags span {
  padding: 5px 9px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
}

.hero-dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 18px;
}

.hero-dots button {
  width: 30px;
  height: 6px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
  cursor: pointer;
}

.hero-dots button.is-active {
  background: #ffffff;
}

main {
  display: block;
}

.section {
  padding: 62px 0;
}

.section-tight {
  padding: 38px 0;
}

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

.kicker,
.page-kicker {
  padding: 6px 12px;
  color: var(--blue-dark);
  background: #dbeafe;
  font-size: 13px;
}

.section-head h2,
.page-title h1,
.detail-title h1 {
  margin: 8px 0 0;
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.section-head h2 {
  font-size: clamp(28px, 3vw, 42px);
}

.section-head p,
.page-title p,
.detail-title p {
  max-width: 740px;
  margin: 10px 0 0;
  color: var(--muted);
}

.section-link {
  flex: none;
  padding: 10px 16px;
  border-radius: 999px;
  color: var(--blue-dark);
  background: #dbeafe;
  font-weight: 900;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, #e0e7ff, #ffe4e6);
}

.movie-grid.large .poster-link,
.movie-card.compact .poster-link {
  aspect-ratio: 3 / 4;
}

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

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

.poster-year,
.poster-play {
  position: absolute;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  color: #ffffff;
  font-weight: 900;
}

.poster-year {
  top: 12px;
  right: 12px;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  font-size: 12px;
}

.poster-play {
  left: 50%;
  top: 50%;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(225, 29, 72, 0.9);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.9);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-body {
  padding: 18px;
}

.card-meta,
.detail-meta,
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.card-meta span,
.meta-chip {
  padding: 4px 9px;
  background: #f1f5f9;
}

.card-body h3 {
  margin: 12px 0 8px;
  font-size: 19px;
  line-height: 1.26;
}

.card-body h3 a:hover {
  color: var(--blue-dark);
}

.card-body p {
  min-height: 3.2em;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
}

.tag-row span {
  padding: 4px 8px;
  color: #475569;
  background: #eef2ff;
}

.category-strip,
.category-grid {
  display: grid;
  gap: 18px;
}

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

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 178px;
  padding: 24px;
  border-radius: var(--radius);
  color: #ffffff;
  background: linear-gradient(135deg, #1d4ed8, #7c3aed 55%, #e11d48);
  box-shadow: var(--shadow);
}

.category-card:nth-child(2n) {
  background: linear-gradient(135deg, #0f766e, #2563eb 58%, #f59e0b);
}

.category-card:nth-child(3n) {
  background: linear-gradient(135deg, #be123c, #7c3aed 58%, #2563eb);
}

.category-card span {
  display: inline-flex;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  font-weight: 800;
}

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

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
}

.category-card small {
  display: block;
  margin-top: 18px;
  color: rgba(255, 255, 255, 0.72);
  font-weight: 800;
}

.rank-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 26px;
  align-items: stretch;
}

.rank-feature {
  overflow: hidden;
  border-radius: 30px;
  color: #ffffff;
  background: #0f172a;
  box-shadow: var(--shadow);
}

.rank-feature img {
  width: 100%;
  height: 330px;
  object-fit: cover;
  opacity: 0.86;
}

.rank-feature-body {
  padding: 24px;
}

.rank-feature-body h3 {
  margin: 0 0 10px;
  font-size: 30px;
}

.rank-feature-body p {
  color: rgba(255, 255, 255, 0.78);
}

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

.rank-item {
  display: grid;
  grid-template-columns: 54px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 7px 18px rgba(15, 23, 42, 0.07);
}

.rank-item:hover {
  color: var(--blue-dark);
}

.rank-num {
  font-size: 22px;
  font-weight: 950;
  color: var(--rose);
}

.rank-title {
  font-weight: 900;
}

.rank-side {
  color: var(--muted);
  font-size: 13px;
}

.page-hero {
  padding: 48px 0 32px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.13), rgba(225, 29, 72, 0.08));
  border-bottom: 1px solid rgba(226, 232, 240, 0.86);
}

.page-title h1 {
  font-size: clamp(34px, 4vw, 56px);
}

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

.filter-search {
  display: flex;
  gap: 10px;
}

.filter-search input,
.filter-selects select {
  width: 100%;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #f8fafc;
  outline: 0;
}

.filter-search input {
  padding: 0 15px;
}

.filter-search button {
  min-width: 94px;
  border: 0;
  border-radius: 16px;
  color: #ffffff;
  background: var(--blue);
  font-weight: 900;
  cursor: pointer;
}

.filter-selects {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.filter-selects label span {
  display: block;
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.filter-selects select {
  padding: 0 12px;
}

.empty-state {
  display: none;
  padding: 38px;
  border-radius: 24px;
  text-align: center;
  color: var(--muted);
  background: #ffffff;
}

.empty-state.is-visible {
  display: block;
}

.breadcrumb {
  margin-bottom: 18px;
}

.breadcrumb a:hover {
  color: var(--blue-dark);
}

.detail-hero {
  padding: 38px 0 24px;
}

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

.player-card,
.detail-card,
.side-card {
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.09);
}

.player-card {
  overflow: hidden;
}

.player-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.player-frame video {
  width: 100%;
  height: 100%;
  display: block;
  background: #020617;
}

.play-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 12px;
  padding: 24px;
  color: #ffffff;
  border: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.2), rgba(2, 6, 23, 0.78));
  cursor: pointer;
}

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

.play-cover span {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--rose), var(--amber));
  box-shadow: 0 18px 38px rgba(225, 29, 72, 0.38);
  font-size: 28px;
}

.play-cover strong {
  font-size: clamp(20px, 3vw, 34px);
}

.detail-title {
  margin-bottom: 22px;
}

.detail-title h1 {
  font-size: clamp(32px, 4vw, 56px);
}

.detail-meta {
  margin: 14px 0 0;
}

.meta-chip {
  color: #334155;
  background: #e0f2fe;
}

.detail-card {
  padding: 28px;
  margin-top: 24px;
}

.detail-card h2,
.side-card h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

.detail-card p {
  margin: 0 0 18px;
  color: #334155;
}

.detail-cover {
  overflow: hidden;
  border-radius: 28px;
  background: linear-gradient(135deg, #dbeafe, #ffe4e6);
  box-shadow: var(--shadow);
}

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

.side-card {
  padding: 22px;
  margin-top: 22px;
}

.side-links {
  display: grid;
  gap: 12px;
}

.side-links a {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 12px;
  align-items: center;
}

.side-links img {
  width: 54px;
  height: 72px;
  border-radius: 12px;
  object-fit: cover;
  background: #eef2ff;
}

.side-links strong {
  display: block;
  line-height: 1.25;
}

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

.site-footer {
  margin-top: 60px;
  padding: 42px 0;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.7fr 1.2fr;
  gap: 30px;
}

.footer-brand {
  color: #ffffff;
  font-size: 20px;
}

.footer-inner p {
  max-width: 520px;
  margin: 10px 0 0;
  color: #94a3b8;
}

.footer-links,
.footer-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-links a,
.footer-categories a {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.footer-links a:hover,
.footer-categories a:hover {
  background: rgba(255, 255, 255, 0.16);
}

.hidden-by-filter {
  display: none !important;
}

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

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

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

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

  .menu-button {
    display: block;
  }

  .nav-wrap {
    height: 64px;
  }

  .hero-inner {
    min-height: auto;
    padding: 42px 0 52px;
  }

  .hero-search,
  .filter-search {
    border-radius: 24px;
    flex-direction: column;
  }

  .hero-search button,
  .filter-search button {
    width: 100%;
  }

  .hero-slider {
    min-height: 430px;
  }

  .hero-slide img {
    height: 250px;
  }

  .section-head {
    display: block;
  }

  .section-link {
    margin-top: 16px;
  }

  .movie-grid.large,
  .movie-grid,
  .category-grid,
  .category-strip,
  .filter-selects {
    grid-template-columns: 1fr;
  }

  .rank-item {
    grid-template-columns: 46px 1fr;
  }

  .rank-side {
    grid-column: 2;
  }

  .footer-inner {
    gap: 22px;
  }
}

@media (max-width: 460px) {
  .container,
  .nav-wrap,
  .hero-inner,
  .footer-inner,
  .mobile-panel {
    width: min(100% - 22px, 1200px);
  }

  .movie-grid.large,
  .movie-grid {
    gap: 16px;
  }

  .card-body,
  .detail-card,
  .side-card {
    padding: 18px;
  }
}
