* {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --bg: #fafaf7;
  --panel: #ffffff;
  --panel-soft: #f5f3eb;
  --text: #1c1917;
  --muted: #78716c;
  --line: #e7e5df;
  --green: #15803d;
  --green-dark: #166534;
  --green-soft: #ecfdf3;
  --amber: #d97706;
  --amber-soft: #fef3c7;
  --shadow: 0 18px 45px rgba(28, 25, 23, 0.12);
  --radius: 22px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at top left, rgba(217, 119, 6, 0.08), transparent 34rem), var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(231, 229, 223, 0.9);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 8px 28px rgba(28, 25, 23, 0.06);
  backdrop-filter: blur(16px);
}

.nav-wrap {
  width: min(1180px, calc(100% - 32px));
  height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--amber), var(--green-dark));
  box-shadow: 0 10px 24px rgba(21, 128, 61, 0.25);
}

.brand-mark span {
  width: 0;
  height: 0;
  margin-left: 3px;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 13px solid #ffffff;
}

.brand-name {
  background: linear-gradient(90deg, #92400e, #15803d);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.site-nav a {
  padding: 10px 15px;
  border-radius: 12px;
  color: #57534e;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--green-dark);
  background: var(--green-soft);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #f5f5f4;
  color: #44403c;
}

.hero {
  position: relative;
  min-height: 68vh;
  overflow: hidden;
  background: #111827;
}

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.04);
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.58) 46%, rgba(0, 0, 0, 0.16));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: 68vh;
  margin: 0 auto;
  display: flex;
  align-items: center;
  padding: 60px 0 76px;
}

.hero-copy {
  width: min(690px, 100%);
  color: #ffffff;
}

.hero-kicker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}

.pill,
.tag,
.movie-region,
.rank-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
}

.pill {
  padding: 6px 12px;
  background: var(--green);
  color: #ffffff;
  font-size: 14px;
}

.hero-year {
  color: #fbbf24;
  font-weight: 900;
}

.hero h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 1;
  letter-spacing: -0.05em;
}

.hero-copy p {
  max-width: 620px;
  margin: 20px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 18px;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.hero-tags .tag {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  backdrop-filter: blur(10px);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--green), var(--green-dark));
  color: #ffffff;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(21, 128, 61, 0.26);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 20px 36px rgba(21, 128, 61, 0.32);
}

.btn.secondary {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow: none;
  backdrop-filter: blur(12px);
}

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

.hero-dot {
  width: 34px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
}

.hero-dot.is-active {
  background: #ffffff;
}

.page-hero,
.search-hero,
.detail-head {
  width: min(1180px, calc(100% - 32px));
  margin: 34px auto 0;
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(21, 128, 61, 0.12), rgba(217, 119, 6, 0.14)), #ffffff;
  box-shadow: var(--shadow);
  padding: clamp(28px, 5vw, 54px);
}

.page-hero h1,
.search-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.06;
  letter-spacing: -0.04em;
}

.page-hero p,
.search-hero p,
.detail-copy p {
  max-width: 760px;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.container {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 46px 0;
}

.section-block {
  margin-bottom: 54px;
}

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

.section-head h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -0.03em;
}

.section-head p {
  margin: 6px 0 0;
  color: var(--muted);
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(231, 229, 223, 0.9);
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(28, 25, 23, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 48px rgba(28, 25, 23, 0.16);
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #e7e5df, #fafaf7);
}

.movie-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.42s ease;
}

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

.movie-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), transparent 58%);
  transition: opacity 0.2s ease;
}

.movie-card:hover .movie-cover::after {
  opacity: 1;
}

.movie-region {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 4px 9px;
  background: var(--amber);
  color: #ffffff;
  font-size: 13px;
}

.movie-play {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--green-dark);
  font-size: 24px;
  transform: translate(-50%, -50%) scale(0.5);
  opacity: 0;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.movie-card:hover .movie-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.movie-info {
  padding: 16px;
}

.movie-info h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
}

.movie-info h3 a:hover {
  color: var(--green-dark);
}

.movie-meta {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.movie-line {
  margin: 10px 0 0;
  color: #57534e;
  font-size: 14px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.tag {
  padding: 4px 9px;
  background: var(--green-soft);
  color: var(--green-dark);
  font-size: 12px;
}

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

.category-card {
  display: flex;
  min-height: 230px;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease;
}

.category-card:hover {
  transform: translateY(-4px);
}

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

.category-posters img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 13px;
  object-fit: cover;
  background: #e7e5df;
}

.category-copy {
  padding: 18px;
}

.category-copy h2,
.category-copy h3 {
  margin: 0;
  font-size: 22px;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 54px 74px 1fr;
  align-items: center;
  gap: 14px;
  min-height: 104px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
}

.rank-number {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, var(--amber), var(--green-dark));
  color: #ffffff;
  font-size: 15px;
}

.rank-thumb img {
  width: 74px;
  height: 92px;
  border-radius: 12px;
  object-fit: cover;
  background: #e7e5df;
}

.rank-item h3 {
  margin: 0;
  font-size: 17px;
}

.rank-item p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.search-panel,
.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 180px 180px auto;
  gap: 12px;
  margin: 24px 0 0;
}

.search-panel input,
.search-panel select,
.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #ffffff;
  padding: 0 14px;
  color: var(--text);
  outline: none;
}

.search-panel input:focus,
.search-panel select:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(21, 128, 61, 0.55);
  box-shadow: 0 0 0 4px rgba(21, 128, 61, 0.1);
}

.empty-state {
  display: none;
  margin-top: 24px;
  padding: 24px;
  border-radius: 18px;
  background: #ffffff;
  color: var(--muted);
  text-align: center;
}

.empty-state.is-visible {
  display: block;
}

.detail-head {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
  align-items: center;
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 24px;
  object-fit: cover;
  box-shadow: var(--shadow);
  background: #e7e5df;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--green-dark);
  font-weight: 800;
}

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

.detail-meta span {
  padding: 7px 12px;
  border-radius: 999px;
  background: #ffffff;
  color: #57534e;
  font-weight: 800;
}

.player-card {
  overflow: hidden;
  border-radius: 24px;
  background: #0b0f13;
  box-shadow: var(--shadow);
}

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

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-items: center;
  border: 0;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.48));
  color: #ffffff;
  cursor: pointer;
}

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

.player-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 15px 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--green-dark);
  font-weight: 900;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28);
}

.player-button span:first-child {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--green), var(--green-dark));
  color: #ffffff;
}

.content-card {
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(28, 25, 23, 0.08);
}

.content-card + .content-card {
  margin-top: 22px;
}

.content-card h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.content-card p {
  margin: 0;
  color: #44403c;
  font-size: 17px;
}

.two-column {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}

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

.side-link {
  display: grid;
  grid-template-columns: 58px 1fr;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 16px;
  background: #ffffff;
  border: 1px solid var(--line);
}

.side-link img {
  width: 58px;
  height: 76px;
  border-radius: 12px;
  object-fit: cover;
  background: #e7e5df;
}

.side-link strong {
  display: block;
  line-height: 1.35;
}

.side-link span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.site-footer {
  margin-top: 28px;
  background: linear-gradient(90deg, #1c1917, #292524);
  color: #d6d3d1;
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr 1fr;
  gap: 26px;
  padding: 42px 0;
}

.footer-grid h2,
.footer-grid h3 {
  margin: 0 0 12px;
  color: #ffffff;
}

.footer-grid p,
.footer-grid ul {
  margin: 0;
  padding: 0;
  color: #a8a29e;
  list-style: none;
}

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

.footer-grid a:hover {
  color: #86efac;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 24px;
  border-top: 1px solid rgba(214, 211, 209, 0.16);
  color: #a8a29e;
  text-align: center;
}

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

  .rank-layout,
  .two-column,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .detail-head {
    grid-template-columns: 220px 1fr;
  }
}

@media (max-width: 760px) {
  .nav-wrap {
    height: auto;
    min-height: 64px;
    flex-wrap: wrap;
    padding: 10px 0;
  }

  .nav-toggle {
    display: block;
  }

  .site-nav {
    width: 100%;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding-bottom: 8px;
  }

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

  .hero,
  .hero-content {
    min-height: 74vh;
  }

  .hero-slide::after {
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.28));
  }

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

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

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

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

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

  .rank-item {
    grid-template-columns: 46px 62px 1fr;
  }

  .rank-thumb img {
    width: 62px;
    height: 78px;
  }
}

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

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    width: 100%;
  }
}
