:root {
  --bg: #f8fafc;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --panel: #ffffff;
  --dark: #0f172a;
  --dark-soft: #1e293b;
  --cyan: #06b6d4;
  --blue: #2563eb;
  --shadow: 0 18px 45px 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(--text);
  background: var(--bg);
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

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

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

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

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

.logo-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: linear-gradient(135deg, #22d3ee, #2563eb);
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.35);
  transition: transform 0.25s ease;
}

.logo:hover .logo-mark {
  transform: scale(1.08) rotate(-4deg);
}

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

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

.nav-link,
.mobile-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.82);
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: #ffffff;
  background: rgba(34, 211, 238, 0.16);
}

.nav-link:hover {
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: #ffffff;
  border-radius: 99px;
}

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

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

.hero-bg,
.hero-slide::before,
.detail-backdrop::before {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
}

.hero-bg {
  background:
    radial-gradient(circle at 15% 20%, rgba(34, 211, 238, 0.36), transparent 34%),
    radial-gradient(circle at 85% 15%, rgba(37, 99, 235, 0.34), transparent 38%),
    linear-gradient(135deg, #0f172a, #1e293b 52%, #0f172a);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 370px;
  align-items: center;
  gap: 56px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  left: 50%;
  transform: translateX(-50%);
  padding: 84px 0 92px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}

.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
}

.hero-slide::before {
  z-index: -1;
  background-image:
    linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.72), rgba(15, 23, 42, 0.55)),
    var(--hero-image);
  background-size: cover;
  background-position: center;
  filter: blur(2px) saturate(1.08);
  transform: scale(1.08);
}

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

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: #0891b2;
  background: rgba(6, 182, 212, 0.12);
  text-transform: uppercase;
}

.hero-kicker {
  color: #67e8f9;
  background: rgba(8, 145, 178, 0.26);
}

.hero h1 {
  margin: 22px 0 18px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.hero p {
  max-width: 680px;
  margin: 0 0 24px;
  color: #cbd5e1;
  font-size: 18px;
}

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

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

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

.primary-btn,
.ghost-btn,
.text-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

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

.text-btn {
  min-height: auto;
  padding: 0;
  color: #0891b2;
}

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

.hero-poster {
  position: relative;
  display: block;
  border-radius: 32px;
  overflow: hidden;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
  transform: perspective(900px) rotateY(-7deg);
}

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

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 34px;
  display: flex;
  gap: 9px;
  transform: translateX(-50%);
  z-index: 2;
}

.hero-dot {
  width: 34px;
  height: 8px;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.28);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

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

.hero-search {
  position: relative;
  z-index: 3;
  margin-top: -42px;
  padding: 18px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.quick-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
}

.quick-search input,
.search-field input,
.search-field select {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0 16px;
  color: var(--text);
  background: #ffffff;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.quick-search input:focus,
.search-field input:focus,
.search-field select:focus {
  border-color: #06b6d4;
  box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.12);
}

.quick-search button {
  min-height: 50px;
  border: 0;
  border-radius: 16px;
  padding: 0 24px;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(135deg, #06b6d4, #2563eb);
  cursor: pointer;
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.quick-links a {
  padding: 7px 11px;
  border-radius: 999px;
  color: #0f172a;
  background: #f1f5f9;
}

.section {
  padding: 70px 0 0;
}

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

.section-head.no-link {
  align-items: flex-start;
}

.section-head h2,
.page-hero h1,
.detail-copy h1 {
  margin: 12px 0 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.section-head a {
  color: #0891b2;
  font-weight: 800;
}

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

.movie-card {
  min-width: 0;
}

.card-link {
  display: block;
  height: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-box {
  position: relative;
  overflow: hidden;
  background: #111827;
}

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

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

.card-year,
.card-type {
  position: absolute;
  top: 12px;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(10px);
}

.card-year {
  left: 12px;
}

.card-type {
  right: 12px;
}

.card-body {
  padding: 16px;
}

.card-body h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 900;
}

.card-body p {
  min-height: 52px;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: #475569;
  font-size: 13px;
}

.card-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #f1f5f9;
}

.tag-row {
  margin-top: 12px;
}

.tag-row span {
  color: #0369a1;
  background: #e0f2fe;
  border-color: transparent;
}

.tag-row.large span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
}

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

.category-tile {
  min-height: 205px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border-radius: var(--radius);
  color: #ffffff;
  background:
    radial-gradient(circle at 80% 0%, rgba(34, 211, 238, 0.32), transparent 36%),
    linear-gradient(135deg, #1e293b, #0f172a);
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.16);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.24);
}

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

.category-tile p {
  color: #cbd5e1;
  font-size: 14px;
}

.category-tile div,
.category-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.category-tile span,
.category-samples a {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 5px 8px;
  border-radius: 999px;
  font-size: 12px;
  color: #e0f2fe;
  background: rgba(255, 255, 255, 0.12);
}

.feature-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 28px;
}

.rank-list,
.small-card-grid,
.category-panel,
.filter-panel,
.detail-section,
.player-shell {
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.rank-list {
  overflow: hidden;
}

.rank-row {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.rank-row:last-child {
  border-bottom: 0;
}

.rank-row:hover {
  background: #f8fafc;
}

.rank-no {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(135deg, #06b6d4, #2563eb);
}

.rank-title {
  font-weight: 800;
}

.rank-score,
.hot-badge {
  color: #0891b2;
  font-weight: 800;
}

.small-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 16px;
}

.small-card {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  background: #111827;
}

.small-card img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  opacity: 0.82;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.small-card:hover img {
  transform: scale(1.06);
  opacity: 0.65;
}

.small-card span {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}

.page-hero {
  padding: 56px 0 20px;
}

.page-hero p {
  max-width: 760px;
  color: var(--muted);
  font-size: 17px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 16px;
  color: #64748b;
  font-size: 14px;
}

.breadcrumbs a:hover {
  color: #0891b2;
}

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

.category-panel {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 20px;
  padding: 18px;
}

.category-cover {
  border-radius: 18px;
  overflow: hidden;
  background: #111827;
}

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

.category-panel h2 {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 900;
}

.category-panel p {
  margin: 0 0 14px;
  color: var(--muted);
}

.category-samples a {
  color: #0369a1;
  background: #e0f2fe;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 16px;
  padding: 16px;
  margin-bottom: 24px;
}

.search-field span {
  display: block;
  margin-bottom: 7px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

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

.rank-card-link {
  display: grid;
  grid-template-columns: 64px 92px 1fr auto;
  align-items: center;
  gap: 18px;
  min-height: 126px;
  padding: 16px;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-card-link:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.rank-big {
  color: #cbd5e1;
  font-size: 30px;
  font-weight: 900;
}

.rank-card img {
  width: 92px;
  height: 112px;
  border-radius: 16px;
  object-fit: cover;
  background: #111827;
}

.rank-info {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.rank-info strong {
  font-size: 19px;
}

.rank-info em,
.rank-info small {
  color: var(--muted);
  font-style: normal;
}

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

.detail-backdrop {
  position: absolute;
  inset: 0;
  background-image: var(--detail-image);
  background-size: cover;
  background-position: center;
  filter: blur(3px) saturate(1.1);
  transform: scale(1.08);
}

.detail-backdrop::before {
  background:
    radial-gradient(circle at 25% 20%, rgba(34, 211, 238, 0.24), transparent 34%),
    linear-gradient(90deg, rgba(15, 23, 42, 0.98), rgba(15, 23, 42, 0.86), rgba(15, 23, 42, 0.72));
}

.detail-inner {
  position: relative;
  padding: 52px 0 62px;
}

.detail-grid {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 34px;
  align-items: end;
}

.detail-poster {
  width: 260px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 28px;
  background: #111827;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
}

.detail-copy .lead {
  max-width: 820px;
  color: #cbd5e1;
  font-size: 18px;
}

.detail-meta {
  margin: 18px 0 6px;
}

.watch-section {
  margin-top: -34px;
  position: relative;
  z-index: 2;
}

.player-shell {
  position: relative;
  overflow: hidden;
  background: #020617;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #ffffff;
  background:
    radial-gradient(circle, rgba(15, 23, 42, 0.2), rgba(15, 23, 42, 0.62)),
    rgba(15, 23, 42, 0.24);
  cursor: pointer;
}

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

.play-button {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding-left: 6px;
  font-size: 32px;
  background: linear-gradient(135deg, #06b6d4, #2563eb);
  box-shadow: 0 18px 45px rgba(37, 99, 235, 0.42);
  transition: transform 0.2s ease;
}

.player-cover:hover .play-button {
  transform: scale(1.08);
}

.detail-content {
  display: grid;
  gap: 24px;
  padding-top: 34px;
}

.detail-section {
  padding: 26px;
}

.detail-section h2 {
  margin: 0 0 12px;
  font-size: 25px;
  font-weight: 900;
}

.detail-section p {
  margin: 0;
  color: #334155;
  font-size: 16px;
}

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

.site-footer {
  margin-top: 76px;
  padding: 52px 0 26px;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 32px;
}

.footer-logo {
  margin-bottom: 12px;
  color: #ffffff;
  font-size: 22px;
  font-weight: 900;
}

.site-footer h3 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 17px;
}

.site-footer a {
  display: block;
  margin: 8px 0;
  color: #cbd5e1;
}

.site-footer a:hover {
  color: #22d3ee;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 30px auto 0;
  padding-top: 22px;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  text-align: center;
  color: #94a3b8;
  font-size: 14px;
}

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

  .menu-toggle {
    display: block;
  }

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

  .mobile-link {
    display: block;
  }

  .hero {
    min-height: 760px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    gap: 30px;
    padding-top: 54px;
  }

  .hero-poster {
    width: min(280px, 72vw);
    margin: 0 auto;
    transform: none;
  }

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

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

  .feature-layout,
  .category-panel-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .detail-poster {
    width: 180px;
  }

  .rank-card-link {
    grid-template-columns: 52px 82px 1fr;
  }

  .hot-badge {
    grid-column: 3;
  }
}

@media (max-width: 680px) {
  .header-inner {
    min-height: 64px;
  }

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

  .hero {
    min-height: 720px;
  }

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

  .hero p {
    font-size: 16px;
  }

  .quick-search,
  .filter-panel,
  .category-panel,
  .detail-grid {
    grid-template-columns: 1fr;
  }

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

  .card-body {
    padding: 13px;
  }

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

  .card-body p {
    min-height: auto;
  }

  .category-grid,
  .small-card-grid {
    grid-template-columns: 1fr;
  }

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

  .rank-score {
    grid-column: 2;
  }

  .rank-card-link {
    grid-template-columns: 44px 74px 1fr;
    gap: 12px;
    padding: 12px;
  }

  .rank-card img {
    width: 74px;
    height: 96px;
  }

  .rank-info small {
    display: none;
  }

  .detail-poster {
    width: min(220px, 70vw);
  }

  .detail-copy h1,
  .page-hero h1 {
    font-size: 32px;
  }
}
