:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --cyan: #06b6d4;
  --purple: #7c3aed;
  --gold: #f59e0b;
  --shadow: 0 22px 55px rgba(15, 23, 42, 0.14);
  --soft-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: radial-gradient(circle at top left, rgba(37, 99, 235, 0.12), transparent 34rem), var(--bg);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

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

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

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #ffffff;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  box-shadow: 0 14px 24px rgba(37, 99, 235, 0.26);
}

.brand-text {
  font-size: 21px;
}

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

.desktop-nav a,
.mobile-nav a,
.footer-links a {
  padding: 9px 14px;
  color: #334155;
  border-radius: 999px;
  font-weight: 700;
  transition: color 0.22s ease, background 0.22s ease, transform 0.22s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.mobile-nav a.active,
.footer-links a:hover {
  color: var(--blue);
  background: #eff6ff;
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  color: var(--text);
  border-radius: 14px;
  background: #eef2ff;
  font-size: 22px;
}

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

main,
.page-main,
.detail-main {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
}

.hero-section {
  position: relative;
  margin-top: 26px;
  overflow: hidden;
  color: #ffffff;
  border-radius: 34px;
  background: linear-gradient(135deg, #0f172a, #1d4ed8 56%, #7c3aed);
  box-shadow: var(--shadow);
}

.hero-slider {
  position: relative;
  min-height: 620px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 38px;
  align-items: center;
  padding: 72px 56px 188px;
  opacity: 0;
  transform: scale(1.02);
  pointer-events: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-backdrop {
  position: absolute;
  inset: 0;
  z-index: -2;
  background-image: linear-gradient(90deg, rgba(15, 23, 42, 0.94), rgba(30, 64, 175, 0.72), rgba(124, 58, 237, 0.3)), var(--hero-image);
  background-size: cover;
  background-position: center;
  filter: saturate(1.08);
}

.hero-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(circle at 15% 20%, rgba(56, 189, 248, 0.28), transparent 18rem), radial-gradient(circle at 82% 30%, rgba(245, 158, 11, 0.22), transparent 17rem);
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 7px 12px;
  color: #e0f2fe;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(34px, 6vw, 68px);
  line-height: 1.04;
  letter-spacing: -0.06em;
}

.hero-copy h2 {
  margin: 22px 0 12px;
  font-size: clamp(25px, 4vw, 42px);
  line-height: 1.1;
}

.hero-copy p,
.page-hero p,
.detail-line {
  margin: 0;
  max-width: 720px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 17px;
}

.hero-tags,
.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.hero-tags span,
.card-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

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

.primary-button,
.ghost-button,
.panel-link,
.wide-search button,
.hero-search button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border: 0;
  border-radius: 14px;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.primary-button,
.wide-search button,
.hero-search button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 16px 28px rgba(37, 99, 235, 0.28);
}

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

.primary-button:hover,
.ghost-button:hover,
.panel-link:hover,
.hero-search button:hover,
.wide-search button:hover {
  transform: translateY(-2px);
}

.hero-poster {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 32px 70px rgba(0, 0, 0, 0.38);
}

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

.hero-poster span {
  position: absolute;
  right: 16px;
  bottom: 16px;
  padding: 8px 12px;
  color: #fff7ed;
  background: rgba(15, 23, 42, 0.82);
  border-radius: 999px;
  font-weight: 900;
}

.hero-panel {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 28px;
  display: grid;
  grid-template-columns: minmax(260px, 420px) minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 18px;
  background: rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  backdrop-filter: blur(18px);
}

.hero-search,
.wide-search {
  display: flex;
  gap: 10px;
}

.hero-search input,
.wide-search input,
.filter-form input,
.filter-form select {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  color: #0f172a;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 14px;
  outline: none;
}

.hero-quick-links,
.hero-thumbs,
.hero-dots {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-quick-links {
  flex-wrap: wrap;
}

.hero-quick-links a {
  padding: 8px 10px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.hero-thumbs {
  display: none;
}

.hero-thumb {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 150px;
  color: #ffffff;
}

.hero-thumb img {
  width: 44px;
  height: 58px;
  border-radius: 10px;
  object-fit: cover;
}

.hero-thumb span {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 13px;
  font-weight: 800;
}

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

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

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

.no-top-space {
  padding-top: 24px;
}

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

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

.section-heading p {
  margin: 7px 0 0;
  color: var(--muted);
}

.section-more,
.panel-link {
  color: var(--blue);
  font-weight: 900;
}

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

.movie-card {
  overflow: hidden;
  background: var(--panel);
  border: 1px solid rgba(226, 232, 240, 0.88);
  border-radius: 22px;
  box-shadow: var(--soft-shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(37, 99, 235, 0.34);
  box-shadow: 0 22px 44px rgba(15, 23, 42, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #dbeafe;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.45s ease;
}

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

.type-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 5px 9px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.78);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.rank-badge {
  left: auto;
  right: 12px;
  background: linear-gradient(135deg, var(--gold), #ef4444);
}

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

.movie-card-body h3 {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.35;
}

.movie-card-body h3 a {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-card-body p {
  display: -webkit-box;
  min-height: 42px;
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-tags {
  margin-top: 12px;
}

.card-tags span {
  color: #2563eb;
  background: #eff6ff;
  border-color: #dbeafe;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 12px;
  color: #64748b;
  font-size: 12px;
}

.card-meta strong {
  color: #f59e0b;
}

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

.ranking-panel,
.story-card,
.info-card,
.filter-section,
.category-overview-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: 24px;
  box-shadow: var(--soft-shadow);
}

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

.ranking-panel h2 {
  margin: 0 0 16px;
}

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

.ranking-list a {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border-radius: 16px;
  background: #f8fafc;
}

.ranking-list span {
  color: var(--blue);
  font-weight: 900;
}

.ranking-list strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ranking-list em {
  color: var(--gold);
  font-style: normal;
  font-weight: 900;
}

.panel-link {
  width: 100%;
  margin-top: 16px;
  background: #eff6ff;
}

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

.category-tile {
  padding: 22px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--soft-shadow);
}

.category-main {
  display: grid;
  gap: 8px;
}

.category-main strong,
.category-overview-head h2 {
  font-size: 22px;
  letter-spacing: -0.03em;
}

.category-main span,
.category-overview-head p {
  color: var(--muted);
}

.category-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.category-samples a {
  padding: 6px 10px;
  color: var(--blue);
  background: #eff6ff;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.page-hero {
  margin-top: 26px;
  padding: 56px;
  color: #ffffff;
  background: linear-gradient(135deg, #0f172a, #2563eb 54%, #7c3aed);
  border-radius: 32px;
  box-shadow: var(--shadow);
}

.slim-hero,
.search-hero,
.category-hero {
  overflow: hidden;
  position: relative;
}

.slim-hero::after,
.search-hero::after,
.category-hero::after {
  content: "";
  position: absolute;
  right: -80px;
  top: -80px;
  width: 280px;
  height: 280px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.filter-section {
  margin-top: 24px;
  padding: 18px;
}

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

.filter-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.category-overview-grid {
  margin-top: 28px;
}

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

.category-overview-head h2 {
  margin: 0 0 7px;
}

.small-card-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.small-card {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px;
  background: #f8fafc;
  border-radius: 16px;
}

.small-card img {
  width: 54px;
  height: 72px;
  object-fit: cover;
  border-radius: 12px;
}

.small-card strong,
.small-card em {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.small-card em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.wide-search {
  max-width: 720px;
  margin-top: 26px;
}

.detail-main {
  padding-top: 26px;
}

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

.breadcrumb a {
  color: var(--blue);
  font-weight: 800;
}

.detail-hero {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
  margin-top: 18px;
  padding: 34px;
  color: #ffffff;
  background: linear-gradient(135deg, #0f172a, #1d4ed8, #7c3aed);
  border-radius: 32px;
  box-shadow: var(--shadow);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 26px;
  box-shadow: 0 24px 52px rgba(0, 0, 0, 0.36);
}

.detail-score {
  display: inline-grid;
  grid-template-columns: auto auto auto;
  gap: 10px;
  align-items: baseline;
  margin-top: 22px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
}

.detail-score strong {
  color: #fde68a;
  font-size: 28px;
}

.detail-score span,
.detail-score em {
  color: rgba(255, 255, 255, 0.82);
  font-style: normal;
}

.player-section {
  padding-top: 46px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  background: #020617;
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.player-video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  gap: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.78), rgba(37, 99, 235, 0.42));
  border: 0;
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  padding-left: 4px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.4);
  font-size: 28px;
}

.play-title {
  font-size: 18px;
  font-weight: 900;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 310px;
  gap: 22px;
  padding-top: 34px;
}

.story-card,
.info-card {
  padding: 24px;
}

.story-card h2,
.info-card h2 {
  margin: 0 0 14px;
}

.story-card p {
  margin: 0;
  color: #334155;
}

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

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

.info-card dd {
  margin: 0;
  color: #0f172a;
}

.site-footer {
  margin-top: 74px;
  padding: 38px 0;
  color: #dbeafe;
  background: #0f172a;
}

.footer-inner {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.footer-inner p {
  margin: 0;
  color: #94a3b8;
}

.footer-links a {
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.08);
}

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

  .hero-slide,
  .detail-hero,
  .split-layout,
  .detail-content {
    grid-template-columns: 1fr;
  }

  .hero-poster {
    max-width: 260px;
  }

  .hero-panel,
  .filter-form,
  .category-grid,
  .category-overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ranking-panel {
    position: static;
  }
}

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

  .menu-button {
    display: inline-grid;
    place-items: center;
  }

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

  .brand-text {
    font-size: 18px;
  }

  .hero-section,
  .page-hero,
  .detail-hero {
    border-radius: 24px;
  }

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

  .hero-slide {
    padding: 42px 24px 310px;
  }

  .hero-panel {
    left: 14px;
    right: 14px;
    bottom: 14px;
    grid-template-columns: 1fr;
  }

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

  .page-hero,
  .detail-hero {
    padding: 30px 22px;
  }

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

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

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

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

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

@media (max-width: 460px) {
  main,
  .page-main,
  .detail-main,
  .header-inner,
  .mobile-nav,
  .footer-inner {
    width: min(100% - 22px, 1220px);
  }

  .movie-grid {
    gap: 12px;
  }

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

  .movie-card-body h3 {
    font-size: 14px;
  }

  .card-tags {
    display: none;
  }
}
