:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.72);
  --panel-strong: rgba(15, 23, 42, 0.94);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #22d3ee;
  --blue: #38bdf8;
  --violet: #818cf8;
  --gold: #facc15;
  --shadow: 0 24px 80px rgba(2, 6, 23, 0.55);
  --radius: 28px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 20% 0%, rgba(34, 211, 238, 0.22), transparent 30rem),
    radial-gradient(circle at 80% 18%, rgba(129, 140, 248, 0.18), transparent 28rem),
    linear-gradient(180deg, #020617 0%, #0f172a 42%, #020617 100%);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.78);
  backdrop-filter: blur(18px);
}

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

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

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: #031018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 14px 28px rgba(34, 211, 238, 0.24);
}

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

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

.nav-link,
.mobile-link {
  color: var(--muted);
  padding: 10px 14px;
  border-radius: 999px;
  transition: color 0.25s ease, background 0.25s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: var(--text);
  background: rgba(34, 211, 238, 0.13);
}

.menu-toggle {
  width: 44px;
  height: 44px;
  display: none;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.6);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 5px auto;
  background: var(--text);
  border-radius: 3px;
}

.mobile-nav {
  display: none;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px 16px;
}

.hero {
  padding: 30px 20px 60px;
}

.hero-shell {
  position: relative;
  max-width: 1240px;
  min-height: 650px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 36px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(15, 23, 42, 0.76);
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.6s ease, transform 0.8s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08) contrast(1.05);
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.74) 45%, rgba(2, 6, 23, 0.35) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.08), rgba(2, 6, 23, 0.96));
}

.hero-content {
  position: relative;
  min-height: 650px;
  padding: 70px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: center;
  gap: 56px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: max-content;
  color: var(--cyan);
  border: 1px solid rgba(34, 211, 238, 0.22);
  background: rgba(34, 211, 238, 0.10);
  border-radius: 999px;
  padding: 8px 16px;
  font-weight: 700;
}

.hero-copy h1 {
  margin: 24px 0 0;
  font-size: clamp(46px, 7vw, 88px);
  line-height: 0.95;
  letter-spacing: -0.06em;
  background: linear-gradient(90deg, #e0f2fe, var(--cyan), var(--violet));
  -webkit-background-clip: text;
  color: transparent;
}

.hero-copy h2 {
  margin: 22px 0 18px;
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.05;
}

.hero-copy p {
  max-width: 720px;
  margin: 0;
  color: #cbd5e1;
  font-size: 20px;
  line-height: 1.8;
}

.hero-tags,
.tag-row,
.detail-tags,
.meta-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  margin: 26px 0 0;
}

.hero-tags span,
.tag-row span,
.detail-tags span,
.meta-pills span {
  color: #dff8ff;
  background: rgba(15, 23, 42, 0.58);
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 13px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 34px;
}

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

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

.btn.primary {
  color: #02131a;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 16px 34px rgba(34, 211, 238, 0.28);
}

.btn.ghost {
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(15, 23, 42, 0.56);
}

.btn.text {
  color: var(--cyan);
  padding-left: 4px;
  padding-right: 4px;
}

.hero-poster {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 70px rgba(2, 6, 23, 0.65);
  transform: rotate(2deg);
}

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

.hero-poster span,
.play-badge {
  position: absolute;
  display: grid;
  place-items: center;
  color: white;
  background: rgba(34, 211, 238, 0.88);
  box-shadow: 0 15px 36px rgba(34, 211, 238, 0.35);
}

.hero-poster span {
  left: 50%;
  top: 50%;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  font-size: 30px;
}

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

.hero-arrow,
.hero-dot {
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(15, 23, 42, 0.62);
  color: white;
  cursor: pointer;
}

.hero-arrow {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  font-size: 30px;
}

.hero-dots {
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  border-radius: 99px;
  padding: 0;
}

.hero-dot.active {
  width: 38px;
  background: var(--cyan);
}

.quick-search,
.content-section,
.page-main,
.detail-main {
  max-width: 1240px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}

.quick-search {
  margin-top: -26px;
  position: relative;
  z-index: 5;
}

.search-panel {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.84);
  backdrop-filter: blur(16px);
  box-shadow: 0 18px 48px rgba(2, 6, 23, 0.38);
}

.search-panel.inside {
  margin-bottom: 26px;
}

.search-panel label {
  display: block;
  margin-bottom: 12px;
  color: #dbeafe;
  font-weight: 700;
}

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

.search-box input {
  flex: 1;
  min-width: 0;
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.20);
  outline: none;
  background: rgba(2, 6, 23, 0.60);
  border-radius: 16px;
  padding: 15px 16px;
}

.search-box input:focus {
  border-color: rgba(34, 211, 238, 0.58);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.10);
}

.search-box button,
.filter-row button {
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(30, 41, 59, 0.72);
  border-radius: 999px;
  padding: 12px 18px;
  cursor: pointer;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.filter-row button.active,
.filter-row button:hover,
.search-box button:hover {
  color: #04131a;
  border-color: transparent;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.content-section {
  padding-top: 70px;
}

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

.section-heading h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.03em;
}

.section-heading p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.section-more,
.text-link {
  color: var(--cyan);
  font-weight: 800;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.70);
  box-shadow: 0 18px 50px rgba(2, 6, 23, 0.26);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.45);
  box-shadow: 0 24px 70px rgba(34, 211, 238, 0.12);
}

.poster {
  position: relative;
  display: block;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.75);
}

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

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

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

.play-badge {
  right: 12px;
  bottom: 12px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  z-index: 2;
}

.rank-num {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 2;
  min-width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #06121a;
  background: linear-gradient(135deg, var(--gold), #fb923c);
}

.card-body {
  padding: 16px;
}

.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--cyan);
  font-size: 13px;
  margin-bottom: 8px;
}

.meta-row span {
  color: var(--muted);
}

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

.movie-card.compact h3 {
  font-size: 16px;
}

.movie-card h3 a:hover {
  color: var(--cyan);
}

.movie-card p {
  color: var(--muted);
  margin: 0 0 13px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card.compact p {
  font-size: 14px;
}

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

.category-tile,
.collection-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.66);
  box-shadow: 0 18px 48px rgba(2, 6, 23, 0.24);
}

.category-tile {
  min-height: 170px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-tile:hover,
.collection-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 211, 238, 0.4);
}

.category-tile strong {
  font-size: 24px;
}

.category-tile span,
.collection-body p {
  color: var(--muted);
  line-height: 1.7;
}

.page-main,
.detail-main {
  padding-top: 42px;
}

.page-hero {
  min-height: 360px;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 34px;
  align-items: center;
  margin-bottom: 28px;
  padding: 44px;
  border: 1px solid var(--line);
  border-radius: 34px;
  background:
    radial-gradient(circle at 20% 20%, rgba(34, 211, 238, 0.20), transparent 24rem),
    rgba(15, 23, 42, 0.68);
  box-shadow: var(--shadow);
}

.page-hero.slim {
  min-height: 280px;
  display: block;
}

.page-hero h1 {
  margin: 20px 0 16px;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 760px;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.8;
}

.category-hero-art {
  overflow: hidden;
  position: relative;
  border-radius: 26px;
  border: 1px solid var(--line);
}

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

.category-hero-art span {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.66);
  backdrop-filter: blur(12px);
  font-weight: 800;
}

.collection-card {
  overflow: hidden;
}

.collection-art {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 190px;
  overflow: hidden;
}

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

.collection-body {
  padding: 22px;
}

.collection-body h2 {
  margin: 0 0 10px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  margin: 4px 0 24px;
}

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

.watch-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  align-items: stretch;
}

.player-card,
.watch-side,
.detail-panel {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.74);
  box-shadow: 0 24px 70px rgba(2, 6, 23, 0.36);
}

.player-card {
  padding: 14px;
}

.player-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000;
  aspect-ratio: 16 / 9;
}

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

.play-layer {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 0;
  color: white;
  background: radial-gradient(circle at center, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.60));
  cursor: pointer;
}

.play-layer span {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 34px;
  background: rgba(34, 211, 238, 0.92);
  box-shadow: 0 20px 44px rgba(34, 211, 238, 0.33);
}

.play-layer.is-hidden {
  display: none;
}

.watch-side {
  padding: 16px;
}

.watch-side img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 20px;
}

.watch-side p {
  color: var(--cyan);
  margin: 18px 0 8px;
  font-weight: 800;
}

.watch-side h1 {
  margin: 0;
  font-size: 28px;
  line-height: 1.25;
}

.detail-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 32px;
  margin-top: 28px;
  padding: 32px;
}

.detail-copy h2 {
  margin: 30px 0 12px;
  font-size: 28px;
}

.detail-copy p {
  color: #cbd5e1;
  line-height: 2;
  font-size: 17px;
}

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

.detail-facts {
  border-left: 1px solid var(--line);
  padding-left: 28px;
}

.detail-facts dl {
  margin: 0;
}

.detail-facts dt {
  color: var(--muted);
  margin-top: 18px;
}

.detail-facts dd {
  margin: 6px 0 0;
  line-height: 1.6;
}

.detail-facts a {
  color: var(--cyan);
}

.related-section {
  padding-bottom: 80px;
}

.empty-state {
  display: none;
  color: var(--muted);
  text-align: center;
  padding: 40px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.62);
}

.empty-state.show {
  display: block;
}

.site-footer {
  margin-top: 80px;
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.76);
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 36px 20px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 30px;
}

.footer-brand {
  color: var(--text);
  font-size: 22px;
}

.footer-inner p {
  color: var(--muted);
  margin: 12px 0 0;
  max-width: 520px;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px 18px;
}

.footer-links a {
  color: var(--muted);
}

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

.footer-bottom {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px 28px;
  color: #64748b;
  font-size: 14px;
}

@media (max-width: 1100px) {
  .featured-grid,
  .category-grid,
  .collection-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .hero-content,
  .watch-layout,
  .detail-panel,
  .page-hero {
    grid-template-columns: 1fr;
  }

  .hero-poster,
  .category-hero-art,
  .watch-side {
    max-width: 360px;
  }

  .detail-facts {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-left: 0;
    padding-top: 22px;
  }
}

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

  .menu-toggle {
    display: block;
  }

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

  .header-inner {
    padding: 14px 16px;
  }

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

  .hero {
    padding: 18px 12px 38px;
  }

  .hero-shell,
  .hero-content {
    min-height: 720px;
  }

  .hero-shell {
    border-radius: 28px;
  }

  .hero-content {
    padding: 36px 24px 92px;
    align-content: center;
    gap: 28px;
  }

  .hero-copy p,
  .page-hero p {
    font-size: 16px;
  }

  .hero-controls {
    left: 24px;
    right: 24px;
  }

  .quick-search,
  .content-section,
  .page-main,
  .detail-main {
    padding-left: 14px;
    padding-right: 14px;
  }

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

  .section-heading,
  .footer-inner {
    display: block;
  }

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

  .movie-card p,
  .tag-row {
    display: none;
  }

  .card-body {
    padding: 12px;
  }

  .page-hero,
  .detail-panel {
    padding: 24px;
    border-radius: 26px;
  }

  .watch-side {
    display: none;
  }

  .footer-links {
    justify-content: flex-start;
    margin-top: 20px;
  }
}

@media (max-width: 480px) {
  .movie-grid,
  .featured-grid,
  .category-grid,
  .collection-grid {
    grid-template-columns: 1fr;
  }

  .hero-copy h1 {
    font-size: 42px;
  }

  .hero-copy h2 {
    font-size: 28px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }
}
