:root {
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --amber-200: #fde68a;
  --amber-400: #fbbf24;
  --amber-500: #f59e0b;
  --amber-600: #d97706;
  --amber-700: #b45309;
  --orange-600: #ea580c;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --white: #ffffff;
  --black: #000000;
  --shadow-sm: 0 1px 2px rgba(17, 24, 39, 0.06);
  --shadow-md: 0 8px 22px rgba(17, 24, 39, 0.10);
  --shadow-lg: 0 22px 60px rgba(17, 24, 39, 0.18);
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--gray-900);
  background: linear-gradient(135deg, #fafafa 0%, #ffffff 45%, rgba(255, 251, 235, 0.88) 100%);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input {
  font: inherit;
}

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

.header-inner {
  width: min(1280px, calc(100% - 32px));
  height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  font-weight: 800;
  box-shadow: var(--shadow-sm);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-copy strong {
  font-size: 19px;
  color: var(--gray-900);
}

.brand-copy small {
  margin-top: 3px;
  color: var(--gray-600);
  font-size: 12px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
}

.nav-link {
  color: var(--gray-700);
  font-weight: 650;
  transition: color 0.2s ease;
  white-space: nowrap;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--amber-700);
}

.header-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input {
  width: 230px;
  height: 40px;
  padding: 0 16px;
  border: 1px solid var(--gray-300);
  border-radius: 999px;
  color: var(--gray-800);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.filter-bar input:focus {
  border-color: transparent;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.24);
}

.header-search button {
  height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: var(--amber-600);
  cursor: pointer;
  transition: background 0.2s ease;
}

.header-search button:hover {
  background: var(--amber-700);
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--gray-100);
  cursor: pointer;
}

.menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: var(--gray-700);
}

.mobile-nav {
  display: none;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 18px;
  border-top: 1px solid var(--gray-200);
}

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

.mobile-link {
  padding: 10px 4px;
  color: var(--gray-700);
  font-weight: 650;
}

.mobile-link.is-active,
.mobile-link:hover {
  color: var(--amber-700);
}

.hero {
  position: relative;
  height: 560px;
  overflow: hidden;
  background: var(--gray-900);
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  display: flex;
  align-items: center;
  opacity: 0;
  background-position: center;
  background-size: cover;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 0.9s ease;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.84) 0%, rgba(0, 0, 0, 0.62) 45%, rgba(0, 0, 0, 0.06) 100%);
}

.hero-content {
  position: relative;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  max-width: 720px;
  color: var(--white);
}

.hero-badge,
.page-hero span {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  color: var(--white);
  background: rgba(217, 119, 6, 0.92);
  font-size: 14px;
  font-weight: 700;
}

.hero h1 {
  margin: 18px 0 18px;
  font-size: clamp(34px, 6vw, 62px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

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

.hero-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 30px;
}

.hero-meta span,
.detail-meta span {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.88);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-size: 13px;
}

.primary-button,
.section-more,
.side-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 12px;
  color: var(--white);
  background: var(--amber-600);
  font-weight: 750;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.primary-button:hover,
.side-more:hover {
  background: var(--amber-700);
  transform: translateY(-2px);
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 26px;
  display: flex;
  gap: 10px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--amber-400);
}

.content-section {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 56px 0;
}

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

.section-head.narrow {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto 28px;
}

.section-head h2 {
  margin: 0 0 8px;
  color: var(--gray-900);
  font-size: clamp(25px, 3vw, 36px);
  line-height: 1.15;
}

.section-head p {
  margin: 0;
  color: var(--gray-600);
}

.section-more {
  min-height: 40px;
  padding: 0 16px;
  color: var(--amber-700);
  background: var(--amber-100);
  box-shadow: none;
  white-space: nowrap;
}

.section-more:hover {
  color: var(--white);
  background: var(--amber-600);
}

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

.movie-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-md);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.card-image {
  position: relative;
  display: block;
  padding-top: 56.25%;
  overflow: hidden;
  background: var(--gray-200);
}

.card-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.card-shade {
  position: absolute;
  inset: auto 0 0;
  height: 45%;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.66), rgba(0, 0, 0, 0));
}

.card-duration {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.72);
  font-size: 12px;
}

.card-body {
  display: flex;
  min-height: 190px;
  flex-direction: column;
  padding: 18px;
}

.card-body strong {
  color: var(--gray-900);
  font-size: 18px;
  line-height: 1.35;
  transition: color 0.2s ease;
}

.movie-card:hover .card-body strong {
  color: var(--amber-700);
}

.card-body em {
  display: -webkit-box;
  margin-top: 10px;
  overflow: hidden;
  color: var(--gray-600);
  font-size: 14px;
  font-style: normal;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 14px;
  color: var(--gray-500);
  font-size: 13px;
}

.card-meta b {
  color: var(--amber-700);
}

.card-meta i {
  overflow: hidden;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-tags,
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.card-tags span,
.tag-cloud span {
  padding: 4px 8px;
  border-radius: 999px;
  color: var(--amber-700);
  background: var(--amber-50);
  font-size: 12px;
}

.category-band {
  padding: 56px 0;
  background: linear-gradient(90deg, var(--amber-50), #fff7ed);
}

.category-grid {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.category-tile {
  position: relative;
  min-height: 168px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  padding: 20px;
  border-radius: var(--radius-lg);
  color: var(--white);
  background-position: center;
  background-size: cover;
  box-shadow: var(--shadow-md);
}

.category-tile::before,
.category-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.12));
}

.category-tile span,
.category-tile em,
.category-cover span {
  position: relative;
}

.category-tile span {
  font-size: 22px;
  font-weight: 800;
}

.category-tile em {
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.82);
  font-style: normal;
  font-size: 14px;
}

.rank-section {
  padding: 56px 0;
  background: linear-gradient(135deg, var(--gray-900), var(--gray-800));
}

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

.rank-panel .section-head h2,
.rank-panel .section-head p {
  color: var(--white);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 48px 82px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: var(--radius-md);
  color: var(--white);
  background: rgba(255, 255, 255, 0.06);
  transition: transform 0.2s ease, background 0.2s ease;
}

.rank-row:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.11);
}

.rank-row span:first-child {
  color: var(--amber-400);
  font-size: 20px;
  font-weight: 800;
}

.rank-row img {
  width: 82px;
  height: 52px;
  object-fit: cover;
  border-radius: 10px;
}

.rank-row strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-row em {
  color: rgba(255, 255, 255, 0.70);
  font-size: 13px;
  font-style: normal;
}

.page-hero {
  min-height: 280px;
  display: flex;
  align-items: center;
  color: var(--white);
  background: linear-gradient(100deg, var(--amber-600), var(--orange-600));
}

.small-hero,
.category-hero,
.search-hero,
.ranking-hero {
  background: linear-gradient(110deg, var(--gray-900), var(--gray-800) 52%, var(--amber-700));
}

.page-hero > div {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
}

.page-hero h1 {
  margin: 16px 0 10px;
  font-size: clamp(36px, 6vw, 58px);
  line-height: 1.1;
}

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

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

.category-card {
  display: grid;
  grid-template-columns: 220px 1fr;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-md);
}

.category-cover {
  position: relative;
  min-height: 220px;
  display: flex;
  align-items: flex-end;
  padding: 18px;
  color: var(--white);
  background-position: center;
  background-size: cover;
}

.category-cover span {
  font-size: 24px;
  font-weight: 850;
}

.category-copy {
  padding: 24px;
}

.category-copy h2 {
  margin: 0 0 10px;
  font-size: 24px;
}

.category-copy p {
  margin: 0 0 18px;
  color: var(--gray-600);
}

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

.category-links a {
  display: block;
  overflow: hidden;
  color: var(--gray-700);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-links a:hover {
  color: var(--amber-700);
}

.filter-bar {
  margin-bottom: 28px;
}

.filter-bar.wide {
  max-width: 760px;
  margin-inline: auto;
}

.filter-bar input {
  width: 100%;
  height: 54px;
  padding: 0 20px;
  border: 1px solid var(--gray-300);
  border-radius: 999px;
  outline: none;
  color: var(--gray-800);
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.empty-state {
  padding: 48px 0;
  text-align: center;
  color: var(--gray-600);
  font-size: 18px;
}

.ranking-list {
  display: grid;
  gap: 14px;
}

.ranking-item {
  display: grid;
  grid-template-columns: 70px 132px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ranking-item:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.ranking-number {
  color: var(--amber-600);
  font-size: 22px;
  font-weight: 850;
}

.ranking-item img {
  width: 132px;
  height: 76px;
  border-radius: 12px;
  object-fit: cover;
}

.ranking-main {
  min-width: 0;
}

.ranking-main strong {
  display: block;
  color: var(--gray-900);
  font-size: 18px;
}

.ranking-main em {
  display: block;
  overflow: hidden;
  margin-top: 4px;
  color: var(--gray-600);
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ranking-meta {
  color: var(--gray-500);
  white-space: nowrap;
}

.detail-wrap {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 64px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 24px;
  color: var(--gray-600);
  font-size: 14px;
}

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

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(320px, 0.82fr);
  gap: 34px;
  align-items: start;
}

.player-card,
.detail-copy,
.detail-side {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-md);
}

.player-shell {
  position: relative;
  overflow: hidden;
  padding-top: 56.25%;
  background: var(--black);
}

.player-video,
.player-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.player-video {
  object-fit: contain;
  background: var(--black);
  cursor: pointer;
}

.player-overlay {
  display: grid;
  place-items: center;
  border: 0;
  color: var(--white);
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.64), rgba(0, 0, 0, 0.18));
  cursor: pointer;
  transition: opacity 0.2s ease;
}

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

.player-overlay strong {
  margin-top: 14px;
  padding: 9px 16px;
  border-radius: 999px;
  background: rgba(217, 119, 6, 0.94);
  font-size: 16px;
}

.play-icon {
  width: 78px;
  height: 78px;
  display: block;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-lg);
}

.play-icon::after {
  content: "";
  position: absolute;
  left: calc(50% - 10px);
  top: calc(50% - 18px);
  width: 0;
  height: 0;
  border-top: 18px solid transparent;
  border-bottom: 18px solid transparent;
  border-left: 28px solid var(--amber-600);
}

.detail-copy {
  margin-top: 22px;
  padding: 28px;
}

.detail-copy h1 {
  margin: 0 0 16px;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.12;
}

.detail-meta {
  margin-bottom: 18px;
}

.detail-meta span {
  color: var(--gray-700);
  background: var(--amber-50);
  border-color: var(--amber-200);
}

.lead-text {
  margin: 0 0 22px;
  color: var(--gray-700);
  font-size: 18px;
}

.text-panel {
  margin-top: 18px;
  padding: 22px;
  border-radius: var(--radius-md);
  background: var(--gray-50);
}

.text-panel h2,
.detail-side h2 {
  margin: 0 0 12px;
  font-size: 22px;
}

.text-panel p {
  margin: 0;
  color: var(--gray-700);
  white-space: pre-line;
}

.warm-panel {
  background: linear-gradient(135deg, var(--amber-50), #fff7ed);
}

.detail-side {
  position: sticky;
  top: 106px;
  padding: 22px;
}

.compact-list {
  display: grid;
  gap: 14px;
}

.compact-card {
  display: grid;
  grid-template-columns: 118px 1fr;
  gap: 12px;
  align-items: center;
  overflow: hidden;
  padding: 10px;
  border-radius: 14px;
  background: var(--gray-50);
  transition: background 0.2s ease, transform 0.2s ease;
}

.compact-card:hover {
  transform: translateY(-2px);
  background: var(--amber-50);
}

.compact-card img {
  width: 118px;
  height: 70px;
  border-radius: 10px;
  object-fit: cover;
}

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

.compact-card em {
  display: block;
  margin-top: 6px;
  color: var(--gray-500);
  font-size: 12px;
  font-style: normal;
}

.side-more {
  width: 100%;
  margin-top: 18px;
}

.site-footer {
  border-top: 1px solid var(--gray-200);
  background: var(--white);
}

.footer-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  color: var(--gray-900);
  font-size: 20px;
  font-weight: 850;
}

.footer-inner p {
  max-width: 560px;
  margin: 8px 0 0;
  color: var(--gray-600);
}

.footer-links {
  display: flex;
  gap: 18px;
  color: var(--gray-600);
}

.footer-links a:hover {
  color: var(--amber-700);
}

.copyright {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 28px;
  color: var(--gray-500);
  font-size: 14px;
}

[hidden] {
  display: none !important;
}

@media (max-width: 1180px) {
  .desktop-nav {
    gap: 14px;
  }

  .header-search input {
    width: 180px;
  }

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

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

@media (max-width: 920px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

  .menu-button {
    display: block;
    margin-left: auto;
  }

  .hero {
    height: 520px;
  }

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

  .rank-list,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .detail-side {
    position: static;
  }

  .ranking-item {
    grid-template-columns: 56px 110px 1fr;
  }

  .ranking-meta {
    grid-column: 3;
  }
}

@media (max-width: 640px) {
  .header-inner {
    width: min(100% - 24px, 1280px);
    height: 68px;
  }

  .brand-copy strong {
    font-size: 17px;
  }

  .brand-copy small {
    display: none;
  }

  .hero {
    height: 500px;
  }

  .hero-overlay {
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.24));
  }

  .hero-content {
    align-self: flex-end;
    padding-bottom: 76px;
  }

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

  .content-section,
  .rank-panel,
  .section-head.narrow,
  .category-grid,
  .detail-wrap,
  .footer-inner,
  .copyright {
    width: min(100% - 24px, 1280px);
  }

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

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

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

  .category-cover {
    min-height: 170px;
  }

  .rank-row {
    grid-template-columns: 40px 78px 1fr;
  }

  .rank-row em {
    display: none;
  }

  .ranking-item {
    grid-template-columns: 1fr;
  }

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

  .ranking-meta {
    grid-column: auto;
  }

  .detail-copy {
    padding: 20px;
  }

  .compact-card {
    grid-template-columns: 100px 1fr;
  }

  .compact-card img {
    width: 100px;
    height: 62px;
  }
}
