:root {
  color-scheme: dark;
  --bg: #0f172a;
  --bg-deep: #020617;
  --panel: rgba(30, 41, 59, 0.74);
  --panel-strong: #1e293b;
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --accent: #f59e0b;
  --accent-dark: #d97706;
  --shadow: 0 24px 80px rgba(2, 6, 23, 0.42);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at top left, rgba(245, 158, 11, 0.15), transparent 32rem), linear-gradient(180deg, #0f172a 0%, #020617 100%);
  color: var(--text);
}

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: 80;
  background: rgba(15, 23, 42, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

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

.brand, .footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #f97316);
  color: white;
  box-shadow: 0 8px 30px rgba(245, 158, 11, 0.36);
  font-size: 14px;
}

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

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

.nav-link {
  color: #cbd5e1;
  font-weight: 700;
  font-size: 15px;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover, .nav-link.active {
  color: var(--accent);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(30, 41, 59, 0.82);
  color: var(--text);
  cursor: pointer;
}

.hero {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  background: #0f172a;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}

.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 180px;
  background: linear-gradient(0deg, var(--bg), transparent);
}

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

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1, .page-hero h1, .detail-copy h1 {
  margin: 0;
  color: white;
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero h1 {
  max-width: 840px;
  font-size: clamp(42px, 7vw, 84px);
}

.hero h2 {
  margin: 22px 0 16px;
  font-size: clamp(26px, 4vw, 48px);
  color: white;
}

.hero-text {
  max-width: 760px;
  margin: 0;
  color: #e5e7eb;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.8;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px) scale(1.02);
}

.btn.primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 14px 32px rgba(245, 158, 11, 0.34);
}

.btn.primary:hover {
  background: var(--accent-dark);
}

.btn.ghost {
  border: 1px solid rgba(248, 250, 252, 0.28);
  background: rgba(15, 23, 42, 0.42);
  color: white;
}

.btn.plain {
  color: #fcd34d;
}

.hero-thumbs {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 5;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.hero-thumb {
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  min-height: 92px;
  padding: 0;
  background: rgba(15, 23, 42, 0.72);
  color: white;
  cursor: pointer;
  display: grid;
  grid-template-columns: 70px 1fr;
  align-items: center;
  text-align: left;
  backdrop-filter: blur(12px);
  opacity: 0.76;
  transition: border-color 0.2s ease, opacity 0.2s ease, transform 0.2s ease;
}

.hero-thumb:hover, .hero-thumb.is-active {
  opacity: 1;
  border-color: rgba(245, 158, 11, 0.75);
  transform: translateY(-2px);
}

.hero-thumb img {
  width: 70px;
  height: 92px;
  object-fit: cover;
}

.hero-thumb span {
  padding: 10px;
  font-weight: 800;
  line-height: 1.35;
}

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

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

.section-head.centered {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  display: block;
}

.section-head h2 {
  margin: 0 0 10px;
  color: white;
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.04em;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.more-link {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  color: var(--accent);
  font-weight: 800;
}

.filter-panel {
  margin: 0 auto 32px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.76);
  box-shadow: var(--shadow);
}

.search-box {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 240px;
  color: var(--accent);
  font-weight: 800;
}

.search-input, .filter-select {
  width: 100%;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.58);
  color: var(--text);
  outline: none;
}

.search-input {
  padding: 0 16px;
}

.filter-selects {
  display: flex;
  gap: 12px;
}

.filter-select {
  min-width: 130px;
  padding: 0 14px;
}

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

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

.movie-card {
  display: block;
  border-radius: 22px;
  overflow: hidden;
  background: rgba(30, 41, 59, 0.76);
  box-shadow: 0 14px 42px rgba(2, 6, 23, 0.28);
  transition: transform 0.26s ease, box-shadow 0.26s ease, background 0.26s ease;
}

.movie-card:hover {
  transform: translateY(-6px) scale(1.02);
  background: rgba(30, 41, 59, 0.96);
  box-shadow: 0 24px 70px rgba(2, 6, 23, 0.44);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(145deg, #1e293b, #0f172a);
}

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

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

.poster-wrap::after {
  content: "";
  position: absolute;
  inset: 45% 0 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.88), transparent);
}

.year-badge, .play-badge {
  position: absolute;
  z-index: 2;
}

.year-badge {
  top: 10px;
  right: 10px;
  padding: 5px 9px;
  border-radius: 9px;
  background: var(--accent);
  color: white;
  font-size: 12px;
  font-weight: 900;
}

.play-badge {
  left: 50%;
  top: 50%;
  width: 52px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.92);
  color: white;
  transform: translate(-50%, -50%) scale(0.82);
  opacity: 0;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

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

.movie-card-body {
  display: block;
  padding: 16px;
}

.movie-card-body strong {
  display: block;
  color: white;
  font-size: 16px;
  line-height: 1.45;
  min-height: 46px;
}

.movie-card:hover strong {
  color: #fbbf24;
}

.movie-card-line, .movie-card-meta {
  display: block;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.movie-card-line {
  margin: 8px 0;
}

.highlight-band, .category-strip:nth-of-type(even) {
  width: 100%;
  max-width: none;
  padding-left: max(16px, calc((100% - 1180px) / 2));
  padding-right: max(16px, calc((100% - 1180px) / 2));
  background: rgba(15, 23, 42, 0.42);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 58px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(30, 41, 59, 0.64);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.rank-row:hover {
  transform: translateX(4px);
  border-color: rgba(245, 158, 11, 0.7);
}

.rank-row span {
  color: var(--accent);
  font-size: 22px;
  font-weight: 900;
}

.rank-row strong {
  color: white;
}

.rank-row em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 86px 0 34px;
}

.small-hero h1 {
  max-width: 880px;
  font-size: clamp(36px, 5vw, 62px);
}

.small-hero p:not(.eyebrow) {
  max-width: 780px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.8;
}

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

.category-card {
  min-height: 210px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: end;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 26px;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow);
  transition: transform 0.24s ease, border-color 0.24s ease;
}

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

.category-card span {
  color: #fcd34d;
  font-weight: 900;
  font-size: 22px;
}

.category-card strong {
  color: white;
  line-height: 1.65;
}

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

.rank-card {
  display: grid;
  grid-template-rows: auto auto auto auto 1fr;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(30, 41, 59, 0.74);
  transition: transform 0.24s ease, border-color 0.24s ease;
}

.rank-card:hover {
  transform: translateY(-5px);
  border-color: rgba(245, 158, 11, 0.68);
}

.rank-card span {
  color: var(--accent);
  font-size: 24px;
  font-weight: 900;
}

.rank-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 18px;
  background: linear-gradient(145deg, #1e293b, #020617);
}

.rank-card strong {
  color: white;
  font-size: 18px;
}

.rank-card em, .rank-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
  font-style: normal;
  font-size: 13px;
}

.detail-hero {
  min-height: 620px;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--line);
}

.detail-layout {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 70px 0;
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 42px;
  align-items: center;
}

.detail-cover {
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: linear-gradient(145deg, #1e293b, #020617);
}

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

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 700;
}

.breadcrumb a:hover {
  color: var(--accent);
}

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

.lead {
  max-width: 840px;
  color: #e5e7eb;
  font-size: 20px;
  line-height: 1.8;
}

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

.meta-tags span, .tag-cloud span {
  padding: 8px 12px;
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.1);
  color: #fcd34d;
  font-weight: 800;
  font-size: 13px;
}

.player-section {
  padding-top: 86px;
}

.player-frame {
  position: relative;
  width: min(960px, 100%);
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  border-radius: 28px;
  overflow: hidden;
  background: #020617;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.movie-player {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #020617;
  cursor: pointer;
}

.player-start {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 50%;
  width: 86px;
  height: 86px;
  transform: translate(-50%, -50%);
  border: 0;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.94);
  color: white;
  cursor: pointer;
  box-shadow: 0 22px 52px rgba(245, 158, 11, 0.36);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.player-start span {
  display: inline-block;
  transform: translateX(3px);
  font-size: 32px;
}

.player-start:hover {
  transform: translate(-50%, -50%) scale(1.06);
}

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

.detail-content {
  padding-top: 30px;
}

.content-card {
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(30, 41, 59, 0.7);
  box-shadow: var(--shadow);
}

.content-card h2 {
  margin: 0 0 14px;
  color: white;
  font-size: 28px;
}

.content-card p {
  margin: 0 0 28px;
  color: #cbd5e1;
  line-height: 1.95;
  font-size: 17px;
}

.site-footer {
  margin-top: 70px;
  background: #020617;
  border-top: 1px solid var(--line);
}

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

.footer-inner p {
  max-width: 520px;
  color: var(--muted);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: end;
  align-content: start;
  gap: 16px 22px;
}

.footer-links a {
  color: var(--muted);
  font-weight: 700;
}

.footer-links a:hover {
  color: var(--accent);
}

.copyright {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 34px;
  border-top: 1px solid var(--line);
  color: #64748b;
  text-align: center;
}

.is-filtered-out {
  display: none !important;
}

@media (max-width: 1080px) {
  .movie-grid, .rank-grid, .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

  .hero-thumb:nth-child(n+4) {
    display: none;
  }

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

@media (max-width: 820px) {
  .site-nav {
    height: auto;
    min-height: 64px;
    flex-wrap: wrap;
    padding: 10px 0;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 10px 0 6px;
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-link {
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.52);
  }

  .hero {
    min-height: 760px;
  }

  .hero-content {
    padding-top: 74px;
  }

  .hero-thumbs {
    grid-template-columns: 1fr;
  }

  .hero-thumb:nth-child(n+3) {
    display: none;
  }

  .filter-panel {
    align-items: stretch;
    flex-direction: column;
  }

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

  .section-head, .footer-inner, .detail-layout {
    display: block;
  }

  .detail-cover {
    max-width: 260px;
    margin-bottom: 28px;
  }

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

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

  .rank-row em {
    grid-column: 2;
  }

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

@media (max-width: 620px) {
  .movie-grid, .compact-grid, .wide-grid, .rank-grid, .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .section {
    padding: 52px 0;
  }

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

  .movie-card-body strong {
    font-size: 14px;
    min-height: 42px;
  }

  .detail-hero {
    min-height: auto;
  }

  .player-start {
    width: 68px;
    height: 68px;
  }
}
