:root {
  --bg: #f8fafc;
  --bg-soft: #eef2f7;
  --panel: #ffffff;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --nav-1: #0f172a;
  --nav-2: #334155;
  --accent: #0284c7;
  --accent-soft: #e0f2fe;
  --accent-strong: #0369a1;
  --shadow: 0 16px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: linear-gradient(180deg, var(--bg), var(--bg-soft));
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, var(--nav-1), var(--nav-2), var(--nav-1));
  color: #fff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.25);
}

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

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

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #e0f2fe;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  box-shadow: 0 10px 25px rgba(14, 165, 233, 0.35);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-size: 20px;
  letter-spacing: 0.04em;
}

.brand-text em {
  margin-top: 3px;
  color: #7dd3fc;
  font-size: 12px;
  font-style: normal;
}

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

.nav-link {
  padding: 9px 15px;
  border-radius: 10px;
  color: #e2e8f0;
  font-size: 14px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
  background: rgba(14, 165, 233, 0.9);
  transform: translateY(-1px);
}

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

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

.hero {
  position: relative;
  min-height: 600px;
  overflow: hidden;
  color: #fff;
  background: #0f172a;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.hero-slide.active {
  opacity: 1;
}

.hero-bg,
.hero-bg img {
  width: 100%;
  height: 100%;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 75% 25%, rgba(14, 165, 233, 0.35), transparent 34%), linear-gradient(135deg, #0f172a, #1e293b);
}

.hero-bg img {
  object-fit: cover;
  opacity: 0.72;
}

.hero-bg img.is-missing,
.poster-image.is-missing,
.detail-poster img.is-missing,
.player-video.is-missing {
  opacity: 0;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.88), rgba(15, 23, 42, 0.62), rgba(15, 23, 42, 0.1));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  min-height: 600px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  align-items: center;
  gap: 48px;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  margin-bottom: 18px;
  border: 1px solid rgba(125, 211, 252, 0.4);
  border-radius: 999px;
  color: #7dd3fc;
  background: rgba(14, 165, 233, 0.12);
  backdrop-filter: blur(8px);
  font-size: 14px;
  font-weight: 700;
}

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

.hero p {
  margin: 0;
  color: #dbeafe;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.8;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-weight: 700;
  cursor: pointer;
  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, #0ea5e9, #2563eb);
  box-shadow: 0 16px 35px rgba(14, 165, 233, 0.35);
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
}

.hero-panel {
  padding: 22px;
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(15, 23, 42, 0.48);
  backdrop-filter: blur(14px);
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.32);
}

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

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

.hero-mini {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  transition: transform 0.2s ease, background 0.2s ease;
}

.hero-mini:hover {
  transform: translateX(4px);
  background: rgba(14, 165, 233, 0.26);
}

.hero-mini .thumb {
  width: 54px;
  height: 72px;
  overflow: hidden;
  border-radius: 12px;
  background: linear-gradient(135deg, #1e293b, #0ea5e9);
}

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

.hero-mini strong {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.hero-mini span {
  color: #bfdbfe;
  font-size: 13px;
}

.hero-dots {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 28px;
  display: flex;
  gap: 8px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 34px;
  height: 4px;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
}

.hero-dot.active {
  background: #38bdf8;
}

.section {
  padding: 52px 0;
}

.section.tight {
  padding-top: 30px;
}

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

.section-title {
  margin: 0;
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -0.03em;
}

.section-desc {
  max-width: 760px;
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

.section-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.round-btn {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--text);
  background: #fff;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

.movie-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(220px, 260px);
  gap: 20px;
  overflow-x: auto;
  padding: 6px 2px 18px;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
}

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

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

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

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.movie-card.compact {
  display: grid;
  grid-template-columns: 96px 1fr;
  min-height: 136px;
}

.card-poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: radial-gradient(circle at 70% 20%, rgba(14, 165, 233, 0.4), transparent 34%), linear-gradient(135deg, #1e293b, #0f172a);
}

.movie-card.compact .card-poster {
  aspect-ratio: auto;
  min-height: 136px;
}

.poster-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease, opacity 0.2s ease;
}

.movie-card:hover .poster-image {
  transform: scale(1.05);
}

.card-score {
  position: absolute;
  right: 10px;
  top: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #fff;
  background: rgba(2, 132, 199, 0.92);
  font-size: 13px;
  font-weight: 800;
}

.card-body {
  padding: 16px;
}

.movie-card.compact .card-body {
  padding: 12px 14px;
}

.card-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 1.5em;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.45;
}

.card-title:hover {
  color: var(--accent);
}

.card-meta {
  margin: 8px 0;
  color: var(--muted);
  font-size: 13px;
}

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

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

.tag-row span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  color: var(--accent-strong);
  background: var(--accent-soft);
  font-size: 12px;
  font-weight: 700;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 210px;
  padding: 24px;
  border-radius: 26px;
  color: #fff;
  background: radial-gradient(circle at 85% 20%, rgba(56, 189, 248, 0.55), transparent 30%), linear-gradient(135deg, #0f172a, #334155);
  box-shadow: var(--shadow);
}

.category-card h3 {
  margin: 0 0 10px;
  font-size: 24px;
}

.category-card p {
  margin: 0 0 24px;
  color: #dbeafe;
  line-height: 1.75;
}

.category-card span {
  display: inline-flex;
  padding: 9px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.16);
}

.rank-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: start;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 48px 1fr auto 52px;
  align-items: center;
  gap: 14px;
  min-height: 62px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-row:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow);
}

.rank-num {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  font-weight: 900;
}

.rank-title {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 800;
}

.rank-meta {
  color: var(--muted);
  font-size: 13px;
}

.rank-score {
  color: var(--accent-strong);
  font-weight: 900;
  text-align: right;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
}

.panel-body {
  padding: 22px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 24px;
}

.search-box {
  height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
}

.search-box span {
  color: var(--accent);
  font-size: 22px;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: #fff;
  cursor: pointer;
}

.chip.active,
.chip:hover {
  color: #fff;
  border-color: var(--accent);
  background: var(--accent);
}

.page-hero {
  padding: 54px 0 28px;
}

.page-hero h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 56px);
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 820px;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: #0f172a;
}

.detail-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 82% 15%, rgba(14, 165, 233, 0.4), transparent 32%), linear-gradient(135deg, #020617, #1e293b);
}

.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.25;
  filter: blur(16px) saturate(1.2);
  transform: scale(1.08);
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(15, 23, 42, 0.72));
}

.detail-wrap {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 56px 0;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 34px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(135deg, #1e293b, #0ea5e9);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
}

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

.detail-info h1 {
  margin: 0 0 16px;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.detail-meta span {
  padding: 7px 11px;
  border-radius: 999px;
  color: #bae6fd;
  background: rgba(14, 165, 233, 0.16);
}

.detail-line {
  max-width: 860px;
  margin: 0 0 20px;
  color: #dbeafe;
  font-size: 19px;
  line-height: 1.8;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.player-section {
  padding: 42px 0 20px;
  background: #020617;
}

.watch-player {
  position: relative;
  overflow: hidden;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  border-radius: 26px;
  background: #000;
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.38);
}

.watch-player::before {
  content: "";
  display: block;
  padding-top: 56.25%;
}

.player-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #000;
  object-fit: contain;
}

.player-start {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  background: radial-gradient(circle at center, rgba(14, 165, 233, 0.25), rgba(2, 6, 23, 0.58));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-start.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-start-inner {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 16px 22px;
  border-radius: 18px;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(10px);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
}

.player-start-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  font-size: 22px;
}

.player-message {
  width: min(1120px, calc(100% - 32px));
  min-height: 24px;
  margin: 12px auto 0;
  color: #bae6fd;
  font-size: 14px;
}

.content-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: start;
}

.article-box {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
}

.article-box + .article-box {
  margin-top: 20px;
}

.article-box h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

.article-box p {
  margin: 0;
  color: #334155;
  font-size: 16px;
  line-height: 2;
}

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

.empty-state {
  display: none;
  padding: 34px;
  border: 1px dashed #cbd5e1;
  border-radius: 20px;
  color: var(--muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.75);
}

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

.site-footer {
  margin-top: 60px;
  padding: 34px 0;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-inner p {
  max-width: 680px;
  margin: 8px 0 0;
  color: #94a3b8;
}

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

.footer-links a {
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
}

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

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

  .rank-layout,
  .content-layout {
    grid-template-columns: 1fr;
  }

  .hero-content {
    grid-template-columns: 1fr;
    padding: 70px 0;
  }

  .hero-panel {
    display: none;
  }
}

@media (max-width: 760px) {
  .top-nav {
    height: 62px;
  }

  .brand-text strong {
    font-size: 17px;
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 70px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border-radius: 18px;
    background: #0f172a;
    box-shadow: var(--shadow);
  }

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

  .nav-link {
    padding: 12px 14px;
  }

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

  .hero-content {
    align-items: end;
    padding-bottom: 72px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .section-head,
  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

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

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

  .rank-row {
    grid-template-columns: 42px 1fr 48px;
  }

  .rank-meta {
    display: none;
  }

  .detail-wrap {
    grid-template-columns: 1fr;
    padding: 36px 0;
  }

  .detail-poster {
    width: min(230px, 70vw);
  }

  .article-box {
    padding: 22px;
  }
}

@media (max-width: 500px) {
  .container,
  .top-nav,
  .hero-content,
  .detail-wrap {
    width: min(100% - 22px, 1240px);
  }

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

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

  .movie-card.compact {
    grid-template-columns: 82px 1fr;
  }

  .card-line {
    -webkit-line-clamp: 2;
  }
}
