:root {
  --emerald: #059669;
  --emerald-dark: #047857;
  --emerald-soft: #d1fae5;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-500: #6b7280;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --white: #ffffff;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, .08);
  --shadow-lg: 0 16px 30px rgba(17, 24, 39, .15);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--gray-900);
  background: linear-gradient(180deg, var(--gray-50), var(--white) 45%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .94);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(10px);
}

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

.brand,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  background: linear-gradient(135deg, #10b981, #047857);
  box-shadow: 0 10px 20px rgba(5, 150, 105, .28);
}

.brand-name {
  font-size: 21px;
  letter-spacing: .02em;
}

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

.nav-link {
  padding: 10px 14px;
  color: var(--gray-700);
  border-radius: 12px;
  font-weight: 600;
  transition: color .2s ease, background .2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--emerald-dark);
  background: var(--emerald-soft);
}

.mobile-menu-button {
  display: none;
  border: 0;
  border-radius: 10px;
  padding: 8px 12px;
  color: var(--gray-700);
  background: var(--gray-100);
  cursor: pointer;
}

.hero {
  position: relative;
  min-height: 520px;
  height: 70vh;
  overflow: hidden;
  color: var(--white);
  background: var(--gray-900);
}

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

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

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

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, .18), rgba(17, 24, 39, .76) 58%, rgba(17, 24, 39, .96));
}

.hero-content {
  position: relative;
  max-width: 1180px;
  height: 100%;
  margin: 0 auto;
  padding: 64px 20px;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 690px;
}

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

.hero-kicker span,
.eyebrow span,
.card-meta span,
.tag-list span,
.detail-meta span,
.filter-row span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 13px;
  font-weight: 700;
}

.hero-kicker span:first-child,
.eyebrow span:first-child {
  color: var(--white);
  background: var(--emerald);
}

.hero-kicker span:not(:first-child),
.eyebrow span:not(:first-child) {
  color: var(--gray-100);
  background: rgba(255, 255, 255, .16);
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(42px, 7vw, 72px);
  line-height: 1.05;
  letter-spacing: -.04em;
}

.hero p {
  max-width: 720px;
  margin: 0 0 30px;
  color: #e5e7eb;
  font-size: clamp(18px, 2vw, 23px);
}

.hero-actions,
.section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 20px;
  border: 0;
  border-radius: 13px;
  color: var(--white);
  background: var(--emerald);
  font-weight: 800;
  box-shadow: 0 12px 24px rgba(5, 150, 105, .26);
  cursor: pointer;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}

.button:hover {
  transform: translateY(-2px) scale(1.02);
  background: var(--emerald-dark);
  box-shadow: 0 18px 34px rgba(5, 150, 105, .32);
}

.button.secondary {
  color: var(--white);
  background: rgba(255, 255, 255, .18);
  box-shadow: none;
  backdrop-filter: blur(8px);
}

.button.light {
  color: var(--emerald-dark);
  background: var(--white);
}

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

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

.hero-dot.active {
  width: 30px;
  background: var(--white);
}

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

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

.section-title {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  letter-spacing: -.03em;
}

.section-subtitle {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--gray-500);
}

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-md);
  transition: transform .22s ease, box-shadow .22s ease;
}

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

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

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

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

.poster-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, .62));
  opacity: .9;
}

.poster-play {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--white);
  background: rgba(5, 150, 105, .94);
  box-shadow: 0 12px 20px rgba(0, 0, 0, .24);
}

.rank-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 2;
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

.card-meta,
.detail-meta,
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 10px;
}

.card-meta span,
.detail-meta span,
.filter-row span {
  color: var(--emerald-dark);
  background: var(--emerald-soft);
}

.movie-card h2 {
  margin: 0 0 8px;
  font-size: 19px;
  line-height: 1.35;
}

.movie-card h2 a:hover {
  color: var(--emerald-dark);
}

.movie-card p {
  margin: 0 0 12px;
  color: var(--gray-500);
  font-size: 14px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag-list span {
  color: var(--gray-700);
  background: var(--gray-100);
  font-weight: 600;
}

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

.category-card {
  min-height: 178px;
  padding: 22px;
  border-radius: var(--radius);
  color: var(--white);
  background: linear-gradient(135deg, #059669, #064e3b);
  box-shadow: var(--shadow-md);
  transition: transform .22s ease, box-shadow .22s ease;
}

.category-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.category-card h2 {
  margin: 0 0 12px;
  font-size: 22px;
}

.category-card p {
  margin: 0;
  color: #d1fae5;
}

.page-hero {
  color: var(--white);
  background: radial-gradient(circle at 18% 20%, rgba(16, 185, 129, .68), transparent 28%), linear-gradient(135deg, #111827, #064e3b);
}

.page-hero .page-section {
  padding-top: 76px;
  padding-bottom: 76px;
}

.page-hero h1 {
  max-width: 820px;
  margin: 0 0 16px;
  font-size: clamp(38px, 6vw, 60px);
  line-height: 1.08;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: #d1d5db;
  font-size: 19px;
}

.search-panel {
  display: grid;
  gap: 14px;
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.search-input {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--gray-200);
  border-radius: 14px;
  padding: 0 16px;
  color: var(--gray-900);
  font-size: 16px;
  outline: none;
}

.search-input:focus {
  border-color: var(--emerald);
  box-shadow: 0 0 0 4px rgba(5, 150, 105, .12);
}

.filter-row button {
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  color: var(--gray-700);
  background: var(--gray-100);
  font-weight: 700;
  cursor: pointer;
}

.filter-row button.active,
.filter-row button:hover {
  color: var(--white);
  background: var(--emerald);
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 74px 96px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.ranking-number {
  font-size: 26px;
  font-weight: 900;
  color: var(--emerald-dark);
  text-align: center;
}

.ranking-row img {
  height: 128px;
  border-radius: 14px;
  object-fit: cover;
}

.ranking-row h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.ranking-row p {
  margin: 0;
  color: var(--gray-500);
}

.ranking-score {
  color: var(--gray-500);
  font-weight: 700;
}

.detail-hero {
  color: var(--white);
  background: linear-gradient(135deg, #111827, #065f46);
}

.detail-wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 48px 20px 32px;
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 34px;
  align-items: end;
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
  aspect-ratio: 3 / 4;
  background: rgba(255, 255, 255, .08);
}

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

.breadcrumb {
  margin-bottom: 18px;
  color: #d1fae5;
  font-size: 14px;
}

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

.detail-info h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.04;
}

.detail-info p {
  max-width: 760px;
  margin: 0 0 20px;
  color: #e5e7eb;
  font-size: 19px;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  box-shadow: var(--shadow-lg);
}

.player-box video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: var(--white);
  background: rgba(0, 0, 0, .35);
  cursor: pointer;
  transition: opacity .2s ease;
}

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

.play-circle {
  width: 92px;
  height: 92px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(5, 150, 105, .94);
  box-shadow: 0 18px 36px rgba(0, 0, 0, .32);
  font-size: 34px;
}

.content-block {
  display: grid;
  gap: 22px;
}

.article-box {
  padding: 28px;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.article-box h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.article-box p {
  margin: 0;
  color: var(--gray-700);
  font-size: 17px;
}

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

.mini-item {
  overflow: hidden;
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.mini-item img {
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.mini-item span {
  display: block;
  padding: 10px 12px;
  font-weight: 700;
}

.no-result {
  display: none;
  padding: 24px;
  border-radius: var(--radius);
  color: var(--gray-500);
  text-align: center;
  background: var(--gray-100);
}

.page-section .eyebrow span:not(:first-child) {
  color: var(--emerald-dark);
  background: var(--emerald-soft);
}

.site-footer {
  margin-top: 40px;
  color: var(--gray-300);
  background: var(--gray-900);
}

.footer-wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 46px 20px;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 32px;
}

.footer-logo {
  color: var(--white);
  font-size: 20px;
}

.footer-brand p {
  max-width: 420px;
  margin: 16px 0 0;
  color: var(--gray-300);
}

.footer-column h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 18px;
}

.footer-links {
  display: grid;
  gap: 8px;
}

.footer-links a {
  color: var(--gray-300);
}

.footer-links a:hover {
  color: #6ee7b7;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .08);
  padding: 18px 20px;
  color: var(--gray-500);
  text-align: center;
}

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

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

  .detail-wrap {
    grid-template-columns: 260px 1fr;
  }
}

@media (max-width: 760px) {
  .nav-wrap {
    height: auto;
    min-height: 64px;
    align-items: flex-start;
    padding-top: 14px;
    padding-bottom: 14px;
  }

  .mobile-menu-button {
    display: inline-flex;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 64px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
    border-radius: 16px;
    background: var(--white);
    box-shadow: var(--shadow-lg);
  }

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

  .hero {
    min-height: 560px;
  }

  .hero-content {
    align-items: end;
    padding-bottom: 88px;
  }

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

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

  .ranking-row {
    grid-template-columns: 48px 82px 1fr;
  }

  .ranking-score {
    display: none;
  }

  .detail-wrap {
    grid-template-columns: 1fr;
    padding-top: 28px;
  }

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

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

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

  .page-section {
    padding-left: 16px;
    padding-right: 16px;
  }
}
