:root {
  color-scheme: dark;
  --page-bg: #020617;
  --panel: rgba(15, 23, 42, 0.86);
  --panel-strong: rgba(15, 23, 42, 0.96);
  --line: rgba(34, 211, 238, 0.18);
  --text: #e2e8f0;
  --muted: #94a3b8;
  --soft: #64748b;
  --cyan: #22d3ee;
  --cyan-deep: #0891b2;
  --blue: #60a5fa;
  --pink: #f472b6;
  --amber: #fbbf24;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 8%, rgba(34, 211, 238, 0.16), transparent 34%),
    radial-gradient(circle at 86% 18%, rgba(96, 165, 250, 0.14), transparent 32%),
    linear-gradient(180deg, #020617 0%, #08111f 54%, #020617 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.035) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 82%);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(34, 211, 238, 0.16);
  background: rgba(2, 6, 23, 0.84);
  backdrop-filter: blur(18px);
}

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

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #06121f;
  font-weight: 900;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 0 36px rgba(34, 211, 238, 0.38);
}

.brand-text {
  display: grid;
  line-height: 1.1;
}

.brand-name {
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-subtitle {
  margin-top: 4px;
  font-size: 12px;
  color: var(--muted);
}

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

.nav-link,
.mobile-link {
  color: #cbd5e1;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link {
  padding: 10px 13px;
  border-radius: 999px;
}

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

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

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--cyan);
  border-radius: 999px;
}

.mobile-panel {
  display: none;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(15, 23, 42, 0.94);
}

.mobile-link {
  display: block;
  padding: 12px;
  border-radius: 12px;
}

.mobile-panel.open {
  display: block;
}

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

.hero {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  border-bottom: 1px solid rgba(34, 211, 238, 0.12);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  filter: blur(8px);
  pointer-events: none;
}

.hero::before {
  width: 460px;
  height: 460px;
  left: -120px;
  top: 40px;
  background: rgba(34, 211, 238, 0.16);
}

.hero::after {
  width: 380px;
  height: 380px;
  right: -70px;
  bottom: -40px;
  background: rgba(96, 165, 250, 0.14);
}

.hero-slide {
  display: none;
  width: min(1240px, calc(100% - 32px));
  min-height: 620px;
  margin: 0 auto;
  padding: 68px 0 76px;
  align-items: center;
  gap: 48px;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.72fr);
}

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

.hero-copy {
  position: relative;
  z-index: 2;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-title h1 {
  margin: 0;
  font-size: clamp(36px, 7vw, 74px);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.hero h1 {
  max-width: 860px;
  background: linear-gradient(110deg, #ffffff 0%, #e0f7ff 45%, var(--cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-desc {
  max-width: 760px;
  margin: 22px 0 0;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.9;
}

.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: 12px 20px;
  border: 1px solid rgba(34, 211, 238, 0.32);
  border-radius: 999px;
  color: #dff9ff;
  font-weight: 900;
  background: rgba(15, 23, 42, 0.74);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.24);
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.btn.primary {
  color: #06121f;
  border-color: transparent;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.btn:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.72);
}

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

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

.hero-tags span,
.tag-row span,
.info-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 11px;
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 999px;
  color: #bae6fd;
  font-size: 13px;
  background: rgba(8, 145, 178, 0.12);
}

.hero-card {
  position: relative;
  z-index: 2;
  padding: 16px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 34px;
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.78), rgba(8, 47, 73, 0.38));
  box-shadow: var(--shadow);
}

.hero-poster {
  position: relative;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.9);
}

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

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

.hero-card-caption {
  position: absolute;
  left: 32px;
  right: 32px;
  bottom: 34px;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
}

.hero-card-caption strong {
  display: block;
  font-size: 28px;
  line-height: 1.1;
}

.hero-card-caption span {
  display: block;
  margin-top: 8px;
  color: #cbd5e1;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 1px solid rgba(34, 211, 238, 0.52);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.82);
  cursor: pointer;
}

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

.quick-search {
  position: relative;
  z-index: 3;
  width: min(1240px, calc(100% - 32px));
  margin: -38px auto 64px;
  padding: 20px;
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.84);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
}

.search-input {
  width: 100%;
  min-height: 50px;
  padding: 0 18px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 16px;
  color: #e2e8f0;
  font-size: 16px;
  background: rgba(2, 6, 23, 0.55);
  outline: none;
}

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

.category-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.category-chips a {
  padding: 9px 13px;
  border: 1px solid rgba(34, 211, 238, 0.16);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(8, 47, 73, 0.24);
}

.category-chips a:hover {
  color: var(--cyan);
  border-color: rgba(34, 211, 238, 0.42);
}

.content-section {
  margin: 72px auto;
}

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

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

.section-link {
  flex: none;
  color: var(--cyan);
  font-weight: 900;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.14);
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.78);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.23);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(34, 211, 238, 0.42);
  box-shadow: 0 26px 80px rgba(8, 145, 178, 0.18);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: rgba(2, 6, 23, 0.72);
}

.poster-glow {
  position: absolute;
  inset: auto 18px -30px;
  height: 68px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.22);
  filter: blur(22px);
}

.card-body {
  padding: 16px;
}

.card-kicker,
.card-bottom,
.meta-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--soft);
  font-size: 12px;
  font-weight: 700;
}

.card-kicker span,
.card-bottom span:not(.rating) {
  max-width: 100%;
}

.movie-card h3 {
  margin: 10px 0 8px;
  font-size: 17px;
  line-height: 1.3;
}

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

.movie-card p {
  display: -webkit-box;
  min-height: 46px;
  margin: 0 0 14px;
  overflow: hidden;
  color: #94a3b8;
  font-size: 13px;
  line-height: 1.65;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-bottom {
  justify-content: space-between;
}

.rating,
.rank-badge {
  color: #06121f;
  font-weight: 1000;
  background: linear-gradient(135deg, var(--amber), #fde68a);
}

.rating {
  padding: 4px 8px;
  border-radius: 999px;
}

.rank-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 4;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
}

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

.category-tile {
  position: relative;
  overflow: hidden;
  min-height: 210px;
  padding: 24px;
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 100% 0%, rgba(34, 211, 238, 0.18), transparent 38%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.92), rgba(8, 47, 73, 0.45));
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.24);
}

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

.category-tile p {
  margin: 0 0 20px;
  color: var(--muted);
  line-height: 1.8;
}

.category-tile a {
  color: var(--cyan);
  font-weight: 900;
}

.page-hero {
  align-items: center;
  padding: 58px 0 20px;
}

.page-hero p {
  max-width: 740px;
  margin: 16px 0 0;
  color: var(--muted);
  line-height: 1.85;
}

.page-tools {
  margin: 28px 0;
  padding: 18px;
  border: 1px solid rgba(34, 211, 238, 0.16);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.68);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 34px 0 24px;
  color: var(--muted);
  font-size: 14px;
}

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

.detail-hero {
  display: grid;
  grid-template-columns: minmax(290px, 0.42fr) minmax(0, 0.58fr);
  gap: 34px;
  align-items: center;
  padding: 26px;
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 34px;
  background:
    radial-gradient(circle at 18% 0%, rgba(34, 211, 238, 0.16), transparent 36%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.9), rgba(8, 47, 73, 0.34));
  box-shadow: var(--shadow);
}

.detail-cover {
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border-radius: 26px;
  border: 1px solid rgba(34, 211, 238, 0.2);
  background: rgba(2, 6, 23, 0.68);
}

.detail-title h1 {
  font-size: clamp(34px, 5vw, 60px);
}

.detail-title .summary {
  margin: 20px 0 0;
  color: #cbd5e1;
  font-size: 17px;
  line-height: 1.9;
}

.meta-line {
  margin-top: 16px;
}

.meta-line span {
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.76);
}

.detail-section {
  margin: 54px 0;
}

.prose-card {
  padding: 28px;
  border: 1px solid rgba(34, 211, 238, 0.14);
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.76);
}

.prose-card p {
  margin: 0 0 18px;
  color: #cbd5e1;
  font-size: 16px;
  line-height: 2;
}

.prose-card p:last-child {
  margin-bottom: 0;
}

.watch-player {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 30px;
  background: #000;
  box-shadow: var(--shadow);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  padding: 28px;
  border: 0;
  color: white;
  cursor: pointer;
  background:
    linear-gradient(180deg, rgba(2, 6, 23, 0.15), rgba(2, 6, 23, 0.82)),
    radial-gradient(circle at 50% 40%, rgba(34, 211, 238, 0.18), transparent 44%);
}

.player-overlay.is-hidden {
  display: none;
}

.play-core {
  display: grid;
  gap: 14px;
  place-items: center;
}

.play-icon {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #06121f;
  font-size: 28px;
  font-weight: 1000;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 0 50px rgba(34, 211, 238, 0.46);
}

.play-title {
  font-size: clamp(22px, 4vw, 36px);
  font-weight: 1000;
}

.play-subtitle {
  color: #cbd5e1;
  font-size: 14px;
}

.next-prev {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-top: 28px;
}

.next-prev a {
  flex: 1;
  padding: 16px;
  border: 1px solid rgba(34, 211, 238, 0.14);
  border-radius: 18px;
  color: var(--cyan);
  background: rgba(15, 23, 42, 0.74);
}

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

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

.site-footer {
  margin-top: 88px;
  border-top: 1px solid rgba(34, 211, 238, 0.14);
  background: rgba(2, 6, 23, 0.82);
}

.footer-grid {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 46px 0;
  display: grid;
  grid-template-columns: 1.1fr 1fr 0.9fr;
  gap: 32px;
}

.footer-brand {
  margin-bottom: 12px;
  color: var(--cyan);
  font-size: 22px;
  font-weight: 1000;
}

.site-footer h3 {
  margin: 0 0 14px;
}

.site-footer p,
.copyright {
  color: var(--muted);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-links a {
  padding: 8px 10px;
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.82);
}

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

.copyright {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 28px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  text-align: center;
}

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

  .menu-toggle {
    display: block;
  }

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

  .hero-card {
    max-width: 430px;
  }

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

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

@media (max-width: 760px) {
  .header-shell {
    width: min(100% - 24px, 1240px);
    height: 64px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  .brand-name {
    font-size: 17px;
  }

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

  .hero-slide {
    padding: 42px 0 82px;
    gap: 28px;
  }

  .hero-desc {
    font-size: 16px;
  }

  .hero-card-caption {
    left: 24px;
    right: 24px;
    bottom: 24px;
    display: block;
  }

  .hero-card-caption strong {
    font-size: 22px;
  }

  .quick-search {
    margin-top: -24px;
    border-radius: 22px;
  }

  .search-row {
    grid-template-columns: 1fr;
  }

  .section-head,
  .page-hero,
  .next-prev {
    display: block;
  }

  .section-link {
    display: inline-block;
    margin-top: 12px;
  }

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

  .movie-card {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
  }

  .poster-link {
    height: 100%;
    min-height: 178px;
  }

  .detail-hero,
  .prose-card {
    padding: 18px;
    border-radius: 24px;
  }

  .play-icon {
    width: 64px;
    height: 64px;
  }

  .next-prev a {
    display: block;
    margin-top: 12px;
  }
}
