:root {
  --bg: #f7fbfa;
  --card: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: rgba(15, 23, 42, 0.1);
  --primary: #059669;
  --primary-dark: #047857;
  --soft: #ecfdf5;
  --shadow: 0 24px 70px rgba(15, 23, 42, 0.14);
  --radius: 24px;
}

* {
  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 10% 0%, rgba(16, 185, 129, 0.18), transparent 32rem),
    linear-gradient(180deg, #f8fffc 0%, #eef7f5 48%, #f8fafc 100%);
  line-height: 1.65;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.header-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 22px;
  font-weight: 800;
  color: #064e3b;
  letter-spacing: -0.03em;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  color: white;
  background: linear-gradient(135deg, #10b981, #047857 60%, #065f46);
  box-shadow: 0 12px 28px rgba(5, 150, 105, 0.32);
}

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

.nav-link {
  padding: 10px 16px;
  border-radius: 999px;
  color: #334155;
  font-weight: 700;
  transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #065f46;
  background: #d1fae5;
}

.quick-nav {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 12px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 3px;
}

.quick-nav a {
  white-space: nowrap;
  border-radius: 999px;
  background: rgba(236, 253, 245, 0.88);
  border: 1px solid rgba(5, 150, 105, 0.16);
  color: #047857;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  background: #ecfdf5;
  padding: 10px;
}

.menu-toggle span {
  display: block;
  height: 2px;
  background: #047857;
  margin: 5px 0;
  border-radius: 999px;
}

main,
.page-shell,
.detail-page {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.hero {
  position: relative;
  min-height: 620px;
  margin: 26px auto 32px;
  border-radius: 36px;
  overflow: hidden;
  background: #064e3b;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) 360px;
  gap: 40px;
  align-items: center;
  padding: 72px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  opacity: 0.42;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(12px) saturate(1.25);
  transform: scale(1.05);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 44, 34, 0.96) 0%, rgba(4, 120, 87, 0.82) 48%, rgba(15, 23, 42, 0.58) 100%),
    radial-gradient(circle at 76% 28%, rgba(16, 185, 129, 0.42), transparent 28rem);
  z-index: 1;
}

.hero-content,
.hero-poster {
  position: relative;
  z-index: 2;
}

.eyebrow {
  margin: 0 0 10px;
  color: #059669;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero-content .eyebrow {
  color: #a7f3d0;
}

.hero h1 {
  margin: 0 0 14px;
  max-width: 780px;
  color: white;
  font-size: clamp(34px, 5vw, 68px);
  line-height: 1.03;
  letter-spacing: -0.06em;
}

.hero h2 {
  margin: 0 0 16px;
  color: #d1fae5;
  font-size: clamp(24px, 3vw, 42px);
  line-height: 1.15;
}

.hero-summary {
  max-width: 720px;
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
}

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

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

.primary-btn {
  color: white;
  background: linear-gradient(135deg, #10b981, #047857);
  box-shadow: 0 14px 34px rgba(5, 150, 105, 0.34);
}

.ghost-btn {
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.11);
}

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

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

.hero-tags span,
.card-tags span,
.detail-meta span {
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.16);
  color: #ecfdf5;
  font-size: 13px;
  font-weight: 800;
}

.card-tags span,
.detail-meta span {
  color: #047857;
  background: #ecfdf5;
}

.hero-poster {
  align-self: center;
  display: block;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.42);
  transform: rotate(2deg);
}

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

.hero-poster span {
  position: absolute;
  left: 22px;
  bottom: 22px;
  display: inline-flex;
  border-radius: 999px;
  padding: 10px 16px;
  color: white;
  background: rgba(5, 150, 105, 0.92);
  font-weight: 900;
}

.hero-dots {
  position: absolute;
  left: 72px;
  bottom: 42px;
  z-index: 4;
  display: flex;
  gap: 10px;
}

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

.hero-dot.active {
  background: white;
}

.category-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin: 26px 0 40px;
}

.category-tile {
  position: relative;
  min-height: 150px;
  border-radius: 24px;
  overflow: hidden;
  background: #064e3b;
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.12);
}

.category-tile img {
  width: 100%;
  height: 100%;
  min-height: 150px;
  object-fit: cover;
  opacity: 0.58;
  transition: transform 0.25s ease;
}

.category-tile:hover img {
  transform: scale(1.06);
}

.category-tile span,
.category-tile small {
  position: absolute;
  left: 18px;
  color: white;
  z-index: 2;
}

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

.category-tile small {
  bottom: 16px;
  color: #d1fae5;
  font-weight: 800;
}

.content-section {
  margin: 54px 0;
}

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

.section-title h2,
.page-hero h1,
.detail-info h1,
.detail-copy h2,
.home-search-panel h2 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(26px, 3vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-more {
  color: #047857;
  font-weight: 900;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--card);
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 56px rgba(15, 23, 42, 0.14);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #064e3b;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.25s ease;
}

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

.poster-badge,
.poster-play {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: white;
  font-weight: 900;
}

.poster-badge {
  left: 12px;
  top: 12px;
  padding: 5px 10px;
  background: rgba(4, 120, 87, 0.92);
  font-size: 12px;
}

.poster-play {
  right: 12px;
  bottom: 12px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.72);
}

.card-body {
  padding: 16px;
}

.card-body h3 {
  margin: 0 0 7px;
  font-size: 18px;
  line-height: 1.3;
}

.card-body h3 a:hover {
  color: var(--primary);
}

.card-meta {
  margin: 0 0 9px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.card-desc {
  margin: 0 0 12px;
  min-height: 52px;
  color: #475569;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 22px;
  align-items: stretch;
}

.rank-list,
.home-search-panel,
.page-hero,
.detail-copy,
.filter-bar {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
}

.rank-list {
  overflow: hidden;
}

.rank-row {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
}

.rank-row:last-child {
  border-bottom: 0;
}

.rank-row:hover {
  background: #ecfdf5;
}

.rank-num {
  color: #059669;
  font-weight: 950;
}

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

.rank-meta {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.home-search-panel {
  padding: 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.home-search-panel p {
  color: var(--muted);
}

.page-shell {
  padding-top: 28px;
}

.page-hero {
  padding: 46px;
  margin-bottom: 28px;
  background:
    linear-gradient(135deg, rgba(236, 253, 245, 0.96), rgba(255, 255, 255, 0.92)),
    radial-gradient(circle at 90% 10%, rgba(16, 185, 129, 0.28), transparent 22rem);
}

.page-hero p {
  max-width: 760px;
  color: #475569;
}

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

.category-card a {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 20px;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--card);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

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

.category-card div {
  padding: 24px 24px 24px 0;
}

.category-card h2 {
  margin: 0 0 10px;
}

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

.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 14px;
  padding: 16px;
  margin-bottom: 24px;
}

.filter-bar label {
  display: grid;
  gap: 6px;
  color: #047857;
  font-size: 13px;
  font-weight: 900;
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: white;
  color: var(--ink);
  padding: 0 14px;
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus {
  border-color: rgba(5, 150, 105, 0.55);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

.listing-grid {
  margin-bottom: 58px;
}

.detail-page {
  padding-top: 24px;
}

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

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

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.42fr) minmax(300px, 0.8fr);
  gap: 24px;
  align-items: stretch;
}

.player-card {
  position: relative;
  overflow: hidden;
  min-height: 460px;
  border-radius: 32px;
  background: #020617;
  box-shadow: var(--shadow);
}

.player-card video {
  width: 100%;
  height: 100%;
  min-height: 460px;
  object-fit: contain;
  background: #020617;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  cursor: pointer;
  background: #020617;
  transition: opacity 0.22s ease, visibility 0.22s ease;
  z-index: 4;
}

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

.player-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
}

.big-play {
  position: relative;
  z-index: 5;
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 50%;
  color: white;
  background: linear-gradient(135deg, #10b981, #047857);
  font-size: 32px;
  box-shadow: 0 20px 50px rgba(4, 120, 87, 0.42);
}

.detail-info {
  border: 1px solid var(--line);
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.92);
  padding: 34px;
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
}

.detail-info .lead {
  color: #334155;
  font-size: 18px;
}

.detail-info .primary-btn {
  margin-top: 22px;
}

.detail-tags span {
  color: #047857;
  background: #ecfdf5;
}

.detail-copy {
  padding: 34px;
  margin: 28px 0 20px;
}

.detail-copy h2 {
  margin-top: 10px;
  margin-bottom: 10px;
  font-size: 28px;
}

.detail-copy p {
  color: #334155;
  font-size: 17px;
}

.full-rank {
  margin-bottom: 58px;
}

.rank-row.full {
  grid-template-columns: 74px minmax(0, 1fr) auto;
}

.site-footer {
  margin-top: 70px;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  color: var(--muted);
}

.footer-grid strong {
  display: block;
  color: #064e3b;
  font-size: 22px;
  margin-bottom: 8px;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 900;
  color: #047857;
}

.is-filtered-out {
  display: none !important;
}

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

  .hero-slide,
  .detail-hero,
  .split-section {
    grid-template-columns: 1fr;
  }

  .hero-slide {
    padding: 48px;
  }

  .hero-poster {
    display: none;
  }

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

@media (max-width: 760px) {
  .header-shell {
    min-height: 64px;
  }

  .menu-toggle {
    display: block;
  }

  .main-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 70px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: white;
    box-shadow: var(--shadow);
  }

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

  .nav-link {
    text-align: center;
  }

  .hero {
    min-height: 620px;
    border-radius: 26px;
  }

  .hero-slide {
    padding: 34px 24px;
  }

  .hero-dots {
    left: 24px;
    bottom: 24px;
  }

  .category-strip,
  .movie-grid,
  .category-grid,
  .filter-bar {
    grid-template-columns: 1fr;
  }

  .category-card a {
    grid-template-columns: 1fr;
  }

  .category-card div {
    padding: 22px;
  }

  .rank-row,
  .rank-row.full {
    grid-template-columns: 48px minmax(0, 1fr);
  }

  .rank-meta {
    grid-column: 2;
  }

  .player-card,
  .player-card video {
    min-height: 280px;
  }

  .footer-grid,
  .footer-links {
    flex-direction: column;
    align-items: flex-start;
  }
}
