:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.86);
  --panel-strong: #0f172a;
  --panel-soft: rgba(30, 41, 59, 0.72);
  --line: rgba(148, 163, 184, 0.18);
  --text: #e5e7eb;
  --muted: #94a3b8;
  --cyan: #22d3ee;
  --cyan-strong: #06b6d4;
  --pink: #f472b6;
  --yellow: #facc15;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, "Microsoft YaHei", "PingFang SC", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.18), transparent 34rem),
    radial-gradient(circle at 80% 10%, rgba(244, 114, 182, 0.13), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 52%, #020617 100%);
}

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

img {
  max-width: 100%;
}

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

.nav-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 14px 22px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
  font-weight: 900;
  letter-spacing: 0.02em;
  font-size: 19px;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #001018;
  background: linear-gradient(135deg, var(--cyan), #67e8f9, var(--pink));
  box-shadow: 0 0 32px rgba(34, 211, 238, 0.34);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 15px;
  color: #cbd5e1;
}

.nav-link,
.nav-drop > button {
  border: 0;
  padding: 8px 2px;
  color: inherit;
  background: transparent;
  font: inherit;
}

.nav-link:hover,
.nav-link.active,
.nav-drop > button:hover {
  color: var(--cyan);
}

.nav-drop {
  position: relative;
}

.drop-panel {
  position: absolute;
  top: 100%;
  left: 0;
  width: 190px;
  padding: 10px;
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.96);
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: 0.22s ease;
}

.nav-drop:hover .drop-panel,
.nav-drop:focus-within .drop-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.drop-panel a,
.mobile-panel a {
  padding: 10px 12px;
  border-radius: 12px;
  color: #dbeafe;
}

.drop-panel a:hover,
.mobile-panel a:hover {
  color: var(--cyan);
  background: rgba(34, 211, 238, 0.1);
}

.top-search {
  margin-left: auto;
  display: flex;
  align-items: center;
  width: min(330px, 100%);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.82);
}

.top-search input,
.mobile-search input,
.quick-search input,
.filter-fields input,
.filter-fields select {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  font: inherit;
}

.top-search input {
  padding: 10px 14px;
}

.top-search button,
.mobile-search button,
.quick-search button {
  border: 0;
  padding: 10px 16px;
  min-width: max-content;
  color: #02111a;
  background: var(--cyan);
  font-weight: 800;
}

.menu-toggle {
  display: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 8px 11px;
  color: var(--text);
  background: rgba(15, 23, 42, 0.8);
}

.mobile-panel {
  display: none;
  padding: 0 22px 18px;
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.94);
}

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

.mobile-search {
  display: flex;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
}

.mobile-search input {
  padding: 12px;
}

.hero-carousel {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

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

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.83) 48%, rgba(2, 6, 23, 0.28) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.12), #020617 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
  padding: 130px 22px 90px;
  margin-left: max(22px, calc((100vw - 1280px) / 2 + 22px));
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: max-content;
  margin-bottom: 14px;
  padding: 7px 12px;
  border: 1px solid rgba(34, 211, 238, 0.38);
  border-radius: 999px;
  color: #67e8f9;
  background: rgba(8, 145, 178, 0.12);
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.08em;
}

.hero-content h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.hero-content p {
  max-width: 640px;
  margin: 24px 0 0;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.8;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.tag-cloud span {
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #bae6fd;
  background: rgba(15, 23, 42, 0.62);
  font-size: 13px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 900;
}

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

.btn.ghost {
  border: 1px solid var(--line);
  color: #e0f2fe;
  background: rgba(15, 23, 42, 0.58);
}

.hero-side {
  position: absolute;
  right: max(22px, calc((100vw - 1280px) / 2 + 22px));
  bottom: 86px;
  z-index: 3;
  width: 370px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-side h2 {
  margin: 0 0 14px;
  font-size: 18px;
}

.hero-dots {
  position: absolute;
  z-index: 4;
  left: max(22px, calc((100vw - 1280px) / 2 + 22px));
  bottom: 40px;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 28px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
}

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

.quick-panel,
.section-block,
.two-column,
.inner-page,
.detail-page {
  max-width: 1280px;
  margin: 0 auto;
  padding-left: 22px;
  padding-right: 22px;
}

.quick-panel {
  margin-top: -38px;
  position: relative;
  z-index: 5;
  display: grid;
  gap: 16px;
  padding-top: 0;
}

.quick-search {
  display: flex;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.94);
  box-shadow: var(--shadow);
}

.quick-search input {
  padding: 18px 20px;
  font-size: 16px;
}

.quick-search button {
  padding-left: 24px;
  padding-right: 24px;
}

.quick-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.quick-cats a {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(15, 23, 42, 0.72);
}

.quick-cats a:hover {
  border-color: rgba(34, 211, 238, 0.6);
  color: var(--cyan);
}

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

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

.section-head h2 {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.03em;
}

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

.section-head.compact {
  align-items: start;
}

.section-more {
  color: var(--cyan);
  font-weight: 900;
  min-width: max-content;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.78);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.22);
  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.46);
  box-shadow: 0 28px 70px rgba(8, 145, 178, 0.18);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #164e63);
}

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

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

.poster-badge,
.play-dot {
  position: absolute;
  border-radius: 999px;
  font-weight: 900;
}

.poster-badge {
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  color: #02111a;
  background: var(--cyan);
  font-size: 12px;
}

.play-dot {
  right: 12px;
  bottom: 12px;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #02111a;
  background: rgba(255, 255, 255, 0.9);
}

.movie-info {
  padding: 16px;
}

.movie-info h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.3;
}

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

.movie-info p {
  min-height: 48px;
  margin: 10px 0 12px;
  color: #b6c4d8;
  line-height: 1.65;
  font-size: 14px;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.meta-row a,
.meta-row span {
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.86);
}

.meta-row a {
  color: #bae6fd;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 22px;
  padding-top: 70px;
}

.panel-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  background: rgba(15, 23, 42, 0.74);
  box-shadow: var(--shadow);
}

.rank-list {
  display: grid;
  gap: 12px;
}

.rank-item {
  display: grid;
  grid-template-columns: auto 56px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 18px;
  background: rgba(30, 41, 59, 0.56);
}

.rank-item:hover {
  background: rgba(8, 145, 178, 0.16);
}

.rank-item img {
  width: 56px;
  height: 76px;
  object-fit: cover;
  border-radius: 12px;
}

.rank-no {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: #02111a;
  background: var(--yellow);
  font-weight: 900;
}

.rank-item strong,
.rank-item em {
  display: block;
}

.rank-item em {
  margin-top: 5px;
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.category-list,
.category-overview {
  display: grid;
  gap: 14px;
}

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

.category-list a,
.category-card a {
  display: grid;
  gap: 8px;
  height: 100%;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(8, 145, 178, 0.14), rgba(30, 41, 59, 0.62));
}

.category-list a:hover,
.category-card a:hover {
  border-color: rgba(34, 211, 238, 0.54);
}

.category-list strong,
.category-card span {
  color: #e0f2fe;
  font-size: 18px;
  font-weight: 900;
}

.category-list span,
.category-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.category-card em {
  color: var(--cyan);
  font-style: normal;
  font-weight: 900;
}

.inner-page,
.detail-page {
  padding-top: 34px;
  padding-bottom: 80px;
}

.page-hero {
  overflow: hidden;
  margin-bottom: 28px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at 15% 0%, rgba(34, 211, 238, 0.22), transparent 26rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.58));
  box-shadow: var(--shadow);
}

.small-hero {
  padding: 42px;
}

.small-hero h1 {
  margin: 0;
  font-size: clamp(32px, 5vw, 54px);
  letter-spacing: -0.04em;
}

.small-hero p {
  max-width: 760px;
  margin: 14px 0 0;
  color: #cbd5e1;
  font-size: 17px;
  line-height: 1.8;
}

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

.crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
}

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

.filter-bar {
  margin: 0 0 22px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
}

.filter-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px 190px;
  gap: 12px;
}

.filter-fields input,
.filter-fields select {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(2, 6, 23, 0.42);
}

.filter-fields select option {
  color: #111827;
}

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

.rank-page-list {
  display: grid;
  gap: 16px;
}

.rank-row {
  display: grid;
  grid-template-columns: 126px minmax(0, 1fr);
  gap: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.74);
}

.rank-cover img {
  width: 126px;
  height: 168px;
  border-radius: 18px;
  object-fit: cover;
}

.rank-main {
  position: relative;
  padding-right: 16px;
}

.rank-large {
  position: absolute;
  right: 0;
  top: 0;
  color: rgba(255, 255, 255, 0.08);
  font-size: 52px;
  font-weight: 900;
  line-height: 1;
}

.rank-main h2 {
  margin: 4px 0 10px;
  font-size: 24px;
}

.rank-main h2 a:hover {
  color: var(--cyan);
}

.rank-main p {
  margin: 0 0 12px;
  color: #b6c4d8;
  line-height: 1.8;
}

.detail-hero {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 28px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at 82% 0%, rgba(34, 211, 238, 0.18), transparent 28rem),
    rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 24px;
  object-fit: cover;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
}

.detail-copy h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.lead {
  max-width: 820px;
  margin: 18px 0 0;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.9;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.detail-meta span {
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.72);
}

.player-section,
.detail-content {
  margin-top: 28px;
}

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

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

.player-start {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  color: #02111a;
  background: rgba(255, 255, 255, 0.92);
  transform: translate(-50%, -50%);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
}

.player-start span {
  margin-left: 5px;
  font-size: 32px;
}

.player-box.playing .player-start {
  opacity: 0;
  pointer-events: none;
}

.player-status {
  position: absolute;
  left: 18px;
  bottom: 12px;
  z-index: 3;
  margin: 0;
  color: #dbeafe;
  font-size: 13px;
}

.detail-content {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.72);
}

.detail-content h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.detail-content h2:not(:first-child) {
  margin-top: 26px;
}

.detail-content p {
  margin: 0;
  color: #cbd5e1;
  line-height: 2;
  font-size: 16px;
}

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

.related-grid .movie-info p {
  display: none;
}

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

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 36px 22px;
  display: grid;
  gap: 18px;
  color: var(--muted);
}

.footer-inner strong {
  color: var(--text);
  font-size: 20px;
}

.footer-inner p {
  margin: 8px 0 0;
  line-height: 1.7;
}

.footer-links,
.footer-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-links a,
.footer-cats a {
  color: #cbd5e1;
}

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

.copyright {
  font-size: 13px;
}

.movie-card.hidden-card {
  display: none;
}

@media (max-width: 1100px) {
  .top-search {
    display: none;
  }

  .hero-side {
    position: relative;
    right: auto;
    bottom: auto;
    width: auto;
    margin: 0 22px 86px;
  }

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

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

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

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

  .hero-carousel {
    min-height: 760px;
  }

  .hero-content {
    margin-left: 0;
    padding: 100px 22px 40px;
  }

  .hero-side {
    margin-bottom: 96px;
  }

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

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

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

  .filter-fields {
    grid-template-columns: 1fr;
  }

  .rank-row {
    grid-template-columns: 92px minmax(0, 1fr);
  }

  .rank-cover img {
    width: 92px;
    height: 124px;
  }
}

@media (max-width: 620px) {
  .nav-shell {
    padding: 12px 16px;
  }

  .brand {
    font-size: 16px;
  }

  .hero-content h1,
  .small-hero h1,
  .detail-copy h1 {
    letter-spacing: -0.03em;
  }

  .quick-search,
  .hero-actions {
    flex-direction: column;
  }

  .quick-search button {
    width: 100%;
  }

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

  .movie-info {
    padding: 12px;
  }

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

  .movie-info p {
    font-size: 13px;
  }

  .small-hero,
  .detail-hero,
  .detail-content,
  .panel-card {
    padding: 18px;
    border-radius: 22px;
  }

  .player-start {
    width: 66px;
    height: 66px;
  }
}
