:root {
  --bg: #f5f5f4;
  --panel: #ffffff;
  --panel-soft: #fffbeb;
  --ink: #292524;
  --muted: #78716c;
  --line: #e7e5e4;
  --accent: #d97706;
  --accent-strong: #ea580c;
  --accent-soft: #fef3c7;
  --dark: #1c1917;
  --shadow: 0 18px 45px rgba(69, 26, 3, 0.12);
  --shadow-soft: 0 10px 30px rgba(28, 25, 23, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at top left, #fff7ed 0, var(--bg) 34rem);
  line-height: 1.6;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid rgba(214, 211, 209, 0.78);
  backdrop-filter: blur(18px);
}

.nav-container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--dark);
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: 0 8px 24px rgba(217, 119, 6, 0.33);
  font-size: 14px;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}

.main-nav a,
.mobile-nav a {
  padding: 9px 12px;
  border-radius: 999px;
  color: #57534e;
  font-size: 14px;
  font-weight: 600;
  transition: color 0.2s ease, background 0.2s ease;
}

.main-nav a:hover,
.mobile-nav a:hover {
  color: var(--accent);
  background: var(--accent-soft);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #fff7ed;
  cursor: pointer;
  padding: 10px;
}

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

.mobile-nav {
  display: none;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px 16px;
  flex-wrap: wrap;
  gap: 8px;
}

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

.hero {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: linear-gradient(135deg, #1c1917, #451a03 58%, #1c1917);
}

.hero-bg {
  position: absolute;
  inset: -42px;
  background-size: cover;
  background-position: center;
  filter: blur(22px) brightness(0.42);
  transform: scale(1.08);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.35) 55%, rgba(69, 26, 3, 0.45));
}

.hero-inner {
  position: relative;
  max-width: 1180px;
  min-height: 70vh;
  margin: 0 auto;
  padding: 92px 20px 72px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  align-items: center;
  gap: 54px;
}

.hero-copy {
  max-width: 760px;
  color: #fff;
}

.hero-badge,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fcd34d;
  background: rgba(217, 119, 6, 0.18);
  border: 1px solid rgba(245, 158, 11, 0.32);
  border-radius: 999px;
  padding: 7px 13px;
  font-size: 13px;
  font-weight: 700;
}

.hero h1 {
  margin: 20px 0 16px;
  font-size: clamp(38px, 7vw, 72px);
  line-height: 1.06;
  letter-spacing: -0.06em;
}

.hero-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0;
  color: #e7e5e4;
}

.hero-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.hero-tags,
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0;
}

.hero-tags span,
.tag-cloud span {
  padding: 7px 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}

.hero p {
  margin: 20px 0 28px;
  max-width: 720px;
  color: #d6d3d1;
  font-size: 18px;
}

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

.primary-btn,
.ghost-btn,
.ghost-dark-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: 0 14px 32px rgba(217, 119, 6, 0.35);
}

.primary-btn:hover,
.ghost-btn:hover,
.ghost-dark-btn:hover {
  transform: translateY(-2px);
}

.ghost-btn {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
}

.ghost-dark-btn {
  color: var(--accent);
  border: 1px solid #fed7aa;
  background: #fff7ed;
}

.hero-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 28px;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.46);
  transform: rotate(2deg);
}

.hero-card img {
  aspect-ratio: 3 / 4;
  height: 440px;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.hero-card:hover img {
  transform: scale(1.06);
}

.hero-card span {
  position: absolute;
  right: 18px;
  bottom: 18px;
  padding: 8px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(12px);
  font-weight: 700;
}

.page-container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
}

.page-top {
  padding-top: 42px;
}

.content-section,
.filter-panel,
.page-hero,
.detail-hero,
.player-section {
  margin: 44px 0;
}

.filter-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
}

.filter-panel h2,
.section-heading h2,
.page-hero h1 {
  margin: 10px 0 0;
}

.filter-controls {
  display: flex;
  gap: 12px;
  width: min(560px, 100%);
}

.filter-controls input,
.filter-controls select {
  width: 100%;
  min-height: 46px;
  border: 1px solid #e7e5e4;
  border-radius: 14px;
  background: #fff;
  color: var(--ink);
  padding: 0 14px;
  font-size: 15px;
  outline: none;
}

.filter-controls input:focus,
.filter-controls select:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.no-results {
  display: none;
  color: var(--muted);
  font-weight: 700;
}

.no-results.is-visible {
  display: block;
}

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

.section-heading h2 {
  color: var(--dark);
  font-size: clamp(26px, 4vw, 36px);
  letter-spacing: -0.04em;
}

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

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

.movie-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
  border: 1px solid rgba(214, 211, 209, 0.66);
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(245, 158, 11, 0.55);
  box-shadow: var(--shadow);
}

.card-poster {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  background: linear-gradient(135deg, #e7e5e4, #fef3c7);
}

.movie-card-small .card-poster {
  min-height: 176px;
}

.movie-card-large .card-poster {
  min-height: 290px;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.6), transparent 58%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.score-badge,
.rank-flag {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.24);
}

.score-badge {
  top: 12px;
  right: 12px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 9px;
  background: #f59e0b;
  font-size: 13px;
}

.rank-flag {
  top: 12px;
  left: 12px;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: linear-gradient(135deg, #d97706, #ea580c);
}

.card-genres {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.card-genres span {
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  color: #44403c;
  font-size: 12px;
  font-weight: 700;
  backdrop-filter: blur(8px);
}

.card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 16px;
}

.card-body h3 {
  margin: 0 0 9px;
  color: var(--dark);
  font-size: 17px;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.movie-card:hover h3 {
  color: var(--accent);
}

.card-meta,
.card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
}

.card-body p {
  display: -webkit-box;
  margin: 10px 0 14px;
  min-height: 44px;
  color: #57534e;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  font-size: 14px;
}

.card-foot {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid #f5f5f4;
}

.card-foot strong {
  color: var(--accent);
}

.highlight-section {
  padding: 30px;
  border-radius: 28px;
  background: linear-gradient(135deg, #fffbeb, #fff7ed);
  box-shadow: var(--shadow-soft);
}

.white-section {
  padding: 30px;
  border: 1px solid rgba(214, 211, 209, 0.7);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow-soft);
}

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

.category-tile {
  position: relative;
  overflow: hidden;
  min-height: 190px;
  border-radius: 20px;
  background: #1c1917;
  box-shadow: var(--shadow-soft);
}

.category-tile img {
  height: 100%;
  min-height: 190px;
  object-fit: cover;
  opacity: 0.64;
  transition: transform 0.45s ease, opacity 0.45s ease;
}

.category-tile:hover img {
  transform: scale(1.08);
  opacity: 0.78;
}

.category-tile span,
.category-tile strong {
  position: absolute;
  left: 16px;
  right: 16px;
  color: #fff;
}

.category-tile span {
  bottom: 58px;
  font-size: 20px;
  font-weight: 900;
}

.category-tile strong {
  bottom: 18px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 13px;
  font-weight: 500;
  color: #e7e5e4;
}

.section-more {
  margin-top: 24px;
  text-align: center;
}

.page-hero {
  padding: 42px;
  border-radius: 30px;
  color: #fff;
  background: linear-gradient(135deg, #1c1917, #451a03 58%, #92400e);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.12;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 760px;
  margin: 18px 0 0;
  color: #e7e5e4;
  font-size: 17px;
}

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

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

.category-overview-grid {
  display: grid;
  gap: 22px;
  margin: 34px 0 54px;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 24px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow-soft);
}

.category-cover {
  overflow: hidden;
  border-radius: 20px;
  background: #e7e5e4;
}

.category-cover img {
  height: 100%;
  min-height: 260px;
  object-fit: cover;
}

.category-overview-card h2 {
  margin: 14px 0 8px;
  font-size: 28px;
}

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

.compact-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}

.compact-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #fafaf9;
  color: var(--dark);
}

.compact-link span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 700;
}

.compact-link small {
  color: var(--muted);
  white-space: nowrap;
}

.text-link {
  color: var(--accent);
  font-weight: 800;
}

.detail-hero {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
  padding: 30px;
  border-radius: 30px;
  color: #fff;
  background: linear-gradient(135deg, #1c1917, #451a03 60%, #1c1917);
  box-shadow: var(--shadow);
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.36);
}

.detail-poster img {
  aspect-ratio: 3 / 4;
  height: 440px;
  object-fit: cover;
}

.detail-copy h1 {
  margin: 16px 0 10px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.detail-copy p {
  max-width: 760px;
  color: #e7e5e4;
  font-size: 18px;
}

.detail-tags span {
  background: rgba(255, 255, 255, 0.12);
}

.player-section {
  padding: 28px;
  border-radius: 30px;
  background: #11100f;
  box-shadow: var(--shadow);
}

.player-section .section-heading h2 {
  color: #fff;
}

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

.video-shell video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  cursor: pointer;
}

.play-layer {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.58));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.play-layer.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.play-button {
  min-width: 160px;
  min-height: 56px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: 0 18px 44px rgba(217, 119, 6, 0.46);
  cursor: pointer;
  font-size: 17px;
  font-weight: 900;
}

.detail-text p {
  color: #44403c;
  font-size: 16px;
}

.detail-text .tag-cloud span {
  color: #78350f;
  background: #fef3c7;
}

.site-footer {
  margin-top: 70px;
  padding: 42px 0;
  color: #d6d3d1;
  background: #1c1917;
}

.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.7fr);
  gap: 40px;
}

.footer-logo {
  color: #fff;
}

.footer-inner p {
  max-width: 580px;
  color: #a8a29e;
}

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

.footer-links a {
  padding: 8px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #e7e5e4;
  font-size: 14px;
}

.footer-links a:hover {
  background: rgba(245, 158, 11, 0.24);
  color: #fcd34d;
}

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

  .mobile-toggle {
    display: block;
  }

  .hero-inner,
  .detail-hero,
  .category-overview-card,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-card {
    max-width: 320px;
    transform: none;
  }

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

  .filter-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 620px) {
  .nav-container {
    height: 64px;
  }

  .hero-inner {
    padding-top: 58px;
  }

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

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

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

  .filter-controls {
    flex-direction: column;
  }

  .highlight-section,
  .white-section,
  .page-hero,
  .detail-hero,
  .player-section {
    padding: 20px;
    border-radius: 22px;
  }

  .card-poster {
    min-height: 250px;
  }
}
