:root {
  --page-bg: #110904;
  --panel-bg: rgba(35, 20, 8, 0.78);
  --panel-strong: rgba(63, 35, 12, 0.9);
  --text-main: #fff7ed;
  --text-soft: #fed7aa;
  --text-muted: #f5bd70;
  --line-soft: rgba(251, 191, 36, 0.22);
  --gold: #f59e0b;
  --gold-light: #fbbf24;
  --gold-dark: #92400e;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text-main);
  background:
    radial-gradient(circle at top left, rgba(245, 158, 11, 0.28), transparent 34rem),
    radial-gradient(circle at top right, rgba(180, 83, 9, 0.24), transparent 32rem),
    linear-gradient(180deg, #2a1305 0%, var(--page-bg) 46%, #090502 100%);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

img {
  max-width: 100%;
}

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

main {
  overflow: hidden;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(251, 191, 36, 0.2);
  background: rgba(38, 20, 6, 0.78);
  backdrop-filter: blur(18px);
}

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

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff7ed;
  font-weight: 900;
  letter-spacing: 0.03em;
}

.logo-mark {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border-radius: 14px;
  color: #431407;
  background: linear-gradient(135deg, #fde68a, #f59e0b 58%, #ea580c);
  box-shadow: 0 10px 30px rgba(245, 158, 11, 0.35);
}

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

.nav-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: #ffedd5;
  font-size: 15px;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #431407;
  background: #fbbf24;
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: rgba(255, 247, 237, 0.08);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: #ffedd5;
  border-radius: 999px;
}

.hero-carousel {
  position: relative;
  padding: 28px 0 42px;
}

.hero-stage {
  position: relative;
  width: min(1220px, calc(100% - 32px));
  min-height: clamp(620px, 82vh, 760px);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.22);
  border-radius: 36px;
  background: #1c0f06;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

.hero-bg,
.detail-backdrop img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.1) contrast(1.04);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(17, 9, 4, 0.92), rgba(17, 9, 4, 0.55) 48%, rgba(17, 9, 4, 0.18)),
    linear-gradient(180deg, rgba(17, 9, 4, 0.2), rgba(17, 9, 4, 0.88));
}

.hero-inner {
  position: relative;
  z-index: 2;
  min-height: inherit;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: center;
  gap: 48px;
  padding: clamp(32px, 6vw, 76px);
}

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

.eyebrow,
.hero-site-title {
  color: #fcd34d;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 16px 0 12px;
  font-size: clamp(38px, 7vw, 76px);
  line-height: 1.02;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.hero-copy h2 {
  margin: 0 0 14px;
  font-size: clamp(30px, 4.4vw, 56px);
  line-height: 1.04;
  font-weight: 900;
}

.hero-desc,
.page-hero p,
.detail-one-line {
  color: #ffedd5;
  font-size: clamp(16px, 1.8vw, 20px);
  line-height: 1.8;
}

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

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

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

.btn-primary {
  color: #431407;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  box-shadow: 0 16px 36px rgba(245, 158, 11, 0.32);
}

.btn-ghost {
  color: #fff7ed;
  border: 1px solid rgba(254, 215, 170, 0.42);
  background: rgba(255, 247, 237, 0.08);
}

.btn-soft {
  color: #fde68a;
  background: rgba(146, 64, 14, 0.46);
}

.hero-poster {
  overflow: hidden;
  border-radius: 30px;
  border: 1px solid rgba(253, 230, 138, 0.34);
  background: rgba(67, 20, 7, 0.58);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
  transform: rotate(2deg);
}

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

.hero-poster span {
  display: block;
  padding: 16px 18px;
  color: #fde68a;
  font-weight: 800;
}

.hero-control {
  position: absolute;
  z-index: 3;
  top: 50%;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(254, 215, 170, 0.35);
  border-radius: 50%;
  color: #fff7ed;
  background: rgba(17, 9, 4, 0.56);
  font-size: 30px;
  transform: translateY(-50%);
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: rgba(255, 237, 213, 0.42);
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 28px;
  background: #fbbf24;
}

.content-section,
.search-section,
.page-hero,
.detail-hero,
.player-section {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
}

.content-section {
  padding: 40px 0;
}

.search-section {
  padding: 18px 0 8px;
}

.search-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 180px;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line-soft);
  border-radius: 22px;
  background: rgba(255, 247, 237, 0.08);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.18);
}

.search-panel input,
.search-panel select {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(254, 215, 170, 0.25);
  border-radius: 16px;
  color: #fff7ed;
  background: rgba(17, 9, 4, 0.62);
  padding: 0 16px;
  outline: none;
}

.search-panel input::placeholder {
  color: rgba(255, 237, 213, 0.58);
}

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

.section-heading h2 {
  margin: 0;
  font-size: clamp(26px, 3.4vw, 42px);
  font-weight: 950;
  letter-spacing: -0.04em;
}

.section-heading p {
  margin: 8px 0 0;
  color: var(--text-soft);
}

.section-more,
.text-link,
.rank-link {
  color: #fcd34d;
  font-weight: 800;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.18);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 247, 237, 0.09), rgba(146, 64, 14, 0.16));
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.22);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  border-color: rgba(251, 191, 36, 0.48);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.34);
  transform: translateY(-4px);
}

.card-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background: #2a1305;
}

.card-cover img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.movie-card:hover .card-cover img {
  transform: scale(1.04);
}

.card-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #431407;
  background: #fbbf24;
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

.card-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--text-muted);
  font-size: 13px;
}

.card-meta span,
.detail-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.13);
}

.card-body h3 {
  margin: 12px 0 8px;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
}

.card-body p {
  min-height: 52px;
  margin: 0 0 12px;
  color: #fed7aa;
  font-size: 14px;
  line-height: 1.65;
}

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

.tag-row span {
  padding: 5px 9px;
  border: 1px solid rgba(251, 191, 36, 0.22);
  border-radius: 999px;
  color: #fde68a;
  font-size: 12px;
  background: rgba(67, 20, 7, 0.5);
}

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

.category-tile,
.category-card {
  min-height: 154px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  padding: 20px;
  border: 1px solid rgba(251, 191, 36, 0.2);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at top right, rgba(251, 191, 36, 0.22), transparent 58%),
    rgba(255, 247, 237, 0.08);
}

.category-tile span,
.category-card-title {
  color: #fde68a;
  font-size: 20px;
  font-weight: 950;
}

.category-tile strong,
.category-card p {
  color: #ffedd5;
  line-height: 1.7;
}

.category-tile em {
  color: #f59e0b;
  font-style: normal;
  font-weight: 800;
}

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

.category-mini-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.category-mini-links a {
  padding: 6px 10px;
  border-radius: 999px;
  color: #fed7aa;
  background: rgba(17, 9, 4, 0.38);
  font-size: 13px;
}

.page-hero {
  margin-top: 28px;
  padding: clamp(36px, 6vw, 70px);
  border: 1px solid var(--line-soft);
  border-radius: 34px;
  background:
    radial-gradient(circle at top right, rgba(251, 191, 36, 0.24), transparent 46%),
    linear-gradient(135deg, rgba(120, 53, 15, 0.88), rgba(28, 14, 6, 0.92));
  box-shadow: var(--shadow);
}

.compact-hero,
.ranking-hero {
  min-height: 300px;
  display: grid;
  align-items: center;
}

.ranking-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rank-item {
  display: grid;
  grid-template-columns: 58px 88px minmax(0, 1fr) 76px;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
}

.rank-num {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  color: #431407;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  font-weight: 950;
}

.rank-cover img {
  width: 88px;
  height: 116px;
  border-radius: 14px;
  object-fit: cover;
}

.rank-info h3 {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 900;
}

.rank-info p {
  margin: 0 0 10px;
  color: #fed7aa;
  line-height: 1.65;
}

.detail-hero {
  position: relative;
  min-height: 520px;
  margin-top: 28px;
  overflow: hidden;
  border: 1px solid var(--line-soft);
  border-radius: 34px;
  background: #1c0f06;
  box-shadow: var(--shadow);
}

.detail-backdrop {
  position: absolute;
  inset: 0;
}

.detail-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(17, 9, 4, 0.96), rgba(17, 9, 4, 0.68) 54%, rgba(17, 9, 4, 0.26)),
    linear-gradient(180deg, rgba(17, 9, 4, 0.2), rgba(17, 9, 4, 0.9));
}

.detail-layout {
  position: relative;
  z-index: 2;
  min-height: inherit;
  display: grid;
  grid-template-columns: 290px minmax(0, 1fr);
  align-items: center;
  gap: 44px;
  padding: clamp(28px, 6vw, 70px);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border: 1px solid rgba(253, 230, 138, 0.3);
  border-radius: 28px;
  box-shadow: 0 30px 78px rgba(0, 0, 0, 0.42);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
  color: #fcd34d;
  font-weight: 800;
}

.detail-copy h1 {
  max-width: 900px;
}

.detail-one-line {
  max-width: 820px;
}

.detail-meta {
  margin: 24px 0 14px;
}

.player-section {
  padding: 34px 0 12px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.26);
  border-radius: 30px;
  background: #050301;
  box-shadow: var(--shadow);
}

.movie-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #050301;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 14px;
  color: #fff7ed;
  background: linear-gradient(180deg, rgba(17, 9, 4, 0.3), rgba(17, 9, 4, 0.72));
  text-align: center;
}

.player-overlay strong {
  max-width: min(720px, 82%);
  font-size: clamp(20px, 3vw, 34px);
  font-weight: 950;
}

.play-circle {
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #431407;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  box-shadow: 0 20px 50px rgba(245, 158, 11, 0.38);
  font-size: 30px;
}

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

.article-content {
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--line-soft);
  border-radius: 28px;
  background: rgba(255, 247, 237, 0.08);
}

.article-content h2 {
  margin: 0 0 14px;
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 950;
}

.article-content h2:not(:first-child) {
  margin-top: 30px;
}

.article-content p {
  margin: 0;
  color: #ffedd5;
  font-size: 17px;
  line-height: 1.95;
}

.site-footer {
  margin-top: 52px;
  border-top: 1px solid rgba(251, 191, 36, 0.18);
  background: linear-gradient(180deg, rgba(67, 20, 7, 0.4), rgba(9, 5, 2, 0.96));
}

.footer-inner {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.8fr);
  gap: 40px;
  padding: 42px 0 24px;
}

.footer-inner p {
  max-width: 560px;
  color: #fed7aa;
  line-height: 1.8;
}

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

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
  color: #fde68a;
  background: rgba(255, 247, 237, 0.07);
}

.footer-bottom {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 28px;
  color: #f5bd70;
  font-size: 14px;
}

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

@media (max-width: 1024px) {
  .hero-inner,
  .detail-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-poster,
  .detail-poster {
    display: none;
  }

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

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

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

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 72px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid var(--line-soft);
    border-radius: 18px;
    background: rgba(38, 20, 6, 0.96);
  }

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

  .nav-link {
    border-radius: 14px;
  }

  .hero-stage {
    min-height: 650px;
    border-radius: 26px;
  }

  .hero-inner {
    padding: 28px;
  }

  .hero-control {
    display: none;
  }

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

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

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

  .rank-item {
    grid-template-columns: 42px 72px minmax(0, 1fr);
  }

  .rank-cover img {
    width: 72px;
    height: 96px;
  }

  .rank-link {
    display: none;
  }
}

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

  .content-section,
  .search-section,
  .page-hero,
  .detail-hero,
  .player-section,
  .hero-stage {
    width: min(100% - 20px, 1220px);
  }

  .page-hero,
  .detail-layout {
    padding: 24px;
  }

  .rank-item {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .rank-cover {
    display: none;
  }
}
