:root {
  --bg: #f4f7fb;
  --ink: #0f172a;
  --muted: #64748b;
  --line: rgba(148, 163, 184, 0.28);
  --blue: #2563eb;
  --cyan: #06b6d4;
  --red: #ef4444;
  --orange: #f97316;
  --card: #ffffff;
  --shadow: 0 24px 80px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 64, 175, 0.94), rgba(8, 145, 178, 0.92));
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.2);
  backdrop-filter: blur(18px);
}

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

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

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

.brand-name {
  font-size: 22px;
  background: linear-gradient(90deg, #bfdbfe, #67e8f9, #fff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-weight: 700;
}

.nav-links a,
.mobile-nav a {
  opacity: 0.9;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.nav-links a:hover,
.mobile-nav a:hover {
  color: #67e8f9;
  opacity: 1;
}

.menu-toggle {
  display: none;
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  padding: 8px 14px;
}

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

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

.hero-carousel {
  position: relative;
  min-height: 640px;
  overflow: hidden;
  color: #fff;
  background: #0f172a;
}

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

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

.hero-slide img {
  position: absolute;
  inset: 0;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08) contrast(1.05);
  transform: scale(1.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 82% 20%, rgba(6, 182, 212, 0.26), transparent 34%),
    linear-gradient(90deg, rgba(15, 23, 42, 0.96) 0%, rgba(30, 64, 175, 0.72) 48%, rgba(15, 23, 42, 0.12) 100%),
    linear-gradient(0deg, rgba(15, 23, 42, 0.72), rgba(15, 23, 42, 0.16));
}

.hero-content {
  position: relative;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding-top: 34px;
  max-width: 760px;
  justify-self: start;
}

.hero-kicker,
.detail-kicker,
.page-hero span,
.section-heading span {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 7px 13px;
  color: #fff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  font-weight: 800;
  font-size: 13px;
  box-shadow: 0 12px 26px rgba(239, 68, 68, 0.28);
}

.hero-content h1 {
  margin: 24px 0 18px;
  font-size: clamp(42px, 7vw, 74px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

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

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

.hero-tags {
  margin: 26px 0;
}

.hero-tags span,
.tag-row span,
.detail-meta span {
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.12);
  color: #e0f2fe;
  font-size: 13px;
  font-weight: 700;
}

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

.primary-btn,
.ghost-btn,
.section-link,
.rank-action,
.quick-search button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border-radius: 14px;
  padding: 12px 20px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn,
.quick-search button {
  color: #0f172a;
  background: #fff;
  box-shadow: 0 16px 34px rgba(255, 255, 255, 0.22);
}

.primary-btn:hover,
.quick-search button:hover,
.section-link:hover,
.rank-action:hover {
  transform: translateY(-2px);
}

.ghost-btn {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
}

.hero-dot.is-active {
  width: 34px;
  background: #fff;
}

.quick-search {
  width: min(1040px, calc(100% - 32px));
  margin: -38px auto 0;
  position: relative;
  z-index: 3;
}

.quick-search form {
  display: flex;
  gap: 14px;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.quick-search label,
.filter-shell label {
  flex: 1;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.quick-search input,
.filter-shell input,
.filter-shell select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 13px 14px;
  color: var(--ink);
  background: #fff;
  outline: none;
}

.quick-search button,
.section-link,
.rank-action {
  border: 0;
  color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.24);
}

.content-section {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0;
}

.highlight-section {
  padding-top: 82px;
}

.category-section,
.latest-section {
  width: 100%;
  padding-left: max(16px, calc((100% - 1200px) / 2));
  padding-right: max(16px, calc((100% - 1200px) / 2));
  background: linear-gradient(135deg, #fff7ed, #eff6ff);
}

.rank-section {
  width: 100%;
  padding-left: max(16px, calc((100% - 1200px) / 2));
  padding-right: max(16px, calc((100% - 1200px) / 2));
  background: linear-gradient(135deg, #ecfeff, #f8fafc);
}

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

.section-heading span {
  color: #fff;
}

.section-heading h2 {
  margin: 13px 0 8px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

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

.movie-grid {
  display: grid;
  gap: 22px;
}

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

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

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

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 70px rgba(15, 23, 42, 0.16);
}

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

.movie-card-compact .poster-wrap {
  aspect-ratio: 16 / 10;
}

.poster-wrap img,
.category-card img,
.detail-poster img,
.rank-thumb img {
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.movie-card:hover .poster-wrap img,
.category-card:hover img,
.rank-row:hover .rank-thumb img {
  transform: scale(1.08);
}

.poster-gradient,
.category-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 25%, rgba(15, 23, 42, 0.86) 100%);
}

.play-chip {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  color: var(--blue);
  background: rgba(255, 255, 255, 0.92);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.86);
  transition: opacity 0.2s ease, transform 0.2s ease;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.26);
}

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

.rank-badge {
  position: absolute;
  left: 14px;
  top: 14px;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  font-style: normal;
  font-weight: 900;
  box-shadow: 0 12px 24px rgba(239, 68, 68, 0.28);
}

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

.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.card-meta a {
  color: var(--blue);
}

.movie-card h2,
.rank-info h2 {
  margin: 8px 0;
  font-size: 19px;
  line-height: 1.25;
}

.movie-card p,
.rank-info p {
  min-height: 48px;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
}

.tag-row span {
  border-color: rgba(37, 99, 235, 0.14);
  color: #1d4ed8;
  background: #eff6ff;
}

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

.category-card {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border-radius: 24px;
  color: #fff;
  background: #0f172a;
  box-shadow: var(--shadow);
}

.category-card strong,
.category-card em,
.category-card p {
  position: absolute;
  left: 22px;
  right: 22px;
  z-index: 2;
}

.category-card strong {
  bottom: 72px;
  font-size: 26px;
}

.category-card em {
  top: 18px;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.16);
  font-style: normal;
  font-weight: 900;
}

.category-card p {
  bottom: 22px;
  margin: 0;
  color: #dbeafe;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(135deg, #0f172a, #1d4ed8 55%, #0891b2);
}

.small-hero {
  padding: 86px 16px;
}

.page-hero > div {
  width: min(1200px, 100%);
  margin: 0 auto;
}

.page-hero h1 {
  margin: 16px 0 10px;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1;
  letter-spacing: -0.05em;
}

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

.filter-panel {
  width: min(1200px, calc(100% - 32px));
  margin: -34px auto 0;
  position: relative;
  z-index: 4;
}

.filter-shell {
  display: grid;
  grid-template-columns: 1fr 220px 180px;
  gap: 14px;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 64px 116px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 16px;
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 36px rgba(15, 23, 42, 0.06);
}

.rank-num {
  display: grid;
  place-items: center;
  height: 54px;
  border-radius: 18px;
  color: #fff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  font-size: 22px;
  font-weight: 900;
}

.rank-thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 16px;
  background: #0f172a;
}

.rank-info p {
  min-height: 0;
}

.detail-hero {
  min-height: 560px;
}

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

.detail-bg img {
  height: 100%;
  object-fit: cover;
  filter: blur(24px) saturate(1.25);
  transform: scale(1.13);
}

.detail-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 64, 175, 0.72), rgba(15, 23, 42, 0.42));
}

.detail-shell {
  position: relative;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0 70px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #dbeafe;
  font-size: 14px;
  margin-bottom: 28px;
}

.breadcrumb a:hover {
  color: #67e8f9;
}

.detail-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 38px;
  align-items: end;
}

.detail-poster {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 26px;
  aspect-ratio: 3 / 4;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.34);
}

.detail-info h1 {
  margin: 16px 0;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.detail-one {
  max-width: 800px;
  margin: 0 0 20px;
  color: #dbeafe;
  font-size: 20px;
}

.detail-meta {
  margin-bottom: 18px;
}

.detail-tags {
  margin: 0 0 26px;
}

.player-section {
  width: min(1200px, calc(100% - 32px));
  margin: -54px auto 0;
  position: relative;
  z-index: 5;
}

.player-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
  gap: 22px;
  align-items: stretch;
}

.video-box {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.video-box video {
  height: 100%;
  object-fit: contain;
  background: #020617;
}

.video-start {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: var(--blue);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.18), rgba(15, 23, 42, 0.64));
}

.video-start span {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  font-size: 34px;
  box-shadow: 0 24px 58px rgba(0, 0, 0, 0.28);
  padding-left: 5px;
}

.video-box.is-playing .video-start {
  display: none;
}

.player-copy,
.detail-article {
  border: 1px solid rgba(226, 232, 240, 0.88);
  border-radius: 28px;
  padding: 26px;
  background: #fff;
  box-shadow: 0 18px 46px rgba(15, 23, 42, 0.08);
}

.player-copy h2,
.detail-article h2 {
  margin: 0 0 12px;
  font-size: 26px;
  letter-spacing: -0.03em;
}

.player-copy p,
.detail-article p {
  margin: 0;
  color: var(--muted);
}

.detail-copy-section {
  padding-top: 34px;
}

.site-footer {
  margin-top: 30px;
  color: #cbd5e1;
  background: linear-gradient(135deg, #0f172a, #1e293b 58%, #0f172a);
}

.footer-shell {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 1fr;
  gap: 34px;
  padding: 52px 0;
}

.footer-shell h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 18px;
}

.footer-shell p {
  max-width: 520px;
  margin: 14px 0 0;
  color: #94a3b8;
}

.footer-shell a {
  display: block;
  margin: 8px 0;
}

.footer-brand {
  display: inline-block;
  color: #fff;
  font-size: 24px;
}

@media (max-width: 1024px) {
  .four-col,
  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .three-col,
  .player-shell,
  .detail-layout,
  .footer-shell {
    grid-template-columns: 1fr;
  }

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

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

  .nav-links {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
  }

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

  .quick-search form,
  .section-heading {
    flex-direction: column;
    align-items: stretch;
  }

  .quick-search form {
    display: grid;
  }

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

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

  .rank-row {
    grid-template-columns: 44px 84px 1fr;
  }

  .rank-action {
    grid-column: 2 / -1;
  }

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

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

  .movie-card h2,
  .rank-info h2 {
    font-size: 16px;
  }
}

@media (max-width: 520px) {
  .four-col,
  .three-col,
  .category-grid {
    grid-template-columns: 1fr;
  }

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

  .hero-actions {
    display: grid;
  }

  .detail-shell {
    padding-top: 28px;
  }

  .player-section {
    margin-top: -28px;
  }
}
