:root {
  --amber-950: #431407;
  --amber-900: #78350f;
  --amber-800: #92400e;
  --amber-700: #b45309;
  --amber-600: #d97706;
  --orange-700: #c2410c;
  --orange-600: #ea580c;
  --orange-500: #f97316;
  --red-600: #dc2626;
  --cream: #fff7ed;
  --paper: #ffffff;
  --text: #2d1b0e;
  --muted: #756051;
  --line: rgba(146, 64, 14, 0.16);
  --shadow: 0 18px 45px rgba(120, 53, 15, 0.15);
  --soft-shadow: 0 10px 25px rgba(120, 53, 15, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 10% 0%, rgba(251, 191, 36, 0.18), transparent 32rem),
    linear-gradient(180deg, #fff7ed 0%, #fffbeb 45%, #ffffff 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 247, 237, 0.88);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--amber-900);
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 12px 24px rgba(217, 119, 6, 0.3);
  font-size: 16px;
}

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

.nav-link {
  padding: 10px 15px;
  border-radius: 999px;
  color: var(--amber-900);
  font-weight: 700;
  transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 10px 22px rgba(234, 88, 12, 0.25);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  border-radius: 2px;
  background: var(--amber-900);
}

.hero-carousel {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: linear-gradient(180deg, var(--amber-950), var(--orange-700));
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease;
}

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.86) 0%, rgba(0, 0, 0, 0.55) 45%, rgba(0, 0, 0, 0.08) 100%),
    linear-gradient(0deg, rgba(67, 20, 7, 0.58), transparent 55%);
}

.hero-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(640px, 100%);
  color: #fff;
}

.hero-tags,
.card-meta,
.detail-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span {
  display: inline-flex;
  align-items: center;
  padding: 5px 11px;
  border-radius: 999px;
  color: #fde68a;
  background: rgba(217, 119, 6, 0.28);
  border: 1px solid rgba(253, 230, 138, 0.22);
  backdrop-filter: blur(12px);
  font-size: 14px;
  font-weight: 700;
}

.hero-copy h1,
.hero-copy h2 {
  margin: 18px 0 16px;
  color: #fff;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -0.06em;
}

.hero-copy p {
  max-width: 580px;
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 19px;
}

.hero-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.primary-btn,
.ghost-btn,
.search-panel button,
.quick-search button,
.text-link,
.pill-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  font-weight: 800;
  transition: all 0.22s ease;
}

.primary-btn,
.search-panel button,
.quick-search button {
  min-height: 46px;
  padding: 0 24px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 14px 26px rgba(234, 88, 12, 0.28);
}

.primary-btn:hover,
.search-panel button:hover,
.quick-search button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(234, 88, 12, 0.34);
}

.ghost-btn {
  min-height: 46px;
  padding: 0 22px;
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(10px);
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.22);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(10px);
  cursor: pointer;
  font-size: 34px;
  line-height: 1;
  transition: background 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(0, 0, 0, 0.52);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  cursor: pointer;
  transition: all 0.25s ease;
}

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

.search-band {
  margin-top: -36px;
  position: relative;
  z-index: 5;
}

.search-band-inner {
  display: grid;
  grid-template-columns: 1fr minmax(320px, 540px);
  gap: 24px;
  align-items: center;
  padding: 24px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.search-band strong {
  display: block;
  color: var(--amber-900);
  font-size: 26px;
  font-weight: 950;
}

.search-band p {
  margin: 4px 0 0;
  color: var(--muted);
}

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

.quick-search input,
.search-panel input,
.filter-bar input,
.filter-bar select {
  min-width: 0;
  width: 100%;
  border: 2px solid rgba(217, 119, 6, 0.18);
  border-radius: 999px;
  background: #fff;
  color: var(--text);
  outline: none;
  transition: all 0.2s ease;
}

.quick-search input,
.search-panel input {
  padding: 13px 18px;
}

.quick-search input:focus,
.search-panel input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--orange-500);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.16);
}

.main-stack,
.page-main {
  padding: 56px 0 70px;
}

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

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

.section-heading > div {
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: var(--soft-shadow);
}

.section-heading h2 {
  margin: 0;
  color: var(--amber-900);
  font-size: clamp(25px, 3vw, 34px);
  font-weight: 950;
  letter-spacing: -0.04em;
}

.section-more,
.text-link {
  color: var(--orange-700);
  font-weight: 850;
}

.section-more:hover,
.text-link:hover {
  color: var(--amber-900);
}

.movie-grid {
  display: grid;
  gap: 22px;
}

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

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

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

.movie-card {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 18px;
  background: var(--paper);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 48px rgba(120, 53, 15, 0.22);
}

.card-poster,
.large-poster {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, #7c2d12, #f59e0b);
}

.card-poster {
  aspect-ratio: 3 / 4;
}

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

.card-poster img,
.large-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.card-poster::after,
.large-poster::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 45%;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.54), transparent);
  pointer-events: none;
}

.type-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 850;
}

.type-badge {
  top: 10px;
  right: 10px;
  padding: 4px 8px;
  background: rgba(217, 119, 6, 0.92);
}

.rank-badge {
  left: 10px;
  top: 10px;
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, #ef4444, #f59e0b);
  box-shadow: 0 10px 18px rgba(239, 68, 68, 0.32);
}

.card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px;
}

.card-body strong {
  color: var(--amber-900);
  font-size: 16px;
  line-height: 1.35;
  font-weight: 900;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card:hover .card-body strong {
  color: var(--orange-600);
}

.card-line {
  color: var(--muted);
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  justify-content: space-between;
  color: #7c6a5b;
  font-size: 13px;
}

.card-meta span:first-child {
  color: var(--amber-800);
  background: #fef3c7;
  border-radius: 999px;
  padding: 3px 8px;
}

.movie-card-horizontal {
  display: grid;
  grid-template-columns: 150px 1fr;
  min-height: 160px;
}

.horizontal-poster {
  aspect-ratio: auto;
  height: 100%;
}

.movie-card-horizontal .card-body {
  justify-content: space-between;
  padding: 16px;
}

.movie-card-large .card-body {
  padding: 20px;
}

.large-overlay {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 16px;
  z-index: 2;
  color: #fff;
  font-size: 14px;
  opacity: 0;
  transform: translateY(12px);
  transition: all 0.3s ease;
}

.movie-card-large:hover .large-overlay {
  opacity: 1;
  transform: translateY(0);
}

.scroll-row {
  display: flex;
  gap: 22px;
  padding-bottom: 10px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.scroll-item {
  flex: 0 0 230px;
}

.feature-panel {
  padding: 30px;
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(254, 243, 199, 0.95), rgba(255, 237, 213, 0.95));
  box-shadow: var(--shadow);
}

.feature-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}

.feature-side,
.horizontal-list {
  display: grid;
  gap: 16px;
}

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

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

.category-card,
.category-overview-card,
.detail-card,
.sidebar-panel,
.poster-card,
.search-panel,
.filter-bar {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--soft-shadow);
}

.category-card {
  display: flex;
  min-height: 178px;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px;
  border-radius: 20px;
  transition: all 0.22s ease;
}

.category-main {
  display: grid;
  gap: 8px;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(234, 88, 12, 0.28);
  box-shadow: var(--shadow);
}

.category-name {
  color: var(--amber-900);
  font-size: 19px;
  font-weight: 950;
}

.category-desc {
  color: var(--muted);
  font-size: 14px;
}

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

.category-links a,
.mini-links a,
.tag-cloud a {
  display: inline-flex;
  max-width: 100%;
  padding: 4px 9px;
  border-radius: 999px;
  color: var(--amber-800);
  background: #fef3c7;
  font-size: 12px;
  font-weight: 750;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.page-hero {
  margin-top: -56px;
  padding: 82px 0 56px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(67, 20, 7, 0.94), rgba(194, 65, 12, 0.9)),
    radial-gradient(circle at 85% 20%, rgba(251, 191, 36, 0.42), transparent 25rem);
}

.page-hero.compact {
  padding-bottom: 46px;
}

.page-hero h1 {
  margin: 8px 0 12px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 18px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--orange-600);
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.page-hero .eyebrow {
  color: #fde68a;
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  margin-top: 44px;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 20px;
  padding: 18px;
  border-radius: 24px;
}

.category-cover {
  overflow: hidden;
  border-radius: 18px;
  background: linear-gradient(135deg, #7c2d12, #f59e0b);
  aspect-ratio: 4 / 3;
}

.category-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-overview-card h2 {
  margin: 0 0 8px;
  color: var(--amber-900);
  font-size: 24px;
}

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

.filter-bar {
  display: grid;
  grid-template-columns: 1fr 180px 180px;
  gap: 12px;
  margin-bottom: 28px;
  padding: 16px;
  border-radius: 22px;
}

.filter-bar input,
.filter-bar select {
  min-height: 44px;
  padding: 0 15px;
}

.ranking-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 26px;
  align-items: start;
  margin-top: 44px;
}

.sidebar-panel {
  padding: 20px;
  border-radius: 22px;
  position: sticky;
  top: 96px;
}

.sidebar-panel h2 {
  margin: 0 0 16px;
  color: var(--amber-900);
}

.compact-list .movie-card-horizontal {
  grid-template-columns: 104px 1fr;
  min-height: 120px;
}

.compact-list .card-line {
  display: none;
}

.search-page {
  margin-top: 44px;
}

.search-panel {
  padding: 16px;
  border-radius: 999px;
}

.search-filters {
  margin-top: 14px;
  grid-template-columns: 1fr 1fr;
}

.search-status {
  margin: 22px 0;
  color: var(--muted);
  font-weight: 750;
}

.search-picks {
  margin-top: 48px;
}

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

.breadcrumb a {
  color: var(--amber-800);
  font-weight: 800;
}

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

.detail-primary {
  display: grid;
  gap: 22px;
}

.player-panel,
.detail-card,
.poster-card {
  border-radius: 24px;
  overflow: hidden;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #0f0a07;
  aspect-ratio: 16 / 9;
  box-shadow: var(--shadow);
}

.movie-video {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  background:
    radial-gradient(circle at center, rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.58)),
    linear-gradient(135deg, rgba(120, 53, 15, 0.2), rgba(234, 88, 12, 0.18));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-overlay span {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.38);
  font-size: 34px;
  text-indent: 5px;
}

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

.detail-card {
  padding: 26px;
}

.detail-heading-row {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
}

.detail-card h1 {
  margin: 0;
  color: var(--amber-900);
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1.16;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.detail-card h2 {
  margin: 28px 0 10px;
  color: var(--amber-900);
  font-size: 24px;
}

.detail-card p {
  color: #4b3527;
}

.lead-text {
  margin: 18px 0;
  color: var(--amber-800) !important;
  font-size: 18px;
  font-weight: 800;
}

.pill-link {
  flex-shrink: 0;
  padding: 8px 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
}

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

.poster-card {
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.poster-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: linear-gradient(135deg, #7c2d12, #f59e0b);
}

.poster-card div {
  display: grid;
  gap: 5px;
  padding: 16px;
}

.poster-card strong {
  color: var(--amber-900);
  font-size: 19px;
}

.poster-card span {
  color: var(--muted);
  font-size: 14px;
}

.site-footer {
  padding: 36px 0;
  border-top: 1px solid var(--line);
  background: rgba(255, 247, 237, 0.86);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
}

.footer-inner p {
  margin: 6px 0 0;
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--amber-800);
  font-weight: 800;
}

[data-movie-card].is-hidden {
  display: none;
}

@media (max-width: 1180px) {
  .movie-grid.six,
  .movie-grid.five,
  .rank-section .rank-list,
  .category-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

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

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

  .detail-sidebar,
  .sidebar-panel {
    position: static;
  }
}

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

  .nav-toggle {
    display: block;
  }

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

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

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

  .hero-carousel {
    height: 560px;
  }

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

  .hero-arrow {
    display: none;
  }

  .search-band-inner,
  .feature-grid,
  .overview-grid,
  .category-overview-card,
  .filter-bar,
  .search-filters {
    grid-template-columns: 1fr;
  }

  .movie-grid.six,
  .movie-grid.five,
  .movie-grid.four,
  .rank-section .rank-list,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .movie-card-horizontal {
    grid-template-columns: 118px 1fr;
    min-height: 134px;
  }

  .footer-inner,
  .detail-heading-row {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 540px) {
  .brand-name {
    font-size: 18px;
  }

  .hero-carousel {
    height: 520px;
  }

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

  .quick-search,
  .search-panel {
    flex-direction: column;
    border-radius: 24px;
  }

  .movie-grid.six,
  .movie-grid.five,
  .movie-grid.four,
  .rank-section .rank-list,
  .category-grid {
    gap: 14px;
  }

  .card-body {
    padding: 12px;
  }

  .movie-card-horizontal {
    grid-template-columns: 96px 1fr;
  }

  .player-overlay span {
    width: 72px;
    height: 72px;
    font-size: 28px;
  }
}
