:root {
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --amber-200: #fde68a;
  --amber-300: #fcd34d;
  --amber-600: #d97706;
  --amber-700: #b45309;
  --amber-800: #92400e;
  --orange-500: #f97316;
  --orange-600: #ea580c;
  --orange-700: #c2410c;
  --yellow-50: #fefce8;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-500: #6b7280;
  --gray-700: #374151;
  --gray-900: #111827;
  --white: #ffffff;
  --shadow-soft: 0 18px 45px rgba(146, 64, 14, 0.14);
  --shadow-card: 0 14px 32px rgba(17, 24, 39, 0.12);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--gray-900);
  background: linear-gradient(135deg, var(--amber-50), #fff7ed 48%, var(--yellow-50));
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(251, 191, 36, 0.28);
  background: rgba(255, 251, 235, 0.92);
  box-shadow: 0 10px 28px rgba(217, 119, 6, 0.12);
  backdrop-filter: blur(18px);
}

.header-inner,
.footer-inner,
.section,
.breadcrumb,
.page-hero,
.detail-layout,
.hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

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

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

.brand-mark {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 12px 24px rgba(234, 88, 12, 0.24);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.12;
}

.brand-text strong {
  color: var(--amber-800);
  font-size: 20px;
  letter-spacing: 0.02em;
}

.brand-text small {
  margin-top: 4px;
  color: var(--amber-600);
  font-size: 12px;
}

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

.nav-link,
.mobile-link,
.footer-links a {
  color: var(--amber-700);
  font-size: 15px;
  font-weight: 700;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active,
.footer-links a:hover {
  color: var(--orange-600);
}

.site-search,
.mobile-search,
.hero-search {
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid rgba(217, 119, 6, 0.26);
  border-radius: 999px;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(217, 119, 6, 0.08);
}

.site-search input,
.mobile-search input,
.hero-search input {
  width: 210px;
  border: 0;
  outline: 0;
  padding: 10px 14px 10px 18px;
  color: var(--gray-700);
  background: transparent;
}

.site-search button,
.mobile-search button,
.hero-search button {
  border: 0;
  padding: 10px 16px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  font-weight: 800;
}

.menu-toggle {
  display: none;
  border: 0;
  color: var(--amber-700);
  background: transparent;
  font-size: 24px;
}

.mobile-menu {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
}

.mobile-menu.is-open {
  display: block;
}

.mobile-menu nav {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 24px;
  min-height: 570px;
  margin-top: 28px;
  overflow: hidden;
  border-radius: var(--radius-xl);
}

.hero-stage {
  position: relative;
  overflow: hidden;
  min-height: 570px;
  border-radius: var(--radius-xl);
  background: var(--gray-900);
  box-shadow: var(--shadow-soft);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.86), rgba(17, 24, 39, 0.26) 54%, rgba(17, 24, 39, 0.72));
}

.hero-content {
  position: absolute;
  left: clamp(24px, 6vw, 72px);
  bottom: clamp(28px, 7vw, 76px);
  width: min(620px, calc(100% - 48px));
  color: var(--white);
}

.hero-kicker,
.section-kicker,
.page-hero span,
.ranking-panel-head span {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 12px;
  color: #fff7ed;
  background: rgba(249, 115, 22, 0.9);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero-content h1 {
  margin: 18px 0 14px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.05;
}

.hero-content p {
  max-width: 590px;
  margin: 0 0 22px;
  color: #ffedd5;
  font-size: 18px;
}

.hero-meta,
.detail-meta,
.card-tags,
.detail-tags,
.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-meta span,
.detail-meta span,
.card-tags span,
.detail-tags span {
  border-radius: 999px;
  padding: 6px 10px;
  color: var(--amber-800);
  background: var(--amber-100);
  font-size: 13px;
  font-weight: 700;
}

.hero-meta span {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 24px;
}

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

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

.btn-primary {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 12px 26px rgba(234, 88, 12, 0.28);
}

.btn-ghost {
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
}

.hero-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  border: 1px solid rgba(251, 191, 36, 0.38);
  border-radius: var(--radius-xl);
  padding: 32px;
  background: linear-gradient(150deg, rgba(255, 251, 235, 0.96), rgba(255, 237, 213, 0.92));
  box-shadow: var(--shadow-soft);
}

.hero-panel > span {
  color: var(--orange-600);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.hero-panel h2 {
  margin: 12px 0;
  color: var(--amber-800);
  font-size: 30px;
  line-height: 1.22;
}

.hero-panel p {
  margin: 0 0 24px;
  color: var(--gray-700);
}

.hero-search {
  width: 100%;
}

.hero-search input {
  width: 100%;
}

.hero-dots {
  display: flex;
  gap: 10px;
  margin-top: 28px;
}

.hero-dot {
  width: 42px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(217, 119, 6, 0.28);
}

.hero-dot.is-active {
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
}

.section {
  margin-top: 52px;
}

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

.section-header h2,
.page-hero h1,
.ranking-panel-head h2 {
  margin: 10px 0 8px;
  color: var(--gray-900);
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.12;
}

.section-header p,
.page-hero p {
  margin: 0;
  color: var(--gray-500);
}

.section-more {
  flex-shrink: 0;
  color: var(--orange-600);
  font-weight: 900;
}

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

.category-card {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--gray-900);
  box-shadow: var(--shadow-card);
}

.category-card img {
  width: 100%;
  height: 100%;
  min-height: 210px;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.category-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.12), rgba(17, 24, 39, 0.84));
}

.category-card strong,
.category-card small {
  position: absolute;
  left: 18px;
  right: 18px;
  color: var(--white);
}

.category-card strong {
  bottom: 46px;
  font-size: 22px;
}

.category-card small {
  bottom: 20px;
  color: #fed7aa;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.28);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 24px rgba(146, 64, 14, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, var(--amber-100), #ffedd5);
}

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

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

.card-type,
.card-score,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--white);
  background: rgba(17, 24, 39, 0.72);
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(8px);
}

.card-type {
  left: 10px;
  top: 10px;
}

.card-score {
  right: 10px;
  bottom: 10px;
  background: rgba(234, 88, 12, 0.88);
}

.rank-badge {
  left: 10px;
  bottom: 10px;
  background: rgba(217, 119, 6, 0.92);
}

.card-body {
  padding: 14px;
}

.card-body h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.32;
}

.card-body h3 a:hover {
  color: var(--orange-600);
}

.card-meta,
.card-desc {
  margin: 0 0 10px;
  color: var(--gray-500);
  font-size: 13px;
}

.card-desc {
  color: var(--gray-700);
}

.card-tags span {
  padding: 4px 8px;
  font-size: 12px;
}

.section-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: start;
}

.ranking-panel,
.side-card,
.poster-card,
.watch-card,
.category-overview-card {
  border: 1px solid rgba(251, 191, 36, 0.3);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.ranking-panel {
  position: sticky;
  top: 96px;
  padding: 22px;
}

.ranking-panel-head h2 {
  font-size: 32px;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 36px 70px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border-radius: var(--radius-md);
  padding: 8px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.rank-row:hover {
  background: var(--amber-50);
  transform: translateX(3px);
}

.rank-number,
.ranking-index {
  color: var(--orange-600);
  font-weight: 950;
}

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

.rank-title {
  display: grid;
  min-width: 0;
}

.rank-title strong,
.ranking-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-title small,
.ranking-info small {
  overflow: hidden;
  color: var(--gray-500);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-heat,
.ranking-score {
  color: var(--amber-700);
  font-weight: 900;
}

.page-hero {
  margin-top: 28px;
  border-radius: var(--radius-xl);
  padding: clamp(34px, 6vw, 70px);
  background: linear-gradient(135deg, rgba(255, 251, 235, 0.98), rgba(255, 237, 213, 0.94));
  box-shadow: var(--shadow-soft);
}

.page-hero-compact {
  padding: clamp(28px, 5vw, 52px);
}

.filter-panel {
  display: grid;
  gap: 14px;
  margin-bottom: 24px;
  border: 1px solid rgba(251, 191, 36, 0.32);
  border-radius: var(--radius-lg);
  padding: 18px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 26px rgba(146, 64, 14, 0.08);
}

.filter-panel-large {
  position: sticky;
  top: 88px;
  z-index: 20;
}

.filter-panel input {
  width: 100%;
  border: 1px solid rgba(217, 119, 6, 0.24);
  border-radius: 999px;
  outline: 0;
  padding: 14px 18px;
  background: var(--white);
}

.filter-panel input:focus {
  border-color: var(--orange-600);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

.filter-chips button {
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  color: var(--amber-800);
  background: var(--amber-100);
  font-weight: 800;
}

.filter-chips button.is-active {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
}

.empty-result {
  border-radius: var(--radius-lg);
  padding: 30px;
  color: var(--gray-500);
  background: var(--white);
  text-align: center;
}

.category-overview-card {
  display: block;
  overflow: hidden;
}

.category-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  background: var(--amber-100);
}

.category-preview-grid img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.category-overview-body {
  padding: 20px;
}

.category-overview-body span {
  color: var(--orange-600);
  font-size: 13px;
  font-weight: 900;
}

.category-overview-body h2 {
  margin: 8px 0;
}

.category-overview-body p {
  margin: 0;
  color: var(--gray-500);
}

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

.ranking-card {
  display: grid;
  grid-template-columns: 58px 86px minmax(0, 1fr) 64px;
  gap: 16px;
  align-items: center;
  border: 1px solid rgba(251, 191, 36, 0.28);
  border-radius: var(--radius-lg);
  padding: 12px;
  background: rgba(255, 255, 255, 0.92);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.ranking-card img {
  width: 86px;
  height: 62px;
  border-radius: 12px;
  object-fit: cover;
}

.ranking-info {
  display: grid;
  min-width: 0;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 26px;
  color: var(--gray-500);
  font-size: 14px;
}

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

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

.watch-card {
  overflow: hidden;
}

.player-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.movie-video,
.player-cover,
.player-cover img {
  width: 100%;
  height: 100%;
}

.movie-video {
  position: absolute;
  inset: 0;
  z-index: 1;
  object-fit: contain;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 0;
  padding: 0;
  background: #000000;
}

.player-cover::after {
  position: absolute;
  inset: 0;
  content: "";
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.62));
}

.player-cover img {
  object-fit: cover;
}

.player-play {
  position: absolute;
  z-index: 4;
  display: grid;
  width: 78px;
  height: 78px;
  place-items: center;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  font-size: 34px;
  line-height: 1;
}

.player-shell.is-started .player-cover {
  display: none;
}

.player-message {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 5;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  padding: 10px 16px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.7);
}

.detail-content {
  padding: 26px;
}

.detail-content h1 {
  margin: 0 0 14px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.14;
}

.detail-tags {
  margin: 18px 0 24px;
}

.detail-section {
  border-top: 1px solid var(--gray-200);
  padding-top: 22px;
  margin-top: 22px;
}

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

.detail-section p {
  margin: 0 0 14px;
  color: var(--gray-700);
}

.review-box {
  border-radius: var(--radius-lg);
  border-top: 0;
  padding: 22px;
  background: linear-gradient(135deg, var(--amber-50), #fff7ed);
}

.detail-side {
  display: grid;
  gap: 18px;
  position: sticky;
  top: 96px;
}

.poster-card {
  overflow: hidden;
  padding: 12px;
}

.poster-card img {
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius-md);
  object-fit: cover;
}

.poster-card .btn {
  width: 100%;
  margin-top: 12px;
}

.side-card {
  padding: 20px;
}

.side-card dl {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 10px 12px;
  margin: 0;
}

.side-card dt {
  color: var(--gray-500);
}

.side-card dd {
  margin: 0;
  color: var(--gray-900);
  font-weight: 700;
}

.movie-card-compact .card-desc {
  display: none;
}

.site-footer {
  margin-top: 72px;
  color: #fffbeb;
  background: linear-gradient(135deg, #78350f, #9a3412 52%, #854d0e);
}

.footer-inner {
  display: grid;
  gap: 26px;
  padding: 46px 0;
}

.brand-footer .brand-text strong,
.brand-footer .brand-text small {
  color: #fffbeb;
}

.footer-brand p {
  max-width: 680px;
  margin: 16px 0 0;
  color: #fde68a;
}

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

.footer-links a {
  color: #ffedd5;
}

.copyright {
  margin: 0;
  color: #fde68a;
  font-size: 14px;
}

[hidden],
.movie-card.is-hidden,
.ranking-card.is-hidden {
  display: none !important;
}

@media (max-width: 1120px) {
  .primary-nav,
  .site-search {
    display: none;
  }

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

  .hero,
  .section-split,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .hero-panel,
  .ranking-panel,
  .detail-side {
    position: static;
  }

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

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

@media (max-width: 760px) {
  .header-inner,
  .footer-inner,
  .section,
  .breadcrumb,
  .page-hero,
  .detail-layout,
  .hero {
    width: min(100% - 22px, 1180px);
  }

  .brand-text strong {
    font-size: 18px;
  }

  .hero,
  .hero-stage {
    min-height: 520px;
  }

  .hero {
    gap: 14px;
  }

  .hero-panel {
    padding: 24px;
  }

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

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

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

  .ranking-score {
    display: none;
  }

  .detail-content {
    padding: 20px;
  }
}

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

  .hero-content {
    left: 20px;
    bottom: 28px;
  }

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

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

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

  .rank-heat {
    display: none;
  }
}
