:root {
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --amber-600: #d97706;
  --amber-500: #f59e0b;
  --orange-600: #ea580c;
  --blue-700: #1d4ed8;
  --purple-700: #6d28d9;
  --white: #ffffff;
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.12);
  --shadow-card: 0 12px 30px rgba(15, 23, 42, 0.10);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--slate-800);
  background: linear-gradient(135deg, var(--slate-50), #eef2f7 45%, #e2e8f0);
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--slate-900), var(--slate-800), var(--slate-900));
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.28);
  backdrop-filter: blur(12px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  box-shadow: 0 10px 22px rgba(234, 88, 12, 0.35);
}

.brand-text {
  display: grid;
  line-height: 1.2;
}

.brand-title {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, #fbbf24, #fb923c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-subtitle {
  margin-top: 4px;
  font-size: 12px;
  color: #cbd5e1;
}

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

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

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

.nav-link:hover,
.nav-link.active {
  color: var(--white);
  background: linear-gradient(90deg, var(--amber-500), var(--orange-600));
  transform: translateY(-1px);
}

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

.mobile-nav {
  display: none;
  border-top: 1px solid rgba(226, 232, 240, 0.12);
  padding: 10px 16px 16px;
}

.mobile-link {
  display: block;
  padding: 12px 14px;
}

.mobile-link:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
}

.hero-carousel {
  position: relative;
  height: 580px;
  overflow: hidden;
  background: var(--slate-900);
}

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

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

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.16), rgba(2, 6, 23, 0.68) 48%, rgba(2, 6, 23, 0.94));
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 64px;
  transform: translateX(-50%);
  color: var(--white);
}

.hero-content h1 {
  max-width: 760px;
  margin: 0 0 16px;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-content p {
  max-width: 720px;
  margin: 0 0 24px;
  color: #e2e8f0;
  font-size: clamp(15px, 2vw, 19px);
}

.hero-label,
.heading-kicker {
  display: inline-flex;
  align-items: center;
  width: max-content;
  border-radius: 999px;
  padding: 6px 13px;
  color: var(--white);
  background: linear-gradient(90deg, var(--amber-500), var(--orange-600));
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.04em;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.hero-tags span,
.detail-meta span,
.movie-meta span,
.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 11px;
  background: rgba(255, 255, 255, 0.12);
  color: #f8fafc;
  font-size: 13px;
  font-weight: 700;
}

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

.primary-button,
.ghost-button,
.filter-panel button,
.category-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 0;
  border-radius: 14px;
  padding: 0 18px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button,
.filter-panel button,
.category-more {
  color: var(--white);
  background: linear-gradient(90deg, var(--amber-500), var(--orange-600));
  box-shadow: 0 14px 30px rgba(234, 88, 12, 0.28);
}

.ghost-button {
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(15, 23, 42, 0.38);
  backdrop-filter: blur(8px);
}

.primary-button:hover,
.ghost-button:hover,
.filter-panel button:hover,
.category-more:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(15, 23, 42, 0.18);
}

.hero-control {
  position: absolute;
  top: 50%;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: rgba(2, 6, 23, 0.52);
  cursor: pointer;
  font-size: 34px;
  line-height: 1;
}

.hero-prev {
  left: 22px;
}

.hero-next {
  right: 22px;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 24px;
  display: flex;
  gap: 8px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 9px;
  height: 9px;
  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: var(--white);
}

.page-sections,
.page-layout,
.detail-layout {
  padding: 42px 0 64px;
}

.page-sections {
  display: grid;
  gap: 58px;
}

.section-card,
.page-title-card,
.detail-card,
.side-card,
.player-card,
.category-overview-card,
.filter-panel,
.ranking-card {
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-card);
}

.intro-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px;
}

.intro-card h2,
.page-title-card h1,
.section-heading h2,
.rank-copy h2,
.detail-card h1,
.side-card h2 {
  margin: 0;
  color: var(--slate-800);
  font-weight: 900;
  line-height: 1.15;
}

.intro-card h2,
.page-title-card h1 {
  font-size: clamp(30px, 4vw, 44px);
}

.intro-card p,
.page-title-card p,
.rank-copy p,
.category-overview-card p,
.detail-card p {
  color: var(--slate-600);
}

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

.section-heading h2 {
  margin-top: 8px;
  font-size: clamp(24px, 3vw, 34px);
}

.section-heading a {
  color: var(--amber-600);
  font-weight: 800;
}

.movie-grid {
  display: grid;
  gap: 22px;
}

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

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

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

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 45px rgba(15, 23, 42, 0.16);
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--slate-800);
}

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

.movie-card:hover .movie-cover img,
.compact-card:hover img,
.category-card:hover img {
  transform: scale(1.08);
}

.cover-gradient,
.category-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(2, 6, 23, 0.72));
}

.cover-badge,
.cover-score {
  position: absolute;
  top: 10px;
  border-radius: 999px;
  padding: 4px 9px;
  color: var(--white);
  font-size: 12px;
  font-weight: 800;
}

.cover-badge {
  left: 10px;
  background: linear-gradient(90deg, var(--amber-500), var(--orange-600));
}

.cover-score {
  right: 10px;
  background: rgba(2, 6, 23, 0.72);
}

.movie-body {
  padding: 15px;
}

.movie-body h3 {
  margin: 0 0 8px;
  color: var(--slate-800);
  font-size: 17px;
  line-height: 1.35;
}

.movie-body h3 a:hover {
  color: var(--amber-600);
}

.movie-body p {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 12px;
  overflow: hidden;
  color: var(--slate-600);
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.movie-meta span,
.detail-meta span,
.tag {
  color: var(--slate-700);
  background: var(--slate-100);
}

.movie-card-small .movie-body h3 {
  font-size: 15px;
}

.movie-card-small .movie-body p {
  min-height: 38px;
  font-size: 13px;
}

.horizontal-list {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 280px;
  gap: 22px;
  margin: 0 -16px;
  padding: 0 16px 12px;
  overflow-x: auto;
}

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

.category-card {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border-radius: 24px;
  color: var(--white);
  box-shadow: var(--shadow-card);
}

.category-card img {
  width: 100%;
  height: 100%;
  min-height: 220px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.category-card strong,
.category-card em {
  position: absolute;
  left: 18px;
  right: 18px;
  z-index: 1;
}

.category-card strong {
  bottom: 78px;
  font-size: 22px;
  font-style: normal;
}

.category-card em {
  bottom: 18px;
  color: #e2e8f0;
  font-size: 13px;
  font-style: normal;
}

.rank-section {
  display: grid;
  grid-template-columns: 0.9fr 1.2fr;
  gap: 28px;
  border-radius: 28px;
  padding: 32px;
  background: linear-gradient(135deg, #e2e8f0, #f8fafc);
}

.rank-copy {
  align-self: center;
}

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

.rank-row,
.compact-card {
  display: flex;
  align-items: center;
  gap: 14px;
  border-radius: 16px;
  padding: 10px;
  background: var(--white);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-row:hover,
.compact-card:hover,
.ranking-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 30px rgba(15, 23, 42, 0.14);
}

.rank-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  color: var(--white);
  background: linear-gradient(135deg, var(--purple-700), var(--blue-700));
  font-weight: 900;
}

.rank-row img,
.compact-thumb {
  width: 88px;
  height: 56px;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 12px;
  background: var(--slate-800);
}

.rank-row img,
.compact-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.rank-info,
.compact-info {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.rank-info strong,
.compact-info strong {
  overflow: hidden;
  color: var(--slate-800);
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rank-info em,
.compact-info em {
  color: var(--slate-600);
  font-size: 12px;
  font-style: normal;
}

.page-layout {
  display: grid;
  gap: 28px;
}

.page-title-card {
  padding: 32px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--slate-600);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--amber-600);
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 160px 160px 110px;
  gap: 14px;
  padding: 16px;
}

.filter-search {
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 14px;
  padding: 0 14px;
  background: var(--slate-100);
}

.filter-search input,
.filter-panel select {
  width: 100%;
  min-height: 46px;
  border: 0;
  outline: 0;
  color: var(--slate-800);
  background: transparent;
}

.filter-panel select {
  border-radius: 14px;
  padding: 0 12px;
  background: var(--slate-100);
}

.empty-state {
  display: none;
  margin: 0;
  border-radius: 18px;
  padding: 24px;
  color: var(--slate-600);
  text-align: center;
  background: rgba(255, 255, 255, 0.8);
}

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

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

.category-overview-card {
  padding: 24px;
}

.category-overview-card h2 {
  margin: 0 0 10px;
  font-size: 24px;
}

.category-overview-card h2 a:hover {
  color: var(--amber-600);
}

.category-more {
  margin-top: 18px;
}

.ranking-card {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 20px;
  padding: 16px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ranking-cover {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  aspect-ratio: 16 / 9;
  background: var(--slate-800);
}

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

.ranking-cover span {
  position: absolute;
  left: 10px;
  top: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  font-weight: 900;
}

.ranking-info h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.ranking-info p {
  margin: 0 0 12px;
  color: var(--slate-600);
}

.detail-layout {
  display: grid;
  gap: 18px;
}

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

.detail-main {
  display: grid;
  gap: 20px;
}

.player-card {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--slate-950);
}

.movie-video {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--slate-950);
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: var(--white);
  background-position: center;
  background-size: cover;
  cursor: pointer;
  z-index: 2;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 74px;
  height: 74px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  box-shadow: 0 18px 38px rgba(2, 6, 23, 0.35);
  cursor: pointer;
  font-size: 30px;
}

.player-overlay span {
  font-size: 20px;
  font-weight: 900;
  text-shadow: 0 4px 12px rgba(2, 6, 23, 0.55);
}

.detail-card {
  padding: 28px;
}

.detail-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.detail-card h1 {
  font-size: clamp(28px, 4vw, 42px);
}

.detail-score {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  height: 42px;
  border-radius: 14px;
  color: var(--amber-600);
  background: #fffbeb;
  font-size: 20px;
  font-weight: 900;
}

.detail-meta {
  margin-bottom: 16px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0 22px;
}

.detail-card h2 {
  margin: 24px 0 10px;
  color: var(--slate-800);
  font-size: 22px;
}

.detail-card p {
  margin: 0;
  white-space: pre-line;
}

.detail-genre {
  margin-top: 22px;
  border-radius: 16px;
  padding: 14px 16px;
  background: var(--slate-100);
  color: var(--slate-700);
}

.prev-next {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.prev-next a {
  min-width: 108px;
  border-radius: 14px;
  padding: 11px 16px;
  color: var(--white);
  text-align: center;
  font-weight: 800;
  background: var(--slate-800);
}

.detail-side {
  position: sticky;
  top: 100px;
  display: grid;
  gap: 18px;
}

.side-card {
  padding: 22px;
}

.side-card h2 {
  margin-bottom: 16px;
  font-size: 22px;
}

.side-tags .tag-row {
  margin-bottom: 0;
}

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(180deg, var(--slate-900), var(--slate-950));
}

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

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

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

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

.footer-bottom {
  border-top: 1px solid rgba(226, 232, 240, 0.08);
  padding: 18px 16px;
  color: #64748b;
  text-align: center;
  font-size: 14px;
}

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

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

  .detail-side {
    position: static;
  }
}

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

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

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

  .hero-carousel {
    height: 520px;
  }

  .hero-content {
    bottom: 62px;
  }

  .intro-card,
  .section-heading,
  .filter-panel,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .intro-card,
  .section-heading {
    display: grid;
    align-items: start;
  }

  .category-overview-grid,
  .ranking-card {
    grid-template-columns: 1fr;
  }

  .filter-panel {
    display: grid;
  }
}

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

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

  .brand-subtitle {
    display: none;
  }

  .hero-carousel {
    height: 480px;
  }

  .hero-control {
    display: none;
  }

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

  .hero-actions {
    display: grid;
  }

  .movie-grid-six,
  .movie-grid-four,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .movie-body {
    padding: 12px;
  }

  .movie-body p {
    display: none;
  }

  .horizontal-list {
    grid-auto-columns: 230px;
  }

  .page-title-card,
  .detail-card,
  .rank-section {
    padding: 22px;
  }

  .player-button {
    width: 62px;
    height: 62px;
  }
}
