:root {
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --panel: #ffffff;
  --soft: #f8fafc;
  --teal: #14b8a6;
  --teal-dark: #0f766e;
  --amber: #f59e0b;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.14);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 42%, #ffffff 100%);
}

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

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

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

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

.brand,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #0f172a;
  background: linear-gradient(135deg, #5eead4, #14b8a6);
  box-shadow: 0 8px 24px rgba(20, 184, 166, 0.35);
  font-size: 17px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-size: 22px;
  letter-spacing: -0.03em;
}

.brand-text em {
  margin-top: 4px;
  color: #94a3b8;
  font-size: 12px;
  font-style: normal;
}

.desktop-nav {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 18px;
  color: #e2e8f0;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
}

.desktop-nav a,
.mobile-panel a,
.footer-links a {
  transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.mobile-panel a:hover,
.footer-links a:hover {
  color: #5eead4;
}

.nav-search,
.mobile-search {
  display: flex;
  align-items: center;
  background: rgba(51, 65, 85, 0.92);
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  padding: 4px;
}

.nav-search input,
.mobile-search input,
.filter-bar input,
.filter-bar select {
  border: 0;
  outline: 0;
  font: inherit;
}

.nav-search input,
.mobile-search input {
  width: 210px;
  padding: 10px 12px;
  color: #ffffff;
  background: transparent;
}

.nav-search input::placeholder,
.mobile-search input::placeholder {
  color: #94a3b8;
}

.nav-search button,
.mobile-search button {
  border: 0;
  border-radius: 999px;
  padding: 10px 14px;
  color: #0f172a;
  background: #5eead4;
  cursor: pointer;
  font-weight: 700;
}

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

.mobile-panel {
  display: none;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 16px 0 20px;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
}

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

.mobile-panel a {
  color: #e2e8f0;
}

.mobile-search {
  width: 100%;
}

.mobile-search input {
  width: 100%;
}

main {
  min-height: 60vh;
}

.hero-carousel {
  position: relative;
  height: 70vh;
  min-height: 560px;
  overflow: hidden;
  color: #ffffff;
  background: #000000;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 900ms ease;
}

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

.hero-slide > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
  filter: saturate(1.08) contrast(1.05);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 72% 28%, rgba(20, 184, 166, 0.28), transparent 35%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(2, 6, 23, 0.64) 48%, rgba(2, 6, 23, 0.24) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.88) 0%, transparent 55%);
}

.hero-content {
  position: absolute;
  left: max(32px, calc((100vw - 1280px) / 2 + 24px));
  bottom: 86px;
  width: min(650px, calc(100% - 64px));
  display: grid;
  gap: 18px;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  color: #0f766e;
  background: #ccfbf1;
  padding: 8px 13px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.hero-content .eyebrow,
.page-hero .eyebrow,
.detail-copy .eyebrow {
  color: #5eead4;
  background: rgba(20, 184, 166, 0.16);
  border: 1px solid rgba(94, 234, 212, 0.22);
}

.hero-content h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 86px);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.hero-content p,
.page-hero p,
.detail-one-line {
  margin: 0;
  color: #cbd5e1;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.8;
}

.hero-tags,
.detail-meta,
.movie-meta-line,
.tag-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.detail-meta span,
.tag-list span {
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(226, 232, 240, 0.16);
  color: #e2e8f0;
  font-size: 13px;
}

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

.primary-button,
.ghost-button,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 13px 20px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #052e2b;
  background: linear-gradient(135deg, #5eead4, #14b8a6);
  box-shadow: 0 14px 28px rgba(20, 184, 166, 0.32);
}

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

.ghost-button {
  color: #ffffff;
  background: rgba(15, 23, 42, 0.46);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 6;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.52);
  cursor: pointer;
  font-size: 36px;
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

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

.quick-entry {
  width: min(1280px, calc(100% - 32px));
  margin: -38px auto 46px;
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.quick-entry a {
  padding: 22px;
  border-radius: 20px;
  color: #ffffff;
  background: linear-gradient(135deg, #0f172a, #1e293b);
  box-shadow: var(--shadow);
  font-size: 18px;
  font-weight: 800;
}

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

.content-section {
  margin-bottom: 64px;
}

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

.section-heading h2,
.article-section h2 {
  margin: 8px 0 0;
  color: #111827;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.section-heading a {
  color: var(--teal-dark);
  font-weight: 800;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
  transition: transform 0.26s ease, box-shadow 0.26s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  height: 260px;
  overflow: hidden;
  background: #0f172a;
}

.small-grid .poster-link,
.library-grid .poster-link {
  height: 220px;
}

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

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

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

.poster-badge {
  left: 12px;
}

.poster-score {
  right: 12px;
  color: #111827;
  background: #fbbf24;
}

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

.movie-title {
  display: -webkit-box;
  overflow: hidden;
  min-height: 44px;
  color: #111827;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.25;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-title:hover {
  color: var(--teal-dark);
}

.movie-card-body p {
  display: -webkit-box;
  overflow: hidden;
  min-height: 48px;
  margin: 10px 0 14px;
  color: var(--muted);
  line-height: 1.65;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-meta-line span {
  border-radius: 999px;
  padding: 6px 9px;
  color: #475569;
  background: #f1f5f9;
  font-size: 12px;
  font-weight: 700;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
}

.compact-card img {
  width: 96px;
  height: 72px;
  border-radius: 14px;
  object-fit: cover;
}

.compact-card span {
  display: block;
  color: #111827;
  font-weight: 900;
}

.compact-card em {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

.ranking-section {
  padding: 30px;
  border-radius: 28px;
  background: linear-gradient(135deg, #fffbeb, #fff7ed);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 54px 118px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  border-radius: 18px;
  background: #ffffff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-row:hover,
.ranking-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.12);
}

.rank-number,
.ranking-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  font-weight: 900;
}

.rank-row img {
  width: 118px;
  height: 72px;
  border-radius: 14px;
  object-fit: cover;
}

.rank-title,
.ranking-title {
  color: #111827;
  font-size: 18px;
  font-weight: 900;
}

.rank-meta {
  color: var(--muted);
  font-weight: 800;
}

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

.category-tile,
.category-overview-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 8px 26px rgba(15, 23, 42, 0.1);
}

.category-tile {
  min-height: 220px;
  padding: 24px;
  color: #ffffff;
}

.category-tile img,
.category-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.52);
  transition: transform 0.4s ease;
}

.category-tile:hover img,
.category-cover:hover img {
  transform: scale(1.08);
}

.category-tile span,
.category-tile em {
  position: relative;
  z-index: 2;
  display: block;
}

.category-tile span {
  font-size: 26px;
  font-weight: 900;
}

.category-tile em {
  margin-top: 12px;
  color: #dbeafe;
  font-style: normal;
  line-height: 1.7;
}

.page-main {
  padding: 36px 0 70px;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  margin-bottom: 34px;
  border-radius: 30px;
  color: #ffffff;
  background:
    radial-gradient(circle at 78% 16%, rgba(20, 184, 166, 0.32), transparent 34%),
    linear-gradient(135deg, #0f172a, #1e293b);
  box-shadow: var(--shadow);
}

.page-hero {
  padding: 64px;
}

.slim-hero,
.category-hero,
.ranking-hero {
  min-height: 300px;
}

.page-hero h1 {
  max-width: 900px;
  margin: 16px 0;
}

.page-hero p {
  max-width: 760px;
}

.filter-bar {
  position: sticky;
  top: 86px;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 28px;
  padding: 14px;
  border: 1px solid rgba(226, 232, 240, 0.84);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
}

.filter-bar input {
  flex: 1;
  min-width: 160px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #f8fafc;
}

.filter-bar select {
  padding: 14px 16px;
  border-radius: 16px;
  color: #334155;
  background: #f8fafc;
}

.filter-empty {
  display: none;
  color: #b45309;
  font-weight: 800;
}

.filter-empty.is-visible {
  display: inline-flex;
}

.category-overview-card {
  padding: 18px;
}

.category-cover {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 180px;
  overflow: hidden;
  border-radius: 20px;
  padding: 20px;
  color: #ffffff;
}

.category-cover span {
  position: relative;
  z-index: 2;
  font-size: 24px;
  font-weight: 900;
}

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

.category-preview-list {
  display: grid;
  gap: 12px;
}

.text-link {
  margin-top: 16px;
  color: #0f766e;
  background: #ccfbf1;
}

.ranking-card {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 20px;
  padding: 16px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ranking-poster {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
}

.ranking-poster img {
  width: 160px;
  height: 110px;
  object-fit: cover;
}

.ranking-poster .ranking-number {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 3;
}

.ranking-copy p {
  margin: 8px 0 14px;
  color: var(--muted);
  line-height: 1.7;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  color: #64748b;
  font-size: 14px;
}

.breadcrumb a {
  color: #0f766e;
  font-weight: 800;
}

.detail-hero {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 34px;
  padding: 34px;
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.38);
}

.detail-copy {
  align-self: center;
  display: grid;
  gap: 18px;
}

.detail-copy h1 {
  font-size: clamp(38px, 5vw, 66px);
}

.detail-meta span,
.tag-list span {
  background: rgba(255, 255, 255, 0.1);
}

.player-section {
  margin-bottom: 54px;
}

.player-heading {
  margin-bottom: 16px;
}

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

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle, rgba(15, 23, 42, 0.22), rgba(0, 0, 0, 0.58));
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.play-overlay span {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #052e2b;
  background: #5eead4;
  font-size: 34px;
  box-shadow: 0 18px 46px rgba(20, 184, 166, 0.36);
}

.play-overlay strong {
  font-size: 22px;
}

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

.article-section {
  padding: 30px;
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 8px 26px rgba(15, 23, 42, 0.08);
}

.article-section p {
  margin: 14px 0 28px;
  color: #334155;
  font-size: 17px;
  line-height: 2;
}

.site-footer {
  margin-top: 70px;
  color: #cbd5e1;
  background: linear-gradient(180deg, #0f172a, #020617);
}

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

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

.footer-brand p {
  max-width: 560px;
  color: #94a3b8;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  padding: 18px;
  text-align: center;
  color: #64748b;
}

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

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

  .menu-toggle {
    display: block;
  }

  .nav-search {
    margin-left: auto;
  }

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

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

@media (max-width: 820px) {
  .nav-shell {
    height: auto;
    min-height: 68px;
  }

  .brand-text em,
  .nav-search {
    display: none;
  }

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

  .hero-content {
    left: 22px;
    bottom: 82px;
    width: calc(100% - 44px);
  }

  .hero-arrow {
    top: auto;
    bottom: 26px;
  }

  .hero-prev {
    left: 22px;
  }

  .hero-next {
    right: 22px;
  }

  .quick-entry,
  .movie-grid,
  .small-grid,
  .library-grid,
  .category-grid,
  .category-overview-grid,
  .compact-grid,
  .footer-shell,
  .detail-hero,
  .ranking-card {
    grid-template-columns: 1fr;
  }

  .quick-entry {
    margin-top: 18px;
  }

  .section-heading,
  .filter-bar,
  .rank-row {
    align-items: stretch;
    flex-direction: column;
  }

  .rank-row {
    display: grid;
    grid-template-columns: 42px 96px 1fr;
  }

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

  .page-hero,
  .detail-hero {
    padding: 28px;
    border-radius: 24px;
  }

  .poster-link,
  .small-grid .poster-link,
  .library-grid .poster-link {
    height: 320px;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 520px) {
  .brand-mark {
    width: 36px;
    height: 36px;
  }

  .brand-text strong {
    font-size: 18px;
  }

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

  .hero-actions,
  .detail-meta,
  .tag-list {
    align-items: stretch;
    flex-direction: column;
  }

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

  .poster-link,
  .small-grid .poster-link,
  .library-grid .poster-link {
    height: 260px;
  }
}
