:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #e5e7eb;
  --amber: #d97706;
  --amber-dark: #b45309;
  --amber-soft: #fff7ed;
  --orange-soft: #ffedd5;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 12px 30px rgba(15, 23, 42, 0.08);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 48%, #fff7ed 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.86);
  border-bottom: 1px solid rgba(229, 231, 235, 0.78);
  backdrop-filter: blur(18px);
}

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

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

.logo-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #dc2626);
  border-radius: 14px;
  box-shadow: 0 12px 26px rgba(217, 119, 6, 0.24);
}

.logo-text {
  font-size: 20px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 10px 16px;
  color: #4b5563;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--amber-dark);
  background: var(--amber-soft);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--amber-soft);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: var(--amber-dark);
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 900ms ease;
}

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

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-bg.is-missing,
.cover-img.is-missing {
  opacity: 0;
}

.hero-slide::before,
.movie-poster::before,
.detail-poster::before,
.rank-thumb::before,
.category-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 25% 25%, rgba(245, 158, 11, 0.38), transparent 34%),
    linear-gradient(135deg, #111827, #92400e 52%, #f59e0b);
}

.hero-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.05));
}

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

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: #f59e0b;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 780px;
  margin: 0 0 18px;
  font-size: clamp(42px, 6vw, 78px);
  line-height: 1.02;
  letter-spacing: -0.05em;
}

.hero p {
  max-width: 650px;
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(18px, 2vw, 24px);
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  padding: 5px 10px;
  color: #92400e;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.hero-actions,
.detail-actions,
.card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
}

.btn,
.section-more,
.card-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  cursor: pointer;
}

.btn:hover,
.section-more:hover,
.card-actions a:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  box-shadow: 0 16px 32px rgba(217, 119, 6, 0.32);
}

.btn-ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(10px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 52px;
  height: 52px;
  color: #ffffff;
  font-size: 38px;
  line-height: 1;
  background: rgba(0, 0, 0, 0.45);
  border: 0;
  border-radius: 999px;
  backdrop-filter: blur(8px);
  cursor: pointer;
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

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

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

.quick-search {
  position: relative;
  z-index: 5;
  margin-top: -46px;
  padding: 24px;
  display: grid;
  grid-template-columns: 1fr minmax(280px, 520px);
  gap: 24px;
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.quick-search h2,
.section-heading h2,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.quick-search p,
.section-heading p,
.page-hero p {
  margin: 8px 0 0;
  color: var(--muted);
}

.search-panel,
.filter-panel {
  display: flex;
  gap: 10px;
}

.search-panel input,
.filter-panel input,
.filter-panel select {
  min-height: 46px;
  width: 100%;
  padding: 0 14px;
  color: var(--text);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 12px;
  outline: none;
}

.search-panel input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.page-shell {
  padding: 64px 0;
}

.page-top {
  padding-top: 36px;
}

.content-section {
  margin-bottom: 72px;
}

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

.section-more,
.card-actions a {
  color: var(--amber-dark);
  background: var(--amber-soft);
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid rgba(229, 231, 235, 0.86);
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: #fed7aa;
  box-shadow: var(--shadow);
}

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

.movie-poster img,
.detail-poster img,
.rank-thumb img,
.category-cover img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  transition: transform 0.5s ease, opacity 0.2s ease;
}

.movie-card:hover .movie-poster img {
  transform: scale(1.08);
}

.poster-badge,
.poster-type {
  position: absolute;
  z-index: 2;
  top: 12px;
  padding: 4px 9px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.64);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.poster-badge {
  left: 12px;
}

.poster-type {
  right: 12px;
}

.play-float {
  position: absolute;
  z-index: 2;
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: rgba(217, 119, 6, 0.88);
  border-radius: 999px;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.82);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

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

.movie-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: var(--amber-dark);
}

.movie-meta,
.movie-one-line {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 14px;
}

.movie-one-line {
  display: -webkit-box;
  min-height: 44px;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.hot-panel {
  padding: 32px;
  background: linear-gradient(135deg, #fff7ed, #ffedd5);
  border-radius: 30px;
}

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

.rank-card,
.prose-card,
.player-section,
.filter-panel,
.page-hero,
.detail-hero,
.category-overview-card {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(229, 231, 235, 0.86);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.rank-card {
  position: sticky;
  top: 96px;
  padding: 24px;
}

.compact-heading {
  margin-bottom: 14px;
}

.compact-heading h2 {
  font-size: 28px;
}

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

.rank-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--line);
}

.rank-list a {
  display: flex;
  gap: 10px;
  min-width: 0;
  color: #374151;
}

.rank-list a span {
  color: var(--amber);
  font-weight: 900;
}

.rank-list strong {
  color: var(--amber-dark);
}

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

.category-tile {
  min-height: 168px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #ffffff;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.26), transparent 32%),
    linear-gradient(135deg, #111827, #92400e 54%, #f59e0b);
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.category-tile span {
  color: #fde68a;
  font-size: 12px;
  font-weight: 800;
}

.category-tile strong {
  margin: 8px 0;
  font-size: 22px;
  line-height: 1.2;
}

.category-tile em {
  color: rgba(255, 255, 255, 0.76);
  font-style: normal;
  font-size: 13px;
}

.page-hero {
  position: relative;
  overflow: hidden;
  padding: 42px;
  margin-bottom: 28px;
}

.page-hero::after {
  content: "";
  position: absolute;
  right: -80px;
  top: -80px;
  width: 240px;
  height: 240px;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.22), transparent 70%);
}

.category-hero {
  background: linear-gradient(135deg, #ffffff, #fff7ed);
}

.filter-panel {
  position: sticky;
  top: 88px;
  z-index: 10;
  margin-bottom: 28px;
  padding: 16px;
  align-items: center;
  backdrop-filter: blur(14px);
}

.filter-panel .btn-ghost {
  color: var(--amber-dark);
  background: var(--amber-soft);
  border-color: #fed7aa;
  white-space: nowrap;
}

.filter-count {
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
}

.category-overview-grid {
  display: grid;
  gap: 22px;
}

.category-overview-card {
  padding: 18px;
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 22px;
  align-items: center;
}

.category-cover {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #111827;
  border-radius: 18px;
}

.mini-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.mini-links a {
  padding: 5px 10px;
  color: #92400e;
  background: #fff7ed;
  border-radius: 999px;
  font-size: 13px;
}

.rank-table {
  display: grid;
  gap: 14px;
}

.rank-row {
  display: grid;
  grid-template-columns: 68px 96px 1fr 120px;
  gap: 18px;
  align-items: center;
  padding: 14px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow-soft);
}

.rank-number {
  color: var(--amber-dark);
  font-size: 24px;
  font-weight: 900;
  text-align: center;
}

.rank-thumb {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #111827;
  border-radius: 14px;
}

.rank-info h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.rank-info p {
  margin: 0 0 12px;
  color: var(--muted);
}

.rank-score {
  text-align: center;
}

.rank-score strong {
  display: block;
  color: var(--amber-dark);
  font-size: 34px;
  line-height: 1;
}

.rank-score span {
  color: var(--muted);
  font-size: 12px;
}

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

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

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 30px;
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 32px;
  background:
    radial-gradient(circle at 20% 20%, rgba(245, 158, 11, 0.15), transparent 38%),
    rgba(255, 255, 255, 0.92);
}

.detail-poster {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: #111827;
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.detail-info {
  align-self: center;
}

.detail-one-line {
  margin: 18px 0;
  color: #374151;
  font-size: 20px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.detail-meta span {
  padding: 7px 12px;
  color: #374151;
  background: #f3f4f6;
  border-radius: 999px;
  font-weight: 700;
}

.large-tags span {
  padding: 7px 12px;
}

.detail-actions .btn-ghost {
  color: var(--amber-dark);
  background: #fff7ed;
  border-color: #fed7aa;
}

.player-section {
  margin: 30px 0;
  padding: 24px;
}

.video-player {
  position: relative;
  overflow: hidden;
  background: #000000;
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.video-element {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.video-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.64));
  border: 0;
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.video-play-icon {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  padding-left: 5px;
  color: #ffffff;
  background: rgba(217, 119, 6, 0.94);
  border-radius: 999px;
  box-shadow: 0 20px 45px rgba(217, 119, 6, 0.38);
}

.video-status {
  position: absolute;
  left: 16px;
  bottom: 16px;
  z-index: 3;
  padding: 7px 10px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.62);
  border-radius: 999px;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
}

.video-status:not(:empty) {
  opacity: 1;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.95fr;
  gap: 24px;
  margin-bottom: 66px;
}

.prose-card {
  padding: 26px;
}

.prose-card h2 {
  margin: 0 0 14px;
  font-size: 28px;
}

.prose-card p {
  margin: 0;
  color: #374151;
  font-size: 16px;
  line-height: 1.85;
}

.site-footer {
  margin-top: 48px;
  color: #cbd5e1;
  background: #111827;
}

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

.footer-inner strong {
  color: #ffffff;
  font-size: 22px;
}

.footer-inner p {
  max-width: 480px;
  color: #9ca3af;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.footer-links a {
  padding: 7px 10px;
  color: #d1d5db;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
}

.footer-links a:hover {
  color: #ffffff;
  background: rgba(245, 158, 11, 0.28);
}

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

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

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

  .rank-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .header-inner {
    min-height: 64px;
  }

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 70px;
    padding: 12px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow);
  }

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

  .nav-link {
    text-align: center;
  }

  .hero {
    min-height: 620px;
  }

  .hero-content {
    justify-content: flex-end;
    padding-bottom: 96px;
  }

  .hero-arrow {
    display: none;
  }

  .quick-search {
    grid-template-columns: 1fr;
    margin-top: -28px;
  }

  .search-panel,
  .filter-panel {
    flex-direction: column;
  }

  .filter-panel {
    position: static;
  }

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

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

  .hot-panel,
  .page-hero,
  .player-section,
  .detail-hero {
    padding: 20px;
    border-radius: 20px;
  }

  .category-overview-card,
  .detail-hero,
  .rank-row,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .category-cover {
    width: 100%;
  }

  .rank-row {
    text-align: left;
  }

  .rank-number,
  .rank-score {
    text-align: left;
  }

  .detail-poster {
    max-width: 280px;
  }

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

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

  .logo-text {
    font-size: 17px;
  }

  .page-shell,
  .quick-search {
    width: min(100% - 22px, 1180px);
  }
}
