:root {
  --bg: #fffaf0;
  --surface: #ffffff;
  --surface-soft: #fff7ed;
  --text: #1f2937;
  --muted: #6b7280;
  --line: rgba(180, 83, 9, 0.16);
  --amber: #d97706;
  --amber-dark: #92400e;
  --orange: #ea580c;
  --shadow: 0 18px 40px rgba(146, 64, 14, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 32%, #fffaf0 100%);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(245, 158, 11, 0.18);
  background: rgba(255, 251, 235, 0.88);
  backdrop-filter: blur(16px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  color: var(--amber-dark);
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 10px 24px rgba(234, 88, 12, 0.28);
}

.brand-text {
  font-size: 1.12rem;
}

.desktop-nav,
.mobile-nav,
.footer-links {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.nav-link,
.footer-links a {
  padding: 9px 14px;
  border-radius: 999px;
  color: #7c2d12;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.footer-links a:hover {
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  transform: translateY(-1px);
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(245, 158, 11, 0.14);
  padding: 10px;
}

.mobile-menu-button span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 999px;
  background: var(--amber-dark);
}

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

.mobile-nav.open {
  display: flex;
}

.hero-slider {
  position: relative;
  min-height: 650px;
  overflow: hidden;
  background: #1c1208;
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: saturate(1.08);
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 20%, rgba(251, 191, 36, 0.28), transparent 32%),
    linear-gradient(180deg, rgba(28, 18, 8, 0.22), rgba(28, 18, 8, 0.92));
}

.hero-content {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  min-height: 650px;
  margin: 0 auto;
  padding: 92px 0 128px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) 360px;
  align-items: center;
  gap: 56px;
}

.hero-copy {
  max-width: 720px;
  color: #ffffff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 7px 12px;
  border: 1px solid rgba(253, 230, 138, 0.35);
  border-radius: 999px;
  color: #fde68a;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  font-weight: 800;
  font-size: 0.9rem;
}

.hero-copy h1,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  font-size: clamp(2.4rem, 6vw, 5.2rem);
  line-height: 1.04;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.hero-copy p,
.page-hero p,
.detail-one-line {
  margin: 20px 0 0;
  max-width: 760px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.08rem;
}

.hero-tags {
  margin-top: 22px;
}

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

.primary-button,
.secondary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 16px 34px rgba(234, 88, 12, 0.35);
}

.secondary-button,
.ghost-button {
  color: #7c2d12;
  background: rgba(255, 255, 255, 0.86);
  border-color: rgba(245, 158, 11, 0.28);
}

.primary-button:hover,
.secondary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.hero-poster {
  position: relative;
  aspect-ratio: 2 / 3;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38);
  transform: rotate(2deg);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.9), rgba(234, 88, 12, 0.8));
}

.hero-poster img,
.poster-frame img,
.rank-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.poster-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 18px;
  color: #ffffff;
  text-align: center;
  font-weight: 950;
  letter-spacing: 0.08em;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.24), transparent 32%),
    linear-gradient(135deg, #d97706, #ea580c 62%, #7c2d12);
}

.poster-img {
  position: relative;
  z-index: 1;
}

.poster-frame.image-missing .poster-img,
.hero-poster.image-missing .poster-img,
.rank-poster.image-missing .poster-img {
  display: none;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 34px;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.hero-dot {
  min-height: 54px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
  color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
  text-align: left;
  padding: 10px 12px;
  cursor: pointer;
}

.hero-dot span {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  margin-right: 6px;
  border-radius: 999px;
  color: #7c2d12;
  background: #fde68a;
  font-weight: 950;
}

.hero-dot.active {
  color: #ffffff;
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.9), rgba(234, 88, 12, 0.86));
}

.hero-search {
  position: absolute;
  right: calc((100% - min(1180px, calc(100% - 32px))) / 2);
  bottom: 104px;
  width: min(440px, calc(100% - 32px));
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 12px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(14px);
}

.hero-search label {
  display: grid;
  gap: 2px;
  color: #fde68a;
  font-size: 0.78rem;
  font-weight: 800;
}

.hero-search input,
.search-field input,
.select-field select {
  width: 100%;
  border: 1px solid rgba(245, 158, 11, 0.24);
  border-radius: 14px;
  outline: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.94);
  padding: 11px 13px;
}

.hero-search button {
  border: 0;
  border-radius: 16px;
  padding: 0 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  font-weight: 900;
}

.content-section,
.overview-list {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 64px 0;
}

.tinted-section {
  width: 100%;
  max-width: none;
  padding-left: max(16px, calc((100% - 1180px) / 2));
  padding-right: max(16px, calc((100% - 1180px) / 2));
  background: linear-gradient(135deg, rgba(255, 247, 237, 0.95), rgba(254, 243, 199, 0.72));
}

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

.section-heading h2,
.text-panel h2,
.overview-head h2 {
  margin: 0;
  color: #7c2d12;
  font-size: clamp(1.55rem, 3vw, 2.2rem);
  line-height: 1.15;
  font-weight: 950;
}

.section-heading p,
.overview-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

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

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

.featured-grid,
.mini-grid {
  gap: 18px;
}

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.16);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: 0 10px 22px rgba(146, 64, 14, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-frame,
.rank-poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #f59e0b;
}

.poster-frame img,
.rank-poster img {
  transition: transform 0.35s ease;
}

.movie-card:hover .poster-frame img {
  transform: scale(1.07);
}

.heat-badge {
  position: absolute;
  z-index: 2;
  right: 10px;
  top: 10px;
  padding: 5px 8px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(124, 45, 18, 0.76);
  backdrop-filter: blur(6px);
  font-size: 0.78rem;
  font-weight: 900;
}

.movie-card-body {
  padding: 14px;
}

.movie-title {
  display: -webkit-box;
  overflow: hidden;
  color: #111827;
  font-weight: 900;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-title:hover {
  color: var(--orange);
}

.movie-meta,
.movie-desc {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.movie-desc {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.tag-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  color: #92400e;
  background: #fef3c7;
  font-size: 0.78rem;
  font-weight: 800;
}

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

.category-card,
.category-overview-card,
.text-panel,
.player-card {
  border: 1px solid rgba(245, 158, 11, 0.16);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 16px 34px rgba(146, 64, 14, 0.08);
}

.category-card > a {
  display: block;
  min-height: 196px;
  padding: 22px;
}

.category-short,
.overview-head span {
  color: var(--orange);
  font-weight: 950;
}

.category-card h3 {
  margin: 8px 0;
  color: #7c2d12;
  font-size: 1.35rem;
}

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

.category-card strong {
  display: inline-flex;
  margin-top: 18px;
  color: var(--amber-dark);
}

.category-preview {
  display: grid;
  gap: 6px;
  padding: 0 22px 22px;
}

.category-preview a {
  color: #9a3412;
  font-weight: 800;
}

.page-hero,
.detail-hero {
  color: #ffffff;
  background:
    radial-gradient(circle at 20% 10%, rgba(253, 230, 138, 0.28), transparent 34%),
    linear-gradient(135deg, #7c2d12, #b45309 52%, #f59e0b);
}

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

.page-hero > div {
  padding: 78px 0;
}

.page-hero h1 {
  max-width: 760px;
}

.overview-list {
  display: grid;
  gap: 28px;
}

.category-overview-card {
  padding: 26px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 180px auto auto;
  align-items: end;
  gap: 12px;
  margin-bottom: 24px;
  padding: 16px;
  border-radius: 22px;
  background: rgba(255, 247, 237, 0.95);
  border: 1px solid rgba(245, 158, 11, 0.16);
}

.search-field,
.select-field {
  display: grid;
  gap: 6px;
  color: #92400e;
  font-size: 0.86rem;
  font-weight: 900;
}

.result-count {
  color: var(--muted);
  font-weight: 800;
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 76px 86px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border: 1px solid rgba(245, 158, 11, 0.16);
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(146, 64, 14, 0.06);
}

.ranking-item.compact {
  grid-template-columns: 54px 68px minmax(0, 1fr) auto;
}

.rank-num {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  font-weight: 950;
}

.rank-poster {
  border-radius: 14px;
}

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

.rank-score {
  color: var(--amber-dark);
  white-space: nowrap;
}

.detail-hero {
  padding: 38px 0 56px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 28px;
  color: rgba(255, 255, 255, 0.82);
}

.breadcrumb a:hover {
  color: #fde68a;
}

.detail-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
}

.detail-poster {
  border-radius: 28px;
  box-shadow: 0 28px 64px rgba(0, 0, 0, 0.28);
}

.detail-info .detail-one-line {
  color: rgba(255, 255, 255, 0.88);
}

.meta-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 24px 0 0;
}

.meta-list div {
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.meta-list dt {
  color: #fde68a;
  font-size: 0.82rem;
  font-weight: 900;
}

.meta-list dd {
  margin: 2px 0 0;
  color: #ffffff;
  font-weight: 900;
}

.detail-content {
  display: grid;
  gap: 24px;
}

.player-card {
  padding: 18px;
}

.player-toolbar {
  align-items: center;
  margin-bottom: 14px;
}

.player-toolbar span {
  display: block;
  color: var(--orange);
  font-weight: 900;
  font-size: 0.9rem;
}

.video-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 22px;
  background: #111827;
}

.video-frame {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #111827;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.12), rgba(17, 24, 39, 0.52));
  cursor: pointer;
}

.player-card.playing .play-overlay {
  opacity: 0;
  pointer-events: none;
}

.play-overlay span {
  width: 78px;
  height: 78px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
  position: relative;
}

.play-overlay span::after {
  content: "";
  position: absolute;
  left: 32px;
  top: 24px;
  border-top: 15px solid transparent;
  border-bottom: 15px solid transparent;
  border-left: 22px solid var(--orange);
}

.player-message {
  margin: 12px 2px 0;
  color: var(--muted);
}

.text-panel {
  padding: 26px;
}

.text-panel p {
  margin: 14px 0 0;
  color: #374151;
  white-space: pre-line;
}

.site-footer {
  margin-top: 44px;
  border-top: 1px solid rgba(245, 158, 11, 0.18);
  background: #fff7ed;
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.5fr);
  gap: 24px;
}

.footer-inner strong {
  color: #7c2d12;
  font-size: 1.2rem;
}

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

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

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

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

  .hero-content {
    grid-template-columns: minmax(0, 1fr) 280px;
  }
}

@media (max-width: 820px) {
  .desktop-nav {
    display: none;
  }

  .mobile-menu-button {
    display: block;
  }

  .hero-slider,
  .hero-content {
    min-height: 720px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    padding-top: 72px;
    gap: 28px;
  }

  .hero-poster {
    width: min(230px, 70vw);
    margin: 0 auto;
  }

  .hero-dots {
    grid-template-columns: 1fr 1fr;
    bottom: 18px;
  }

  .hero-search {
    left: 16px;
    right: 16px;
    bottom: 142px;
    width: auto;
  }

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

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

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

  .ranking-item,
  .ranking-item.compact {
    grid-template-columns: 54px 68px minmax(0, 1fr);
  }

  .rank-score {
    grid-column: 2 / -1;
  }

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

  .detail-poster {
    width: min(280px, 78vw);
  }

  .meta-list,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .section-heading,
  .overview-head,
  .player-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .header-inner,
  .content-section,
  .overview-list,
  .page-hero > div,
  .detail-hero,
  .footer-inner {
    width: min(100% - 24px, 1180px);
  }

  .brand-text {
    font-size: 1rem;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-info h1 {
    font-size: 2.25rem;
  }

  .movie-grid {
    gap: 14px;
  }

  .movie-card-body {
    padding: 11px;
  }

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