* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #0f172a;
  background: #f8fafc;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(15, 23, 42, 0.92);
  color: #ffffff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(18px);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 22px;
  min-height: 72px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.35);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
}

.desktop-nav a {
  color: #dbeafe;
  font-size: 14px;
  transition: color 0.2s ease;
}

.desktop-nav a:hover {
  color: #ffffff;
}

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 286px;
  flex-shrink: 0;
}

.header-search input,
.mobile-search input,
.filter-panel input,
.filter-panel select {
  border: 1px solid rgba(148, 163, 184, 0.45);
  outline: none;
  color: #0f172a;
  background: rgba(255, 255, 255, 0.96);
}

.header-search input {
  width: 100%;
  height: 38px;
  padding: 0 14px;
  border-radius: 999px;
}

.header-search button,
.mobile-search button {
  height: 38px;
  border: 0;
  color: #ffffff;
  background: #2563eb;
  border-radius: 999px;
  padding: 0 16px;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.header-search button:hover,
.mobile-search button:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  cursor: pointer;
}

.mobile-toggle span {
  width: 18px;
  height: 2px;
  background: #ffffff;
  border-radius: 99px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 14px 16px 20px;
}

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

.mobile-panel nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.mobile-panel nav a {
  padding: 11px 12px;
  color: #e0f2fe;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
}

.mobile-search {
  display: flex;
  gap: 8px;
}

.mobile-search input {
  flex: 1;
  min-width: 0;
  height: 42px;
  padding: 0 14px;
  border-radius: 999px;
}

.hero {
  position: relative;
  min-height: 650px;
  color: #ffffff;
  background: radial-gradient(circle at 15% 20%, rgba(59, 130, 246, 0.48), transparent 34%), linear-gradient(135deg, #020617 0%, #0f2f70 52%, #020617 100%);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.1;
  background-image: linear-gradient(rgba(255, 255, 255, 0.25) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.25) 1px, transparent 1px);
  background-size: 42px 42px;
}

.hero-slide {
  display: none;
  position: relative;
  z-index: 1;
  min-height: 650px;
  padding: 80px 0 72px;
}

.hero-slide.is-active {
  display: block;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  align-items: center;
  gap: 54px;
}

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

.hero-kicker,
.section-kicker,
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding: 7px 12px;
  color: #bfdbfe;
  background: rgba(59, 130, 246, 0.18);
  border: 1px solid rgba(147, 197, 253, 0.22);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.hero h1 {
  margin: 0;
  font-size: clamp(38px, 7vw, 68px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero h1 span {
  display: block;
  color: #93c5fd;
}

.hero-copy p {
  margin: 24px 0 0;
  max-width: 660px;
  color: #dbeafe;
  font-size: clamp(18px, 2.1vw, 24px);
  line-height: 1.75;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-primary {
  color: #ffffff;
  background: #2563eb;
  box-shadow: 0 18px 34px rgba(37, 99, 235, 0.36);
}

.btn-primary:hover {
  background: #1d4ed8;
}

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

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
}

.hero-tags span {
  padding: 8px 12px;
  color: #dbeafe;
  background: rgba(15, 23, 42, 0.38);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  font-size: 13px;
}

.hero-poster {
  position: relative;
  min-height: 458px;
}

.hero-poster-card {
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.45);
  transform: rotate(1.2deg);
}

.hero-poster-card img {
  height: 520px;
  object-fit: cover;
}

.hero-poster-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(2, 6, 23, 0.8), transparent 62%);
}

.hero-poster-info {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 22px;
  z-index: 2;
  padding: 18px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 22px;
  backdrop-filter: blur(14px);
}

.hero-poster-info strong {
  display: block;
  font-size: 21px;
  margin-bottom: 8px;
}

.hero-poster-info span {
  color: #bfdbfe;
  font-size: 14px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  background: rgba(255, 255, 255, 0.36);
  border-radius: 999px;
  cursor: pointer;
}

.hero-dot.is-active {
  width: 34px;
  background: #60a5fa;
}

.main-section {
  padding: 64px 0;
}

.main-section.alt {
  background: linear-gradient(135deg, #eff6ff 0%, #f8fafc 58%, #ecfeff 100%);
}

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

.section-heading h2,
.page-hero h1,
.detail-title h1 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.section-heading p,
.page-hero p {
  margin: 10px 0 0;
  color: #64748b;
  line-height: 1.8;
}

.section-more {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #2563eb;
  font-weight: 800;
}

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

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

.movie-card:hover {
  transform: translateY(-6px);
  border-color: #bfdbfe;
  box-shadow: 0 22px 50px rgba(37, 99, 235, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0f172a;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(2, 6, 23, 0.78), transparent 55%);
  pointer-events: none;
}

.quality-badge,
.year-badge {
  position: absolute;
  z-index: 2;
  padding: 6px 9px;
  color: #ffffff;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.quality-badge {
  left: 12px;
  top: 12px;
  background: #2563eb;
}

.year-badge {
  right: 12px;
  bottom: 12px;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(8px);
}

.movie-card-body {
  padding: 18px;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #64748b;
  font-size: 13px;
  margin-bottom: 8px;
}

.card-meta a {
  color: #2563eb;
  font-weight: 800;
}

.movie-card h3 {
  margin: 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: #2563eb;
}

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

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

.tag-row span {
  padding: 5px 8px;
  color: #334155;
  background: #f1f5f9;
  border-radius: 999px;
  font-size: 12px;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 212px;
  padding: 24px;
  color: #ffffff;
  background: linear-gradient(135deg, #1d4ed8, #0f172a);
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(30, 64, 175, 0.18);
}

.category-card::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -50px;
  width: 170px;
  height: 170px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
}

.category-card h3 {
  position: relative;
  z-index: 1;
  margin: 0 0 10px;
  font-size: 24px;
}

.category-card p,
.category-card span {
  position: relative;
  z-index: 1;
  color: #dbeafe;
  line-height: 1.75;
}

.category-card span {
  display: inline-flex;
  margin-top: 18px;
  font-weight: 800;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 42px 70px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  padding: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.rank-item:hover {
  transform: translateX(4px);
  border-color: #93c5fd;
}

.rank-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  color: #ffffff;
  background: #2563eb;
  border-radius: 999px;
  font-weight: 900;
}

.rank-item img {
  width: 70px;
  height: 96px;
  object-fit: cover;
  border-radius: 12px;
  background: #0f172a;
}

.rank-item strong {
  display: block;
  color: #0f172a;
  line-height: 1.4;
}

.rank-item em {
  display: block;
  margin-top: 6px;
  color: #64748b;
  font-style: normal;
  font-size: 13px;
}

.cta-band {
  padding: 72px 0;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #0f172a);
  text-align: center;
}

.cta-band h2 {
  margin: 0;
  font-size: clamp(30px, 4vw, 46px);
}

.cta-band p {
  max-width: 680px;
  margin: 16px auto 28px;
  color: #dbeafe;
  line-height: 1.8;
}

.page-hero {
  padding: 56px 0;
  color: #ffffff;
  background: radial-gradient(circle at 15% 20%, rgba(96, 165, 250, 0.42), transparent 30%), linear-gradient(135deg, #0f172a, #1e3a8a);
}

.page-hero h1,
.page-hero p {
  color: #ffffff;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: #dbeafe;
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #ffffff;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 170px 170px 170px;
  gap: 14px;
  margin-bottom: 26px;
  padding: 16px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  border-radius: 13px;
}

.empty-state {
  display: none;
  padding: 36px;
  color: #64748b;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  text-align: center;
}

.empty-state.is-visible {
  display: block;
}

.player-section {
  padding: 32px 0 56px;
  background: #020617;
}

.player-shell {
  position: relative;
  overflow: hidden;
  max-width: 1080px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  background: #000000;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 26px;
  box-shadow: 0 36px 90px rgba(0, 0, 0, 0.42);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #ffffff;
  background: linear-gradient(to top, rgba(2, 6, 23, 0.82), rgba(2, 6, 23, 0.36));
  border: 0;
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.play-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.play-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 82px;
  height: 82px;
  padding-left: 6px;
  color: #ffffff;
  background: #2563eb;
  border-radius: 999px;
  box-shadow: 0 24px 54px rgba(37, 99, 235, 0.42);
  font-size: 34px;
}

.play-overlay strong {
  font-size: 20px;
}

.detail-main {
  padding: 52px 0 70px;
}

.detail-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 34px;
}

.detail-poster {
  overflow: hidden;
  align-self: start;
  background: #0f172a;
  border-radius: 24px;
  box-shadow: 0 22px 54px rgba(15, 23, 42, 0.16);
}

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

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

.detail-title p {
  margin: 0;
  color: #475569;
  font-size: 18px;
  line-height: 1.8;
}

.info-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0;
}

.info-chips span,
.info-chips a {
  padding: 8px 12px;
  color: #1e3a8a;
  background: #dbeafe;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
}

.content-panel {
  margin-top: 24px;
  padding: 24px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 22px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.content-panel h2 {
  margin: 0 0 14px;
  color: #0f172a;
  font-size: 22px;
}

.content-panel p {
  margin: 0;
  color: #475569;
  line-height: 1.9;
}

.related-section {
  padding-top: 22px;
}

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(180deg, #0f172a, #020617);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 32px;
  padding: 48px 0;
}

.site-footer h2,
.site-footer h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.site-footer p,
.site-footer li {
  color: #cbd5e1;
  line-height: 1.8;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer a:hover {
  color: #60a5fa;
}

.footer-bottom {
  padding: 18px;
  color: #94a3b8;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

@media (max-width: 1040px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

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

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

  .hero-poster {
    min-height: auto;
  }

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

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

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

@media (max-width: 720px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .site-logo {
    font-size: 17px;
  }

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

  .hero-slide {
    padding: 52px 0 70px;
  }

  .hero-layout {
    gap: 34px;
  }

  .hero-poster-card img {
    height: 420px;
  }

  .section-heading {
    display: block;
  }

  .section-more {
    margin-top: 14px;
  }

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

  .main-section,
  .detail-main {
    padding: 42px 0;
  }

  .player-section {
    padding: 18px 0 34px;
  }

  .player-shell {
    border-radius: 16px;
  }

  .play-circle {
    width: 66px;
    height: 66px;
    font-size: 26px;
  }

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