:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-soft: #f1f5f9;
  --text: #111827;
  --muted: #64748b;
  --line: #e2e8f0;
  --brand: #0284c7;
  --brand-dark: #0369a1;
  --brand-soft: #e0f2fe;
  --accent: #f59e0b;
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

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

img {
  max-width: 100%;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(18px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), #06b6d4);
  box-shadow: 0 10px 24px rgba(2, 132, 199, 0.28);
}

.brand-name {
  font-size: 1.18rem;
}

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

.nav-link,
.mobile-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: #475569;
  font-size: 0.95rem;
  font-weight: 700;
  transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--brand-dark);
  background: var(--brand-soft);
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--surface-soft);
}

.mobile-menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  border-radius: 99px;
  background: #0f172a;
}

.mobile-nav {
  display: none;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto 12px;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

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

.hero-carousel {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  color: #ffffff;
  background: #020617;
}

.hero-slides,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 1.2s ease;
  pointer-events: none;
}

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

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

.hero-overlay,
.detail-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 30%, rgba(14, 165, 233, 0.42), transparent 34%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.72) 42%, rgba(2, 6, 23, 0.28) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.10), rgba(2, 6, 23, 0.88));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  min-height: 680px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 720px;
  padding: 96px 0 130px;
}

.hero-kicker,
.detail-kicker,
.page-hero span,
.section-heading span {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  color: #bae6fd;
  background: rgba(14, 165, 233, 0.18);
  border: 1px solid rgba(186, 230, 253, 0.3);
  font-size: 0.83rem;
  font-weight: 800;
}

.hero-content h1,
.detail-copy h1,
.page-hero h1 {
  margin: 20px 0 18px;
  font-size: clamp(2.6rem, 8vw, 6.2rem);
  line-height: 0.95;
  letter-spacing: -0.075em;
}

.hero-content p {
  max-width: 680px;
  margin: 0;
  color: #dbeafe;
  font-size: 1.1rem;
  line-height: 1.85;
}

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

.hero-tags,
.detail-tags {
  margin-top: 22px;
}

.hero-tags span,
.detail-tags span,
.tag-row span {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.20);
  color: #ffffff;
  padding: 6px 10px;
  font-size: 0.78rem;
  font-weight: 700;
}

.tag-row span {
  color: var(--brand-dark);
  background: var(--brand-soft);
  border-color: transparent;
}

.hero-actions,
.detail-copy .button {
  margin-top: 30px;
}

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

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

.button-primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), #06b6d4);
  box-shadow: 0 16px 36px rgba(2, 132, 199, 0.36);
}

.button-secondary {
  margin-left: 10px;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.32);
  background: rgba(255, 255, 255, 0.10);
  backdrop-filter: blur(12px);
}

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

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

.hero-dot.is-active {
  background: #ffffff;
}

.content-section,
.search-hero-panel {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 70px 0;
}

.search-hero-panel {
  margin-top: -70px;
  position: relative;
  z-index: 5;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow);
  padding: 34px;
}

.section-heading {
  margin-bottom: 26px;
}

.section-heading.is-centered {
  text-align: center;
}

.section-heading.is-centered span {
  margin: 0 auto;
}

.section-heading h2 {
  margin: 12px 0 0;
  font-size: clamp(1.7rem, 3vw, 2.5rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.section-heading p {
  color: var(--muted);
}

.section-heading.is-light,
.section-heading.is-light span {
  color: #ffffff;
}

.home-search,
.filter-bar {
  display: flex;
  gap: 14px;
}

.home-search {
  max-width: 760px;
  margin: 24px auto 0;
}

.home-search input,
.search-box input,
.select-box select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  outline: 0;
  background: #ffffff;
  padding: 14px 16px;
  color: var(--text);
  font: inherit;
}

.home-search button {
  border: 0;
  border-radius: 16px;
  background: var(--brand);
  color: #ffffff;
  padding: 0 24px;
  font-weight: 800;
}

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

.category-tile,
.category-overview-card,
.movie-card,
.ranking-panel,
.player-card,
.detail-article {
  background: var(--surface);
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: var(--radius);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.06);
}

.category-tile {
  display: block;
  padding: 24px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.movie-card:hover,
.category-overview-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.category-tile span {
  display: block;
  margin-bottom: 10px;
  color: var(--brand-dark);
  font-size: 1.12rem;
  font-weight: 900;
}

.category-tile p,
.category-overview-copy p,
.movie-card p,
.detail-article p {
  color: var(--muted);
  line-height: 1.75;
}

.two-column-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 26px;
  align-items: start;
}

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

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

.movie-card {
  overflow: hidden;
  transition: 0.2s ease;
}

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

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

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

.poster-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.72);
  font-size: 0.78rem;
  font-weight: 800;
}

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

.movie-card-meta {
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 800;
}

.movie-card h2 {
  margin: 8px 0;
  font-size: 1.08rem;
  line-height: 1.28;
  letter-spacing: -0.025em;
}

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

.movie-card.is-compact h2 {
  font-size: 1rem;
}

.movie-card.is-compact p {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tag-row {
  margin-top: 14px;
}

.ranking-panel {
  position: sticky;
  top: 94px;
  padding: 22px;
}

.rank-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.rank-item a {
  display: grid;
  grid-template-columns: 42px 58px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 16px;
  transition: background 0.2s ease;
}

.rank-item a:hover {
  background: var(--surface-soft);
}

.rank-number {
  color: var(--brand-dark);
  font-weight: 950;
  font-size: 1.05rem;
}

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

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

.rank-copy strong {
  line-height: 1.3;
}

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

.panel-link {
  display: block;
  margin-top: 18px;
  color: var(--brand-dark);
  font-weight: 800;
}

.highlight-band {
  width: 100%;
  max-width: none;
  padding: 74px max(16px, calc((100vw - 1240px) / 2));
  color: #ffffff;
  background:
    radial-gradient(circle at 82% 12%, rgba(14, 165, 233, 0.35), transparent 30%),
    linear-gradient(135deg, #0f172a, #082f49 55%, #155e75);
}

.page-main,
.detail-main {
  min-height: 70vh;
}

.page-hero {
  position: relative;
  width: min(1240px, calc(100% - 32px));
  margin: 34px auto 0;
  border-radius: 30px;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #0369a1);
  color: #ffffff;
  min-height: 300px;
  box-shadow: var(--shadow);
}

.simple-hero {
  display: grid;
  align-items: center;
  padding: 54px;
}

.simple-hero p,
.ranking-hero p {
  max-width: 760px;
  color: #dbeafe;
  font-size: 1.08rem;
  line-height: 1.8;
}

.ranking-hero {
  min-height: 390px;
}

.ranking-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ranking-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.38));
}

.ranking-hero div {
  position: relative;
  z-index: 2;
  padding: 56px;
}

.ranking-page-section {
  max-width: 920px;
}

.rank-list-large .rank-item a {
  grid-template-columns: 54px 82px minmax(0, 1fr);
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.05);
}

.rank-list-large .rank-item img {
  width: 82px;
  height: 110px;
}

.filter-bar {
  margin-bottom: 26px;
  padding: 16px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
}

.search-box,
.select-box {
  display: grid;
  gap: 7px;
  flex: 1;
}

.select-box {
  max-width: 210px;
}

.search-box span,
.select-box span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.category-overview-card {
  overflow: hidden;
  transition: 0.2s ease;
}

.category-thumb-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 150px;
  background: var(--surface-soft);
}

.category-thumb-row img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-overview-copy {
  padding: 22px;
}

.category-overview-copy span {
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 900;
}

.category-overview-copy h2 {
  margin: 8px 0 10px;
}

.detail-hero {
  position: relative;
  min-height: 660px;
  color: #ffffff;
  overflow: hidden;
  background: #020617;
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0 70px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  color: #cbd5e1;
  font-size: 0.9rem;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 42px;
  align-items: end;
  min-height: 520px;
}

.detail-poster {
  width: 310px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 26px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
}

.detail-copy h1 {
  max-width: 820px;
}

.detail-one-line {
  max-width: 780px;
  color: #dbeafe;
  font-size: 1.15rem;
  line-height: 1.8;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  gap: 26px;
  align-items: start;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000000;
  aspect-ratio: 16 / 9;
}

.video-shell video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.72));
  font-size: 1.08rem;
  font-weight: 900;
  cursor: pointer;
}

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

.play-symbol {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--brand), #06b6d4);
  box-shadow: 0 18px 44px rgba(14, 165, 233, 0.36);
}

.detail-article {
  padding: 28px;
}

.detail-article h2 {
  margin: 0 0 12px;
  font-size: 1.35rem;
}

.detail-article h2 + p {
  margin: 0 0 24px;
}

.detail-meta-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 0;
}

.detail-meta-list div {
  padding: 14px;
  border-radius: 16px;
  background: var(--surface-soft);
}

.detail-meta-list dt {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.detail-meta-list dd {
  margin: 6px 0 0;
  font-weight: 800;
}

.related-section {
  padding-top: 0;
}

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

.footer-inner {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0;
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr;
  gap: 28px;
}

.footer-brand p {
  max-width: 440px;
  color: #94a3b8;
  line-height: 1.8;
}

.footer-logo .brand-name,
.footer-column h2 {
  color: #ffffff;
}

.footer-column h2 {
  margin: 0 0 14px;
  font-size: 1.05rem;
}

.footer-column ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}

.footer-column a {
  color: #cbd5e1;
}

.footer-column a:hover {
  color: #38bdf8;
}

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  text-align: center;
  padding: 20px 16px;
  color: #94a3b8;
}

.is-hidden-by-filter {
  display: none !important;
}

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

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

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

  .ranking-panel {
    position: static;
  }
}

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

  .mobile-menu-button {
    display: block;
  }

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

  .hero-content h1,
  .detail-copy h1,
  .page-hero h1 {
    font-size: clamp(2.25rem, 15vw, 4rem);
  }

  .button-secondary {
    margin-left: 0;
    margin-top: 10px;
  }

  .hero-actions {
    display: grid;
    max-width: 260px;
  }

  .home-search,
  .filter-bar {
    flex-direction: column;
  }

  .select-box {
    max-width: none;
  }

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

  .simple-hero,
  .ranking-hero div {
    padding: 34px;
  }

  .detail-layout {
    grid-template-columns: 1fr;
    align-items: start;
    padding-top: 34px;
  }

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

  .footer-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .header-inner,
  .content-section,
  .search-hero-panel,
  .page-hero,
  .detail-hero-inner,
  .footer-inner {
    width: min(100% - 22px, 1240px);
  }

  .brand-name {
    font-size: 1rem;
  }

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

  .search-hero-panel {
    padding: 22px;
  }

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

  .rank-item a,
  .rank-list-large .rank-item a {
    grid-template-columns: 42px 58px minmax(0, 1fr);
  }

  .rank-list-large .rank-item img {
    width: 58px;
    height: 78px;
  }

  .detail-meta-list {
    grid-template-columns: 1fr;
  }
}
