:root {
  --bg: #f8fafc;
  --paper: #ffffff;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --brand: #d97706;
  --brand-strong: #b45309;
  --brand-soft: #fef3c7;
  --dark: #0f172a;
  --radius: 18px;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
  --shadow-soft: 0 10px 25px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #fff7ed 0%, #f8fafc 22%, #f8fafc 100%);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.85);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(18px);
}

.header-inner {
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  color: #111827;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #b45309);
  box-shadow: 0 10px 22px rgba(180, 83, 9, 0.25);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 26px;
}

.nav-link {
  position: relative;
  color: #374151;
  font-size: 15px;
  font-weight: 650;
  transition: color 0.2s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -8px;
  width: 100%;
  height: 3px;
  border-radius: 999px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

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

.nav-link:hover::after,
.nav-link-active::after {
  transform: scaleX(1);
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: var(--ink);
  background: var(--brand-soft);
  font-size: 22px;
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
  background: #fff;
  border-top: 1px solid var(--line);
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 680px;
  color: #fff;
  background:
    radial-gradient(circle at 18% 18%, rgba(245, 158, 11, 0.42), transparent 26%),
    radial-gradient(circle at 78% 26%, rgba(239, 68, 68, 0.28), transparent 28%),
    linear-gradient(135deg, #111827 0%, #422006 52%, #020617 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.86), rgba(2, 6, 23, 0.48), rgba(2, 6, 23, 0.86)),
    var(--hero-image, none) center / cover no-repeat;
  opacity: 0.82;
  transition: background-image 0.4s ease;
}

.hero-inner {
  position: relative;
  min-height: 680px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 48px;
  align-items: center;
  padding: 72px 0 58px;
}

.hero-copy {
  max-width: 670px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #fbbf24;
}

.hero h1 {
  margin: 0;
  font-size: clamp(40px, 5.8vw, 74px);
  line-height: 1.06;
  letter-spacing: -0.06em;
}

.hero p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 28px 0;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 750;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: #1f1306;
  background: #fbbf24;
  box-shadow: 0 18px 35px rgba(245, 158, 11, 0.28);
}

.button-secondary {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.hero-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  max-width: 560px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
}

.hero-search input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 14px;
  color: var(--ink);
  background: #fff;
  outline: 0;
}

.hero-search button,
.filter-bar button {
  border: 0;
  border-radius: 14px;
  padding: 0 18px;
  color: #fff;
  background: var(--brand);
  font-weight: 750;
  cursor: pointer;
}

.hero-panel {
  position: relative;
}

.hero-feature-card {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.10);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(16px);
}

.hero-feature-card img {
  width: 100%;
  aspect-ratio: 16 / 12;
  object-fit: cover;
}

.hero-feature-body {
  padding: 24px;
}

.hero-feature-body h2 {
  margin: 0 0 8px;
  font-size: 30px;
}

.hero-feature-body p {
  margin: 0 0 16px;
  font-size: 15px;
}

.hero-thumbs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  margin-top: 14px;
}

.hero-thumb {
  overflow: hidden;
  border: 2px solid transparent;
  border-radius: 16px;
  cursor: pointer;
  opacity: 0.74;
  transition: opacity 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.hero-thumb.is-active,
.hero-thumb:hover {
  opacity: 1;
  border-color: #fbbf24;
  transform: translateY(-3px);
}

.hero-thumb img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.stat-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 24px;
}

.stat-card {
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.10);
}

.stat-card strong {
  display: block;
  font-size: 28px;
}

main {
  overflow: hidden;
}

.section {
  padding: 70px 0;
}

.section-tight {
  padding: 42px 0;
}

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

.section-head h1,
.section-head h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.section-head p {
  max-width: 720px;
  margin: 8px 0 0;
  color: var(--muted);
}

.section-more {
  flex: 0 0 auto;
  color: var(--brand);
  font-weight: 800;
}

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

.movie-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(217, 119, 6, 0.35);
  box-shadow: var(--shadow);
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  background: #111827;
}

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

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

.score-badge {
  position: absolute;
  right: 10px;
  top: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #1f1306;
  background: #fbbf24;
  font-size: 12px;
  font-weight: 850;
}

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

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

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

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--brand-strong);
  font-size: 12px;
  font-weight: 750;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-row span {
  padding: 4px 8px;
  border-radius: 999px;
  color: #92400e;
  background: #fffbeb;
  font-size: 12px;
}

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

.category-card {
  min-height: 190px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.18), transparent 46%),
    #fff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-card h3 {
  margin: 0 0 8px;
  font-size: 22px;
}

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

.category-card strong {
  color: var(--brand);
  font-size: 34px;
}

.rank-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 50px 1fr;
  gap: 12px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}

.rank-num {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #b45309);
  font-weight: 850;
}

.rank-item a {
  font-weight: 800;
}

.rank-item small {
  display: block;
  color: var(--muted);
}

.filter-bar {
  display: grid;
  grid-template-columns: 1.6fr 0.9fr 0.9fr 0.9fr auto;
  gap: 12px;
  margin-bottom: 26px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.detail-hero {
  padding: 48px 0 34px;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.68)),
    var(--detail-bg) center / cover no-repeat;
}

.detail-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.42);
}

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

.detail-copy h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 6vw, 70px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.detail-copy p {
  color: rgba(255, 255, 255, 0.84);
  font-size: 18px;
}

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

.detail-meta span {
  padding: 7px 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: #fde68a;
  background: rgba(255, 255, 255, 0.12);
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 28px;
}

.content-card,
.sidebar-card {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.content-card + .content-card,
.sidebar-card + .sidebar-card {
  margin-top: 22px;
}

.content-card h2,
.sidebar-card h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.movie-player {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: var(--shadow);
}

.movie-player video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.20), rgba(2, 6, 23, 0.68));
  cursor: pointer;
}

.player-play-button {
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: 999px;
  color: #1f1306;
  background: #fbbf24;
  font-size: 32px;
  box-shadow: 0 22px 45px rgba(245, 158, 11, 0.35);
  cursor: pointer;
}

.player-status {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 16px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 14px;
}

.year-index {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.year-index a {
  padding: 7px 12px;
  border-radius: 999px;
  color: #92400e;
  background: #fffbeb;
  font-weight: 750;
}

.empty-state {
  display: none;
  padding: 38px;
  border: 1px dashed #f59e0b;
  border-radius: 24px;
  color: var(--muted);
  background: #fffbeb;
  text-align: center;
}

.site-footer {
  margin-top: 50px;
  padding: 54px 0 0;
  color: #d1d5db;
  background: #111827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 1fr;
  gap: 38px;
}

.site-footer a {
  display: block;
  margin: 7px 0;
  color: #d1d5db;
}

.site-footer h3 {
  color: #fff;
}

.footer-brand {
  color: #fff;
}

.footer-bottom {
  margin-top: 36px;
  padding: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

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

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

  .hero-inner,
  .detail-layout,
  .content-grid,
  .rank-panel {
    grid-template-columns: 1fr;
  }

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

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

  .mobile-menu-button {
    display: inline-grid;
    place-items: center;
  }

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

  .hero,
  .hero-inner {
    min-height: auto;
  }

  .hero-inner {
    padding: 46px 0;
  }

  .stat-strip,
  .movie-grid,
  .category-grid,
  .filter-bar,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .section-head {
    display: block;
  }

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

  .hero-thumbs {
    grid-template-columns: repeat(5, minmax(48px, 1fr));
  }
}

@media (max-width: 520px) {
  .movie-grid {
    gap: 16px;
  }

  .movie-card {
    border-radius: 16px;
  }

  .detail-copy h1 {
    font-size: 38px;
  }
}
