:root {
  --cyan: #06b6d4;
  --blue: #2563eb;
  --purple: #7c3aed;
  --pink: #ec4899;
  --orange: #f97316;
  --slate: #0f172a;
  --muted: #64748b;
  --line: rgba(15, 23, 42, 0.1);
  --shadow: 0 20px 55px rgba(15, 23, 42, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  color: #1f2937;
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 50%, #ecfeff 100%);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--purple));
  box-shadow: 0 10px 30px rgba(37, 99, 235, 0.28);
}

.nav-shell {
  max-width: 1180px;
  height: 68px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  gap: 20px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 800;
  font-size: 22px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.brand-icon {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
  transition: transform 0.25s ease;
}

.brand:hover .brand-icon {
  transform: scale(1.12);
}

.nav-search {
  flex: 1;
  max-width: 430px;
  display: flex;
  align-items: center;
  background: #fff;
  border-radius: 999px;
  padding: 5px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.15);
}

.nav-search input {
  width: 100%;
  border: 0;
  outline: 0;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 14px;
  color: #111827;
}

.nav-search button,
.search-panel button,
.btn-primary,
.btn-ghost,
.player-button {
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.nav-search button {
  padding: 10px 18px;
  color: #fff;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  color: #fff;
  font-weight: 700;
  white-space: nowrap;
}

.nav-links a {
  opacity: 0.96;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.nav-links a:hover {
  color: #cffafe;
}

.nav-toggle {
  display: none;
  border: 0;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border-radius: 12px;
  padding: 9px 12px;
  font-size: 20px;
}

.hero {
  position: relative;
  min-height: 600px;
  overflow: hidden;
  background: linear-gradient(135deg, #0891b2 0%, #2563eb 46%, #7c3aed 100%);
  color: #fff;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 10% 20%, rgba(255, 255, 255, 0.2), transparent 23%), radial-gradient(circle at 88% 85%, rgba(103, 232, 249, 0.24), transparent 28%), rgba(0, 0, 0, 0.22);
}

.hero-orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(55px);
  opacity: 0.35;
  animation: pulseOrb 4.5s ease-in-out infinite alternate;
}

.hero-orb.one {
  width: 280px;
  height: 280px;
  left: 8%;
  top: 8%;
  background: #fff;
}

.hero-orb.two {
  width: 420px;
  height: 420px;
  right: 5%;
  bottom: 0;
  background: #67e8f9;
  animation-delay: 0.8s;
}

@keyframes pulseOrb {
  from {
    transform: scale(0.92);
  }

  to {
    transform: scale(1.12);
  }
}

.hero-inner {
  position: relative;
  max-width: 1180px;
  min-height: 600px;
  margin: 0 auto;
  padding: 72px 22px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(330px, 0.95fr);
  gap: 42px;
  align-items: center;
}

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

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(10px);
  font-weight: 700;
  margin-bottom: 18px;
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(44px, 7vw, 78px);
  line-height: 1.02;
  letter-spacing: -0.06em;
  font-weight: 900;
}

.hero h1 span {
  color: #cffafe;
}

.hero-text {
  font-size: 20px;
  line-height: 1.85;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 0 30px;
}

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

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 24px;
}

.btn-primary {
  color: var(--blue);
  background: #fff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.18);
}

.btn-ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(10px);
}

.btn-primary:hover,
.btn-ghost:hover,
.player-button:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-stage {
  position: relative;
  min-height: 460px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateY(22px) scale(0.98);
  transition: opacity 0.65s ease, transform 0.65s ease;
  pointer-events: none;
}

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

.hero-card {
  height: 100%;
  min-height: 460px;
  border-radius: 32px;
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow);
  background: #0f172a;
}

.hero-card img {
  width: 100%;
  height: 100%;
  min-height: 460px;
  object-fit: cover;
  transform: scale(1.04);
}

.hero-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.1) 58%, rgba(0, 0, 0, 0.18));
}

.hero-card-content {
  position: absolute;
  z-index: 2;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 32px;
}

.hero-card h2 {
  margin: 12px 0 10px;
  font-size: 30px;
}

.hero-card p {
  margin: 0 0 20px;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.7;
}

.hero-dots {
  position: absolute;
  z-index: 4;
  display: flex;
  gap: 10px;
  right: 26px;
  bottom: 22px;
}

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

.hero-dots button.active {
  width: 34px;
  background: #fff;
}

.section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 62px 22px;
}

.section-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 26px;
}

.section-title h2,
.page-title h1,
.detail-main h1 {
  margin: 0;
  color: #1f2937;
  font-size: 32px;
  line-height: 1.2;
}

.section-title p,
.page-title p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

.more-link {
  color: var(--blue);
  font-weight: 800;
}

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

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

.movie-card {
  min-width: 0;
  background: #fff;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 8px 26px rgba(15, 23, 42, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  height: 190px;
  overflow: hidden;
  background: #0f172a;
}

.card-large .poster-link {
  height: 250px;
}

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

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

.duration,
.rank-badge,
.compact-rank {
  position: absolute;
  border-radius: 999px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.68);
  backdrop-filter: blur(10px);
}

.duration {
  right: 10px;
  top: 10px;
  padding: 5px 9px;
}

.rank-badge {
  left: 10px;
  top: 10px;
  min-width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--pink), var(--orange));
}

.card-body {
  padding: 16px;
}

.meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 10px;
}

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

.chip {
  padding: 5px 9px;
  color: #fff;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.tag {
  padding: 7px 12px;
  color: #475569;
  background: #f1f5f9;
}

.movie-card h3 {
  margin: 0 0 9px;
  font-size: 17px;
  line-height: 1.35;
}

.movie-card h3 a:hover,
.compact-card:hover strong,
.related-card:hover strong {
  color: var(--blue);
}

.movie-card p {
  min-height: 3.1em;
  margin: 0 0 12px;
  color: #64748b;
  line-height: 1.55;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-tags {
  color: #94a3b8;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.feature-band {
  background: linear-gradient(90deg, #f3e8ff, #fce7f3, #ffedd5);
}

.feature-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
}

.feature-main {
  min-height: 460px;
}

.feature-side {
  display: grid;
  gap: 24px;
}

.feature-tile {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border-radius: 30px;
  box-shadow: var(--shadow);
  background: #111827;
}

.feature-tile img {
  width: 100%;
  height: 100%;
  min-height: inherit;
  object-fit: cover;
  transition: transform 0.7s ease;
}

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

.feature-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.14));
}

.feature-content {
  position: absolute;
  z-index: 2;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 26px;
  color: #fff;
}

.feature-content h3 {
  margin: 12px 0 8px;
  font-size: 28px;
}

.feature-content p {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.7;
}

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

.category-card {
  position: relative;
  min-height: 168px;
  border-radius: 24px;
  padding: 22px;
  color: #fff;
  overflow: hidden;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 16px 36px rgba(37, 99, 235, 0.18);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card:nth-child(3n+2) {
  background: linear-gradient(135deg, var(--purple), var(--pink));
}

.category-card:nth-child(3n+3) {
  background: linear-gradient(135deg, #059669, var(--cyan));
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 48px rgba(15, 23, 42, 0.2);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 10px;
}

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  line-height: 1.65;
  font-size: 14px;
}

.page-hero {
  background: linear-gradient(135deg, #0891b2, #2563eb, #1d4ed8);
  color: #fff;
  padding: 84px 22px;
  text-align: center;
}

.page-hero h1 {
  max-width: 900px;
  margin: 0 auto 16px;
  font-size: clamp(36px, 6vw, 58px);
  line-height: 1.15;
}

.page-hero p {
  max-width: 800px;
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.8;
  font-size: 18px;
}

.search-panel {
  display: flex;
  gap: 12px;
  padding: 18px;
  margin-bottom: 26px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.1);
}

.search-panel input,
.search-panel select {
  min-width: 0;
  flex: 1;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 13px 14px;
  outline: 0;
  font-size: 15px;
}

.search-panel button {
  padding: 0 20px;
  color: #fff;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

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

.compact-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  padding: 12px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.compact-card img {
  width: 116px;
  height: 74px;
  flex: 0 0 auto;
  object-fit: cover;
  border-radius: 14px;
  transition: transform 0.35s ease;
}

.compact-info {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.compact-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-info em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.compact-rank {
  right: 12px;
  top: 12px;
  min-width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--pink), var(--orange));
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #64748b;
  margin-bottom: 22px;
  font-size: 14px;
}

.breadcrumb a {
  color: var(--blue);
  font-weight: 700;
}

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

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: var(--shadow);
}

.player-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.62));
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-shell.is-playing .player-cover {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 26px;
  color: var(--blue);
  background: #fff;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
  font-size: 17px;
}

.detail-panel,
.sidebar-panel {
  background: #fff;
  border-radius: 26px;
  padding: 24px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.1);
}

.detail-panel {
  margin-top: 24px;
}

.detail-main h1 {
  margin-bottom: 14px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: #64748b;
  margin-bottom: 18px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 18px 0 24px;
}

.detail-section {
  border-top: 1px solid #e2e8f0;
  padding-top: 22px;
  margin-top: 22px;
}

.detail-section h2 {
  margin: 0 0 12px;
  font-size: 22px;
}

.detail-section p {
  margin: 0;
  color: #334155;
  line-height: 1.9;
  white-space: pre-line;
}

.sidebar-panel {
  position: sticky;
  top: 94px;
}

.sidebar-panel h2,
.sidebar-panel h3 {
  margin: 0 0 18px;
  font-size: 22px;
}

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

.related-card {
  display: flex;
  gap: 12px;
  padding: 10px;
  border-radius: 16px;
  transition: background 0.2s ease;
}

.related-card:hover {
  background: #f8fafc;
}

.related-card img {
  width: 126px;
  height: 78px;
  border-radius: 13px;
  object-fit: cover;
  flex: 0 0 auto;
  transition: transform 0.35s ease;
}

.related-card span {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 6px;
}

.related-card strong {
  line-height: 1.4;
}

.related-card em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(135deg, #0f172a, #172554, #0f172a);
  margin-top: 40px;
}

.footer-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 46px 22px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 34px;
}

.footer-brand {
  color: #fff;
  margin-bottom: 12px;
}

.site-footer p {
  margin: 0;
  line-height: 1.8;
  color: #94a3b8;
}

.site-footer h3 {
  margin: 0 0 14px;
  color: #67e8f9;
}

.site-footer a:not(.footer-brand) {
  display: block;
  margin: 8px 0;
  color: #cbd5e1;
}

.footer-bottom {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  text-align: center;
}

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

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

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

  .hero-stage {
    min-height: 420px;
  }

  .sidebar-panel {
    position: static;
  }
}

@media (max-width: 820px) {
  .nav-shell {
    height: auto;
    min-height: 64px;
    flex-wrap: wrap;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .nav-search {
    order: 3;
    flex-basis: 100%;
    max-width: none;
  }

  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px 0 4px;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 11px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
  }

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

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

@media (max-width: 560px) {
  .hero-inner {
    padding-top: 48px;
    padding-bottom: 48px;
  }

  .hero,
  .hero-inner {
    min-height: auto;
  }

  .hero-stage,
  .hero-card,
  .hero-card img {
    min-height: 380px;
  }

  .section {
    padding: 44px 16px;
  }

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

  .search-panel {
    flex-direction: column;
  }

  .search-panel button {
    padding: 13px 18px;
  }

  .compact-card img,
  .related-card img {
    width: 104px;
    height: 68px;
  }

  .detail-panel,
  .sidebar-panel {
    padding: 18px;
    border-radius: 20px;
  }
}
