:root {
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-850: #162033;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --orange-600: #ea580c;
  --orange-500: #f97316;
  --orange-400: #fb923c;
  --red-500: #ef4444;
  --amber-100: #fef3c7;
  --white: #ffffff;
  --shadow-soft: 0 24px 60px rgba(15, 23, 42, 0.16);
  --shadow-card: 0 14px 36px rgba(15, 23, 42, 0.12);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--slate-800);
  background:
    radial-gradient(circle at top left, rgba(251, 146, 60, 0.22), transparent 34rem),
    linear-gradient(135deg, #f8fafc 0%, #fff7ed 48%, #fffbeb 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  color: var(--white);
  background: linear-gradient(90deg, var(--slate-950), var(--slate-850), var(--slate-950));
  box-shadow: 0 16px 36px rgba(2, 6, 23, 0.22);
}

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

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: var(--white);
  background: linear-gradient(135deg, var(--orange-500), var(--red-500));
  box-shadow: 0 12px 28px rgba(249, 115, 22, 0.36);
}

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

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

.nav-link,
.mobile-link {
  color: var(--slate-300);
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: var(--white);
}

.nav-link.active {
  font-weight: 800;
}

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

.menu-toggle span {
  width: 22px;
  height: 2px;
  margin: 4px auto;
  display: block;
  border-radius: 999px;
  background: var(--white);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.menu-toggle.is-open span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu-toggle.is-open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.is-open span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
}

.mobile-nav.is-open {
  display: grid;
  gap: 8px;
}

.mobile-link {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
}

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

.hero-slider {
  position: relative;
  min-height: 75vh;
  overflow: hidden;
  color: var(--white);
  background: linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

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

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

.hero-slide::before {
  content: "";
  position: absolute;
  inset: -26px;
  background-image: var(--hero-bg);
  background-size: cover;
  background-position: center;
  filter: blur(22px);
  transform: scale(1.08);
  opacity: 0.48;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 76% 35%, rgba(249, 115, 22, 0.28), transparent 24rem),
    linear-gradient(0deg, rgba(0, 0, 0, 0.9), rgba(2, 6, 23, 0.58));
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.52fr);
  align-items: center;
  gap: 48px;
  padding: 84px 0 68px;
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 9px 14px;
  border-radius: 999px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(14px);
}

.hero-title {
  max-width: 820px;
  margin: 22px 0 20px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.gradient-word {
  color: transparent;
  background: linear-gradient(90deg, var(--orange-400), var(--red-500));
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-desc {
  max-width: 720px;
  margin: 0 0 26px;
  color: var(--slate-200);
  font-size: clamp(18px, 2.4vw, 24px);
  line-height: 1.7;
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  padding: 7px 11px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: var(--slate-700);
  background: var(--slate-100);
}

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

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

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

.btn-primary,
.play-button {
  color: var(--white);
  background: linear-gradient(135deg, var(--orange-500), var(--red-500));
  box-shadow: 0 16px 34px rgba(239, 68, 68, 0.28);
}

.btn-primary:hover,
.btn-dark:hover,
.play-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 44px rgba(239, 68, 68, 0.34);
}

.btn-ghost {
  color: var(--white);
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.btn-dark {
  color: var(--white);
  background: linear-gradient(135deg, var(--slate-900), var(--slate-700));
}

.hero-poster {
  position: relative;
  width: min(100%, 340px);
  justify-self: end;
  border-radius: 28px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 38px 90px rgba(0, 0, 0, 0.46);
}

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: inherit;
  pointer-events: none;
}

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

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

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.48);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: var(--white);
}

.quick-search {
  position: relative;
  z-index: 6;
  width: min(980px, calc(100% - 32px));
  margin: -34px auto 34px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 14px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
}

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

.quick-search input {
  min-height: 48px;
  padding: 0 16px;
}

.quick-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--orange-400);
  box-shadow: 0 0 0 4px rgba(251, 146, 60, 0.16);
}

.content-section {
  width: min(1180px, calc(100% - 32px));
  margin: 46px auto;
  padding: 42px;
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow-card);
}

.content-section.section-gradient {
  color: var(--white);
  background:
    radial-gradient(circle at top right, rgba(251, 146, 60, 0.28), transparent 24rem),
    linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

.section-heading {
  margin-bottom: 28px;
}

.section-heading p,
.page-kicker {
  margin: 0 0 8px;
  color: var(--orange-600);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section-gradient .section-heading p {
  color: var(--orange-400);
}

.section-heading h2,
.page-hero h1,
.detail-title {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.18;
  font-weight: 900;
  letter-spacing: -0.03em;
}

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

.movie-card a {
  display: block;
  height: 100%;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.section-gradient .movie-card a {
  background: rgba(255, 255, 255, 0.95);
}

.movie-card a:hover {
  transform: translateY(-7px);
  box-shadow: 0 24px 48px rgba(15, 23, 42, 0.18);
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, var(--slate-900), var(--slate-700));
}

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

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

.poster-glow {
  position: absolute;
  inset: auto 0 0;
  height: 45%;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.72), transparent);
}

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  min-width: 32px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: var(--white);
  font-weight: 900;
  background: linear-gradient(135deg, var(--orange-500), var(--red-500));
  box-shadow: 0 8px 20px rgba(239, 68, 68, 0.35);
}

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

.card-title {
  overflow: hidden;
  color: var(--slate-900);
  font-size: 16px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-meta,
.card-desc {
  color: var(--slate-500);
  font-size: 13px;
  line-height: 1.5;
}

.card-desc {
  min-height: 39px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.category-tile {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  padding: 24px;
  border-radius: var(--radius-xl);
  color: var(--white);
  background: linear-gradient(135deg, var(--slate-950), var(--slate-700));
  box-shadow: var(--shadow-card);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 58px rgba(15, 23, 42, 0.22);
}

.category-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--cover);
  background-size: cover;
  background-position: center;
  opacity: 0.28;
  transform: scale(1.08);
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.86), rgba(2, 6, 23, 0.26));
}

.category-tile > * {
  position: relative;
  z-index: 1;
}

.category-tile h2,
.category-tile h3 {
  margin: 0 0 12px;
  font-size: 24px;
}

.category-tile p {
  margin: 0;
  color: var(--slate-200);
  line-height: 1.7;
}

.category-tile span {
  position: absolute;
  right: 22px;
  bottom: 20px;
  z-index: 1;
  font-weight: 900;
  color: var(--orange-400);
}

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 36px auto;
  padding: 46px;
  border-radius: var(--radius-xl);
  color: var(--white);
  background:
    radial-gradient(circle at top right, rgba(249, 115, 22, 0.26), transparent 24rem),
    linear-gradient(135deg, var(--slate-950), var(--slate-800));
  box-shadow: var(--shadow-soft);
}

.page-hero p {
  max-width: 820px;
  margin: 16px 0 0;
  color: var(--slate-200);
  font-size: 18px;
  line-height: 1.8;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 16px;
  margin: 0 0 28px;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.filter-bar label {
  display: grid;
  gap: 8px;
  color: var(--slate-600);
  font-size: 13px;
  font-weight: 800;
}

.filter-bar input,
.filter-bar select {
  min-height: 46px;
  padding: 0 14px;
}

.empty-state {
  display: none;
  padding: 28px;
  border-radius: var(--radius-lg);
  text-align: center;
  color: var(--slate-600);
  background: var(--slate-100);
}

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

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

.ranking-row {
  display: grid;
  grid-template-columns: 56px 70px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ranking-row:hover {
  transform: translateX(6px);
  box-shadow: var(--shadow-card);
}

.ranking-index {
  font-size: 22px;
  font-weight: 900;
  color: var(--orange-600);
}

.ranking-cover {
  overflow: hidden;
  border-radius: 12px;
  background: var(--slate-900);
}

.ranking-cover img {
  width: 70px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.ranking-main {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.ranking-main strong {
  overflow: hidden;
  color: var(--slate-900);
  font-size: 17px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ranking-main em {
  overflow: hidden;
  color: var(--slate-500);
  font-size: 14px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ranking-meta {
  color: var(--slate-500);
  font-size: 14px;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--slate-500);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--orange-600);
  font-weight: 800;
}

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

.player-card,
.detail-card {
  border-radius: var(--radius-xl);
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.player-card {
  overflow: hidden;
}

.video-frame {
  position: relative;
  background: var(--slate-950);
}

.video-frame video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: var(--slate-950);
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: var(--white);
  background: rgba(2, 6, 23, 0.42);
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.48;
}

.play-icon {
  position: relative;
  z-index: 2;
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 32px;
  background: linear-gradient(135deg, var(--orange-500), var(--red-500));
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.4);
}

.player-info {
  padding: 24px;
}

.player-info p {
  margin: 14px 0 0;
  color: var(--slate-600);
  line-height: 1.8;
}

.detail-card {
  padding: 24px;
}

.detail-poster {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--slate-900);
}

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

.detail-meta {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.detail-meta span {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--slate-200);
  color: var(--slate-500);
}

.detail-meta strong {
  color: var(--slate-800);
}

.text-panel {
  margin-top: 28px;
  padding: 30px;
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-card);
}

.text-panel h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.text-panel p {
  margin: 0 0 18px;
  color: var(--slate-600);
  font-size: 16px;
  line-height: 1.9;
}

.site-footer {
  margin-top: 70px;
  color: var(--white);
  background: linear-gradient(90deg, var(--slate-900), var(--slate-950), var(--slate-900));
}

.footer-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 34px;
  padding: 46px 0;
}

.footer-brand p,
.footer-column li,
.footer-column a {
  color: var(--slate-300);
}

.footer-brand p {
  margin: 16px 0 0;
  line-height: 1.8;
}

.footer-column h2 {
  margin: 0 0 16px;
  color: var(--orange-400);
  font-size: 17px;
}

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

.footer-column a:hover {
  color: var(--orange-400);
}

.footer-bottom {
  padding: 18px 16px;
  color: var(--slate-300);
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.back-to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 60;
  width: 44px;
  height: 44px;
  display: none;
  border: 0;
  border-radius: 14px;
  color: var(--white);
  background: linear-gradient(135deg, var(--orange-500), var(--red-500));
  box-shadow: 0 14px 32px rgba(239, 68, 68, 0.32);
  cursor: pointer;
}

.back-to-top.is-visible {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

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

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

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

  .detail-card {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 20px;
  }

  .detail-meta {
    margin-top: 0;
  }
}

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

  .menu-toggle {
    display: block;
  }

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

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 64px 0 78px;
  }

  .hero-poster {
    width: min(100%, 260px);
    justify-self: start;
  }

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

  .content-section,
  .page-hero,
  .text-panel {
    padding: 24px;
  }

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

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

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

  .ranking-meta {
    grid-column: 3;
  }

  .ranking-cover img {
    width: 58px;
  }

  .detail-card {
    display: block;
  }

  .detail-meta {
    margin-top: 18px;
  }
}

@media (max-width: 430px) {
  .section-grid,
  .movie-grid {
    grid-template-columns: 1fr;
  }

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

  .quick-search {
    margin-top: -20px;
  }
}
