* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #102a43;
  color: #f3f4f6;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 20% 0%, rgba(245, 158, 11, 0.18), transparent 32rem),
    radial-gradient(circle at 85% 12%, rgba(90, 77, 126, 0.28), transparent 34rem),
    linear-gradient(180deg, rgba(16, 42, 67, 0.2), #102a43 70%);
  z-index: -1;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(36, 59, 83, 0.95);
  border-bottom: 1px solid rgba(51, 78, 104, 0.9);
  backdrop-filter: blur(16px);
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  min-height: 72px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  box-shadow: 0 0 22px rgba(245, 158, 11, 0.35);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
}

.nav-link {
  color: #d1d5db;
  font-size: 15px;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #f59e0b;
}

.nav-search,
.mobile-search {
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 12px;
  background: #334e68;
}

.nav-search input,
.mobile-search input {
  width: 220px;
  border: 0;
  outline: 0;
  padding: 10px 12px;
  color: #f3f4f6;
  background: transparent;
}

.nav-search button,
.mobile-search button {
  border: 0;
  padding: 10px 14px;
  color: #111827;
  background: #f59e0b;
  font-weight: 700;
}

.mobile-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: #f3f4f6;
  background: transparent;
  font-size: 28px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid rgba(51, 78, 104, 0.8);
  padding: 12px 24px 18px;
  background: #243b53;
}

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

.mobile-link {
  display: block;
  padding: 10px 0;
  color: #d1d5db;
}

.mobile-link.active,
.mobile-link:hover {
  color: #f59e0b;
}

.mobile-search {
  margin-top: 10px;
}

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

.hero-section {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: #0b1f33;
}

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

.hero-slide {
  opacity: 0;
  background-position: center;
  background-size: cover;
  transition: opacity 0.8s ease;
}

.hero-slide.active {
  opacity: 1;
  z-index: 1;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right, rgba(16, 42, 67, 0.96), rgba(36, 59, 83, 0.72), rgba(16, 42, 67, 0.25)),
    linear-gradient(to bottom, rgba(16, 42, 67, 0.55), #102a43 94%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 760px;
  min-height: 70vh;
  padding: 9vh 24px 16vh;
  margin: 0 auto;
  transform: translateX(-260px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-content h1,
.hero-content h2 {
  margin: 0 0 14px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
  color: #ffffff;
  text-shadow: 0 8px 26px rgba(0, 0, 0, 0.48);
}

.hero-content .hero-movie-title {
  margin: 0 0 14px;
  font-size: clamp(28px, 4vw, 46px);
  color: #fbbf24;
}

.hero-content p {
  max-width: 680px;
  margin: 0 0 24px;
  color: #e5e7eb;
  font-size: clamp(16px, 2vw, 20px);
  text-shadow: 0 6px 20px rgba(0, 0, 0, 0.48);
}

.eyebrow {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 16px;
  padding: 7px 12px;
  border: 1px solid rgba(245, 158, 11, 0.36);
  border-radius: 999px;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.14);
  font-size: 14px;
  font-weight: 700;
}

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

.hero-tags {
  margin-bottom: 28px;
}

.hero-tags span,
.tag-row span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #f3f4f6;
  background: rgba(51, 78, 104, 0.82);
  border: 1px solid rgba(75, 100, 130, 0.72);
  font-size: 13px;
}

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

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

.btn-primary {
  color: #ffffff;
  background: #f59e0b;
  box-shadow: 0 0 20px rgba(251, 191, 36, 0.22);
}

.btn-primary:hover {
  transform: translateY(-2px);
  background: #d97706;
  box-shadow: 0 0 28px rgba(251, 191, 36, 0.34);
}

.btn-secondary {
  color: #f3f4f6;
  background: #334e68;
}

.btn-secondary:hover {
  transform: translateY(-2px);
  background: #486581;
}

.btn-ghost {
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
  background: rgba(16, 42, 67, 0.26);
}

.btn-ghost:hover {
  transform: translateY(-2px);
  background: rgba(245, 158, 11, 0.13);
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(209, 213, 219, 0.78);
  transition: width 0.3s ease, background 0.3s ease;
}

.hero-dot.active {
  width: 36px;
  background: #f59e0b;
}

.hero-preview {
  position: absolute;
  right: max(24px, calc((100vw - 1280px) / 2 + 24px));
  bottom: 88px;
  z-index: 3;
  width: min(420px, 38vw);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.mini-card {
  display: grid;
  grid-template-columns: 66px 1fr;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border: 1px solid rgba(75, 100, 130, 0.72);
  border-radius: 14px;
  background: rgba(36, 59, 83, 0.78);
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px -5px rgba(16, 42, 67, 0.5);
}

.mini-card img {
  width: 66px;
  height: 86px;
  border-radius: 10px;
  object-fit: cover;
}

.mini-card span {
  display: -webkit-box;
  overflow: hidden;
  color: #f8fafc;
  font-weight: 700;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.animate-fade-in {
  animation: fadeIn 0.6s ease-in-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.content-section,
.page-main {
  max-width: 1280px;
  margin: 0 auto;
}

.content-section {
  padding: 64px 24px;
}

.page-main {
  padding: 28px 24px 64px;
}

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

.section-heading h2 {
  margin: 0;
  color: #f8fafc;
  font-size: clamp(26px, 3vw, 40px);
}

.section-heading p {
  max-width: 620px;
  margin: 8px 0 0;
  color: #9ca3af;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 16px;
  background: rgba(36, 59, 83, 0.82);
  box-shadow: 0 10px 30px -5px rgba(16, 42, 67, 0.5);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(245, 158, 11, 0.56);
  box-shadow: 0 20px 42px -12px rgba(0, 0, 0, 0.52);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0b1f33;
}

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

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

.poster-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 4px 9px;
  border-radius: 999px;
  color: #111827;
  background: rgba(245, 158, 11, 0.92);
  font-size: 12px;
  font-weight: 900;
}

.poster-play {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(245, 158, 11, 0.92);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.35);
}

.card-body {
  padding: 15px;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  color: #9ca3af;
  font-size: 13px;
}

.card-body h3 {
  margin: 0 0 8px;
  color: #f8fafc;
  font-size: 17px;
  line-height: 1.35;
}

.card-body h3 a:hover {
  color: #f59e0b;
}

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

.tag-row {
  gap: 6px;
}

.tag-row span {
  min-height: 24px;
  padding: 3px 8px;
  font-size: 12px;
}

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

.category-tile,
.category-overview-card {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 18px;
  padding: 18px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 18px;
  background: rgba(36, 59, 83, 0.72);
  box-shadow: 0 10px 30px -5px rgba(16, 42, 67, 0.5);
}

.category-cover,
.category-hero-link {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
}

.category-cover img,
.category-hero-link img {
  width: 100%;
  height: 210px;
  object-fit: cover;
}

.category-tile h3,
.category-overview-card h3 {
  margin: 0 0 8px;
  color: #ffffff;
  font-size: 24px;
}

.category-tile p,
.category-overview-card p {
  margin: 0 0 14px;
  color: #cbd5e1;
}

.category-sample,
.category-links,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.category-sample a,
.category-links a,
.footer-links a {
  color: #fbbf24;
  font-size: 14px;
}

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

.category-hero-link span {
  position: absolute;
  left: 16px;
  bottom: 16px;
  padding: 6px 12px;
  border-radius: 999px;
  color: #111827;
  background: #f59e0b;
  font-weight: 900;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

.ranking-panel,
.side-card,
.detail-card {
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 18px;
  background: rgba(36, 59, 83, 0.82);
  box-shadow: 0 10px 30px -5px rgba(16, 42, 67, 0.5);
}

.ranking-panel {
  position: sticky;
  top: 92px;
  padding: 22px;
}

.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.panel-title h2 {
  margin: 0;
}

.panel-title a {
  color: #fbbf24;
  font-size: 14px;
}

.rank-list,
.ranking-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rank-list li + li {
  margin-top: 10px;
}

.rank-list a {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 8px 12px;
  align-items: center;
  padding: 10px;
  border-radius: 12px;
  background: rgba(51, 78, 104, 0.58);
}

.rank-no {
  color: #f59e0b;
  font-weight: 900;
  font-style: normal;
}

.rank-title {
  color: #f8fafc;
  font-weight: 800;
}

.rank-meta {
  grid-column: 2;
  color: #9ca3af;
  font-size: 13px;
}

.page-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin: 24px 0 32px;
  padding: 38px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(41, 32, 61, 0.9), rgba(64, 54, 92, 0.78), rgba(90, 77, 126, 0.55)),
    #243b53;
  box-shadow: 0 10px 30px -5px rgba(16, 42, 67, 0.5);
}

.page-hero h1 {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.1;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: #d1d5db;
  font-size: 17px;
}

.filter-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
  padding: 16px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 16px;
  background: rgba(36, 59, 83, 0.72);
}

.filter-panel input,
.filter-panel select {
  min-height: 44px;
  border: 1px solid rgba(75, 100, 130, 0.9);
  border-radius: 12px;
  outline: 0;
  padding: 10px 12px;
  color: #f3f4f6;
  background: #334e68;
}

.filter-panel input {
  flex: 1 1 260px;
}

.filter-panel select {
  flex: 0 0 170px;
}

.movie-card.hidden,
.ranking-row.hidden {
  display: none;
}

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

.ranking-row a {
  display: grid;
  grid-template-columns: 54px 70px minmax(0, 1fr) minmax(180px, auto);
  gap: 14px;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 16px;
  background: rgba(36, 59, 83, 0.74);
}

.ranking-row img {
  width: 70px;
  height: 92px;
  border-radius: 10px;
  object-fit: cover;
}

.ranking-row strong {
  color: #f8fafc;
  font-size: 17px;
}

.ranking-row em {
  color: #9ca3af;
  font-size: 14px;
  font-style: normal;
  text-align: right;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 0 0 24px;
  color: #9ca3af;
  font-size: 14px;
}

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

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

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  background: #000000;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.52);
}

.movie-player {
  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: linear-gradient(to top, rgba(0, 0, 0, 0.68), rgba(0, 0, 0, 0.26));
  cursor: pointer;
}

.play-overlay span {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.94);
  font-size: 36px;
  box-shadow: 0 0 32px rgba(245, 158, 11, 0.35);
}

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

.player-shell.is-playing .play-overlay {
  display: none;
}

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

.detail-card h1 {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.18;
}

.one-line {
  margin: 0 0 20px;
  color: #fbbf24;
  font-size: 18px;
  font-weight: 700;
}

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

.detail-tags {
  margin-bottom: 24px;
}

.detail-section + .detail-section {
  margin-top: 24px;
}

.detail-section h2,
.side-card h2 {
  margin: 0 0 12px;
  color: #f8fafc;
}

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

.detail-side {
  position: sticky;
  top: 92px;
}

.detail-poster {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 18px;
  box-shadow: 0 20px 42px -12px rgba(0, 0, 0, 0.5);
}

.side-card {
  margin-top: 18px;
  padding: 20px;
}

.side-card dl {
  margin: 0;
}

.side-card div {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(51, 78, 104, 0.8);
}

.side-card div:last-child {
  border-bottom: 0;
}

.side-card dt {
  color: #9ca3af;
}

.side-card dd {
  margin: 0;
  color: #f8fafc;
  text-align: right;
}

.side-card a {
  color: #fbbf24;
}

.next-links {
  display: grid;
  gap: 10px;
}

.next-links a {
  display: block;
  padding: 10px;
  border-radius: 10px;
  background: rgba(51, 78, 104, 0.58);
}

.site-footer {
  margin-top: 40px;
  border-top: 1px solid rgba(51, 78, 104, 0.9);
  background: rgba(16, 42, 67, 0.96);
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 36px 24px;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-brand {
  display: inline-flex;
  margin-bottom: 10px;
  color: #ffffff;
  font-size: 22px;
  font-weight: 900;
}

.site-footer p {
  max-width: 620px;
  margin: 0;
  color: #9ca3af;
}

.footer-links {
  max-width: 460px;
  justify-content: flex-end;
}

@media (max-width: 1180px) {
  .movie-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .hero-content {
    transform: none;
    max-width: 1280px;
  }

  .hero-preview {
    display: none;
  }

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

  .ranking-panel,
  .detail-side {
    position: static;
  }
}

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

  .mobile-toggle {
    display: block;
  }

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

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

  .page-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-inner {
    flex-direction: column;
  }

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

@media (max-width: 640px) {
  .header-inner,
  .content-section,
  .page-main {
    padding-left: 16px;
    padding-right: 16px;
  }

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

  .hero-section,
  .hero-content {
    min-height: 78vh;
  }

  .hero-content {
    padding: 84px 16px 112px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

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

  .category-tile {
    grid-template-columns: 1fr;
  }

  .category-cover img {
    height: 220px;
  }

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

  .filter-panel select {
    flex: 1 1 100%;
  }

  .ranking-row a {
    grid-template-columns: 42px 58px 1fr;
  }

  .ranking-row img {
    width: 58px;
    height: 78px;
  }

  .ranking-row em {
    grid-column: 3;
    text-align: left;
  }

  .detail-card,
  .page-hero {
    padding: 22px;
  }
}
