* {
  box-sizing: border-box;
}

:root {
  --green-950: #052e16;
  --green-900: #064e3b;
  --green-800: #065f46;
  --green-700: #047857;
  --green-600: #059669;
  --green-500: #10b981;
  --green-300: #86efac;
  --gray-950: #030712;
  --gray-900: #111827;
  --gray-800: #1f2937;
  --gray-700: #374151;
  --gray-500: #6b7280;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --white: #ffffff;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.16);
  --soft-shadow: 0 12px 28px rgba(15, 23, 42, 0.10);
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--gray-900);
  background: linear-gradient(180deg, #f8fafc 0%, #eef8f1 48%, #ffffff 100%);
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--green-700), var(--green-950));
  box-shadow: 0 12px 26px rgba(4, 120, 87, 0.30);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
  font-weight: 800;
}

.brand-mark {
  font-size: 28px;
}

.brand-text {
  font-size: 20px;
  letter-spacing: 0.02em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-left: auto;
}

.main-nav a,
.mobile-nav a {
  color: rgba(255, 255, 255, 0.88);
  transition: color 0.2s ease, transform 0.2s ease;
}

.main-nav a:hover,
.main-nav a.active,
.mobile-nav a:hover {
  color: var(--green-300);
}

.nav-search {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 10px;
}

.nav-search input {
  width: 180px;
  border: 0;
  outline: 0;
  border-radius: 999px;
  padding: 9px 14px;
  color: var(--white);
  background: rgba(6, 78, 59, 0.75);
}

.nav-search input::placeholder {
  color: rgba(209, 250, 229, 0.72);
}

.nav-search button,
.hero-search button,
.page-search-form button {
  border: 0;
  border-radius: 999px;
  padding: 9px 15px;
  color: var(--green-950);
  background: var(--green-300);
  cursor: pointer;
  font-weight: 700;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: var(--white);
  background: rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  width: 42px;
  height: 42px;
}

.mobile-nav {
  display: none;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
  gap: 14px;
  flex-wrap: wrap;
}

.hero {
  position: relative;
  width: min(1240px, calc(100% - 32px));
  min-height: 620px;
  margin: 26px auto 34px;
  border-radius: 34px;
  overflow: hidden;
  background: radial-gradient(circle at top left, rgba(16, 185, 129, 0.45), transparent 42%), linear-gradient(135deg, #022c22 0%, #052e16 55%, #0f172a 100%);
  box-shadow: var(--shadow);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(6, 78, 59, 0.90), rgba(15, 23, 42, 0.58));
  pointer-events: none;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 48px;
  align-items: center;
  padding: 70px 420px 88px 70px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(90deg, rgba(2, 44, 34, 0.92), rgba(2, 44, 34, 0.62), rgba(15, 23, 42, 0.72)), var(--hero-img);
  background-size: cover;
  background-position: center;
  filter: blur(1px) saturate(0.88);
  transform: scale(1.05);
}

.hero-slide.active {
  opacity: 1;
  visibility: visible;
}

.hero-copy,
.hero-poster {
  position: relative;
  z-index: 1;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  margin-bottom: 14px;
  padding: 7px 13px;
  border-radius: 999px;
  color: #d1fae5;
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid rgba(134, 239, 172, 0.28);
  font-weight: 700;
  font-size: 13px;
}

.hero h1,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  color: var(--white);
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero p,
.page-hero p,
.detail-info .lead {
  max-width: 680px;
  margin: 20px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 18px;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  color: #065f46;
  background: #d1fae5;
  font-size: 12px;
  font-weight: 700;
}

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

.primary-btn,
.ghost-btn,
.section-more,
.category-block-head a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: var(--green-950);
  background: linear-gradient(135deg, #bbf7d0, #34d399);
  box-shadow: 0 12px 24px rgba(16, 185, 129, 0.28);
}

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

.primary-btn:hover,
.ghost-btn:hover,
.section-more:hover,
.category-block-head a:hover {
  transform: translateY(-2px);
}

.hero-poster {
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.38);
  aspect-ratio: 4 / 5;
}

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

.hero-controls {
  position: absolute;
  left: 70px;
  bottom: 34px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 14px;
}

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

.hero-arrow {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: var(--white);
  background: rgba(255, 255, 255, 0.14);
  font-size: 28px;
}

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

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

.hero-dot.active {
  width: 28px;
  background: var(--green-300);
}

.hero-panel {
  position: absolute;
  right: 34px;
  top: 34px;
  bottom: 34px;
  z-index: 4;
  width: 330px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hero-search {
  display: flex;
  gap: 10px;
  padding: 12px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
}

.hero-search input,
.page-search-form input,
.toolbar-section input,
.toolbar-section select {
  min-width: 0;
  border: 1px solid rgba(6, 95, 70, 0.15);
  outline: 0;
  border-radius: 999px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.92);
}

.hero-search input {
  flex: 1;
}

.hero-mini-list {
  display: grid;
  gap: 12px;
  padding: 12px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.10);
  backdrop-filter: blur(14px);
}

.hero-mini,
.rank-item {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  gap: 12px;
  color: var(--white);
  padding: 8px;
  border-radius: 18px;
  transition: background 0.2s ease;
}

.hero-mini:hover,
.rank-item:hover {
  background: rgba(255, 255, 255, 0.10);
}

.hero-mini img,
.rank-item img {
  width: 54px;
  height: 66px;
  border-radius: 14px;
  object-fit: cover;
}

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

.content-section {
  margin-top: 46px;
}

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

.section-heading h2,
.article-section h2,
.category-block h2 {
  margin: 0;
  color: var(--gray-950);
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.03em;
}

.section-heading p,
.category-block p,
.article-section p {
  margin: 6px 0 0;
  color: var(--gray-500);
}

.section-more,
.category-block-head a {
  color: var(--white);
  background: var(--green-700);
  box-shadow: var(--soft-shadow);
}

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

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

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--green-950);
}

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

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

.card-badge,
.play-dot {
  position: absolute;
  z-index: 2;
}

.card-badge {
  top: 12px;
  left: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--white);
  background: var(--green-600);
  font-size: 12px;
  font-weight: 800;
}

.play-dot {
  right: 12px;
  bottom: 12px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--green-950);
  background: #bbf7d0;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.20);
}

.card-body {
  padding: 17px;
}

.card-title {
  display: -webkit-box;
  min-height: 50px;
  overflow: hidden;
  color: var(--gray-950);
  font-weight: 850;
  font-size: 18px;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-body p {
  display: -webkit-box;
  min-height: 44px;
  margin: 10px 0 0;
  overflow: hidden;
  color: var(--gray-500);
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  color: var(--gray-500);
  font-size: 12px;
}

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

.category-tile {
  min-height: 130px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 20px;
  border-radius: 24px;
  color: var(--white);
  background: radial-gradient(circle at top right, rgba(134, 239, 172, 0.34), transparent 42%), linear-gradient(135deg, var(--green-800), var(--green-950));
  box-shadow: var(--soft-shadow);
  transition: transform 0.2s ease;
}

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

.category-tile span {
  font-size: 21px;
  font-weight: 850;
}

.category-tile em {
  margin-top: 6px;
  color: rgba(209, 250, 229, 0.78);
  font-style: normal;
}

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

.rank-item {
  grid-template-columns: 34px 54px 1fr;
  color: var(--gray-950);
  background: var(--white);
  box-shadow: var(--soft-shadow);
}

.rank-num {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: var(--white);
  background: var(--green-700);
  font-weight: 850;
}

.rank-title,
.rank-desc {
  display: block;
}

.rank-title {
  font-weight: 800;
}

.rank-desc {
  color: var(--gray-500);
  font-size: 13px;
}

.page-main,
.detail-main {
  padding: 28px 0 60px;
}

.page-hero {
  padding: 56px;
  border-radius: 34px;
  color: var(--white);
  background: radial-gradient(circle at right top, rgba(187, 247, 208, 0.30), transparent 38%), linear-gradient(135deg, var(--green-800), var(--green-950));
  box-shadow: var(--shadow);
}

.page-hero.small-hero,
.channel-hero,
.library-hero,
.ranking-hero,
.search-hero {
  min-height: 240px;
}

.category-block {
  margin-top: 24px;
  padding: 24px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--soft-shadow);
}

.category-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

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

.mini-card-row .rank-item {
  grid-template-columns: 54px 1fr;
}

.toolbar-section {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0;
  padding: 16px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--soft-shadow);
}

.toolbar-section input {
  flex: 1 1 260px;
}

.plain-section {
  margin-top: 24px;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 52px 84px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: 22px;
  background: var(--white);
  box-shadow: var(--soft-shadow);
  transition: transform 0.2s ease;
}

.ranking-row:hover {
  transform: translateY(-3px);
}

.ranking-row img {
  width: 84px;
  height: 96px;
  object-fit: cover;
  border-radius: 16px;
}

.rank-num.large {
  width: 42px;
  height: 42px;
}

.ranking-info strong,
.ranking-info em {
  display: block;
}

.ranking-info strong {
  color: var(--gray-950);
  font-size: 18px;
}

.ranking-info em,
.ranking-meta {
  color: var(--gray-500);
  font-style: normal;
}

.ranking-info em {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.page-search-form {
  display: flex;
  gap: 12px;
  max-width: 620px;
  margin-top: 26px;
}

.page-search-form input {
  flex: 1;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 20px;
  color: var(--gray-500);
}

.breadcrumb a {
  color: var(--green-700);
  font-weight: 700;
}

.detail-hero {
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 40px;
  align-items: center;
  padding: 38px;
  border-radius: 34px;
  background: linear-gradient(135deg, var(--green-900), var(--gray-950));
  box-shadow: var(--shadow);
}

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 24px 54px rgba(0, 0, 0, 0.34);
  aspect-ratio: 4 / 5;
}

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

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

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  color: #d1fae5;
  background: rgba(255, 255, 255, 0.11);
}

.player-section {
  margin-top: 28px;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: var(--gray-950);
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at center, rgba(5, 150, 105, 0.34), rgba(0, 0, 0, 0.54));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-cover button {
  width: 90px;
  height: 90px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: var(--green-950);
  background: #bbf7d0;
  font-size: 36px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.36);
}

.article-section {
  margin-top: 28px;
  padding: 34px;
  border-radius: 28px;
  background: var(--white);
  box-shadow: var(--soft-shadow);
}

.article-section h2 + p {
  margin-bottom: 24px;
}

.site-footer {
  margin-top: 64px;
  color: rgba(255, 255, 255, 0.78);
  background: linear-gradient(90deg, var(--gray-950), #0b1f17);
}

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

.footer-brand {
  color: var(--white);
  font-weight: 850;
  font-size: 22px;
  margin-bottom: 12px;
}

.footer-grid h3 {
  margin: 0 0 12px;
  color: var(--white);
}

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

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

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
  color: rgba(255, 255, 255, 0.58);
}

.hidden-card {
  display: none !important;
}

@media (max-width: 1100px) {
  .hero-slide {
    grid-template-columns: 1fr 280px;
    padding-right: 56px;
  }

  .hero-panel {
    position: relative;
    inset: auto;
    width: auto;
    padding: 0 34px 34px;
  }

  .hero {
    min-height: auto;
  }

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

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

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

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

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

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

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

  .hero-slide {
    position: relative;
    padding: 46px 26px 98px;
  }

  .hero-stage {
    min-height: auto;
  }

  .hero-poster {
    max-width: 280px;
  }

  .hero-controls {
    left: 26px;
  }

  .movie-grid,
  .mini-card-row,
  .rank-list,
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ranking-row {
    grid-template-columns: 42px 72px 1fr;
  }

  .ranking-meta {
    grid-column: 3;
  }
}

@media (max-width: 560px) {
  .nav-shell {
    height: 62px;
  }

  .brand-text {
    font-size: 17px;
  }

  .hero,
  .page-hero,
  .detail-hero,
  .article-section {
    border-radius: 24px;
  }

  .hero h1,
  .page-hero h1,
  .detail-info h1 {
    font-size: 34px;
  }

  .page-hero,
  .detail-hero,
  .article-section {
    padding: 26px;
  }

  .hero-search,
  .page-search-form,
  .toolbar-section {
    flex-direction: column;
  }

  .movie-grid,
  .mini-card-row,
  .rank-list,
  .category-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .category-block-head,
  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .ranking-row img {
    width: 68px;
    height: 82px;
  }
}
