:root {
  color-scheme: light;
  --bg: #f4f7fb;
  --panel: rgba(255, 255, 255, 0.88);
  --panel-solid: #ffffff;
  --text: #172033;
  --muted: #68758a;
  --line: rgba(92, 113, 145, 0.18);
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --accent: #7c3aed;
  --cyan: #06b6d4;
  --shadow: 0 20px 55px rgba(35, 51, 84, 0.13);
  --radius: 26px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.12), transparent 32rem),
    radial-gradient(circle at top right, rgba(124, 58, 237, 0.12), transparent 30rem),
    linear-gradient(135deg, #f8fbff 0%, #edf4ff 46%, #f7f2ff 100%);
  color: var(--text);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(22px);
  background: rgba(248, 251, 255, 0.76);
  border-bottom: 1px solid var(--line);
}

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

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.logo-mark {
  width: 42px;
  height: 42px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.28);
}

.logo-text {
  font-size: 1.16rem;
}

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

.nav-link {
  padding: 10px 16px;
  border-radius: 999px;
  color: #536179;
  font-weight: 700;
  transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--primary-dark);
  background: rgba(37, 99, 235, 0.1);
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel-solid);
  padding: 10px;
}

.menu-button span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--text);
  border-radius: 10px;
}

.hero {
  width: min(1240px, calc(100% - 32px));
  margin: 28px auto 0;
  min-height: 620px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 22px;
  align-items: stretch;
}

.hero-frame {
  position: relative;
  overflow: hidden;
  border-radius: 36px;
  box-shadow: var(--shadow);
  min-height: 620px;
  background: #101827;
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08) contrast(1.02);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(10, 16, 31, 0.9) 0%, rgba(10, 16, 31, 0.68) 43%, rgba(10, 16, 31, 0.2) 100%),
    linear-gradient(0deg, rgba(10, 16, 31, 0.58), transparent 55%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(650px, 92%);
  padding: clamp(36px, 7vw, 84px);
  color: #ffffff;
}

.eyebrow,
.section-heading span,
.page-hero span,
.hero-side-card span {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 7px 12px;
  border-radius: 999px;
  color: #1d4ed8;
  background: rgba(37, 99, 235, 0.1);
  font-size: 0.8rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-content .eyebrow {
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-content h1 {
  margin: 20px 0 18px;
  font-size: clamp(2.4rem, 6vw, 5.4rem);
  line-height: 0.96;
  letter-spacing: -0.08em;
}

.hero-content p {
  max-width: 620px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.06rem;
  line-height: 1.85;
}

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

.hero-tags span,
.tag-row span {
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.82rem;
  font-weight: 800;
}

.tag-row span {
  background: rgba(37, 99, 235, 0.08);
  color: #34507c;
}

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

.primary-button,
.secondary-button,
.rank-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 16px 34px rgba(37, 99, 235, 0.32);
}

.secondary-button {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.primary-button:hover,
.secondary-button:hover,
.rank-more:hover {
  transform: translateY(-2px);
}

.hero-dots {
  position: absolute;
  left: clamp(36px, 7vw, 84px);
  bottom: 34px;
  z-index: 3;
  display: flex;
  gap: 10px;
}

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

.hero-dots button.is-active {
  width: 62px;
  background: #ffffff;
}

.hero-side-card {
  border-radius: 34px;
  padding: 30px;
  color: #ffffff;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.22), transparent 16rem),
    linear-gradient(145deg, #2563eb, #7c3aed 70%, #0f172a);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 620px;
}

.hero-side-card span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
}

.hero-side-card h2 {
  margin: 20px 0 12px;
  font-size: 2.2rem;
  line-height: 1.08;
  letter-spacing: -0.06em;
}

.hero-side-card p {
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.75;
}

.hero-side-card a {
  margin-top: 24px;
  display: inline-flex;
  justify-content: center;
  padding: 14px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.16);
  font-weight: 900;
}

.section {
  margin-top: 42px;
}

.wrap-section,
.wide-panel {
  width: min(1200px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

.wide-panel {
  padding: 32px;
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.56);
  border: 1px solid var(--line);
  box-shadow: 0 18px 50px rgba(50, 67, 103, 0.08);
}

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

.section-heading h2,
.page-hero h1,
.content-card h2,
.info-card h2 {
  margin: 12px 0 0;
  font-size: clamp(1.55rem, 3vw, 2.4rem);
  letter-spacing: -0.05em;
  line-height: 1.12;
}

.split-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.split-heading > a {
  color: var(--primary-dark);
  font-weight: 900;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
  box-shadow: 0 12px 38px rgba(50, 67, 103, 0.08);
}

.search-box {
  display: grid;
  gap: 8px;
}

.search-box span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
}

.search-box input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 15px 16px;
  outline: none;
  background: #ffffff;
  color: var(--text);
}

.search-box input:focus {
  border-color: rgba(37, 99, 235, 0.55);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.quick-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.quick-filters button {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 14px;
  background: #ffffff;
  color: #45526a;
  font-weight: 900;
  cursor: pointer;
}

.quick-filters button:hover,
.quick-filters button.is-active {
  color: #ffffff;
  border-color: var(--primary);
  background: var(--primary);
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(92, 113, 145, 0.16);
  box-shadow: 0 16px 42px rgba(50, 67, 103, 0.09);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 55px rgba(37, 99, 235, 0.16);
  border-color: rgba(37, 99, 235, 0.32);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  background: linear-gradient(135deg, #dbeafe, #ede9fe);
  overflow: hidden;
}

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

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

.poster-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(10px);
  font-size: 0.82rem;
  font-weight: 900;
}

.card-body {
  padding: 17px;
}

.card-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.card-body h3 {
  min-height: 2.6em;
  margin: 10px 0 8px;
  font-size: 1.05rem;
  line-height: 1.3;
  letter-spacing: -0.03em;
}

.card-body p {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  min-height: 4.8em;
  overflow: hidden;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

.movie-card.compact .card-body p {
  -webkit-line-clamp: 2;
  min-height: 3.2em;
}

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

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

.category-card {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border-radius: 26px;
  display: flex;
  align-items: end;
  padding: 20px;
  color: #ffffff;
  background: #0f172a;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.18);
}

.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.category-card:hover img {
  opacity: 0.72;
  transform: scale(1.08);
}

.category-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.84), rgba(15, 23, 42, 0.1));
}

.category-card div {
  position: relative;
  z-index: 2;
}

.category-card span {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 0.8rem;
  font-weight: 900;
}

.category-card h3 {
  margin: 12px 0 8px;
  font-size: 1.4rem;
  letter-spacing: -0.04em;
}

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.6;
}

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

.rank-panel,
.info-card,
.content-card {
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 16px 42px rgba(50, 67, 103, 0.08);
}

.rank-item {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 52px;
  gap: 10px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.rank-number {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  font-weight: 900;
}

.rank-title {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 900;
}

.rank-year {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 900;
}

.rank-more {
  width: 100%;
  margin-top: 16px;
  color: #ffffff;
  background: var(--text);
}

.page-hero {
  width: min(1200px, calc(100% - 32px));
  margin: 28px auto 0;
  padding: clamp(42px, 8vw, 86px);
  border-radius: 34px;
  color: #ffffff;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.24), transparent 20rem),
    linear-gradient(135deg, #0f172a, #1d4ed8 50%, #7c3aed);
  box-shadow: var(--shadow);
}

.page-hero span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
}

.page-hero h1 {
  font-size: clamp(2.2rem, 5vw, 4.2rem);
}

.page-hero p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.8;
}

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

.sticky-rank {
  position: sticky;
  top: 98px;
  max-height: calc(100vh - 120px);
  overflow: auto;
}

.detail-hero {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  color: #ffffff;
  background: #0f172a;
}

.detail-bg {
  position: absolute;
  inset: 0;
}

.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.34;
  filter: blur(8px) saturate(1.1);
  transform: scale(1.04);
}

.detail-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.94), rgba(15, 23, 42, 0.56)),
    linear-gradient(0deg, #0f172a, transparent 45%);
}

.detail-content {
  position: relative;
  z-index: 2;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 560px;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
  padding: 56px 0;
}

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: rgba(255, 255, 255, 0.68);
  margin-bottom: 18px;
  font-size: 0.9rem;
}

.detail-info .eyebrow {
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.14);
}

.detail-info h1 {
  margin: 18px 0;
  font-size: clamp(2.4rem, 6vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.08em;
}

.detail-info p {
  max-width: 780px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.05rem;
  line-height: 1.85;
}

.detail-tags span {
  background: rgba(255, 255, 255, 0.14);
}

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

.detail-main {
  display: grid;
  gap: 24px;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  background: #000000;
  aspect-ratio: 16 / 9;
  box-shadow: 0 28px 75px rgba(15, 23, 42, 0.28);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  border: 0;
  color: #ffffff;
  background:
    radial-gradient(circle at center, rgba(37, 99, 235, 0.24), transparent 18rem),
    rgba(15, 23, 42, 0.42);
  display: grid;
  place-items: center;
  align-content: center;
  gap: 16px;
  cursor: pointer;
  z-index: 4;
}

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

.play-icon {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.42);
  position: relative;
}

.play-icon::after {
  content: "";
  position: absolute;
  left: 31px;
  top: 23px;
  border-left: 24px solid #ffffff;
  border-top: 16px solid transparent;
  border-bottom: 16px solid transparent;
}

.play-overlay strong {
  padding: 12px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(12px);
}

.content-card p {
  color: #4e5b70;
  line-height: 1.92;
  font-size: 1rem;
}

.detail-sidebar {
  display: grid;
  gap: 20px;
}

.info-card dl {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px;
  margin: 18px 0 0;
}

.info-card dt {
  color: var(--muted);
  font-weight: 900;
}

.info-card dd {
  margin: 0;
  min-width: 0;
  line-height: 1.6;
}

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

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

.related-list .poster-link {
  aspect-ratio: 2 / 3;
}

.related-list .card-body {
  padding: 12px;
}

.related-list .card-body h3 {
  min-height: auto;
  font-size: 0.98rem;
}

.related-list .card-body p,
.related-list .tag-row {
  display: none;
}

.site-footer {
  margin-top: 56px;
  padding: 46px 0;
  color: rgba(255, 255, 255, 0.78);
  background: #0f172a;
}

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 420px);
  gap: 28px;
}

.footer-logo {
  color: #ffffff;
  font-size: 1.3rem;
  font-weight: 900;
}

.footer-inner p {
  max-width: 620px;
  line-height: 1.8;
}

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

.footer-links a {
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-weight: 800;
}

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

@media (max-width: 1100px) {
  .hero,
  .two-column-section,
  .ranking-layout,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .hero-side-card {
    min-height: 260px;
  }

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

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

  .sticky-rank {
    position: static;
    max-height: none;
  }
}

@media (max-width: 760px) {
  .header-inner {
    height: 66px;
  }

  .menu-button {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 68px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .nav-link {
    border-radius: 14px;
  }

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

  .hero {
    grid-template-columns: 1fr;
    width: min(100% - 20px, 1240px);
    margin-top: 16px;
  }

  .hero-frame,
  .hero-side-card,
  .page-hero {
    border-radius: 26px;
  }

  .hero-content {
    padding: 34px 24px 76px;
  }

  .hero-content h1,
  .detail-info h1 {
    letter-spacing: -0.06em;
  }

  .hero-dots {
    left: 24px;
    bottom: 26px;
  }

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

  .quick-filters {
    justify-content: flex-start;
  }

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

  .card-body {
    padding: 13px;
  }

  .card-body h3 {
    font-size: 0.98rem;
  }

  .card-body p,
  .tag-row {
    display: none;
  }

  .split-heading {
    align-items: start;
    flex-direction: column;
  }

  .detail-content {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .detail-poster {
    width: min(240px, 72vw);
  }

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

@media (max-width: 440px) {
  .movie-grid,
  .small-grid,
  .category-movie-grid,
  .category-grid,
  .large-category-grid {
    grid-template-columns: 1fr;
  }
}
