* {
  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: #17251f;
  background: #f3f8f4;
  line-height: 1.6;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
}

.top-nav {
  color: #ffffff;
  background: linear-gradient(135deg, #047857 0%, #065f46 55%, #064e3b 100%);
  box-shadow: 0 16px 34px rgba(4, 120, 87, 0.22);
}

.nav-inner {
  max-width: 1240px;
  height: 68px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

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

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

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: 1;
}

.nav-link {
  font-size: 15px;
  opacity: 0.92;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #bbf7d0;
  opacity: 1;
}

.nav-link.soft {
  font-size: 14px;
  color: #d1fae5;
}

.site-search-form {
  width: min(270px, 26vw);
  display: flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(6, 95, 70, 0.92);
  overflow: hidden;
  border: 1px solid rgba(187, 247, 208, 0.24);
}

.site-search-form input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #ffffff;
  background: transparent;
  padding: 10px 12px 10px 16px;
}

.site-search-form input::placeholder {
  color: #bbf7d0;
}

.site-search-form button {
  border: 0;
  color: #d1fae5;
  background: transparent;
  padding: 8px 14px;
  cursor: pointer;
}

.mobile-menu-button {
  display: none;
  color: #ffffff;
  background: rgba(6, 95, 70, 0.72);
  border: 0;
  border-radius: 10px;
  padding: 9px 12px;
  cursor: pointer;
}

.mobile-nav {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 22px 18px;
}

.mobile-link {
  display: block;
  padding: 10px 0;
  color: #ffffff;
  border-top: 1px solid rgba(209, 250, 229, 0.12);
}

.mobile-link.is-active {
  color: #bbf7d0;
}

.mobile-search {
  width: 100%;
  margin: 8px 0 12px;
}

.hero-carousel {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: #052e26;
}

.hero-background {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 16% 18%, rgba(52, 211, 153, 0.34), transparent 30%),
    radial-gradient(circle at 82% 10%, rgba(16, 185, 129, 0.26), transparent 26%),
    linear-gradient(135deg, #064e3b 0%, #052e26 50%, #021c17 100%);
}

.hero-viewport {
  position: relative;
  max-width: 1240px;
  min-height: 560px;
  margin: 0 auto;
  padding: 70px 22px 72px;
}

.hero-slide {
  display: none;
  align-items: center;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.68fr);
  gap: 54px;
  animation: fadeIn 0.6s ease both;
}

.hero-slide.is-active {
  display: grid;
}

.hero-content h1 {
  max-width: 760px;
  margin: 14px 0 18px;
  font-size: clamp(36px, 7vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero-content p {
  max-width: 740px;
  margin: 0;
  color: #d1fae5;
  font-size: 18px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: max-content;
  color: #dcfce7;
  background: rgba(34, 197, 94, 0.22);
  border: 1px solid rgba(187, 247, 208, 0.28);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  margin: 22px 0 28px;
}

.hero-tags span,
.tag-row span {
  color: #065f46;
  background: #dcfce7;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 700;
}

.hero-actions,
.category-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.primary-button,
.secondary-button,
.text-button,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #064e3b;
  background: #bbf7d0;
  padding: 12px 22px;
  box-shadow: 0 14px 30px rgba(34, 197, 94, 0.26);
}

.secondary-button {
  color: #ffffff;
  border: 1px solid rgba(220, 252, 231, 0.45);
  padding: 11px 20px;
}

.primary-button:hover,
.secondary-button:hover,
.text-button:hover,
.section-more:hover {
  transform: translateY(-2px);
}

.hero-cover {
  position: relative;
  min-height: 420px;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.42);
  transform: rotate(1deg);
}

.hero-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0, 0, 0, 0.52) 100%);
}

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

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

.hero-dot {
  width: 11px;
  height: 11px;
  border: 0;
  border-radius: 999px;
  background: rgba(220, 252, 231, 0.48);
  cursor: pointer;
}

.hero-dot.is-active {
  width: 30px;
  background: #bbf7d0;
}

.quick-search-panel,
.content-section,
.page-main,
.category-overview-list,
.filter-panel,
.text-section,
.player-section {
  max-width: 1240px;
  margin-left: auto;
  margin-right: auto;
}

.quick-search-panel {
  margin-top: -34px;
  padding: 28px;
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(280px, 0.7fr);
  gap: 22px;
  align-items: center;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.12);
}

.quick-search-panel h2,
.section-heading h2,
.text-section h2,
.player-section h2 {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  color: #12372c;
}

.quick-search-panel p,
.section-heading p,
.text-section p,
.player-section p {
  color: #53645d;
}

.large-search {
  display: flex;
  padding: 7px;
  border-radius: 999px;
  background: #ecfdf5;
  border: 1px solid #bbf7d0;
}

.large-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  padding: 13px 18px;
}

.large-search button {
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: #047857;
  padding: 0 22px;
  cursor: pointer;
}

.content-section {
  padding: 56px 22px 0;
}

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

.section-heading p {
  margin: 6px 0 0;
}

.section-more,
.text-button {
  color: #047857;
  background: #dcfce7;
  padding: 9px 16px;
}

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

.movie-card {
  background: #ffffff;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.09);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 52px rgba(15, 23, 42, 0.15);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #0f2d25;
}

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

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

.poster-link::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(180deg, transparent 34%, rgba(0, 0, 0, 0.55));
  transition: opacity 0.25s ease;
}

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

.card-badge,
.year-badge,
.rank-number {
  position: absolute;
  z-index: 2;
  color: #ffffff;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  padding: 5px 10px;
}

.card-badge {
  top: 12px;
  left: 12px;
  background: #16a34a;
}

.year-badge {
  right: 12px;
  bottom: 12px;
  background: rgba(5, 46, 38, 0.78);
}

.rank-number {
  left: 12px;
  bottom: 12px;
  background: #f59e0b;
}

.card-body {
  padding: 18px;
}

.card-body h3 {
  margin: 0 0 8px;
  color: #17251f;
  font-size: 18px;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}

.card-body h3 a:hover {
  color: #047857;
}

.card-body p {
  min-height: 48px;
  margin: 0 0 12px;
  color: #64736d;
  font-size: 14px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  color: #64736d;
  font-size: 12px;
}

.card-meta span {
  padding: 3px 7px;
  border-radius: 999px;
  background: #f0fdf4;
}

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

.category-card {
  min-height: 190px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 24px;
  color: #ffffff;
  padding: 22px;
  background: linear-gradient(135deg, #047857, #064e3b);
  box-shadow: 0 18px 42px rgba(4, 120, 87, 0.2);
  overflow: hidden;
}

.category-card span {
  font-size: 22px;
  font-weight: 900;
}

.category-card strong {
  display: block;
  margin: 18px 0;
  color: #d1fae5;
  font-size: 14px;
  font-weight: 500;
}

.category-card em {
  display: flex;
  flex-direction: column;
  gap: 3px;
  color: #bbf7d0;
  font-style: normal;
  font-size: 12px;
}

.highlight-section,
.ranking-strip {
  padding-bottom: 12px;
}

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

.movie-card.compact .card-body {
  padding: 14px;
}

.movie-card.compact .card-body p,
.movie-card.compact .tag-row {
  display: none;
}

.page-main {
  padding: 34px 22px 0;
}

.page-hero {
  border-radius: 30px;
  padding: 52px;
  color: #ffffff;
  background:
    radial-gradient(circle at 85% 12%, rgba(187, 247, 208, 0.34), transparent 28%),
    linear-gradient(135deg, #065f46, #022c22);
  box-shadow: 0 22px 64px rgba(6, 78, 59, 0.22);
}

.page-hero h1 {
  margin: 16px 0 12px;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.1;
}

.page-hero p {
  max-width: 820px;
  margin: 0;
  color: #d1fae5;
  font-size: 17px;
}

.filter-panel {
  margin-top: 28px;
  padding: 22px;
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 16px;
  align-items: center;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.09);
}

.filter-panel label {
  color: #12372c;
  font-weight: 900;
}

.filter-panel input {
  width: 100%;
  border: 1px solid #bbf7d0;
  border-radius: 999px;
  outline: 0;
  padding: 13px 18px;
  background: #f0fdf4;
}

.all-list-section {
  padding-left: 0;
  padding-right: 0;
}

.category-overview-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  padding-top: 36px;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 22px;
  border-radius: 26px;
  background: #ffffff;
  padding: 18px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.1);
}

.category-poster-stack {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
}

.category-poster-stack img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 14px;
}

.category-overview-card h2 {
  margin: 4px 0 8px;
  color: #12372c;
}

.category-overview-card p {
  margin: 0 0 14px;
  color: #64736d;
}

.category-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.category-samples a {
  color: #047857;
  background: #dcfce7;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 700;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: #047857;
  margin-bottom: 20px;
  font-size: 14px;
}

.detail-hero {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
  border-radius: 30px;
  padding: 28px;
  color: #ffffff;
  background:
    radial-gradient(circle at 84% 18%, rgba(187, 247, 208, 0.26), transparent 28%),
    linear-gradient(135deg, #064e3b, #021c17);
  box-shadow: 0 22px 64px rgba(6, 78, 59, 0.22);
}

.detail-poster {
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

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

.detail-info h1 {
  margin: 16px 0 12px;
  font-size: clamp(32px, 5vw, 58px);
  line-height: 1.1;
}

.detail-one-line {
  margin: 0 0 20px;
  color: #d1fae5;
  font-size: 18px;
}

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

.detail-meta-grid span {
  display: grid;
  gap: 4px;
  border-radius: 16px;
  padding: 12px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.detail-meta-grid strong {
  color: #bbf7d0;
  font-size: 12px;
}

.large-tags {
  margin-bottom: 24px;
}

.player-section {
  padding-top: 38px;
}

.player-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 28px;
  overflow: hidden;
  background: #000000;
  box-shadow: 0 26px 72px rgba(15, 23, 42, 0.28);
}

.movie-player,
.player-cover,
.player-cover img {
  width: 100%;
  height: 100%;
}

.movie-player {
  display: block;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 4;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #000000;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-cover img {
  object-fit: cover;
  opacity: 0.72;
}

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

.play-icon {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  color: #064e3b;
  background: #bbf7d0;
  border-radius: 999px;
  font-size: 32px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.34);
}

.text-section {
  margin-top: 36px;
  padding: 30px;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.09);
}

.text-section p {
  margin: 14px 0 0;
  font-size: 16px;
}

.related-section {
  padding-left: 0;
  padding-right: 0;
}

.site-footer {
  margin-top: 70px;
  color: #d1fae5;
  background: #111827;
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 34px 22px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  display: inline-block;
  margin-bottom: 8px;
  color: #ffffff;
  font-size: 22px;
  font-weight: 900;
}

.footer-inner p {
  margin: 0;
  color: #9ca3af;
}

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

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

.footer-bottom {
  max-width: 1240px;
  margin: 0 auto;
  padding: 18px 22px 28px;
  color: #9ca3af;
  border-top: 1px solid rgba(156, 163, 175, 0.2);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1100px) {
  .desktop-nav {
    display: none;
  }

  .site-search-form {
    margin-left: auto;
  }

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

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

  .category-overview-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .nav-inner {
    gap: 12px;
  }

  .site-search-form:not(.mobile-search) {
    display: none;
  }

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

  .hero-viewport {
    min-height: auto;
    padding-top: 44px;
  }

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

  .hero-cover {
    min-height: 320px;
  }

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

  .quick-search-panel {
    margin-left: 16px;
    margin-right: 16px;
  }

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

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

  .detail-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .page-hero,
  .detail-hero {
    padding: 30px;
  }
}

@media (max-width: 560px) {
  .brand-text {
    font-size: 18px;
  }

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

  .movie-grid,
  .ranking-grid,
  .ranking-list,
  .category-grid {
    grid-template-columns: 1fr;
  }

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

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

  .large-search {
    border-radius: 22px;
    flex-direction: column;
    align-items: stretch;
  }

  .large-search button {
    padding: 12px 18px;
  }
}
