:root {
  --color-bg: #020617;
  --color-bg-soft: #0f172a;
  --color-bg-card: rgba(30, 41, 59, 0.58);
  --color-bg-card-strong: rgba(30, 41, 59, 0.88);
  --color-line: rgba(148, 163, 184, 0.22);
  --color-text: #f8fafc;
  --color-muted: #94a3b8;
  --color-soft: #cbd5e1;
  --color-accent: #f59e0b;
  --color-accent-dark: #d97706;
  --shadow-card: 0 22px 55px rgba(2, 6, 23, 0.42);
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 12px;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

body.is-menu-open {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.96), rgba(15, 23, 42, 0.96));
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: 0 12px 35px rgba(2, 6, 23, 0.35);
  backdrop-filter: blur(18px);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
  transition: color 0.2s ease;
  white-space: nowrap;
}

.logo:hover {
  color: #fbbf24;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  color: #fff;
  box-shadow: 0 12px 28px rgba(245, 158, 11, 0.3);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #cbd5e1;
  font-weight: 650;
}

.main-nav a {
  transition: color 0.2s ease;
}

.main-nav a:hover,
.main-nav a.is-active {
  color: #fbbf24;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  justify-content: flex-end;
}

.search-form {
  width: min(300px, 100%);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
}

.search-form input,
.inline-filter input {
  width: 100%;
  color: #f8fafc;
  background: transparent;
  border: 0;
  outline: 0;
}

.search-form input::placeholder,
.inline-filter input::placeholder {
  color: #64748b;
}

.search-form button {
  border: 0;
  padding: 7px 13px;
  border-radius: 999px;
  color: #ffffff;
  background: #f59e0b;
  font-weight: 700;
  transition: background 0.2s ease, transform 0.2s ease;
}

.search-form button:hover {
  background: #d97706;
  transform: translateY(-1px);
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 12px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.82);
}

.mobile-panel {
  display: none;
}

.hero {
  position: relative;
  min-height: 600px;
  overflow: hidden;
  background: #020617;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  filter: saturate(1.06);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.72) 44%, rgba(15, 23, 42, 0.22) 100%),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.3) 48%, rgba(2, 6, 23, 0.72) 100%);
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 78px;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fbbf24;
  font-weight: 750;
  margin-bottom: 18px;
}

.hero h1,
.hero h2 {
  max-width: 790px;
  margin: 0 0 18px;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.04;
  letter-spacing: -0.045em;
}

.hero p {
  max-width: 680px;
  margin: 0 0 24px;
  color: #dbe4ef;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.75;
}

.hero-meta,
.meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.16);
  border: 1px solid rgba(245, 158, 11, 0.25);
  font-size: 13px;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 44px;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

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

.btn-primary {
  color: #ffffff;
  background: #f59e0b;
}

.btn-primary:hover {
  background: #d97706;
}

.btn-ghost {
  color: #e2e8f0;
  background: rgba(15, 23, 42, 0.7);
  border-color: rgba(148, 163, 184, 0.24);
}

.btn-ghost:hover {
  background: rgba(30, 41, 59, 0.92);
}

.hero-control {
  position: absolute;
  top: 50%;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.45);
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-control:hover {
  background: rgba(0, 0, 0, 0.72);
}

.hero-control.prev {
  left: 24px;
}

.hero-control.next {
  right: 24px;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  transition: width 0.2s ease, background 0.2s ease;
}

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

main {
  min-height: 72vh;
}

.section {
  padding: 52px 0;
}

.section.tight {
  padding-top: 32px;
}

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

.section-kicker {
  color: #fbbf24;
  font-size: 14px;
  font-weight: 800;
}

.section-title {
  margin: 6px 0 0;
  color: #ffffff;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.section-desc {
  max-width: 720px;
  margin: 10px 0 0;
  color: var(--color-muted);
  line-height: 1.8;
}

.grid {
  display: grid;
  gap: 18px;
}

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

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

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

.movie-card,
.category-card,
.rank-card,
.info-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-line);
  box-shadow: var(--shadow-card);
}

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-md);
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  background: rgba(51, 65, 85, 0.68);
  border-color: rgba(245, 158, 11, 0.34);
}

.poster {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0f172a;
}

.poster.landscape {
  aspect-ratio: 16 / 9;
}

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

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

.poster::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: rgba(0, 0, 0, 0.42);
  transition: opacity 0.2s ease;
}

.movie-card:hover .poster::after {
  opacity: 1;
}

.play-badge {
  position: absolute;
  inset: 50% auto auto 50%;
  z-index: 2;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(245, 158, 11, 0.92);
  transform: translate(-50%, -50%) scale(0.86);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.top-label,
.duration-label,
.score-label {
  position: absolute;
  z-index: 3;
  padding: 5px 8px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.68);
  font-size: 12px;
  font-weight: 750;
}

.top-label {
  top: 10px;
  left: 10px;
}

.duration-label {
  top: 10px;
  right: 10px;
}

.score-label {
  left: 10px;
  bottom: 10px;
  color: #fbbf24;
}

.movie-body {
  padding: 13px;
}

.movie-title {
  margin: 0 0 8px;
  color: #ffffff;
  font-size: 16px;
  line-height: 1.35;
  font-weight: 800;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

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

.movie-meta {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  color: #64748b;
  font-size: 12px;
}

.feature-card {
  min-height: 360px;
}

.feature-card .poster {
  aspect-ratio: 16 / 12;
}

.category-card {
  display: block;
  min-height: 172px;
  padding: 22px;
  border-radius: var(--radius-md);
  background:
    linear-gradient(135deg, rgba(245, 158, 11, 0.14), rgba(30, 41, 59, 0.68)),
    rgba(30, 41, 59, 0.64);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

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

.category-card h3 {
  margin: 0 0 10px;
  color: #ffffff;
  font-size: 22px;
}

.category-card p {
  margin: 0 0 18px;
  color: var(--color-muted);
  line-height: 1.7;
}

.category-card span {
  color: #fbbf24;
  font-weight: 800;
}

.page-hero {
  padding: 60px 0 32px;
  background:
    radial-gradient(circle at 12% 10%, rgba(245, 158, 11, 0.16), transparent 26rem),
    linear-gradient(180deg, rgba(15, 23, 42, 0.78), transparent);
}

.breadcrumb {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 18px;
  color: #94a3b8;
  font-size: 14px;
}

.breadcrumb a {
  color: #fbbf24;
}

.page-hero h1 {
  margin: 0;
  max-width: 860px;
  color: #ffffff;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 780px;
  margin: 18px 0 0;
  color: var(--color-soft);
  font-size: 18px;
  line-height: 1.78;
}

.inline-filter {
  display: flex;
  gap: 12px;
  align-items: center;
  width: min(620px, 100%);
  margin: 0 0 28px;
  padding: 12px 16px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.7);
}

.rank-list {
  display: grid;
  gap: 16px;
}

.rank-card {
  display: grid;
  grid-template-columns: 86px 150px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border-radius: var(--radius-md);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

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

.rank-number {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: #ffffff;
  background: rgba(245, 158, 11, 0.9);
  font-size: 20px;
  font-weight: 900;
}

.rank-card img {
  width: 150px;
  height: 84px;
  object-fit: cover;
  border-radius: 12px;
  transition: transform 0.25s ease;
}

.rank-card h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.rank-card p {
  margin: 0;
  color: var(--color-muted);
  line-height: 1.65;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 24px;
  align-items: start;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: #000000;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.46);
}

.player-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.player-cover-button {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background:
    linear-gradient(180deg, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.76)),
    rgba(2, 6, 23, 0.24);
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.player-cover-button.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-cover-button .play-ring {
  width: 76px;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: #f59e0b;
  box-shadow: 0 18px 40px rgba(245, 158, 11, 0.34);
}

.player-cover-button span:last-child {
  font-size: 18px;
  font-weight: 800;
}

.info-card {
  padding: 22px;
  border-radius: var(--radius-md);
}

.info-card h2,
.info-card h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.info-card p {
  margin: 0 0 16px;
  color: #cbd5e1;
  line-height: 1.9;
}

.detail-poster {
  width: 100%;
  border-radius: var(--radius-md);
  aspect-ratio: 2 / 3;
  object-fit: cover;
  margin-bottom: 16px;
}

.detail-facts {
  display: grid;
  gap: 12px;
  color: #cbd5e1;
}

.detail-facts div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.detail-facts strong {
  color: #ffffff;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag-cloud span {
  padding: 6px 10px;
  border-radius: 999px;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.14);
  font-size: 12px;
  font-weight: 750;
}

.content-stack {
  display: grid;
  gap: 20px;
  margin-top: 24px;
}

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

.empty-state {
  padding: 48px 20px;
  color: var(--color-muted);
  text-align: center;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.62);
}

.site-footer {
  margin-top: 56px;
  padding: 42px 0;
  color: #94a3b8;
  background: rgba(2, 6, 23, 0.72);
  border-top: 1px solid rgba(148, 163, 184, 0.16);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 28px;
}

.footer-grid h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.footer-grid p,
.footer-grid li {
  color: #94a3b8;
  line-height: 1.8;
}

.footer-grid ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-grid a:hover {
  color: #fbbf24;
}

.footer-bottom {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  color: #64748b;
  text-align: center;
  font-size: 14px;
}

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

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

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

@media (max-width: 820px) {
  .main-nav,
  .header-actions .search-form {
    display: none;
  }

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

  .mobile-panel {
    position: fixed;
    inset: 68px 0 auto 0;
    z-index: 90;
    display: block;
    padding: 18px;
    background: rgba(15, 23, 42, 0.98);
    border-bottom: 1px solid rgba(148, 163, 184, 0.18);
    transform: translateY(-120%);
    transition: transform 0.24s ease;
  }

  .mobile-panel.is-open {
    transform: translateY(0);
  }

  .mobile-panel nav {
    display: grid;
    gap: 12px;
    margin-bottom: 16px;
  }

  .mobile-panel nav a {
    padding: 12px;
    color: #e2e8f0;
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.72);
  }

  .mobile-panel .search-form {
    width: 100%;
  }

  .hero {
    min-height: 540px;
  }

  .hero-control {
    display: none;
  }

  .hero-content {
    bottom: 64px;
  }

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

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

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

  .rank-card {
    grid-template-columns: 52px 96px 1fr;
  }

  .rank-card img {
    width: 96px;
    height: 64px;
  }

  .rank-card .btn {
    grid-column: 2 / -1;
    justify-self: start;
  }

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

@media (max-width: 520px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .logo {
    font-size: 18px;
  }

  .hero {
    min-height: 500px;
  }

  .hero h1,
  .hero h2 {
    font-size: 34px;
  }

  .hero p,
  .page-hero p {
    font-size: 16px;
  }

  .section {
    padding: 40px 0;
  }

  .movie-body {
    padding: 11px;
  }

  .movie-title {
    font-size: 15px;
  }

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

  .rank-number {
    width: 48px;
    height: 48px;
  }

  .rank-card img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}
