* {
  box-sizing: border-box;
}

:root {
  color-scheme: dark;
  --bg: #0c0a09;
  --panel: #1c1917;
  --panel-soft: #292524;
  --panel-line: #44403c;
  --text: #fafaf9;
  --muted: #a8a29e;
  --faint: #78716c;
  --accent: #f59e0b;
  --accent-light: #fbbf24;
  --accent-deep: #92400e;
  --danger: #ef4444;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.46);
  --radius: 18px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: radial-gradient(circle at 20% 0%, rgba(146, 64, 14, 0.20), transparent 32%), var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(28, 25, 23, 0.94);
  border-bottom: 1px solid rgba(68, 64, 60, 0.85);
  backdrop-filter: blur(14px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--accent-light);
  font-weight: 800;
  letter-spacing: 0.03em;
}

.brand-mark {
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent-light), var(--accent-deep));
  color: #1c1917;
  font-size: 13px;
  box-shadow: 0 10px 28px rgba(245, 158, 11, 0.32);
}

.brand-name {
  font-size: 21px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link,
.mobile-nav-link,
.footer-links a,
.breadcrumb a {
  color: var(--muted);
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active,
.footer-links a:hover,
.breadcrumb a:hover {
  color: var(--accent-light);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--panel-soft);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: var(--text);
  border-radius: 99px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border: 1px solid var(--panel-line);
  border-radius: 16px;
  background: rgba(12, 10, 9, 0.92);
}

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

.mobile-nav-link {
  padding: 10px 12px;
  border-radius: 12px;
}

.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  background: rgba(245, 158, 11, 0.10);
}

.page-main {
  padding-top: 64px;
}

.hero {
  position: relative;
  min-height: 600px;
  overflow: hidden;
  background: var(--panel);
}

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

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

.hero-slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, #0c0a09 0%, rgba(12, 10, 9, 0.55) 48%, rgba(12, 10, 9, 0.08) 100%),
    linear-gradient(to right, rgba(12, 10, 9, 0.92), rgba(12, 10, 9, 0.48), transparent 70%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: 600px;
  margin: 0 auto;
  display: flex;
  align-items: center;
}

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

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-light);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 18px 0 18px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.06em;
  text-shadow: 0 16px 36px rgba(0, 0, 0, 0.55);
}

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

.hero-meta,
.detail-meta,
.movie-meta-row,
.rank-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: 14px;
}

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

.btn,
.btn-ghost,
.btn-small,
.category-card,
.filter-panel input,
.filter-panel select {
  border-radius: 14px;
}

.btn,
.btn-small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  color: #1c1917;
  font-weight: 800;
  box-shadow: 0 16px 36px rgba(245, 158, 11, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn {
  padding: 13px 20px;
}

.btn-small {
  padding: 9px 13px;
  font-size: 14px;
}

.btn:hover,
.btn-small:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 44px rgba(245, 158, 11, 0.38);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(245, 158, 11, 0.42);
  background: rgba(28, 25, 23, 0.74);
  color: var(--text);
  padding: 12px 18px;
  font-weight: 700;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.btn-ghost:hover {
  background: rgba(245, 158, 11, 0.12);
  border-color: var(--accent-light);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 46px;
  height: 46px;
  transform: translateY(-50%);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(28, 25, 23, 0.72);
  color: var(--text);
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-control:hover {
  background: rgba(245, 158, 11, 0.82);
  color: #1c1917;
}

.hero-prev {
  left: max(18px, calc((100vw - 1180px) / 2 - 72px));
}

.hero-next {
  right: max(18px, calc((100vw - 1180px) / 2 - 72px));
}

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

.hero-dot {
  width: 34px;
  height: 4px;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--accent-light);
}

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

.content-section,
.listing-hero,
.detail-layout,
.search-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.content-section {
  padding: 54px 0 0;
}

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

.section-heading h2,
.listing-hero h1,
.search-hero h1,
.detail-title h1 {
  margin: 0;
  letter-spacing: -0.03em;
}

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

.section-heading p,
.listing-hero p,
.search-hero p,
.detail-lead,
.footer-inner p {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-more {
  color: var(--accent-light);
  font-weight: 700;
}

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

.movie-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(68, 64, 60, 0.70);
  border-radius: var(--radius);
  background: rgba(28, 25, 23, 0.86);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.18);
  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.55);
  box-shadow: var(--shadow);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #292524, #0c0a09);
}

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

.movie-card:hover .poster-link img,
.related-card:hover img,
.mini-movie:hover img {
  transform: scale(1.06);
}

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(12, 10, 9, 0.82), transparent 55%);
  opacity: 0.88;
}

.poster-play {
  position: absolute;
  left: 12px;
  bottom: 12px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.92);
  color: #1c1917;
  font-size: 13px;
  font-weight: 900;
}

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  min-width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(245, 158, 11, 0.96);
  color: #1c1917;
  font-weight: 900;
}

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

.movie-card h3 {
  min-height: 3em;
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.35;
}

.movie-card h3 a {
  transition: color 0.2s ease;
}

.movie-card:hover h3 a {
  color: var(--accent-light);
}

.movie-card-line {
  display: -webkit-box;
  min-height: 3.25em;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.movie-meta-row {
  justify-content: space-between;
  font-size: 12px;
}

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

.category-card {
  display: block;
  min-height: 152px;
  padding: 20px;
  border: 1px solid rgba(68, 64, 60, 0.76);
  background:
    radial-gradient(circle at right top, rgba(245, 158, 11, 0.18), transparent 40%),
    rgba(28, 25, 23, 0.86);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(245, 158, 11, 0.55);
}

.category-card h3 {
  margin: 0 0 10px;
  color: var(--accent-light);
  font-size: 21px;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 54px 78px 1fr;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(68, 64, 60, 0.72);
  border-radius: 18px;
  background: rgba(28, 25, 23, 0.82);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.rank-item:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 158, 11, 0.55);
}

.rank-number {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 13px;
  background: rgba(245, 158, 11, 0.16);
  color: var(--accent-light);
  font-size: 20px;
  font-weight: 900;
}

.rank-item img {
  width: 78px;
  height: 112px;
  object-fit: cover;
  border-radius: 12px;
  background: var(--panel-soft);
}

.rank-item h3 {
  margin: 0 0 6px;
  font-size: 18px;
}

.rank-item p {
  display: -webkit-box;
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.listing-hero,
.search-hero {
  padding: 118px 0 28px;
}

.listing-hero h1,
.search-hero h1 {
  font-size: clamp(34px, 5vw, 58px);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  color: var(--faint);
  font-size: 14px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 160px 160px;
  gap: 14px;
  padding: 16px;
  margin: 18px 0 30px;
  border: 1px solid rgba(68, 64, 60, 0.76);
  border-radius: 20px;
  background: rgba(28, 25, 23, 0.78);
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(68, 64, 60, 0.9);
  background: #0c0a09;
  color: var(--text);
  padding: 0 14px;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(245, 158, 11, 0.72);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.13);
}

.no-match {
  display: none;
  padding: 24px;
  border: 1px solid rgba(68, 64, 60, 0.74);
  border-radius: 18px;
  background: rgba(28, 25, 23, 0.78);
  color: var(--muted);
  text-align: center;
}

.no-match.is-visible {
  display: block;
}

.detail-main {
  padding: 106px 0 60px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.62fr) minmax(280px, 0.78fr);
  gap: 32px;
}

.detail-title h1 {
  margin-top: 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.05;
}

.detail-tags,
.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.detail-tags span,
.hero-tags span {
  padding: 6px 10px;
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.11);
  color: var(--accent-light);
  font-size: 13px;
}

.player-card,
.detail-panel,
.sidebar-panel {
  border: 1px solid rgba(68, 64, 60, 0.76);
  border-radius: 24px;
  background: rgba(28, 25, 23, 0.86);
  box-shadow: var(--shadow);
}

.player-card {
  overflow: hidden;
  margin: 28px 0;
}

.video-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-shell video {
  width: 100%;
  height: 100%;
  background: #000;
}

.video-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.16), rgba(0, 0, 0, 0.48) 48%, rgba(0, 0, 0, 0.72));
  color: var(--text);
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.play-ring {
  width: 88px;
  height: 88px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  color: #1c1917;
  font-size: 30px;
  font-weight: 900;
  box-shadow: 0 18px 56px rgba(245, 158, 11, 0.38);
}

.detail-panel {
  padding: 24px;
  margin-bottom: 24px;
}

.detail-panel h2,
.sidebar-panel h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.detail-panel p {
  margin: 0 0 16px;
  color: #d6d3d1;
}

.sidebar-panel {
  padding: 18px;
  margin-bottom: 20px;
}

.cover-large {
  width: 100%;
  border-radius: 20px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: var(--panel-soft);
}

.info-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 14px;
}

.info-list strong {
  color: var(--text);
}

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

.related-card {
  overflow: hidden;
  border: 1px solid rgba(68, 64, 60, 0.72);
  border-radius: 16px;
  background: rgba(12, 10, 9, 0.52);
}

.related-card img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.related-card span {
  display: block;
  padding: 10px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.35;
}

.mini-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.mini-movie {
  overflow: hidden;
  border-radius: 16px;
  background: rgba(28, 25, 23, 0.8);
}

.mini-movie img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.mini-movie span {
  display: block;
  padding: 10px;
  color: #e7e5e4;
  font-size: 13px;
}

.site-footer {
  margin-top: 70px;
  border-top: 1px solid rgba(68, 64, 60, 0.76);
  background: rgba(28, 25, 23, 0.74);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 30px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 16px 0 26px;
  color: var(--faint);
  font-size: 13px;
}

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

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

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

  .menu-toggle {
    display: block;
  }

  .hero,
  .hero-content {
    min-height: 560px;
  }

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

  .rank-list,
  .detail-layout,
  .filter-panel {
    grid-template-columns: 1fr;
  }

  .detail-layout {
    gap: 22px;
  }

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

@media (max-width: 640px) {
  .header-inner {
    width: min(100% - 22px, 1180px);
  }

  .brand-name {
    font-size: 19px;
  }

  .hero,
  .hero-content {
    min-height: 520px;
  }

  .hero-copy {
    padding-top: 38px;
  }

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

  .hero-control {
    display: none;
  }

  .section-heading,
  .footer-inner {
    display: block;
  }

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

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

  .rank-item {
    grid-template-columns: 42px 70px 1fr;
  }

  .rank-item img {
    width: 70px;
    height: 100px;
  }

  .listing-hero,
  .search-hero {
    padding-top: 100px;
  }

  .detail-main {
    padding-top: 96px;
  }

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

  .footer-links {
    margin-top: 18px;
  }
}
