:root {
  color-scheme: light;
  --bg: #f8fbff;
  --surface: #ffffff;
  --surface-soft: #f1f5f9;
  --text: #0f172a;
  --muted: #64748b;
  --line: #dbeafe;
  --primary: #2563eb;
  --primary-dark: #1e3a8a;
  --cyan: #06b6d4;
  --shadow: 0 22px 60px rgba(15, 23, 42, 0.12);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 46%, #f8fafc 100%);
  color: var(--text);
  min-height: 100vh;
}

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

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  color: #ffffff;
  background: linear-gradient(90deg, #0f172a 0%, #1e3a8a 52%, #0f172a 100%);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.22);
}

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

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 210px;
}

.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 24px;
  font-weight: 800;
  background: linear-gradient(135deg, #60a5fa, #22d3ee);
  box-shadow: 0 12px 28px rgba(34, 211, 238, 0.35);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-copy strong {
  font-size: 20px;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, #bfdbfe, #67e8f9);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-copy small {
  color: #bfdbfe;
  font-size: 12px;
  margin-top: 3px;
}

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

.nav-link {
  font-weight: 700;
  color: #e0f2fe;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #67e8f9;
  transform: translateY(-1px);
}

.top-search,
.mobile-search,
.wide-search {
  display: flex;
  align-items: center;
}

.top-search {
  position: relative;
  width: 260px;
}

.top-search input,
.mobile-search input,
.wide-search input,
.local-search {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.4);
  outline: 0;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.54);
  color: #ffffff;
  padding: 12px 48px 12px 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.top-search input:focus,
.mobile-search input:focus,
.wide-search input:focus,
.local-search:focus {
  border-color: #22d3ee;
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.15);
}

.top-search button {
  position: absolute;
  right: 7px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 10px;
  background: #0ea5e9;
  color: #ffffff;
  cursor: pointer;
  font-size: 18px;
}

.menu-toggle {
  display: none;
  border: 0;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.45);
  width: 44px;
  height: 44px;
  border-radius: 12px;
  font-size: 22px;
}

.mobile-panel {
  display: none;
  padding: 16px;
  background: #0f172a;
  border-top: 1px solid #334155;
}

.mobile-panel.is-open {
  display: grid;
  gap: 12px;
}

.mobile-panel a {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(30, 41, 59, 0.82);
}

.mobile-search {
  gap: 8px;
}

.mobile-search input {
  background: #1e293b;
}

.mobile-search button,
.wide-search button {
  border: 0;
  border-radius: 12px;
  padding: 12px 18px;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}

main {
  padding-top: 72px;
}

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

.hero-track {
  position: relative;
  min-height: 680px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  background-size: cover;
  background-position: center;
  transition: opacity 0.65s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.hero-content {
  width: min(760px, calc(100% - 32px));
  margin-left: max(24px, calc((100vw - 1280px) / 2));
  color: #ffffff;
  padding: 64px 0;
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  color: #67e8f9;
  background: rgba(14, 165, 233, 0.14);
  border: 1px solid rgba(34, 211, 238, 0.24);
  font-weight: 800;
  letter-spacing: 0.02em;
}

.hero-content h1 {
  margin: 22px 0 18px;
  font-size: clamp(42px, 8vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.hero-content p {
  max-width: 680px;
  color: #dbeafe;
  font-size: clamp(18px, 2.2vw, 24px);
  line-height: 1.7;
}

.hero-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.hero-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  border-radius: 12px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
  font-weight: 700;
}

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

.primary-btn,
.ghost-btn,
.small-btn,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn,
.small-btn {
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  box-shadow: 0 14px 34px rgba(37, 99, 235, 0.28);
}

.primary-btn {
  padding: 15px 24px;
}

.ghost-btn {
  padding: 15px 24px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

.primary-btn:hover,
.ghost-btn:hover,
.small-btn:hover,
.text-link:hover {
  transform: translateY(-2px);
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  border: 0;
  background: rgba(255, 255, 255, 0.48);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.active {
  width: 34px;
  background: #22d3ee;
}

.quick-search-panel,
.content-section,
.page-shell {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
}

.quick-search-panel {
  margin-top: -52px;
  position: relative;
  z-index: 2;
}

.quick-search-inner {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 520px);
  gap: 24px;
  align-items: center;
  padding: 28px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.quick-search-inner h2 {
  margin: 0 0 8px;
  font-size: 28px;
}

.quick-search-inner p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.wide-search {
  gap: 10px;
}

.wide-search input,
.local-search {
  background: #ffffff;
  color: var(--text);
}

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

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

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

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

.section-more,
.text-link {
  color: #2563eb;
  font-weight: 900;
}

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

.category-card,
.category-overview-card {
  background: var(--surface);
  border: 1px solid rgba(191, 219, 254, 0.8);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}

.category-card div {
  padding: 16px;
}

.category-card h3,
.category-overview-card h2,
.movie-card h3 {
  margin: 0;
}

.category-card p,
.category-overview-card p,
.card-line,
.card-meta {
  color: var(--muted);
  line-height: 1.7;
}

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

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

.movie-card {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  border: 1px solid rgba(226, 232, 240, 0.92);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

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

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

.card-year,
.card-play {
  position: absolute;
  z-index: 2;
}

.card-year {
  top: 10px;
  right: 10px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.78);
  font-size: 12px;
  font-weight: 900;
}

.card-play {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #2563eb;
  background: rgba(255, 255, 255, 0.9);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .card-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

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

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

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

.card-meta {
  margin: 7px 0;
  font-size: 13px;
}

.card-line {
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 14px;
}

.card-tags,
.detail-tags,
.category-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.card-tags span,
.detail-tags span,
.category-chips span {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 999px;
  color: #1d4ed8;
  background: #dbeafe;
  font-size: 12px;
  font-weight: 800;
}

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

.ranking-card {
  position: sticky;
  top: 94px;
  padding: 22px;
  border-radius: 24px;
  background: #0f172a;
  color: #ffffff;
  box-shadow: var(--shadow);
}

.ranking-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.ranking-head h2 {
  margin: 0;
}

.ranking-head a {
  color: #67e8f9;
  font-weight: 800;
}

.rank-item {
  display: grid;
  grid-template-columns: 42px 58px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
}

.rank-num {
  color: #67e8f9;
  font-size: 18px;
  font-weight: 900;
}

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

.rank-copy {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.rank-copy strong,
.rank-copy em {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-copy em {
  color: #cbd5e1;
  font-style: normal;
  font-size: 13px;
}

.page-shell {
  padding-top: 112px;
  padding-bottom: 72px;
}

.page-hero {
  border-radius: 28px;
  color: #ffffff;
  background: radial-gradient(circle at 20% 20%, rgba(34, 211, 238, 0.35), transparent 32%), linear-gradient(135deg, #0f172a, #1e3a8a 62%, #0f172a);
  padding: clamp(36px, 6vw, 72px);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.small-hero {
  margin-bottom: 30px;
}

.category-hero {
  margin-bottom: 24px;
}

.page-hero span {
  color: #67e8f9;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.page-hero h1 {
  margin: 12px 0 10px;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.05;
}

.page-hero p {
  margin: 0;
  max-width: 820px;
  color: #dbeafe;
  line-height: 1.8;
  font-size: 18px;
}

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

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

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

.category-overview-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 24px;
  padding: 18px;
}

.category-overview-cover {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 16px;
}

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

.category-overview-card h2 {
  font-size: 26px;
}

.filter-panel,
.search-strip {
  padding: 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(191, 219, 254, 0.8);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.06);
  margin-bottom: 28px;
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
}

.filter-group strong {
  margin-right: 6px;
}

.filter-group button {
  border: 0;
  border-radius: 999px;
  padding: 8px 13px;
  color: #1e3a8a;
  background: #dbeafe;
  font-weight: 800;
  cursor: pointer;
}

.filter-group button.active {
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}

.large-search-strip {
  padding: 24px;
}

.local-search {
  color: var(--text);
  background: #ffffff;
  padding: 16px 18px;
  font-size: 18px;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 14px;
}

.ranking-cover {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: #0f172a;
}

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

.ranking-cover span {
  position: absolute;
  left: 8px;
  top: 8px;
  z-index: 1;
  padding: 5px 8px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.84);
  font-weight: 900;
}

.ranking-row-body h2 {
  margin: 0;
  font-size: 24px;
}

.ranking-row-body p {
  margin: 8px 0;
  color: var(--muted);
  line-height: 1.75;
}

.small-btn {
  padding: 10px 15px;
  border: 0;
  cursor: pointer;
}

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

.detail-main {
  min-width: 0;
}

.player-card,
.detail-copy,
.poster-panel,
.side-list {
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--shadow);
  border: 1px solid rgba(226, 232, 240, 0.92);
  overflow: hidden;
}

.player-stage {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.player-stage video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  cursor: pointer;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.1), rgba(2, 6, 23, 0.42));
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-overlay span {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #2563eb;
  background: rgba(255, 255, 255, 0.92);
  font-size: 34px;
  box-shadow: 0 18px 40px rgba(2, 6, 23, 0.28);
}

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

.detail-copy {
  margin-top: 24px;
  padding: clamp(22px, 4vw, 34px);
}

.detail-title-row {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
}

.detail-copy h1 {
  margin: 14px 0 0;
  font-size: clamp(30px, 5vw, 52px);
  line-height: 1.1;
}

.detail-copy h2 {
  margin: 28px 0 10px;
  font-size: 24px;
}

.detail-copy p {
  color: #334155;
  line-height: 1.9;
  font-size: 16px;
}

.detail-copy .lead-text {
  color: #1e3a8a;
  font-weight: 800;
  font-size: 18px;
}

.detail-meta span {
  background: #eff6ff;
  color: #1e40af;
  border-color: #dbeafe;
}

.detail-tags {
  margin-top: 24px;
}

.detail-side {
  display: grid;
  gap: 20px;
  position: sticky;
  top: 94px;
}

.poster-panel {
  padding: 18px;
}

.poster-panel img {
  width: 100%;
  border-radius: 18px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.poster-panel h2 {
  margin: 16px 0 6px;
  font-size: 24px;
}

.poster-panel p {
  margin: 0;
  color: var(--muted);
}

.side-list {
  padding: 18px;
}

.side-list h2 {
  margin: 0 0 12px;
}

.side-list a {
  display: block;
  padding: 11px 0;
  color: #1e40af;
  font-weight: 800;
  border-top: 1px solid #e2e8f0;
}

.related-section {
  width: 100%;
}

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

.footer-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 38px 0;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-brand {
  display: inline-flex;
  margin-bottom: 10px;
  font-size: 22px;
  font-weight: 900;
  color: #67e8f9;
}

.footer-inner p {
  max-width: 560px;
  margin: 0;
  line-height: 1.8;
}

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

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.14);
}

.is-filtered-out,
.is-search-hidden {
  display: none !important;
}

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

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

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

  .ranking-card,
  .detail-side {
    position: static;
  }
}

@media (max-width: 860px) {
  .site-nav,
  .top-search {
    display: none;
  }

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .header-inner {
    width: min(100% - 24px, 1280px);
  }

  .brand-copy strong {
    font-size: 17px;
  }

  .hero-carousel,
  .hero-track {
    min-height: 590px;
  }

  .hero-content {
    margin-left: 16px;
    padding-top: 76px;
  }

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

  .wide-search {
    flex-direction: column;
    align-items: stretch;
  }

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

  .section-head,
  .footer-inner,
  .detail-title-row {
    align-items: start;
    flex-direction: column;
  }

  .category-overview-card,
  .ranking-row {
    grid-template-columns: 1fr;
  }

  .category-overview-cover,
  .ranking-cover {
    max-width: 260px;
  }
}

@media (max-width: 520px) {
  .brand {
    min-width: 0;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .brand-copy small {
    display: none;
  }

  .hero-content h1 {
    font-size: 42px;
  }

  .hero-meta span {
    font-size: 13px;
  }

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

  .page-shell,
  .content-section,
  .quick-search-panel {
    width: min(100% - 24px, 1280px);
  }

  .player-overlay span {
    width: 68px;
    height: 68px;
    font-size: 28px;
  }
}
