:root {
  --bg: #fff7ed;
  --bg-soft: #fffbeb;
  --paper: #ffffff;
  --paper-warm: #fffaf0;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #f3d7a4;
  --brand: #b45309;
  --brand-dark: #78350f;
  --brand-strong: #92400e;
  --brand-soft: #fef3c7;
  --accent: #f59e0b;
  --shadow: 0 16px 40px rgba(120, 53, 15, 0.12);
  --radius: 20px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: radial-gradient(circle at top left, rgba(253, 230, 138, 0.38), transparent 34rem), var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

body.no-scroll {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1280px;
  height: 70px;
  margin: 0 auto;
  padding: 0 24px;
}

.logo-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.logo-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, #d97706, #92400e);
  color: #fff;
  box-shadow: 0 10px 25px rgba(180, 83, 9, 0.28);
}

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

.logo-copy strong {
  color: var(--brand-dark);
  font-size: 1.3rem;
  letter-spacing: 0.02em;
}

.logo-copy em {
  margin-top: 4px;
  color: var(--brand);
  font-size: 0.75rem;
  font-style: normal;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: #4b5563;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  background: var(--brand-soft);
  color: var(--brand-strong);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  cursor: pointer;
}

main {
  min-height: 65vh;
}

.hero-carousel {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  background: #2a1708;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  background-position: center;
  background-size: cover;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 0.8s ease, transform 1.2s ease;
}

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

.hero-content {
  position: relative;
  z-index: 2;
  width: min(780px, calc(100% - 48px));
  margin-left: max(24px, calc((100vw - 1280px) / 2 + 24px));
  padding: 52px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 32px;
  background: linear-gradient(135deg, rgba(69, 26, 3, 0.78), rgba(120, 53, 15, 0.45));
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(7px);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(251, 191, 36, 0.18);
  color: #fde68a;
  font-size: 0.92rem;
  font-weight: 700;
}

.hero-content h1,
.hero-content h2 {
  margin: 0;
  color: #fff7ed;
  font-size: clamp(2.45rem, 6vw, 5.6rem);
  line-height: 1;
  letter-spacing: -0.055em;
}

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

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

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

.hero-tags span,
.tag-row span,
.tag-row a {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(251, 191, 36, 0.16);
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 700;
}

.hero-tags span {
  background: rgba(255, 255, 255, 0.16);
  color: #fff7ed;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.primary-button,
.secondary-button,
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  background: linear-gradient(135deg, #f59e0b, #b45309);
  color: #fff;
  box-shadow: 0 15px 30px rgba(180, 83, 9, 0.32);
}

.secondary-button {
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.12);
  color: #fff7ed;
}

.text-button {
  background: var(--brand-soft);
  color: var(--brand-strong);
}

.primary-button:hover,
.secondary-button:hover,
.text-button:hover {
  transform: translateY(-2px);
}

.hero-panel {
  position: absolute;
  right: max(24px, calc((100vw - 1280px) / 2 + 24px));
  bottom: 56px;
  z-index: 3;
  width: min(420px, calc(100% - 48px));
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 24px;
  background: rgba(255, 251, 235, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.hero-search,
.filter-bar {
  display: grid;
  gap: 12px;
}

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

.hero-search input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(245, 158, 11, 0.32);
  border-radius: 999px;
  background: #fff;
  color: var(--text);
  outline: none;
  padding: 0 16px;
}

.hero-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.hero-search button {
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  background: var(--brand-strong);
  color: #fff;
  cursor: pointer;
  font-weight: 800;
  padding: 0 18px;
}

.hero-shortcuts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.hero-shortcuts a {
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff7ed;
  color: var(--brand-dark);
  font-size: 0.86rem;
  font-weight: 700;
}

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

.hero-dot {
  width: 11px;
  height: 11px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.46);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

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

.section,
.page-hero,
.detail-shell {
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
}

.section {
  padding: 58px 0;
}

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

.section-kicker,
.breadcrumb {
  color: var(--brand);
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.section h2,
.page-hero h1,
.detail-title {
  margin: 4px 0 0;
  color: #111827;
  font-size: clamp(1.85rem, 3vw, 3rem);
  line-height: 1.12;
  letter-spacing: -0.035em;
}

.section-header p,
.page-hero p {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--muted);
}

.page-hero {
  align-items: flex-start;
  margin-top: 44px;
  padding: 32px;
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(254, 243, 199, 0.72));
  box-shadow: var(--shadow);
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.18);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 12px 30px rgba(120, 53, 15, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 46px rgba(120, 53, 15, 0.16);
}

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

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

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

.poster-badge,
.poster-score {
  position: absolute;
  top: 12px;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 900;
}

.poster-badge {
  left: 12px;
  background: #f59e0b;
  color: #fff;
}

.poster-score {
  right: 12px;
  background: rgba(17, 24, 39, 0.74);
  color: #fde68a;
}

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

.movie-meta,
.inline-meta {
  color: var(--muted);
  font-size: 0.85rem;
}

.movie-card h3,
.ranking-row h3,
.category-card h3 {
  margin: 6px 0 8px;
  color: #111827;
  font-size: 1.05rem;
  line-height: 1.35;
}

.movie-card h3 a:hover,
.ranking-row h3 a:hover,
.category-card h3 a:hover {
  color: var(--brand);
}

.movie-line {
  display: -webkit-box;
  min-height: 3.1em;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.92rem;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

.category-card {
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 12px 30px rgba(120, 53, 15, 0.09);
}

.category-cover {
  display: flex;
  min-height: 170px;
  align-items: end;
  padding: 22px;
  background-position: center;
  background-size: cover;
  color: #fff;
  font-size: 1.7rem;
  font-weight: 900;
}

.category-card-body {
  padding: 18px;
}

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

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

.category-links a {
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 700;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 56px 86px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(245, 158, 11, 0.18);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 24px rgba(120, 53, 15, 0.08);
}

.rank-num {
  color: var(--brand);
  font-size: 1.55rem;
  font-weight: 950;
}

.rank-poster {
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 12px;
  background: linear-gradient(135deg, #92400e, #fde68a);
}

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

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

.inline-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.inline-meta span {
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-weight: 700;
}

.filter-bar {
  grid-template-columns: 1.5fr repeat(3, minmax(130px, 0.45fr));
  margin: 24px 0;
  padding: 16px;
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.76);
}

.detail-shell {
  padding: 36px 0 70px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

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

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

.player-card,
.detail-info,
.side-card {
  border: 1px solid rgba(245, 158, 11, 0.18);
  border-radius: 24px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.player-card {
  overflow: hidden;
}

.video-box {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0f172a;
}

.video-box video {
  width: 100%;
  height: 100%;
  background: #000;
  cursor: pointer;
}

.video-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-position: center;
  background-size: cover;
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.video-overlay::before {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.62), rgba(120, 53, 15, 0.42));
}

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

.play-button {
  position: relative;
  z-index: 1;
  display: inline-grid;
  width: 86px;
  height: 86px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #b45309);
  color: #fff;
  cursor: pointer;
  font-size: 2rem;
  box-shadow: 0 20px 42px rgba(0, 0, 0, 0.36);
}

.player-caption {
  padding: 18px 22px;
  background: #111827;
  color: #fef3c7;
  font-weight: 800;
}

.detail-info {
  margin-top: 24px;
  padding: 26px;
}

.detail-title {
  margin-top: 10px;
}

.detail-summary,
.detail-review {
  margin-top: 24px;
}

.detail-summary h2,
.detail-review h2,
.side-card h2 {
  margin: 0 0 10px;
  color: #111827;
  font-size: 1.35rem;
}

.detail-summary p,
.detail-review p,
.side-card p {
  margin: 0;
  color: #4b5563;
}

.side-card {
  padding: 20px;
}

.side-poster {
  overflow: hidden;
  border-radius: 18px;
  background: linear-gradient(135deg, #92400e, #fde68a);
  box-shadow: 0 14px 34px rgba(120, 53, 15, 0.16);
}

.side-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.side-meta {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.side-meta span {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(245, 158, 11, 0.16);
  color: var(--muted);
}

.side-meta strong {
  color: #111827;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}

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

.footer-shell {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 30px;
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
  padding: 34px 0 22px;
}

.footer-logo {
  color: var(--brand-dark);
  font-size: 1.4rem;
  font-weight: 950;
}

.footer-shell p {
  max-width: 520px;
  color: var(--muted);
}

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

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff;
  color: var(--brand-dark);
  font-weight: 700;
}

.copyright {
  margin: 0;
  padding: 0 24px 28px;
  color: var(--muted);
  text-align: center;
  font-size: 0.92rem;
}

.empty-state {
  display: none;
  padding: 36px;
  border: 1px dashed rgba(245, 158, 11, 0.45);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
  text-align: center;
}

.empty-state.show {
  display: block;
}

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

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

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

  .side-card {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 20px;
  }
}

@media (max-width: 820px) {
  .nav-shell {
    height: 64px;
    padding: 0 18px;
  }

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

  .nav-links {
    position: fixed;
    top: 64px;
    right: 16px;
    left: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid rgba(245, 158, 11, 0.25);
    border-radius: 18px;
    background: rgba(255, 251, 235, 0.98);
    box-shadow: var(--shadow);
  }

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

  .nav-link {
    width: 100%;
  }

  .hero-carousel {
    min-height: 720px;
  }

  .hero-slide {
    align-items: start;
    padding-top: 42px;
  }

  .hero-content {
    width: calc(100% - 32px);
    margin: 0 auto;
    padding: 28px;
  }

  .hero-panel {
    right: 16px;
    bottom: 68px;
    left: 16px;
    width: auto;
  }

  .section,
  .page-hero,
  .detail-shell {
    width: min(100% - 32px, 1280px);
  }

  .section-header,
  .page-hero {
    display: block;
  }

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

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

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

  .footer-shell {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 540px) {
  .logo-copy strong {
    font-size: 1rem;
  }

  .logo-copy em {
    display: none;
  }

  .hero-content h1,
  .hero-content h2 {
    font-size: 2.35rem;
  }

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

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

  .ranking-row {
    grid-template-columns: 40px 68px 1fr;
    gap: 10px;
  }

  .ranking-row p {
    display: none;
  }

  .side-card {
    display: block;
  }
}
