:root {
  --bg: #fff7ed;
  --paper: #ffffff;
  --ink: #1f2937;
  --muted: #6b7280;
  --line: rgba(148, 163, 184, 0.28);
  --amber: #d97706;
  --amber-dark: #92400e;
  --orange: #f97316;
  --soft: #fffbeb;
  --dark: #111827;
  --shadow: 0 22px 50px rgba(146, 64, 14, 0.16);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(251, 191, 36, 0.24), transparent 30rem),
    linear-gradient(180deg, #fff7ed 0%, #ffffff 48%, #fff7ed 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(255, 251, 235, 0.94), rgba(255, 247, 237, 0.94));
  border-bottom: 1px solid rgba(217, 119, 6, 0.14);
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 36px rgba(146, 64, 14, 0.08);
}

.nav-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 76px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.brand-mark,
.footer-brand span {
  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 14px 28px rgba(217, 119, 6, 0.28);
}

.brand-text strong {
  display: block;
  font-size: 22px;
  line-height: 1;
  color: var(--amber-dark);
}

.brand-text small {
  color: var(--muted);
  font-size: 12px;
}

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

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

.nav-link:hover,
.nav-link.active {
  color: var(--amber-dark);
  background: rgba(251, 191, 36, 0.16);
}

.nav-search {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  background: #ffffff;
  border: 1px solid rgba(217, 119, 6, 0.18);
  border-radius: 999px;
  box-shadow: 0 12px 30px rgba(146, 64, 14, 0.08);
}

.nav-search input,
.filter-bar input,
.filter-bar select {
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font: inherit;
}

.nav-search input {
  width: 230px;
  padding: 8px 8px 8px 14px;
}

.nav-search button,
.primary-button {
  border: 0;
  border-radius: 999px;
  padding: 10px 18px;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 16px 30px rgba(217, 119, 6, 0.28);
  cursor: pointer;
}

.menu-button {
  display: none;
  border: 0;
  border-radius: 14px;
  padding: 10px 12px;
  background: rgba(251, 191, 36, 0.18);
  color: var(--amber-dark);
  font-size: 22px;
  cursor: pointer;
}

.mobile-panel {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.mobile-link {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  color: #4b5563;
  font-weight: 700;
}

.mobile-link:hover {
  background: var(--soft);
  color: var(--amber-dark);
}

.hero-carousel {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 30px auto 0;
  overflow: hidden;
  border-radius: 34px;
  background: linear-gradient(135deg, #1f2937, #431407 50%, #7c2d12);
  box-shadow: 0 30px 80px rgba(67, 20, 7, 0.32);
}

.hero-bg-glow {
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(circle at 20% 10%, rgba(251, 191, 36, 0.36), transparent 24rem),
    radial-gradient(circle at 80% 30%, rgba(249, 115, 22, 0.28), transparent 24rem);
  pointer-events: none;
}

.hero-stage {
  position: relative;
  min-height: 590px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(280px, 0.85fr) minmax(300px, 1.15fr);
  gap: 44px;
  align-items: center;
  padding: 54px;
  opacity: 0;
  visibility: hidden;
  transform: translateX(20px);
  transition: opacity 0.45s ease, transform 0.45s ease, visibility 0.45s ease;
}

.hero-slide.active {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

.hero-media {
  position: relative;
  min-height: 430px;
  border-radius: 30px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
}

.hero-media img {
  width: 100%;
  height: 100%;
  min-height: 430px;
  object-fit: cover;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, 0.34));
}

.hero-copy {
  position: relative;
  color: #ffffff;
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--amber);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 900;
}

.hero-copy h1 {
  margin: 14px 0 16px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 0.96;
  letter-spacing: -0.05em;
}

.hero-line {
  margin: 0 0 16px;
  color: #ffedd5;
  font-size: 21px;
  font-weight: 700;
}

.hero-summary {
  max-width: 680px;
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 16px;
  line-height: 1.8;
}

.hero-tags,
.detail-tags,
.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.detail-tags span,
.card-tags span {
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(251, 191, 36, 0.14);
  color: #92400e;
  font-size: 12px;
  font-weight: 800;
}

.hero-tags span {
  color: #fffbeb;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

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

.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 10px 18px;
  color: #ffffff;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.ghost-button.dark {
  color: var(--amber-dark);
  background: #ffffff;
  border-color: rgba(217, 119, 6, 0.18);
}

.hero-controls {
  position: absolute;
  left: 54px;
  bottom: 40px;
  display: flex;
  align-items: center;
  gap: 14px;
  z-index: 5;
}

.hero-prev,
.hero-next,
.hero-dot {
  border: 0;
  cursor: pointer;
}

.hero-prev,
.hero-next {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 28px;
}

.hero-dots {
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
}

.hero-dot.active {
  width: 28px;
  background: #ffffff;
}

.hero-strip {
  position: absolute;
  right: 34px;
  bottom: 34px;
  z-index: 6;
  display: flex;
  gap: 12px;
}

.hero-mini-card {
  width: 112px;
  overflow: hidden;
  border-radius: 18px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(14px);
}

.hero-mini-card img {
  width: 100%;
  height: 70px;
  object-fit: cover;
}

.hero-mini-card span {
  display: block;
  padding: 8px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 12px;
  font-weight: 800;
}

.content-section,
.page-hero,
.detail-page {
  width: min(1180px, calc(100% - 32px));
  margin: 36px auto;
}

.intro-card,
.page-hero,
.detail-hero,
.player-section,
.detail-content,
.category-card-large a {
  border: 1px solid rgba(217, 119, 6, 0.16);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow);
}

.intro-card,
.page-hero {
  padding: clamp(28px, 5vw, 54px);
}

.intro-card h1,
.page-hero h1,
.section-heading h2,
.detail-copy h1,
.detail-content h2,
.player-section h2 {
  margin: 8px 0 0;
  color: #111827;
  line-height: 1.12;
}

.intro-card h1,
.page-hero h1 {
  font-size: clamp(30px, 5vw, 54px);
  letter-spacing: -0.04em;
}

.intro-card p,
.page-hero p {
  max-width: 800px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

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

.section-heading h2 {
  font-size: clamp(26px, 4vw, 38px);
}

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

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

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

.category-tile,
.category-card-large a {
  display: block;
  padding: 22px;
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(255, 251, 235, 0.92)),
    radial-gradient(circle at top right, rgba(251, 191, 36, 0.32), transparent 12rem);
  border: 1px solid rgba(217, 119, 6, 0.16);
  box-shadow: 0 16px 36px rgba(146, 64, 14, 0.09);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.category-card-large a:hover,
.movie-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 52px rgba(146, 64, 14, 0.16);
}

.category-tile span,
.category-card-large strong {
  display: block;
  color: #111827;
  font-size: 20px;
  font-weight: 900;
}

.category-tile small,
.category-card-large p {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.7;
}

.category-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.category-preview span {
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(251, 191, 36, 0.18);
  color: var(--amber-dark);
  font-size: 12px;
  font-weight: 800;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid rgba(217, 119, 6, 0.14);
  box-shadow: 0 16px 34px rgba(146, 64, 14, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

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

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

.quality-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(217, 119, 6, 0.92);
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

.card-body h3 {
  margin: 10px 0 8px;
  color: #111827;
  font-size: 19px;
  line-height: 1.35;
}

.movie-card.compact .card-body h3 {
  font-size: 16px;
}

.card-body p {
  min-height: 54px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

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

.card-meta a {
  color: var(--amber-dark);
}

.filter-bar {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
  padding: 14px;
  border: 1px solid rgba(217, 119, 6, 0.16);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 14px 32px rgba(146, 64, 14, 0.08);
}

.filter-bar label {
  display: grid;
  gap: 6px;
}

.filter-bar span {
  color: var(--amber-dark);
  font-size: 12px;
  font-weight: 900;
}

.filter-bar input,
.filter-bar select {
  min-height: 42px;
  padding: 0 12px;
  border-radius: 14px;
  background: var(--soft);
  border: 1px solid rgba(217, 119, 6, 0.14);
}

.rank-section {
  padding: 28px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #111827, #431407);
  color: #ffffff;
  box-shadow: 0 30px 80px rgba(67, 20, 7, 0.24);
}

.rank-section .section-heading h2 {
  color: #ffffff;
}

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

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

.rank-list a {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 12px;
  align-items: center;
  padding: 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.09);
}

.rank-no {
  grid-row: span 2;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #431407;
  background: #fbbf24;
  font-weight: 1000;
}

.rank-title {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 900;
}

.rank-meta {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: rgba(255, 255, 255, 0.65);
  font-size: 13px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--amber-dark);
  font-weight: 800;
}

.detail-page {
  margin-top: 30px;
}

.detail-hero {
  padding: clamp(22px, 4vw, 44px);
}

.detail-grid {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 34px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  background: #fed7aa;
  box-shadow: 0 22px 48px rgba(146, 64, 14, 0.18);
}

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

.detail-copy h1 {
  font-size: clamp(34px, 6vw, 64px);
  letter-spacing: -0.05em;
}

.detail-line {
  margin: 18px 0;
  color: #374151;
  font-size: 20px;
  font-weight: 800;
  line-height: 1.65;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}

.detail-meta span {
  border-radius: 14px;
  padding: 9px 12px;
  background: var(--soft);
  color: var(--amber-dark);
  font-weight: 800;
}

.player-section,
.detail-content {
  margin-top: 24px;
  padding: clamp(20px, 4vw, 34px);
}

.player-wrap {
  position: relative;
  overflow: hidden;
  margin-top: 18px;
  border-radius: 26px;
  background: #000000;
  aspect-ratio: 16 / 9;
  box-shadow: 0 28px 68px rgba(17, 24, 39, 0.28);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.18), rgba(17, 24, 39, 0.72));
  cursor: pointer;
}

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

.play-icon {
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 20px 40px rgba(249, 115, 22, 0.34);
  font-size: 30px;
}

.player-overlay strong {
  font-size: 18px;
}

.detail-content p {
  color: #374151;
  font-size: 17px;
  line-height: 1.95;
}

.detail-content h2 + p {
  margin-top: 12px;
}

.related-section {
  width: 100%;
  margin: 24px 0 36px;
}

.site-footer {
  margin-top: 60px;
  padding: 48px 0 24px;
  color: #d1d5db;
  background: linear-gradient(135deg, #111827, #1f2937 55%, #431407);
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 34px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #ffffff;
  font-size: 20px;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 18px;
}

.site-footer p {
  color: #d1d5db;
  line-height: 1.8;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer li + li {
  margin-top: 8px;
}

.site-footer a:hover {
  color: #fbbf24;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 32px auto 0;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #9ca3af;
  font-size: 14px;
}

[hidden] {
  display: none !important;
}

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

  .category-grid,
  .category-grid.large,
  .rank-list.wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-strip {
    display: none;
  }
}

@media (max-width: 880px) {
  .nav-links,
  .nav-search {
    display: none;
  }

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

  .hero-stage {
    min-height: 760px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    padding: 28px;
    gap: 24px;
    align-content: start;
  }

  .hero-media,
  .hero-media img {
    min-height: 320px;
  }

  .hero-controls {
    left: 28px;
    bottom: 24px;
  }

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

  .detail-poster {
    max-width: 320px;
  }
}

@media (max-width: 640px) {
  .nav-shell,
  .content-section,
  .page-hero,
  .detail-page,
  .hero-carousel,
  .footer-grid,
  .footer-bottom {
    width: min(100% - 24px, 1180px);
  }

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

  .hero-stage {
    min-height: 700px;
  }

  .hero-copy h1 {
    font-size: 38px;
  }

  .movie-grid,
  .movie-grid.dense-grid,
  .category-grid,
  .category-grid.large,
  .rank-list,
  .rank-list.wide {
    grid-template-columns: 1fr;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }
}
