* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #020617;
  color: #e2e8f0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.96);
  border-bottom: 1px solid rgba(30, 41, 59, 0.9);
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(16px);
}

.navbar {
  width: min(100% - 32px, 1280px);
  height: 64px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
  color: #ffffff;
  font-size: 14px;
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.38);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #cbd5e1;
  font-size: 15px;
}

.nav-links a {
  transition: color 0.2s ease;
}

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

.top-search,
.mobile-search,
.inline-filter {
  display: flex;
  align-items: center;
  gap: 8px;
}

.top-search input,
.mobile-search input,
.inline-filter input {
  min-width: 220px;
  border: 1px solid #334155;
  border-radius: 12px;
  outline: none;
  background: #1e293b;
  color: #ffffff;
  padding: 10px 14px;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.top-search input:focus,
.mobile-search input:focus,
.inline-filter input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.top-search button,
.mobile-search button,
.inline-filter button {
  border: 0;
  border-radius: 12px;
  color: #ffffff;
  background: #2563eb;
  padding: 10px 14px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.top-search button:hover,
.mobile-search button:hover,
.inline-filter button:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #1e293b;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #ffffff;
}

.mobile-panel {
  display: none;
  width: min(100% - 32px, 1280px);
  margin: 0 auto;
  padding: 12px 0 18px;
  border-top: 1px solid #1e293b;
}

.mobile-panel a {
  display: block;
  padding: 10px 0;
  color: #cbd5e1;
}

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

.hero {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: #020617;
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  display: flex;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  background-position: center;
  background-size: cover;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.96), rgba(0, 0, 0, 0.74), rgba(0, 0, 0, 0.18));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(100% - 32px, 1280px);
  margin: 0 auto;
}

.hero-label,
.detail-badge,
.card-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #2563eb;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  padding: 5px 12px;
}

.hero h1,
.hero h2 {
  margin: 18px 0 16px;
  max-width: 760px;
  color: #ffffff;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-one {
  max-width: 720px;
  margin: 0 0 8px;
  color: #e2e8f0;
  font-size: 19px;
}

.hero-summary {
  max-width: 680px;
  display: -webkit-box;
  margin: 0 0 22px;
  color: #94a3b8;
  font-size: 16px;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.hero-tags span,
.tag-row span {
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.74);
  font-size: 12px;
  padding: 4px 9px;
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border-radius: 12px;
  padding: 0 24px;
  color: #ffffff;
  font-weight: 700;
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.primary-btn {
  background: #2563eb;
  box-shadow: 0 16px 38px rgba(37, 99, 235, 0.3);
}

.primary-btn:hover {
  background: #1d4ed8;
  transform: translateY(-2px);
}

.ghost-btn {
  background: rgba(30, 41, 59, 0.86);
}

.ghost-btn:hover {
  background: rgba(51, 65, 85, 0.94);
  transform: translateY(-2px);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.55);
  font-size: 36px;
  line-height: 1;
  cursor: pointer;
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-control:hover {
  background: rgba(0, 0, 0, 0.78);
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

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

.hero-dot {
  width: 18px;
  height: 5px;
  border: 0;
  border-radius: 99px;
  background: #475569;
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 36px;
  background: #2563eb;
}

.section {
  padding: 56px 0;
}

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

.section-heading.compact {
  align-items: center;
}

.eyebrow {
  display: block;
  margin-bottom: 6px;
  color: #60a5fa;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.section-heading h2,
.page-hero h1,
.detail-info h1,
.text-card h2,
.player-title-row h2 {
  margin: 0;
  color: #ffffff;
  letter-spacing: -0.03em;
}

.section-heading h2 {
  font-size: clamp(26px, 3vw, 36px);
}

.text-link {
  color: #93c5fd;
  font-weight: 700;
}

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

.category-pill {
  min-height: 118px;
  border: 1px solid #1e293b;
  border-radius: 18px;
  background: linear-gradient(145deg, #111827, #1e293b);
  padding: 20px;
  transition: transform 0.2s ease, border 0.2s ease, background 0.2s ease;
}

.category-pill:hover {
  border-color: #2563eb;
  background: linear-gradient(145deg, #172554, #1e293b);
  transform: translateY(-4px);
}

.category-pill span {
  display: block;
  margin-bottom: 8px;
  color: #ffffff;
  font-size: 20px;
  font-weight: 800;
}

.category-pill small {
  display: -webkit-box;
  color: #94a3b8;
  font-size: 13px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

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

.movie-link {
  display: block;
  height: 100%;
}

.poster-wrap {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 14px;
  background: #1e293b;
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.25);
}

.poster-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease, filter 0.35s ease;
}

.movie-card:hover img {
  filter: brightness(0.75);
  transform: scale(1.1);
}

.card-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  border-radius: 7px;
  font-size: 12px;
  padding: 4px 8px;
}

.year-badge,
.rank-num {
  position: absolute;
  top: 10px;
  right: 10px;
  border-radius: 7px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.64);
  font-size: 12px;
  font-weight: 800;
  padding: 4px 8px;
}

.rank-num {
  left: 10px;
  right: auto;
  background: #2563eb;
}

.movie-card-wide .card-badge {
  left: 58px;
}

.poster-play {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(37, 99, 235, 0.92);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.82);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-body {
  padding: 12px 2px 0;
}

.card-body h3 {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 6px;
  color: #ffffff;
  font-size: 15px;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.movie-card:hover h3 {
  color: #60a5fa;
}

.card-body p {
  display: -webkit-box;
  margin: 0 0 10px;
  color: #94a3b8;
  font-size: 13px;
  line-height: 1.55;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag-row {
  gap: 5px;
}

.tag-row span {
  padding: 2px 7px;
}

.split-section {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 28px;
}

.rank-panel,
.spotlight-panel,
.text-card,
.player-card {
  border: 1px solid #1e293b;
  border-radius: 24px;
  background: #0f172a;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.25);
}

.rank-panel {
  padding: 28px;
}

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

.ranking-list-large {
  grid-template-columns: repeat(2, 1fr);
}

.movie-card-wide .movie-link {
  display: grid;
  grid-template-columns: 132px 1fr;
  gap: 16px;
  align-items: center;
  border-radius: 16px;
  background: rgba(30, 41, 59, 0.62);
  padding: 12px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.movie-card-wide .movie-link:hover {
  background: #1e293b;
  transform: translateY(-2px);
}

.movie-card-wide .poster-wrap {
  width: 132px;
  border-radius: 12px;
}

.movie-card-wide .card-body {
  padding: 0;
}

.spotlight-panel {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  background-position: center;
  background-size: cover;
}

.spotlight-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.3));
}

.spotlight-content {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 28px;
}

.spotlight-content span {
  color: #93c5fd;
  font-weight: 800;
}

.spotlight-content h2 {
  margin: 10px 0;
  color: #ffffff;
  font-size: 36px;
  line-height: 1.1;
}

.spotlight-content p {
  color: #cbd5e1;
}

.page-hero {
  padding: 82px 0 44px;
  background:
    radial-gradient(circle at 20% 0%, rgba(37, 99, 235, 0.32), transparent 34%),
    linear-gradient(180deg, #0f172a, #020617);
}

.page-hero-small h1 {
  margin-top: 0;
  font-size: clamp(36px, 5vw, 58px);
}

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

.inline-filter {
  margin-top: 24px;
  max-width: 620px;
}

.inline-filter input {
  flex: 1;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.search-status {
  margin-bottom: 24px;
  color: #cbd5e1;
  font-size: 18px;
}

.detail-hero {
  padding: 56px 0;
  background:
    radial-gradient(circle at 24% 10%, rgba(37, 99, 235, 0.28), transparent 30%),
    linear-gradient(180deg, #0f172a, #020617);
}

.detail-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 42px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.45);
}

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

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

.breadcrumb a:hover {
  color: #ffffff;
}

.detail-info h1 {
  margin: 18px 0 14px;
  font-size: clamp(36px, 5vw, 62px);
  line-height: 1.08;
}

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

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.meta-row span {
  border-radius: 999px;
  color: #cbd5e1;
  background: #1e293b;
  padding: 7px 12px;
}

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

.player-card {
  padding: 22px;
}

.player-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.player-title-row span {
  color: #93c5fd;
  font-weight: 800;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  background: #000000;
  aspect-ratio: 16 / 9;
}

.movie-player {
  width: 100%;
  height: 100%;
  display: block;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle, rgba(15, 23, 42, 0.32), rgba(0, 0, 0, 0.58));
  cursor: pointer;
}

.player-overlay[hidden] {
  display: none;
}

.player-overlay span {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #2563eb;
  font-size: 28px;
  box-shadow: 0 18px 50px rgba(37, 99, 235, 0.42);
  transition: transform 0.2s ease;
}

.player-overlay:hover span {
  transform: scale(1.08);
}

.player-error {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(90%, 420px);
  border-radius: 14px;
  color: #fecaca;
  background: rgba(127, 29, 29, 0.82);
  padding: 16px;
  text-align: center;
  transform: translate(-50%, -50%);
}

.detail-text {
  padding-top: 10px;
}

.text-card {
  padding: 32px;
}

.text-card h2 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 26px;
}

.text-card h2:not(:first-child) {
  margin-top: 30px;
}

.text-card p {
  margin: 0;
  color: #cbd5e1;
  font-size: 17px;
  line-height: 1.9;
}

.site-footer {
  margin-top: 48px;
  border-top: 1px solid #1e293b;
  background: #0f172a;
}

.footer-inner {
  width: min(100% - 32px, 1280px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 38px;
  padding: 42px 0;
}

.footer-brand p,
.site-footer li,
.site-footer p {
  color: #94a3b8;
}

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

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer li {
  margin-bottom: 8px;
}

.site-footer a:hover {
  color: #60a5fa;
}

.footer-bottom {
  border-top: 1px solid #1e293b;
  color: #64748b;
  padding: 16px;
  text-align: center;
}

.is-hidden {
  display: none !important;
}

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

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

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

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

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

  .detail-poster {
    width: min(340px, 100%);
  }
}

@media (max-width: 820px) {
  .top-search {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero {
    height: 560px;
  }


  .hero-control {
    display: none;
  }

  .category-grid,
  .category-overview,
  .feature-grid,
  .ranking-list-large,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .movie-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .movie-card-wide .movie-link {
    grid-template-columns: 105px 1fr;
  }

  .movie-card-wide .poster-wrap {
    width: 105px;
  }
}

@media (max-width: 560px) {
  .navbar {
    height: 58px;
  }

  .brand {
    font-size: 18px;
  }

  .hero {
    height: 540px;
  }

  .hero h1,
  .hero h2 {
    font-size: 38px;
  }

  .hero-one {
    font-size: 17px;
  }

  .hero-summary {
    -webkit-line-clamp: 2;
  }

  .hero-actions,
  .detail-actions {
    gap: 10px;
  }

  .primary-btn,
  .ghost-btn {
    width: 100%;
  }

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

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

  .page-hero {
    padding: 58px 0 30px;
  }

  .inline-filter,
  .mobile-search {
    align-items: stretch;
    flex-direction: column;
  }

  .inline-filter input,
  .mobile-search input,
  .inline-filter button,
  .mobile-search button {
    width: 100%;
  }

  .detail-hero {
    padding: 34px 0;
  }

  .detail-info h1 {
    font-size: 34px;
  }

  .player-card,
  .text-card,
  .rank-panel {
    padding: 18px;
    border-radius: 18px;
  }

  .movie-card-wide .movie-link {
    grid-template-columns: 92px 1fr;
    gap: 12px;
  }

  .movie-card-wide .poster-wrap {
    width: 92px;
  }
}
