:root {
  --bg: #f6f8fb;
  --paper: #ffffff;
  --ink: #101827;
  --muted: #667085;
  --soft: #e6edf3;
  --primary: #059669;
  --primary-dark: #047857;
  --teal: #0d9488;
  --cyan: #0891b2;
  --night: #111827;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 8px 22px rgba(15, 23, 42, 0.08);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(14px);
}

.nav-shell {
  max-width: 1220px;
  height: 68px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.brand-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  box-shadow: 0 10px 20px rgba(5, 150, 105, 0.28);
}

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

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

.nav-link,
.nav-dropdown > button {
  padding: 9px 13px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #344054;
  font-size: 15px;
  font-weight: 650;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.nav-dropdown:hover > button {
  color: var(--primary-dark);
  background: #ecfdf5;
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-panel {
  position: absolute;
  top: 42px;
  right: 0;
  min-width: 168px;
  padding: 10px;
  display: none;
  border: 1px solid var(--soft);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.nav-dropdown:hover .nav-dropdown-panel {
  display: grid;
  gap: 4px;
}

.nav-dropdown-panel a {
  padding: 9px 11px;
  border-radius: 12px;
  color: #475467;
  font-size: 14px;
}

.nav-dropdown-panel a:hover {
  color: var(--primary-dark);
  background: #f0fdfa;
}

.nav-toggle {
  width: 42px;
  height: 42px;
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  border: 0;
  border-radius: 14px;
  background: #f2f4f7;
}

.nav-toggle span {
  width: 20px;
  height: 2px;
  margin: 0 auto;
  border-radius: 999px;
  background: #182230;
}

.hero-carousel {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  background: #08111f;
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.55s ease;
}

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

.hero-slide > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
  filter: saturate(1.08);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 78% 22%, rgba(13, 148, 136, 0.34), transparent 36%),
    linear-gradient(90deg, rgba(5, 12, 24, 0.96), rgba(5, 12, 24, 0.72) 42%, rgba(5, 12, 24, 0.32)),
    linear-gradient(0deg, rgba(5, 12, 24, 0.88), transparent 42%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1220px;
  min-height: 620px;
  margin: 0 auto;
  padding: 94px 22px 92px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #fff;
}

.hero-eyebrow,
.eyebrow {
  margin: 0 0 10px;
  color: #34d399;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero-content h1,
.hero-content h2,
.hero-content h3 {
  max-width: 760px;
  margin: 0;
  font-weight: 900;
  line-height: 1.06;
  letter-spacing: -0.05em;
}

.hero-content h1 {
  margin-bottom: 14px;
  font-size: clamp(38px, 7vw, 76px);
}

.hero-content h2,
.hero-content h3 {
  margin-bottom: 18px;
  font-size: clamp(32px, 5vw, 58px);
}

.hero-content p:not(.hero-eyebrow) {
  max-width: 680px;
  margin: 0 0 26px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
}

.hero-actions,
.detail-nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 13px;
}

.btn {
  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;
}

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

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  box-shadow: 0 18px 28px rgba(5, 150, 105, 0.28);
}

.btn-ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.34);
  backdrop-filter: blur(8px);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 50%;
  color: #fff;
  background: rgba(15, 23, 42, 0.36);
  font-size: 36px;
  line-height: 1;
  backdrop-filter: blur(8px);
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-control:hover {
  background: rgba(5, 150, 105, 0.8);
  transform: translateY(-50%) scale(1.06);
}

.hero-prev {
  left: 24px;
  transform: translateY(-50%);
}

.hero-next {
  right: 24px;
  transform: translateY(-50%);
}

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

.hero-dots button {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.46);
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dots button.is-active {
  width: 28px;
  background: #fff;
}

.section-shell {
  max-width: 1220px;
  margin: 0 auto;
  padding: 54px 22px 0;
}

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

.section-title-row h2,
.panel-head h2,
.footer-links h2 {
  margin: 0;
  color: #101828;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.15;
  letter-spacing: -0.035em;
}

.text-link {
  color: var(--primary-dark);
  font-weight: 800;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 180px 180px;
  gap: 12px;
  margin-bottom: 22px;
  padding: 14px;
  border: 1px solid #d9e4e9;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-soft);
}

.filter-panel label {
  display: grid;
  gap: 5px;
  color: #475467;
  font-size: 13px;
  font-weight: 700;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid #d0d5dd;
  border-radius: 14px;
  outline: none;
  background: #fff;
  color: #182230;
  font: inherit;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #10b981;
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.14);
}

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

.category-card,
.category-overview-card,
.content-card,
.ranking-panel {
  border: 1px solid #e2e8f0;
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
}

.category-card {
  min-height: 178px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.category-card:hover,
.movie-card:hover,
.category-overview-card:hover {
  transform: translateY(-5px);
  border-color: #a7f3d0;
  box-shadow: var(--shadow);
}

.category-card span,
.category-overview-head span {
  color: #101828;
  font-size: 20px;
  font-weight: 850;
}

.category-card p,
.category-overview-card p,
.movie-desc,
.content-card p,
.footer-brand p {
  margin: 0;
  color: var(--muted);
}

.category-card div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.category-card div a {
  padding: 5px 9px;
  border-radius: 999px;
  color: #047857;
  background: #ecfdf5;
  font-size: 12px;
  font-weight: 750;
}

.two-column-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  align-items: start;
  gap: 24px;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid #e4e7ec;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

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

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

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

.poster-year {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #fff;
  background: rgba(17, 24, 39, 0.7);
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(7px);
}

.movie-card-body {
  padding: 15px;
}

.movie-meta {
  margin: 0 0 7px;
  color: #059669;
  font-size: 12px;
  font-weight: 800;
}

.movie-card h3 {
  margin: 0 0 8px;
  color: #101828;
  font-size: 18px;
  line-height: 1.25;
}

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

.movie-desc {
  display: -webkit-box;
  min-height: 45px;
  overflow: hidden;
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.tag-row span {
  padding: 4px 8px;
  border-radius: 999px;
  color: #047857;
  background: #ecfdf5;
  font-size: 12px;
  font-weight: 750;
}

.ranking-panel {
  position: sticky;
  top: 88px;
  padding: 20px;
}

.panel-head {
  margin-bottom: 14px;
}

.rank-list {
  display: grid;
  gap: 10px;
}

.rank-row {
  display: grid;
  grid-template-columns: 38px 58px minmax(0, 1fr) 46px;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  background: #f8fafc;
  transition: background 0.2s ease, transform 0.2s ease;
}

.full-rank .rank-row {
  grid-template-columns: 48px 78px minmax(0, 1fr) 60px;
  padding: 14px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.rank-row:hover {
  background: #ecfdf5;
  transform: translateX(4px);
}

.rank-number {
  color: #059669;
  font-size: 18px;
  font-weight: 900;
  text-align: center;
}

.rank-row img {
  width: 58px;
  height: 78px;
  object-fit: cover;
  border-radius: 12px;
}

.full-rank .rank-row img {
  width: 78px;
  height: 104px;
}

.rank-info {
  min-width: 0;
}

.rank-info strong,
.rank-info em {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-info strong {
  color: #101828;
  font-size: 15px;
}

.rank-info em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.rank-score {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  border-radius: 999px;
  font-weight: 900;
  text-align: center;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 78% 18%, rgba(6, 182, 212, 0.32), transparent 35%),
    linear-gradient(135deg, #052e2b, #0f172a 58%, #111827);
}

.page-hero {
  padding: 84px 22px;
}

.page-hero > div {
  max-width: 1220px;
  margin: 0 auto;
}

.page-hero h1 {
  max-width: 760px;
  margin: 0 0 16px;
  font-size: clamp(36px, 6vw, 66px);
  line-height: 1.06;
  letter-spacing: -0.05em;
}

.page-hero p:last-child {
  max-width: 720px;
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.slim-hero {
  padding-top: 72px;
  padding-bottom: 72px;
}

.category-overview-card {
  padding: 18px;
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.category-overview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.category-overview-head em {
  color: var(--primary-dark);
  font-size: 13px;
  font-style: normal;
  font-weight: 800;
}

.mini-poster-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 15px;
}

.mini-poster-row a {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  aspect-ratio: 2 / 3;
  background: #d9e4e9;
}

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

.mini-poster-row span {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 20px 8px 8px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.74), transparent);
}

.detail-hero {
  max-width: 1220px;
  margin: 34px auto 0;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
  padding: 28px;
  border-radius: 32px;
}

.detail-cover {
  overflow: hidden;
  border-radius: 26px;
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.32);
}

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

.breadcrumb {
  margin: 0 0 16px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #fff;
}

.detail-info h1 {
  margin: 0 0 16px;
  font-size: clamp(32px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.detail-one-line {
  max-width: 760px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  max-width: 720px;
}

.detail-meta-grid span {
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 14px;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.09);
}

.detail-tags span {
  color: #ecfdf5;
  background: rgba(255, 255, 255, 0.16);
}

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

.video-frame {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #000;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

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

.play-cover {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-items: center;
  gap: 10px;
  border: 0;
  color: #fff;
  background:
    radial-gradient(circle at center, rgba(5, 150, 105, 0.32), transparent 28%),
    linear-gradient(0deg, rgba(0, 0, 0, 0.46), rgba(0, 0, 0, 0.24));
  cursor: pointer;
}

.play-cover.is-hidden {
  display: none;
}

.play-symbol {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  padding-left: 5px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  box-shadow: 0 20px 50px rgba(5, 150, 105, 0.42);
  font-size: 30px;
}

.play-cover strong {
  font-size: 18px;
  letter-spacing: 0.08em;
}

.detail-content {
  display: grid;
  gap: 18px;
}

.content-card {
  padding: 24px;
}

.content-card h2 {
  margin: 0 0 12px;
  font-size: 25px;
  letter-spacing: -0.025em;
}

.content-card p {
  font-size: 16px;
}

.detail-nav-links a {
  flex: 1 1 260px;
  padding: 14px 16px;
  border: 1px solid #dbe7e9;
  border-radius: 16px;
  color: #047857;
  background: #fff;
  font-weight: 800;
  box-shadow: var(--shadow-soft);
}

.site-footer {
  margin-top: 72px;
  color: #cbd5e1;
  background: #101828;
}

.footer-shell {
  max-width: 1220px;
  margin: 0 auto;
  padding: 44px 22px;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.8fr);
  gap: 40px;
}

.brand-footer {
  color: #fff;
  margin-bottom: 14px;
}

.footer-brand p {
  max-width: 620px;
  color: #cbd5e1;
}

.footer-links h2 {
  margin-bottom: 14px;
  color: #fff;
  font-size: 20px;
}

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

.footer-links a {
  padding: 7px 10px;
  border-radius: 999px;
  color: #d1fae5;
  background: rgba(255, 255, 255, 0.08);
}

.footer-links a:hover {
  background: rgba(16, 185, 129, 0.28);
}

.footer-bottom {
  max-width: 1220px;
  margin: 0 auto;
  padding: 18px 22px 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  font-size: 14px;
}

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

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

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

  .ranking-panel {
    position: static;
  }
}

@media (max-width: 820px) {
  .nav-toggle {
    display: flex;
  }

  .nav-menu {
    position: absolute;
    top: 68px;
    left: 14px;
    right: 14px;
    display: none;
    padding: 14px;
    border: 1px solid #e4e7ec;
    border-radius: 20px;
    background: #fff;
    box-shadow: var(--shadow);
  }

  .nav-menu.is-open {
    display: grid;
    gap: 4px;
  }

  .nav-link,
  .nav-dropdown > button {
    width: 100%;
    text-align: left;
    border-radius: 14px;
  }

  .nav-dropdown-panel {
    position: static;
    display: grid;
    margin-top: 6px;
    box-shadow: none;
  }

  .hero-carousel,
  .hero-content {
    min-height: 560px;
  }

  .hero-content {
    padding-top: 84px;
  }

  .hero-control {
    display: none;
  }

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

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

  .detail-hero {
    grid-template-columns: 1fr;
    margin: 18px 14px 0;
    padding: 18px;
  }

  .detail-cover {
    max-width: 280px;
  }

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

@media (max-width: 560px) {
  .nav-shell {
    padding: 0 14px;
  }

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

  .section-shell {
    padding-left: 14px;
    padding-right: 14px;
  }

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

  .category-grid,
  .category-overview-grid,
  .movie-grid,
  .wide-grid {
    grid-template-columns: 1fr;
  }

  .hero-content p:not(.hero-eyebrow),
  .page-hero p:last-child,
  .detail-one-line {
    font-size: 16px;
  }

  .detail-meta-grid,
  .full-rank .rank-row,
  .rank-row {
    grid-template-columns: 1fr;
  }

  .rank-number {
    text-align: left;
  }

  .rank-row img,
  .full-rank .rank-row img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}
