:root {
  color-scheme: dark;
  --bg: #111827;
  --bg-soft: #1f2937;
  --bg-card: rgba(31, 41, 55, 0.74);
  --line: rgba(255, 255, 255, 0.1);
  --text: #f3f4f6;
  --muted: #9ca3af;
  --soft: #d1d5db;
  --sunset: #d97706;
  --sunset-light: #f59e0b;
  --twilight: #f97316;
  --twilight-deep: #9a3412;
  --radius: 1.25rem;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(217, 119, 6, 0.22), transparent 34rem),
    radial-gradient(circle at 85% 18%, rgba(249, 115, 22, 0.18), transparent 30rem),
    linear-gradient(180deg, #0b1120 0%, #111827 48%, #0f172a 100%);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.75), transparent 72%);
}

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

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

button,
input,
select {
  font: inherit;
}

.container {
  width: min(1200px, calc(100% - 2rem));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(17, 24, 39, 0.92);
  backdrop-filter: blur(16px);
}

.nav-wrap {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.brand-icon {
  width: 2.4rem;
  height: 2.4rem;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  color: #111827;
  background: linear-gradient(135deg, var(--sunset-light), var(--twilight));
  box-shadow: 0 0 24px rgba(245, 158, 11, 0.35);
}

.brand-text {
  display: grid;
  gap: 0.05rem;
}

.brand-text strong,
.footer-logo {
  font-size: 1.25rem;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, #f59e0b, #fb923c, #fbbf24);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text small {
  color: var(--muted);
  font-size: 0.75rem;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.main-nav a {
  padding: 0.65rem 1rem;
  border-radius: 999px;
  color: var(--soft);
  transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.main-nav a:hover,
.main-nav a.active {
  color: #fff;
  background: rgba(217, 119, 6, 0.18);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 2.7rem;
  height: 2.7rem;
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.nav-toggle span {
  display: block;
  width: 1.2rem;
  height: 2px;
  margin: 5px auto;
  border-radius: 999px;
  background: #fff;
}

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

.hero-slider {
  position: relative;
  min-height: 70vh;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  background-color: #111827;
  background-position: center;
  background-size: cover;
  transition: opacity 1s ease;
}

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

.hero-slide::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 38%;
  background: linear-gradient(0deg, #111827 0%, rgba(17, 24, 39, 0));
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 70vh;
  display: flex;
  align-items: flex-end;
  padding: 7rem 0 5rem;
}

.hero-copy {
  width: min(680px, 100%);
}

.eyebrow {
  margin: 0 0 0.4rem;
  color: #fbbf24;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(2.4rem, 8vw, 5.8rem);
  line-height: 0.95;
  font-weight: 900;
  letter-spacing: -0.06em;
}

.hero-copy p,
.page-hero p,
.detail-copy p {
  color: var(--soft);
  font-size: clamp(1rem, 2.6vw, 1.25rem);
}

.hero-tags,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: 1.1rem 0 1.35rem;
}

.hero-tags span,
.detail-tags span,
.tag-list span {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 999px;
  color: #fde68a;
  background: rgba(217, 119, 6, 0.12);
}

.hero-tags span,
.detail-tags span {
  padding: 0.36rem 0.78rem;
}

.hero-actions,
.form-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
}

.btn-primary,
.btn-secondary,
.section-link,
.rank-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.btn-primary,
.rank-action {
  padding: 0.85rem 1.35rem;
  color: #fff;
  background: linear-gradient(90deg, var(--sunset), var(--twilight));
  box-shadow: 0 14px 35px rgba(217, 119, 6, 0.28);
}

.btn-secondary,
.section-link {
  padding: 0.8rem 1.15rem;
  color: #fff;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.08);
}

.btn-primary:hover,
.btn-secondary:hover,
.section-link:hover,
.rank-action:hover {
  transform: translateY(-2px);
}

.hero-search {
  width: min(620px, 100%);
  margin-top: 1.35rem;
  padding: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  display: flex;
  gap: 0.5rem;
  background: rgba(17, 24, 39, 0.76);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0.78rem 1rem;
  color: #fff;
  background: transparent;
}

.hero-search button {
  border: 0;
  padding: 0.78rem 1.2rem;
  border-radius: 999px;
  color: #111827;
  font-weight: 900;
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 3rem;
  height: 3rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.42);
  transform: translateY(-50%);
}

.hero-control.prev {
  left: 1.3rem;
}

.hero-control.next {
  right: 1.3rem;
}

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

.hero-dot {
  width: 2rem;
  height: 0.28rem;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
}

.hero-dot.active {
  background: linear-gradient(90deg, var(--sunset-light), var(--twilight));
}

.section {
  padding: 4.5rem 0;
}

.section-tight {
  padding: 2.5rem 0;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.4rem;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

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

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

.movie-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-card);
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.18);
  transition: transform 0.28s ease, border-color 0.28s ease, box-shadow 0.28s ease;
}

.movie-card:hover {
  border-color: rgba(245, 158, 11, 0.42);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  transform: translateY(-5px);
}

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

.poster-frame,
.rank-cover,
.detail-cover,
.category-card::before {
  background-color: #1f2937;
  background-position: center;
  background-size: cover;
}

.poster-frame {
  position: absolute;
  inset: 0;
  transition: transform 0.45s ease;
}

.movie-card:hover .poster-frame {
  transform: scale(1.05);
}

.poster-glow {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0) 32%, rgba(0, 0, 0, 0.78) 100%),
    radial-gradient(circle at 70% 15%, rgba(245, 158, 11, 0.22), transparent 45%);
}

.play-circle {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  width: 3.6rem;
  height: 3.6rem;
  place-items: center;
  border-radius: 999px;
  color: #111827;
  background: rgba(255, 255, 255, 0.9);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.88);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-badge,
.rank-mark {
  position: absolute;
  top: 0.8rem;
  border-radius: 999px;
  padding: 0.24rem 0.58rem;
  color: #fff;
  font-size: 0.76rem;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(8px);
}

.card-badge {
  left: 0.8rem;
}

.rank-mark {
  right: 0.8rem;
  background: linear-gradient(90deg, var(--sunset), var(--twilight));
}

.card-body {
  padding: 1rem;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.movie-meta span + span::before {
  content: "·";
  margin-right: 0.45rem;
  color: rgba(255, 255, 255, 0.28);
}

.movie-card h3,
.rank-content h3 {
  margin: 0.45rem 0 0.35rem;
  font-size: 1.05rem;
  line-height: 1.3;
}

.movie-card h3 a:hover,
.rank-content h3 a:hover,
.article-copy a:hover {
  color: #fbbf24;
}

.movie-card p,
.rank-content p,
.category-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.8rem;
}

.tag-list span {
  padding: 0.18rem 0.5rem;
  font-size: 0.75rem;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 12rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: linear-gradient(135deg, rgba(31, 41, 55, 0.92), rgba(154, 52, 18, 0.22));
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-card::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.35;
  transform: scale(1.02);
}

.category-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(17, 24, 39, 0.92));
}

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

.category-card h3,
.category-card p,
.category-card span {
  position: relative;
  z-index: 2;
}

.category-card h3 {
  margin: 0 0 0.3rem;
  font-size: 1.3rem;
}

.category-card span {
  width: fit-content;
  margin-top: 0.85rem;
  border-radius: 999px;
  padding: 0.35rem 0.65rem;
  color: #111827;
  font-size: 0.8rem;
  font-weight: 900;
  background: #fbbf24;
}

.page-hero {
  padding: 7rem 0 3rem;
  background:
    radial-gradient(circle at 20% 20%, rgba(245, 158, 11, 0.2), transparent 26rem),
    linear-gradient(180deg, rgba(17, 24, 39, 0.36), rgba(17, 24, 39, 0));
}

.page-hero .hero-tags {
  margin-bottom: 0;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr repeat(3, minmax(150px, 190px));
  gap: 0.8rem;
  margin-bottom: 1.4rem;
  padding: 0.85rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(31, 41, 55, 0.66);
  backdrop-filter: blur(16px);
}

.search-box {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  border-radius: 999px;
  padding: 0 1rem;
  background: rgba(17, 24, 39, 0.9);
}

.search-box span {
  color: #fbbf24;
  font-weight: 800;
}

.search-box input,
.filter-select {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  outline: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(17, 24, 39, 0.88);
}

.search-box input {
  border: 0;
  padding: 0.75rem 0;
  background: transparent;
}

.filter-select {
  padding: 0.75rem 0.9rem;
}

.empty-state {
  display: none;
  margin: 2rem 0;
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  text-align: center;
  background: rgba(31, 41, 55, 0.66);
}

.rank-list {
  display: grid;
  gap: 0.85rem;
}

.rank-item {
  display: grid;
  grid-template-columns: 86px 58px 1fr auto;
  align-items: center;
  gap: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.7rem;
  background: rgba(31, 41, 55, 0.66);
}

.rank-cover {
  aspect-ratio: 2 / 3;
  border-radius: 0.8rem;
}

.rank-number {
  font-size: 1.5rem;
  font-weight: 900;
  color: #fbbf24;
  text-align: center;
}

.rank-content h3 {
  font-size: 1.08rem;
}

.detail-hero {
  padding: 5.5rem 0 3rem;
  background-color: #111827;
  background-position: center;
  background-size: cover;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: 2rem;
  align-items: end;
}

.detail-cover {
  min-height: 460px;
  border: 1px solid var(--line);
  border-radius: 1.5rem;
  box-shadow: var(--shadow);
}

.detail-copy .breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.detail-copy .breadcrumb a {
  color: #fbbf24;
}

.player-section {
  padding-top: 1.8rem;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.26);
  border-radius: 1.5rem;
  background: #000;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  color: #fff;
  background:
    radial-gradient(circle at center, rgba(249, 115, 22, 0.16), transparent 28rem),
    rgba(0, 0, 0, 0.46);
  cursor: pointer;
}

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

.play-panel {
  display: grid;
  justify-items: center;
  gap: 0.75rem;
  text-align: center;
}

.play-button {
  width: 5rem;
  height: 5rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #111827;
  font-size: 1.9rem;
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
  box-shadow: 0 16px 48px rgba(245, 158, 11, 0.32);
}

.play-title {
  font-weight: 900;
  letter-spacing: 0.02em;
}

.article-copy {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 2rem;
  align-items: start;
}

.prose-card,
.side-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem;
  background: rgba(31, 41, 55, 0.66);
}

.prose-card h2,
.side-card h2 {
  margin: 0 0 1rem;
  font-size: 1.45rem;
}

.prose-card p {
  margin: 0 0 1rem;
  color: var(--soft);
}

.detail-list {
  display: grid;
  gap: 0.65rem;
  color: var(--soft);
}

.detail-list div {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 0.7rem;
}

.detail-list strong {
  color: #fbbf24;
}

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

.site-footer {
  margin-top: 4rem;
  border-top: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.82);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 2rem;
  padding: 3rem 0;
}

.footer-grid p {
  max-width: 34rem;
  color: var(--muted);
}

.footer-grid h3 {
  margin: 0 0 1rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.footer-links a {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.45rem 0.75rem;
  color: var(--soft);
  background: rgba(255, 255, 255, 0.04);
}

.footer-bottom {
  border-top: 1px solid var(--line);
  padding: 1rem;
  color: var(--muted);
  text-align: center;
}

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

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

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

  .article-copy {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(100% - 1rem, 1200px);
  }

  .nav-toggle {
    display: block;
  }

  .main-nav {
    position: absolute;
    left: 0.5rem;
    right: 0.5rem;
    top: calc(100% + 0.5rem);
    display: none;
    flex-direction: column;
    align-items: stretch;
    border: 1px solid var(--line);
    border-radius: 1rem;
    padding: 0.5rem;
    background: rgba(17, 24, 39, 0.98);
  }

  .main-nav.open {
    display: flex;
  }

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

  .hero-control {
    display: none;
  }

  .hero-search {
    border-radius: 1.2rem;
    flex-direction: column;
  }

  .hero-search button {
    width: 100%;
  }

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

  .movie-grid,
  .movie-grid-wide,
  .category-grid,
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
  }

  .card-body {
    padding: 0.85rem;
  }

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

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

  .rank-action {
    grid-column: 3;
    justify-self: start;
    padding: 0.55rem 0.95rem;
  }

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

  .detail-cover {
    min-height: 420px;
  }

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

@media (max-width: 480px) {
  .movie-grid,
  .movie-grid-wide,
  .category-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .brand-text small {
    display: none;
  }

  .detail-cover {
    min-height: 360px;
  }
}
