:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --cyan: #06b6d4;
  --emerald: #10b981;
  --slate: #0f172a;
  --radius: 22px;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, #0f172a 0%, #1e3a8a 50%, #0f172a 100%);
  color: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.28);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 28px;
}

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

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  color: #dbeafe;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 10px 30px rgba(37, 99, 235, 0.35);
  font-size: 16px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
}

.main-nav a,
.nav-dropdown > button {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.82);
  cursor: pointer;
  transition: color 0.2s ease;
}

.main-nav a:hover,
.nav-dropdown > button:hover,
.main-nav a.active {
  color: #ffffff;
}

.nav-dropdown {
  position: relative;
}

.dropdown-panel {
  position: absolute;
  top: calc(100% + 16px);
  left: 50%;
  width: 180px;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--ink);
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, -8px);
  transition: 0.2s ease;
}

.dropdown-panel a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: #334155;
}

.dropdown-panel a:hover {
  background: #eff6ff;
  color: var(--blue);
}

.nav-dropdown:hover .dropdown-panel {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.header-search {
  position: relative;
  display: flex;
  align-items: center;
  width: 280px;
  margin-left: 8px;
}

.header-search input,
.mobile-panel input,
.wide-search input,
.filter-search input {
  width: 100%;
  border: 1px solid transparent;
  outline: none;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.78);
  color: #ffffff;
  padding: 12px 92px 12px 18px;
}

.header-search input::placeholder,
.mobile-panel input::placeholder,
.wide-search input::placeholder,
.filter-search input::placeholder {
  color: rgba(255, 255, 255, 0.58);
}

.header-search button,
.mobile-panel form button,
.wide-search button,
.filter-search button {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  padding: 8px 16px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  cursor: pointer;
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  background: transparent;
  color: #ffffff;
  font-size: 26px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
}

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

.mobile-panel form {
  position: relative;
  margin-bottom: 14px;
}

.mobile-panel nav {
  display: grid;
  gap: 8px;
}

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

.hero {
  position: relative;
  height: 640px;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 48%, #164e63 100%);
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  opacity: 0.22;
}

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

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 160px;
  background: linear-gradient(0deg, var(--bg), rgba(248, 250, 252, 0));
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  align-items: center;
  gap: 54px;
}

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

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--blue);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 13px;
}

.hero-kicker {
  color: #7dd3fc;
  margin-bottom: 14px;
}

.hero h1 {
  margin: 0 0 14px;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.06em;
}

.hero h2 {
  margin: 0 0 16px;
  font-size: clamp(24px, 3vw, 42px);
  color: #67e8f9;
}

.hero p {
  margin: 0 0 26px;
  max-width: 680px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 20px;
}

.hero-tags .pill {
  background: rgba(255, 255, 255, 0.12);
  color: #e0f2fe;
  border-color: rgba(255, 255, 255, 0.16);
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

.primary-button,
.ghost-button,
.small-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  font-weight: 800;
  transition: 0.22s ease;
}

.primary-button {
  padding: 12px 28px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 14px 35px rgba(37, 99, 235, 0.35);
}

.primary-button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 18px 45px rgba(37, 99, 235, 0.45);
}

.ghost-button {
  padding: 11px 24px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

.ghost-button:hover {
  background: rgba(255, 255, 255, 0.22);
}

.small-button {
  padding: 8px 16px;
  color: #ffffff;
  background: var(--blue);
  font-size: 14px;
}

.hero-poster {
  display: block;
  width: 100%;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.36);
  transform: rotate(2deg);
  transition: 0.3s ease;
}

.hero-poster:hover {
  transform: rotate(0deg) translateY(-4px);
}

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

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

.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;
}

.section-block,
.quick-filter,
.filter-panel {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.section-block {
  padding: 72px 0;
}

.quick-filter {
  position: relative;
  z-index: 5;
  margin-top: -54px;
  padding: 26px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

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

.section-head.compact {
  margin-bottom: 20px;
}

.section-head h2 {
  margin: 6px 0 0;
  font-size: clamp(26px, 3vw, 38px);
  letter-spacing: -0.04em;
}

.section-head.light h2,
.section-head.light .section-kicker {
  color: #ffffff;
}

.section-link {
  color: var(--blue);
  font-weight: 800;
}

.wide-search {
  position: relative;
  max-width: 780px;
}

.wide-search input {
  min-height: 58px;
  background: #0f172a;
  padding-right: 112px;
}

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

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

.movie-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #dbe4ef;
}

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

.movie-card:hover .poster-wrap img {
  transform: scale(1.08);
}

.poster-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.56), rgba(15, 23, 42, 0.02));
}

.poster-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.72);
  font-size: 12px;
  font-weight: 700;
}

.movie-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  padding: 18px;
}

.card-meta {
  color: var(--blue);
  font-size: 13px;
  font-weight: 800;
}

.movie-card h3,
.rank-info h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
}

.movie-card h3 a:hover,
.rank-info h3 a:hover,
.category-overview-card h2 a:hover {
  color: var(--blue);
}

.movie-card p,
.rank-info p,
.category-tile em,
.category-overview-card p {
  margin: 0;
  color: var(--muted);
}

.movie-card p {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  min-height: 50px;
}

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

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 10px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  color: #1d4ed8;
  background: #eff6ff;
  font-size: 12px;
  font-weight: 700;
}

.category-band {
  padding: 72px 0;
  background: linear-gradient(90deg, #0f172a, #1e3a8a, #0e7490);
}

.category-band > * {
  width: min(1180px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

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

.category-tile {
  display: flex;
  min-height: 170px;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
  padding: 24px;
  border-radius: 24px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(16px);
  transition: 0.22s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.18);
}

.category-tile span {
  color: #93c5fd;
  font-weight: 800;
}

.category-tile strong {
  font-size: 24px;
}

.category-tile em {
  color: rgba(255, 255, 255, 0.74);
  font-style: normal;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr);
  gap: 34px;
}

.horizontal-scroll {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 310px;
  gap: 20px;
  overflow-x: auto;
  padding: 2px 2px 18px;
  scrollbar-width: thin;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 54px 96px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.07);
}

.rank-num {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 15px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  font-weight: 900;
}

.rank-thumb {
  display: block;
  overflow: hidden;
  border-radius: 14px;
  aspect-ratio: 16 / 10;
  background: #dbe4ef;
}

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

.rank-info p {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.page-hero {
  min-height: 330px;
  display: grid;
  align-items: center;
  background: radial-gradient(circle at top left, rgba(14, 165, 233, 0.34), transparent 32%), linear-gradient(135deg, #0f172a, #1e3a8a 52%, #164e63);
  color: #ffffff;
}

.page-hero > div {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 64px 0;
}

.page-hero h1 {
  max-width: 860px;
  margin: 8px 0 14px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 19px;
}

.crumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

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

.filter-panel {
  margin-top: -36px;
  padding: 22px;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.filter-search {
  position: relative;
  margin-bottom: 18px;
}

.filter-search input {
  min-height: 54px;
  color: #ffffff;
  background: #0f172a;
}

.filter-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding-top: 12px;
}

.filter-row span {
  color: var(--muted);
  font-weight: 800;
  margin-right: 6px;
}

.filter-row button {
  border: 0;
  padding: 8px 13px;
  border-radius: 999px;
  color: #334155;
  background: #f1f5f9;
  cursor: pointer;
}

.filter-row button.is-active,
.filter-row button:hover {
  color: #ffffff;
  background: var(--blue);
}

.category-overview-grid {
  display: grid;
  gap: 22px;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 26px;
  align-items: center;
  padding: 22px;
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.category-collage {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  overflow: hidden;
  border-radius: 22px;
}

.category-collage img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.category-overview-card h2 {
  margin: 6px 0 8px;
  font-size: 30px;
}

.category-overview-card .small-button {
  margin-top: 18px;
}

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

.detail-backdrop {
  position: absolute;
  inset: 0;
  opacity: 0.24;
}

.detail-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(3px);
  transform: scale(1.04);
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.98), rgba(15, 23, 42, 0.75), rgba(15, 23, 42, 0.44));
}

.detail-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 74px 0;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 48px;
  align-items: center;
}

.detail-poster {
  display: block;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.42);
}

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

.detail-copy h1 {
  margin: 16px 0;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.detail-one-line {
  max-width: 760px;
  margin: 0 0 20px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 20px;
}

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

.detail-meta span {
  padding: 7px 12px;
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.12);
}

.detail-copy .primary-button {
  margin-top: 26px;
}

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

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

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.55), rgba(2, 6, 23, 0.12));
  cursor: pointer;
  transition: 0.22s ease;
}

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

.play-circle {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 18px 45px rgba(37, 99, 235, 0.42);
  font-size: 30px;
}

.player-overlay strong {
  font-size: 24px;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.45);
}

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

.article-panel,
.side-panel {
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.article-panel {
  padding: 34px;
}

.article-panel h2,
.side-panel h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.article-panel p {
  margin: 0 0 28px;
  color: #334155;
  font-size: 17px;
}

.article-panel p:last-child {
  margin-bottom: 0;
}

.side-panel {
  padding: 26px;
}

.side-panel dl {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  gap: 12px 16px;
  margin: 0 0 24px;
}

.side-panel dt {
  color: var(--muted);
  font-weight: 800;
}

.side-panel dd {
  margin: 0;
  color: #334155;
}

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

.search-page-form {
  margin-top: -48px;
}

[data-card].is-hidden {
  display: none;
}

[data-search-results]:empty::before {
  content: "请输入关键词开始搜索";
  display: block;
  padding: 30px;
  border-radius: 24px;
  color: var(--muted);
  background: #ffffff;
}

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

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

  .menu-toggle {
    display: block;
  }

  .hero {
    height: auto;
    min-height: 720px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 72px 0 120px;
  }

  .hero-poster {
    max-width: 320px;
    transform: none;
  }

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

  .two-column,
  .detail-content,
  .detail-inner,
  .category-overview-card {
    grid-template-columns: 1fr;
  }

  .category-collage {
    max-width: 420px;
  }

  .rank-item {
    grid-template-columns: 44px 82px minmax(0, 1fr);
  }

  .rank-item .small-button {
    grid-column: 2 / -1;
    justify-self: start;
  }
}

@media (max-width: 640px) {
  .header-inner {
    width: min(100% - 24px, 1180px);
  }

  .brand {
    font-size: 20px;
  }

  .hero h1 {
    font-size: 38px;
  }

  .hero p,
  .detail-one-line,
  .page-hero p {
    font-size: 16px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .primary-button,
  .ghost-button {
    width: 100%;
  }

  .movie-grid,
  .movie-grid.wide,
  .category-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .quick-filter,
  .filter-panel {
    padding: 18px;
  }

  .section-block {
    padding: 48px 0;
  }

  .rank-item {
    grid-template-columns: 40px 76px minmax(0, 1fr);
    gap: 12px;
    padding: 12px;
  }

  .rank-info p {
    display: none;
  }

  .detail-inner {
    padding: 46px 0;
  }

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

  .article-panel,
  .side-panel {
    padding: 22px;
  }
}
