:root {
  color-scheme: light;
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --amber-600: #d97706;
  --amber-500: #f59e0b;
  --amber-400: #fbbf24;
  --rose-600: #e11d48;
  --red-600: #dc2626;
  --shadow: 0 24px 60px rgba(15, 23, 42, .16);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--slate-900);
  background: linear-gradient(180deg, var(--slate-50), var(--slate-100));
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  color: #fff;
  background: linear-gradient(90deg, var(--slate-950), var(--slate-900), #321608);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  box-shadow: 0 14px 40px rgba(2, 6, 23, .22);
}

.header-inner {
  max-width: 1280px;
  height: 76px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 230px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--amber-400), var(--amber-600));
  color: #fff;
  font-weight: 900;
  box-shadow: 0 0 30px rgba(245, 158, 11, .35);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-text strong {
  font-size: 22px;
  letter-spacing: .04em;
}

.brand-text em {
  margin-top: 4px;
  color: var(--slate-300);
  font-size: 12px;
  font-style: normal;
}

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

.nav-link {
  padding: 10px 16px;
  border-radius: 12px;
  color: var(--slate-300);
  font-weight: 700;
  transition: .25s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #fff;
  background: rgba(245, 158, 11, .92);
  box-shadow: 0 12px 24px rgba(245, 158, 11, .26);
}

.header-search-button,
.menu-button,
.header-search button,
.search-box button,
.hero-action,
.player-button {
  border: 0;
  cursor: pointer;
}

.header-search-button,
.menu-button {
  padding: 10px 14px;
  border-radius: 12px;
  color: #fff;
  background: rgba(255, 255, 255, .1);
}

.menu-button {
  display: none;
}

.header-search,
.mobile-nav {
  display: none;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px 18px;
}

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

.header-search form,
.search-box {
  display: flex;
  gap: 12px;
}

.header-search input,
.search-box input {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 16px;
  padding: 14px 16px;
  color: #fff;
  background: rgba(15, 23, 42, .78);
  outline: none;
}

.search-box input {
  color: var(--slate-900);
  background: #fff;
  border-color: var(--slate-200);
}

.header-search button,
.search-box button {
  white-space: nowrap;
  padding: 14px 22px;
  border-radius: 16px;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--amber-500), var(--amber-600));
}

.mobile-nav a {
  display: block;
  padding: 14px 0;
  color: var(--slate-200);
  border-top: 1px solid rgba(255, 255, 255, .08);
}

.hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: radial-gradient(circle at 12% 12%, rgba(245, 158, 11, .38), transparent 28%), linear-gradient(120deg, var(--slate-950), #2f1608 45%, var(--slate-900));
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .12;
  background-image: repeating-linear-gradient(45deg, transparent, transparent 35px, rgba(255, 255, 255, .08) 35px, rgba(255, 255, 255, .08) 70px);
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 120px;
  background: linear-gradient(0deg, var(--slate-50), transparent);
}

.hero-track {
  position: relative;
  z-index: 2;
  min-height: 620px;
}

.hero-slide {
  display: none;
  max-width: 1280px;
  min-height: 620px;
  margin: 0 auto;
  padding: 82px 24px 130px;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, .72fr);
  gap: 48px;
  align-items: center;
}

.hero-slide.is-active {
  display: grid;
  animation: heroFade .65s ease both;
}

@keyframes heroFade {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(245, 158, 11, .4);
  border-radius: 999px;
  padding: 8px 14px;
  color: #fde68a;
  background: rgba(245, 158, 11, .12);
  backdrop-filter: blur(12px);
  font-size: 14px;
  font-weight: 800;
}

.hero h1 {
  margin: 22px 0 18px;
  max-width: 780px;
  font-size: clamp(42px, 6vw, 82px);
  line-height: .98;
  letter-spacing: -.06em;
}

.hero h1 span {
  background: linear-gradient(90deg, var(--amber-400), #fff7ed, var(--amber-500));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-summary {
  max-width: 720px;
  color: var(--slate-200);
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 34px;
}

.hero-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  font-weight: 900;
  transition: .28s ease;
}

.hero-action.primary {
  color: #fff;
  background: linear-gradient(135deg, var(--amber-500), var(--amber-600));
  box-shadow: 0 18px 38px rgba(245, 158, 11, .32);
}

.hero-action.secondary {
  color: #fff;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .18);
  backdrop-filter: blur(12px);
}

.hero-action:hover {
  transform: translateY(-3px) scale(1.02);
}

.hero-poster {
  position: relative;
  overflow: hidden;
  border-radius: 34px;
  box-shadow: 0 34px 90px rgba(0, 0, 0, .45);
  transform: rotate(2deg);
}

.hero-poster img {
  aspect-ratio: 3 / 4;
  height: auto;
  object-fit: cover;
}

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, .74), transparent 55%);
}

.hero-poster-info {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 22px;
  z-index: 2;
}

.hero-poster-info strong {
  display: block;
  font-size: 22px;
}

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

.hero-dot {
  width: 42px;
  height: 5px;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, .28);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--amber-400);
}

.main-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 54px 24px;
}

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

.section-head h2,
.page-hero h1,
.detail-title h1 {
  margin: 0;
  color: var(--slate-900);
  font-size: clamp(28px, 4vw, 46px);
  letter-spacing: -.04em;
}

.section-head p,
.page-hero p,
.detail-title p {
  margin: 12px 0 0;
  color: var(--slate-600);
  line-height: 1.8;
}

.more-link {
  color: var(--amber-600);
  font-weight: 900;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, .3);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .88);
  box-shadow: 0 12px 30px rgba(15, 23, 42, .08);
  transition: .28s ease;
}

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

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

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

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

.play-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--slate-950);
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 12px 24px rgba(0, 0, 0, .22);
}

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

.movie-meta,
.tag-row,
.breadcrumb,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.movie-meta span,
.tag-row span,
.detail-meta span {
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--slate-600);
  background: var(--slate-100);
  font-size: 12px;
  font-weight: 800;
}

.movie-card h3 {
  margin: 13px 0 8px;
  font-size: 20px;
  line-height: 1.25;
}

.movie-card p {
  min-height: 68px;
  margin: 0 0 16px;
  color: var(--slate-600);
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.category-card {
  min-height: 148px;
  padding: 24px;
  border-radius: 24px;
  color: #fff;
  background: linear-gradient(135deg, var(--slate-900), var(--amber-600));
  box-shadow: 0 18px 38px rgba(15, 23, 42, .16);
  transition: .28s ease;
}

.category-card:hover {
  transform: translateY(-6px);
}

.category-card strong {
  display: block;
  margin-bottom: 10px;
  font-size: 22px;
}

.category-card span {
  color: rgba(255, 255, 255, .76);
  line-height: 1.7;
}

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

.rank-list,
.side-panel,
.detail-panel {
  border: 1px solid rgba(148, 163, 184, .28);
  border-radius: 26px;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 12px 30px rgba(15, 23, 42, .08);
}

.rank-row {
  display: grid;
  grid-template-columns: 52px 84px minmax(0, 1fr) 110px;
  gap: 16px;
  align-items: center;
  padding: 15px 18px;
  border-bottom: 1px solid var(--slate-100);
}

.rank-row:last-child {
  border-bottom: 0;
}

.rank-number {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber-500), var(--red-600));
  font-weight: 900;
}

.rank-row img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 12px;
}

.rank-row h3 {
  margin: 0 0 6px;
  font-size: 18px;
}

.rank-row p {
  margin: 0;
  color: var(--slate-600);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rank-score {
  color: var(--amber-600);
  font-weight: 900;
  text-align: right;
}

.side-panel {
  padding: 22px;
}

.side-panel h2 {
  margin: 0 0 18px;
}

.rank-item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--slate-100);
}

.rank-item:last-child {
  border-bottom: 0;
}

.rank-item img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 12px;
}

.rank-item strong,
.rank-item em {
  display: block;
}

.rank-item em {
  margin-top: 6px;
  color: var(--slate-500);
  font-style: normal;
  font-size: 13px;
}

.page-hero {
  max-width: 1280px;
  margin: 0 auto;
  padding: 58px 24px 16px;
}

.breadcrumb {
  margin-bottom: 18px;
  color: var(--slate-500);
  font-weight: 800;
}

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

.search-tools {
  margin: 24px 0 30px;
}

.is-hidden {
  display: none !important;
}

.detail-layout {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 24px 60px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 30px;
}

.detail-title {
  max-width: 1280px;
  margin: 0 auto;
  padding: 44px 24px 0;
}

.player-panel {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: 0 28px 70px rgba(15, 23, 42, .28);
}

.video-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-wrap video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  background: #000;
}

.play-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  padding: 0;
  color: #fff;
  background: rgba(0, 0, 0, .22);
  cursor: pointer;
  z-index: 3;
}

.play-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .68;
}

.play-cover span {
  position: relative;
  z-index: 2;
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--slate-950);
  background: rgba(255, 255, 255, .92);
  font-size: 34px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .35);
}

.player-caption {
  padding: 22px 24px 26px;
  color: #fff;
  background: linear-gradient(90deg, #020617, #111827);
}

.player-caption h2 {
  margin: 0 0 10px;
  font-size: 24px;
}

.player-caption p {
  margin: 0;
  color: var(--slate-300);
  line-height: 1.75;
}

.detail-panel {
  margin-top: 26px;
  padding: 26px;
}

.detail-panel h2 {
  margin: 0 0 16px;
  font-size: 26px;
}

.detail-panel p {
  color: var(--slate-700);
  line-height: 2;
}

.detail-cover {
  overflow: hidden;
  border-radius: 26px;
  box-shadow: var(--shadow);
}

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

.detail-aside .side-panel {
  margin-top: 22px;
}

.empty-state {
  padding: 24px;
  border: 1px dashed var(--slate-300);
  border-radius: 20px;
  color: var(--slate-600);
  background: rgba(255, 255, 255, .7);
}

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

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 34px 24px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.footer-inner p {
  margin: 8px 0 0;
}

.footer-links {
  display: flex;
  gap: 16px;
  align-items: center;
}

.footer-links a {
  color: #fff;
}

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

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

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

@media (max-width: 820px) {
  .header-inner {
    height: 68px;
  }

  .main-nav,
  .header-search-button {
    display: none;
  }

  .menu-button {
    display: inline-flex;
  }

  .brand {
    min-width: 0;
  }

  .brand-text em {
    display: none;
  }

  .hero-slide {
    min-height: auto;
    grid-template-columns: 1fr;
    padding-top: 46px;
    padding-bottom: 110px;
  }

  .hero-poster {
    transform: none;
    max-width: 360px;
    margin: 0 auto;
  }

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

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

  .rank-row {
    grid-template-columns: 42px 64px minmax(0, 1fr);
  }

  .rank-score {
    display: none;
  }

  .footer-inner {
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .header-inner,
  .main-section,
  .page-hero,
  .detail-title,
  .detail-layout,
  .footer-inner {
    padding-left: 16px;
    padding-right: 16px;
  }

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

  .hero-slide {
    padding-left: 16px;
    padding-right: 16px;
  }

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

  .hero-actions {
    flex-direction: column;
  }

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

  .search-box,
  .header-search form {
    flex-direction: column;
  }

  .detail-panel {
    padding: 20px;
  }
}
