:root {
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --blue-700: #1d4ed8;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --cyan-400: #22d3ee;
  --orange-500: #f97316;
  --radius-xl: 24px;
  --shadow-soft: 0 18px 50px rgba(15, 23, 42, 0.12);
  --shadow-deep: 0 28px 80px rgba(2, 6, 23, 0.38);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.74));
  color: #fff;
  transition: background 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
  backdrop-filter: blur(14px);
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.96);
  color: var(--slate-900);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
}

.header-inner {
  width: min(1240px, calc(100% - 32px));
  height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.logo-mark {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--blue-600), var(--cyan-400));
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.35);
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.logo-text strong {
  font-size: 20px;
  letter-spacing: -0.02em;
}

.logo-text em {
  margin-top: 3px;
  color: currentColor;
  opacity: 0.72;
  font-size: 12px;
  font-style: normal;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  font-size: 14px;
  font-weight: 650;
}

.nav-link {
  position: relative;
  opacity: 0.88;
  transition: opacity 0.2s ease, color 0.2s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -8px;
  height: 2px;
  transform: scaleX(0);
  transform-origin: center;
  border-radius: 999px;
  background: var(--blue-500);
  transition: transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--blue-500);
  opacity: 1;
}

.nav-link.active::after,
.nav-link:hover::after {
  transform: scaleX(1);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  color: inherit;
  background: rgba(255, 255, 255, 0.12);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  border-radius: 999px;
  background: currentColor;
}

.hero-section {
  position: relative;
  min-height: 760px;
  padding: 138px 0 78px;
  overflow: hidden;
  color: #fff;
  background: var(--slate-950);
}

.hero-bg,
.detail-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-bg-img,
.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 0.8s ease, transform 1.2s ease;
}

.hero-bg-img.is-active {
  opacity: 0.42;
  transform: scale(1);
}

.hero-shade,
.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(34, 211, 238, 0.24), transparent 32%),
    radial-gradient(circle at 80% 10%, rgba(37, 99, 235, 0.28), transparent 30%),
    linear-gradient(115deg, rgba(2, 6, 23, 0.95), rgba(15, 23, 42, 0.74) 54%, rgba(15, 23, 42, 0.38));
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(420px, 1.05fr);
  align-items: center;
  gap: 48px;
}

.hero-copy h1,
.sub-hero h1,
.detail-copy h1 {
  margin: 12px 0 18px;
  font-size: clamp(38px, 7vw, 76px);
  line-height: 1.02;
  letter-spacing: -0.055em;
}

.hero-copy p,
.sub-hero p,
.detail-one-line {
  max-width: 680px;
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 18px;
}

.eyebrow,
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--cyan-400);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

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

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

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

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--blue-600), var(--cyan-400));
  box-shadow: 0 16px 38px rgba(37, 99, 235, 0.34);
}

.btn-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: rgba(255, 255, 255, 0.1);
}

.hero-copy .filter-panel {
  margin-top: 34px;
  max-width: 570px;
  color: var(--slate-900);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-deep);
}

.hero-slider {
  position: relative;
  min-height: 520px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 34px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: var(--shadow-deep);
  backdrop-filter: blur(18px);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: 58% 42%;
  opacity: 0;
  pointer-events: none;
  transform: translateX(22px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.hero-poster {
  position: relative;
  min-height: 280px;
  overflow: hidden;
}

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

.hero-slide-copy {
  padding: 26px;
}

.hero-label,
.card-meta,
.breadcrumb {
  color: var(--slate-500);
  font-size: 13px;
  font-weight: 700;
}

.hero-slide-copy h2 {
  margin: 10px 0 8px;
  color: #fff;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.12;
}

.hero-slide-copy p {
  min-height: 48px;
  margin: 0 0 16px;
  color: rgba(255, 255, 255, 0.76);
}

.hero-controls {
  position: absolute;
  right: 22px;
  bottom: 20px;
  left: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.hero-controls button {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
}

.hero-dots {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-dot {
  width: 10px !important;
  height: 10px !important;
  padding: 0;
  background: rgba(255, 255, 255, 0.32) !important;
}

.hero-dot.is-active {
  width: 28px !important;
  background: var(--cyan-400) !important;
}

.content-section {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 70px 0;
}

.dark-section {
  width: 100%;
  max-width: none;
  padding-inline: max(16px, calc((100% - 1240px) / 2));
  color: #fff;
  background:
    radial-gradient(circle at 12% 10%, rgba(59, 130, 246, 0.28), transparent 28%),
    linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

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

.section-heading h2 {
  margin: 6px 0 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.section-heading p {
  max-width: 720px;
  margin: 10px 0 0;
  color: var(--slate-600);
}

.dark-section .section-heading p,
.dark-section .card-body p,
.dark-section .card-meta {
  color: rgba(255, 255, 255, 0.68);
}

.section-more {
  min-width: max-content;
  color: var(--blue-600);
  font-weight: 800;
}

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

.category-tile {
  position: relative;
  min-height: 200px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: end;
  overflow: hidden;
  border-radius: 24px;
  color: #fff;
  background: var(--slate-900);
  box-shadow: var(--shadow-soft);
}

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

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.7;
  transition: transform 0.35s ease;
}

.category-tile:hover img {
  transform: scale(1.06);
}

.category-tile span,
.category-tile p {
  position: relative;
  z-index: 1;
}

.category-tile span {
  font-size: 22px;
  font-weight: 900;
}

.category-tile p {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: var(--radius-xl);
  background: #fff;
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.dark-section .movie-card {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
}

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

.poster-frame {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: inherit;
  background:
    radial-gradient(circle at 40% 20%, rgba(34, 211, 238, 0.28), transparent 30%),
    linear-gradient(145deg, var(--slate-800), var(--slate-950));
}

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

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

.year-badge,
.rank-badge,
.heat-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 850;
}

.year-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 9px;
  color: #fff;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(10px);
}

.rank-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 5px 9px;
  color: #fff;
  background: linear-gradient(135deg, var(--orange-500), #ef4444);
}

.heat-badge {
  padding: 3px 7px;
  color: #fff;
  background: var(--orange-500);
}

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.card-body h3 {
  margin: 0;
  font-size: 17px;
  line-height: 1.28;
}

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

.card-body p {
  margin: 9px 0 13px;
  color: var(--slate-600);
  font-size: 14px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-row span {
  padding: 4px 8px;
  border-radius: 999px;
  color: var(--blue-700);
  background: #dbeafe;
  font-size: 12px;
  font-weight: 750;
}

.dark-section .tag-row span,
.hero-slide .tag-row span,
.detail-copy .tag-row span {
  color: #dbeafe;
  background: rgba(59, 130, 246, 0.24);
}

.filter-panel {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px;
  margin-bottom: 28px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.07);
}

.search-box {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-box span {
  color: var(--slate-500);
  font-weight: 800;
}

.search-box input,
.year-select {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--slate-900);
  background: transparent;
}

.year-select {
  width: 150px;
  padding: 8px 10px;
  border-left: 1px solid rgba(148, 163, 184, 0.24);
}

.empty-text {
  display: none;
  padding: 28px;
  border-radius: 18px;
  color: var(--slate-500);
  text-align: center;
  background: #fff;
}

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

.sub-hero {
  position: relative;
  overflow: hidden;
  padding: 144px 0 84px;
  color: #fff;
  background:
    radial-gradient(circle at 20% 10%, rgba(34, 211, 238, 0.25), transparent 26%),
    linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

.sub-hero-inner {
  position: relative;
  z-index: 1;
  width: min(1000px, calc(100% - 32px));
  margin: 0 auto;
}

.sub-hero h1 {
  font-size: clamp(36px, 6vw, 68px);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  color: rgba(255, 255, 255, 0.7);
}

.breadcrumb a:hover {
  color: #fff;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  min-height: 680px;
  padding: 130px 0 70px;
  color: #fff;
  background: var(--slate-950);
}

.detail-bg img {
  opacity: 0.34;
}

.detail-inner {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(240px, 330px) minmax(0, 1fr);
  gap: 40px;
  align-items: center;
}

.detail-poster {
  border-radius: 30px;
  box-shadow: var(--shadow-deep);
}

.detail-copy h1 {
  font-size: clamp(38px, 6vw, 70px);
}

.detail-copy .btn-ghost {
  color: #fff;
}

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

.detail-main,
.detail-side {
  display: grid;
  gap: 22px;
}

.player-card,
.text-card,
.side-card {
  overflow: hidden;
  border-radius: 26px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.video-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--slate-950);
}

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

.play-cover {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: #fff;
  background:
    radial-gradient(circle at center, rgba(37, 99, 235, 0.22), rgba(2, 6, 23, 0.68)),
    rgba(2, 6, 23, 0.36);
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-symbol {
  width: 84px;
  height: 84px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--blue-600), var(--cyan-400));
  font-size: 30px;
  box-shadow: 0 20px 50px rgba(37, 99, 235, 0.38);
}

.text-card,
.side-card {
  padding: 26px;
}

.text-card h2,
.side-card h2 {
  margin: 0 0 14px;
  font-size: 24px;
  line-height: 1.25;
}

.text-card p {
  margin: 0;
  color: var(--slate-700);
  font-size: 16px;
}

.side-card dl {
  display: grid;
  gap: 12px;
  margin: 0;
}

.side-card dl div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.side-card dt {
  color: var(--slate-500);
  font-weight: 800;
}

.side-card dd {
  margin: 0;
  text-align: right;
}

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

.side-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.side-links a:hover span {
  color: var(--blue-600);
}

.side-links em {
  color: var(--slate-500);
  font-style: normal;
  font-size: 12px;
}

.site-footer {
  color: var(--slate-400);
  background: var(--slate-950);
}

.footer-inner {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0 34px;
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 1fr;
  gap: 34px;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  font-size: 18px;
}

.footer-brand p {
  max-width: 420px;
  margin: 18px 0 0;
}

.footer-column h3 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 16px;
}

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

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

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 20px 0 30px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  font-size: 13px;
}

.footer-bottom p {
  margin: 0;
}

@media (max-width: 1100px) {
  .site-nav {
    gap: 12px;
    font-size: 13px;
  }

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

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

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

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

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

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 66px;
    right: 16px;
    left: 16px;
    display: none;
    padding: 18px;
    border-radius: 20px;
    color: var(--slate-900);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow-soft);
  }

  .site-nav.is-open {
    display: grid;
  }

  .nav-link::after {
    display: none;
  }

  .hero-section {
    min-height: auto;
    padding: 112px 0 50px;
  }

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

  .hero-slider {
    min-height: 530px;
    border-radius: 24px;
  }

  .hero-slide {
    grid-template-rows: 52% 48%;
  }

  .hero-slide-copy {
    padding: 20px;
  }

  .section-heading {
    display: block;
  }

  .section-more {
    display: inline-flex;
    margin-top: 12px;
  }

  .content-section {
    padding: 46px 0;
  }

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

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

  .filter-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .year-select {
    width: 100%;
    border-left: 0;
    border-top: 1px solid rgba(148, 163, 184, 0.24);
  }

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

  .detail-poster {
    max-width: 270px;
  }

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

@media (max-width: 520px) {
  .logo-text strong {
    font-size: 17px;
  }

  .logo-text em {
    display: none;
  }

  .hero-copy h1,
  .sub-hero h1,
  .detail-copy h1 {
    letter-spacing: -0.04em;
  }

  .hero-actions,
  .detail-actions {
    display: grid;
  }

  .btn {
    width: 100%;
  }

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

  .category-tile {
    min-height: 180px;
  }
}
