:root {
  --sky: #0284c7;
  --sky-dark: #0369a1;
  --pink: #db2777;
  --amber: #f59e0b;
  --text: #1f2937;
  --muted: #64748b;
  --line: #e5e7eb;
  --soft: #f8fafc;
  --white: #ffffff;
  --shadow: 0 24px 60px rgba(15, 23, 42, 0.14);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 42%, #ffffff 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 10px 34px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(16px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  white-space: nowrap;
}

.brand-icon {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: #ffffff;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--sky), var(--pink));
  box-shadow: 0 12px 22px rgba(2, 132, 199, 0.25);
}

.brand-text {
  font-size: 24px;
  letter-spacing: -0.04em;
  background: linear-gradient(90deg, var(--sky-dark), var(--pink));
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 15px;
  font-weight: 700;
}

.nav-link {
  color: #334155;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--sky);
  transform: translateY(-1px);
}

.header-search,
.mobile-search,
.large-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-search input,
.large-search input,
.filter-grid input,
.filter-grid select {
  min-width: 0;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  background: #ffffff;
  padding: 11px 14px;
  color: #0f172a;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.mobile-search input:focus,
.large-search input:focus,
.filter-grid input:focus,
.filter-grid select:focus {
  border-color: var(--sky);
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.15);
}

.header-search button,
.mobile-search button,
.large-search button {
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--sky), var(--pink));
  padding: 11px 16px;
  font-weight: 800;
  cursor: pointer;
}

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
  font-size: 30px;
  color: #334155;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  border-top: 1px solid var(--line);
  padding: 16px;
  background: rgba(255, 255, 255, 0.98);
}

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

.mobile-nav {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.hero-slider {
  position: relative;
  min-height: 610px;
  overflow: hidden;
  background: linear-gradient(135deg, #38bdf8 0%, #f9a8d4 50%, #fde68a 100%);
}

.hero-wrap {
  position: relative;
  min-height: 610px;
}

.hero-glow {
  position: absolute;
  border-radius: 999px;
  filter: blur(18px);
  opacity: 0.42;
  background: #ffffff;
  animation: pulseGlow 5s ease-in-out infinite;
}

.hero-glow-one {
  top: 78px;
  left: 8%;
  width: 190px;
  height: 190px;
}

.hero-glow-two {
  right: 11%;
  bottom: 90px;
  width: 280px;
  height: 280px;
  animation-delay: 0.8s;
}

@keyframes pulseGlow {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.12);
  }
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  align-items: center;
  gap: 42px;
  padding: 68px 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

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

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  color: var(--sky-dark);
  background: rgba(255, 255, 255, 0.88);
  padding: 7px 14px;
  font-size: 14px;
  font-weight: 900;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.1);
}

.hero-copy h1 {
  margin: 20px 0 16px;
  color: #ffffff;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.06em;
  text-shadow: 0 16px 36px rgba(15, 23, 42, 0.25);
}

.hero-copy p {
  max-width: 670px;
  margin: 0 0 30px;
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(17px, 2.2vw, 22px);
  text-shadow: 0 10px 22px rgba(15, 23, 42, 0.22);
}

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

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

.primary-btn {
  color: var(--sky-dark);
  background: #ffffff;
  padding: 14px 26px;
  box-shadow: var(--shadow);
}

.ghost-btn {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.68);
  background: rgba(255, 255, 255, 0.16);
  padding: 13px 22px;
  backdrop-filter: blur(10px);
}

.primary-btn:hover,
.ghost-btn:hover,
.section-more:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-poster {
  justify-self: end;
  display: block;
  width: min(390px, 100%);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 34px 80px rgba(15, 23, 42, 0.32);
  transform: rotate(1deg);
}

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

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: #0f172a;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
  cursor: pointer;
  font-size: 34px;
  transform: translateY(-50%);
}

.hero-prev {
  left: 8px;
}

.hero-next {
  right: 8px;
}

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

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

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

.section {
  padding: 72px 0;
}

.bg-white {
  background: #ffffff;
}

.soft-section {
  background: linear-gradient(135deg, #f0f9ff 0%, #fdf2f8 100%);
}

.rank-section {
  background: #ffffff;
}

.section-head {
  margin-bottom: 28px;
}

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

.section-head h2 {
  margin: 10px 0 0;
  color: #0f172a;
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-more {
  color: var(--sky-dark);
  background: #e0f2fe;
  padding: 11px 18px;
}

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

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 18px 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 28px 62px rgba(15, 23, 42, 0.15);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, #e0f2fe, #fce7f3);
}

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

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

.poster-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 132, 199, 0.9);
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(10px);
}

.card-body {
  padding: 18px;
}

.card-title {
  display: -webkit-box;
  overflow: hidden;
  min-height: 48px;
  color: #0f172a;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  transition: color 0.2s ease;
}

.card-title:hover {
  color: var(--sky-dark);
}

.card-meta {
  margin: 8px 0;
  color: var(--muted);
  font-size: 13px;
}

.card-body p {
  display: -webkit-box;
  overflow: hidden;
  min-height: 48px;
  margin: 0 0 12px;
  color: #475569;
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.tag-row span {
  border-radius: 999px;
  color: #0f766e;
  background: #ccfbf1;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 800;
}

.compact-card {
  display: grid;
  grid-template-columns: 112px 1fr;
  min-height: 168px;
}

.compact-card .poster-link img {
  height: 100%;
  aspect-ratio: auto;
}

.compact-card .card-title {
  min-height: auto;
}

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

.category-tile,
.overview-card {
  border: 1px solid rgba(14, 165, 233, 0.12);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.8);
  box-shadow: 0 20px 42px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(14px);
}

.category-tile {
  display: grid;
  gap: 10px;
  padding: 24px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-tile:hover,
.overview-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 28px 62px rgba(15, 23, 42, 0.13);
}

.category-tile span,
.overview-main span {
  color: var(--pink);
  font-size: 15px;
  font-weight: 900;
}

.category-tile strong {
  color: #0f172a;
  font-size: 20px;
  line-height: 1.3;
}

.category-tile small,
.overview-main p {
  color: var(--muted);
  font-size: 14px;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 54px 90px 1fr;
  align-items: center;
  gap: 16px;
  border: 1px solid #e2e8f0;
  border-radius: 22px;
  background: linear-gradient(90deg, #ffffff 0%, #f8fafc 100%);
  padding: 14px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 46px rgba(15, 23, 42, 0.12);
}

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

.rank-cover img {
  width: 90px;
  height: 120px;
  border-radius: 16px;
  object-fit: cover;
}

.rank-title {
  color: #0f172a;
  font-size: 18px;
  font-weight: 900;
}

.rank-copy p {
  margin: 6px 0;
  color: #475569;
  font-size: 14px;
}

.rank-meta {
  color: var(--muted);
  font-size: 13px;
}

.page-hero {
  padding: 84px 0 76px;
  color: #ffffff;
  background: linear-gradient(135deg, #0ea5e9 0%, #db2777 54%, #f59e0b 100%);
}

.slim-hero,
.rank-hero,
.search-hero {
  background: linear-gradient(135deg, #0284c7 0%, #7c3aed 100%);
}

.page-hero h1 {
  margin: 18px 0 12px;
  font-size: clamp(36px, 5vw, 58px);
  line-height: 1.1;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: 18px;
}

.crumb {
  display: inline-flex;
  margin-bottom: 14px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 800;
}

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

.overview-card {
  padding: 24px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.overview-main {
  display: block;
}

.overview-main p {
  margin: 10px 0 18px;
}

.overview-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.overview-links a {
  border-radius: 999px;
  color: var(--sky-dark);
  background: #e0f2fe;
  padding: 7px 11px;
  font-size: 13px;
  font-weight: 800;
}

.filter-panel,
.search-box-panel {
  margin-bottom: 28px;
  border: 1px solid #e2e8f0;
  border-radius: 28px;
  background: #ffffff;
  padding: 24px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.07);
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 24px;
  align-items: end;
}

.filter-panel h2 {
  margin: 0 0 6px;
  font-size: 22px;
}

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

.filter-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 12px;
}

.full-rank .rank-item {
  grid-template-columns: 64px 100px 1fr;
}

.empty-state {
  display: none;
  margin: 24px 0;
  border-radius: 22px;
  background: #f8fafc;
  padding: 24px;
  color: var(--muted);
  text-align: center;
  font-weight: 800;
}

.empty-state.show {
  display: block;
}

.detail-shell {
  padding: 36px 0 68px;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.breadcrumb a {
  color: var(--sky-dark);
}

.player-card,
.detail-card,
.side-box,
.side-poster {
  border: 1px solid #e2e8f0;
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 20px 48px rgba(15, 23, 42, 0.08);
}

.player-card {
  overflow: hidden;
  padding: 12px;
}

.movie-player {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000000;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  padding: 0;
  background: #000000;
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.player-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
  filter: saturate(1.1);
}

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

.play-ring {
  position: relative;
  z-index: 2;
  display: grid;
  width: 86px;
  height: 86px;
  place-items: center;
  border: 4px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.9), rgba(219, 39, 119, 0.9));
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.35);
  font-size: 34px;
}

.detail-card {
  margin-top: 22px;
  padding: 28px;
}

.pill-link {
  display: inline-flex;
  border-radius: 999px;
  color: var(--sky-dark);
  background: #e0f2fe;
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 900;
}

.detail-card h1 {
  margin: 16px 0 10px;
  color: #0f172a;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 20px;
}

.detail-meta span {
  border-radius: 999px;
  background: #f1f5f9;
  padding: 6px 11px;
  color: #475569;
  font-size: 13px;
  font-weight: 800;
}

.lead-text {
  color: #334155;
  font-size: 18px;
  font-weight: 700;
}

.detail-card h2,
.side-box h2,
.site-footer h2 {
  color: #0f172a;
  font-size: 22px;
}

.detail-side {
  position: sticky;
  top: 104px;
  display: grid;
  gap: 18px;
}

.side-poster {
  display: block;
  overflow: hidden;
}

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

.side-box {
  padding: 22px;
}

.side-box p {
  margin: 9px 0;
  color: #475569;
}

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

.search-box-panel .filter-panel {
  margin: 18px 0 0;
  box-shadow: none;
}

.large-search input {
  flex: 1;
  width: 100%;
  font-size: 18px;
  padding: 14px 18px;
}

.large-search button {
  padding: 14px 24px;
}

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(135deg, #0f172a 0%, #1f2937 48%, #111827 100%);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 32px;
  padding: 54px 0;
}

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

.site-footer p {
  max-width: 460px;
  margin: 0;
}

.site-footer h2 {
  color: #ffffff;
  margin: 0 0 12px;
}

.footer-links {
  display: grid;
  gap: 8px;
}

.footer-links a {
  color: #cbd5e1;
}

.footer-links a:hover {
  color: #ffffff;
}

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  padding: 18px 0;
  color: #94a3b8;
  text-align: center;
}

@media (max-width: 1100px) {
  .desktop-nav {
    gap: 12px;
    font-size: 14px;
  }

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

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

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

  .detail-side {
    position: static;
    grid-template-columns: 240px 1fr;
  }
}

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

  .menu-toggle {
    display: block;
  }

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

  .hero-slide {
    grid-template-columns: 1fr;
    align-content: center;
    text-align: center;
    gap: 28px;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-poster {
    justify-self: center;
    width: min(310px, 76vw);
  }

  .section-head.between,
  .filter-panel {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .section-head.between {
    display: grid;
  }

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

  .home-rank {
    grid-template-columns: 1fr;
  }

  .overview-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

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

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

  .section {
    padding: 52px 0;
  }

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

  .compact-card {
    grid-template-columns: 98px 1fr;
  }

  .rank-item,
  .full-rank .rank-item {
    grid-template-columns: 42px 76px 1fr;
    gap: 10px;
    padding: 10px;
  }

  .rank-cover img {
    width: 76px;
    height: 102px;
  }

  .rank-copy p {
    display: none;
  }

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

  .detail-card,
  .side-box,
  .filter-panel,
  .search-box-panel {
    padding: 18px;
    border-radius: 22px;
  }

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

  .hero-arrow {
    display: none;
  }

  .large-search {
    display: grid;
  }
}
