:root {
  --color-bg: #f8fafc;
  --color-panel: #ffffff;
  --color-text: #111827;
  --color-muted: #667085;
  --color-soft: #ecfdf5;
  --color-line: #e5e7eb;
  --color-brand: #059669;
  --color-brand-dark: #047857;
  --color-brand-soft: #d1fae5;
  --color-accent: #0f766e;
  --shadow-card: 0 16px 45px rgba(15, 23, 42, 0.10);
  --shadow-soft: 0 10px 25px rgba(15, 23, 42, 0.08);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.88);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  min-height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.03em;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-brand), var(--color-accent));
  box-shadow: 0 12px 22px rgba(5, 150, 105, 0.28);
}

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

.nav-links a {
  padding: 10px 13px;
  border-radius: 12px;
  color: #475467;
  font-size: 15px;
  font-weight: 650;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--color-brand-dark);
  background: var(--color-soft);
}

.header-search {
  display: flex;
  align-items: center;
  width: 230px;
  padding: 6px;
  gap: 6px;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
}

.header-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #111827;
  padding-left: 8px;
}

.header-search button {
  border: 0;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: var(--color-brand);
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #f3f4f6;
  color: #111827;
  margin-left: auto;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.mobile-panel.is-open {
  display: block;
}

.mobile-panel a {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  color: #475467;
  font-weight: 700;
}

.mobile-panel a:hover {
  color: var(--color-brand-dark);
  background: var(--color-soft);
}

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

.hero {
  position: relative;
  overflow: hidden;
  min-height: 620px;
  background: radial-gradient(circle at 20% 10%, rgba(16, 185, 129, 0.18), transparent 36%), linear-gradient(135deg, #064e3b, #0f766e 48%, #111827);
  color: #ffffff;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateX(30px);
  transition: opacity 0.55s ease, transform 0.55s ease, visibility 0.55s ease;
}

.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.36;
  filter: blur(1px) saturate(1.04);
  transform: scale(1.04);
}

.hero-bg img.is-missing {
  opacity: 0;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(6, 78, 59, 0.95), rgba(15, 118, 110, 0.78) 44%, rgba(17, 24, 39, 0.62)), linear-gradient(0deg, rgba(17, 24, 39, 0.55), transparent 50%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: 620px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  align-items: center;
  gap: 56px;
  padding: 70px 0 80px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-radius: 999px;
  color: #d1fae5;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
  font-weight: 700;
}

.hero h1 {
  margin: 22px 0 18px;
  font-size: clamp(40px, 6vw, 74px);
  line-height: 1.05;
  letter-spacing: -0.06em;
  font-weight: 900;
}

.hero-text {
  max-width: 720px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 20px;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  border: 0;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

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

.button-primary {
  color: #065f46;
  background: #ffffff;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.18);
}

.button-secondary {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.button-brand {
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-brand), var(--color-accent));
  box-shadow: 0 14px 26px rgba(5, 150, 105, 0.25);
}

.hero-poster {
  position: relative;
  border-radius: 32px;
  overflow: hidden;
  min-height: 500px;
  background: linear-gradient(135deg, rgba(255,255,255,0.18), rgba(255,255,255,0.06));
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.38);
  transform: rotate(1.5deg);
}

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

.hero-poster img.is-missing {
  opacity: 0;
}

.poster-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0, 0, 0, 0.68));
}

.hero-poster-caption {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 22px;
}

.hero-poster-caption strong {
  display: block;
  font-size: 22px;
  line-height: 1.25;
}

.hero-poster-caption span {
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

.hero-controls {
  position: absolute;
  z-index: 5;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

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

.hero-dot.is-active {
  background: #ffffff;
}

.section {
  padding: 68px 0 0;
}

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

.section-title {
  margin: 0;
  color: #0f172a;
  font-size: 30px;
  line-height: 1.2;
  letter-spacing: -0.04em;
  font-weight: 900;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--color-muted);
}

.link-more {
  color: var(--color-brand-dark);
  font-weight: 800;
}

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.poster-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #064e3b, #0f766e);
}

.movie-grid.compact .poster-frame,
.related-grid .poster-frame {
  aspect-ratio: 3 / 4;
}

.poster-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.32s ease, opacity 0.2s ease;
}

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

.poster-frame img.is-missing {
  opacity: 0;
}

.poster-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 48%, rgba(0, 0, 0, 0.68));
  pointer-events: none;
}

.badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 5px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(5, 150, 105, 0.92);
  font-size: 12px;
  font-weight: 850;
}

.play-dot {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 2;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #065f46;
  background: rgba(255, 255, 255, 0.92);
  font-size: 13px;
  font-weight: 900;
}

.card-body {
  padding: 18px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--color-brand-dark);
  font-size: 12px;
  font-weight: 850;
}

.movie-card h3 {
  margin: 0;
  color: #111827;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 850;
}

.movie-card p {
  margin: 8px 0 0;
  color: var(--color-muted);
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.tag,
.category-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: #065f46;
  background: var(--color-soft);
  font-size: 12px;
  font-weight: 750;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 138px;
  padding: 22px;
  border-radius: 22px;
  background: linear-gradient(135deg, #ffffff, #ecfdf5);
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-card strong {
  display: block;
  color: #0f172a;
  font-size: 20px;
}

.category-card span {
  display: block;
  margin-top: 8px;
  color: var(--color-muted);
}

.page-hero {
  padding: 58px 0;
  color: #ffffff;
  background: radial-gradient(circle at 20% 20%, rgba(209, 250, 229, 0.16), transparent 28%), linear-gradient(135deg, #059669, #0f766e);
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.08;
  letter-spacing: -0.05em;
  font-weight: 900;
}

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

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 30px 0 0;
}

.filter-pills a {
  padding: 9px 14px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-weight: 750;
}

.filter-pills a.is-active {
  background: #ffffff;
  color: var(--color-brand-dark);
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 42px 0 0;
}

.pagination a,
.pagination span {
  min-width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  padding: 0 12px;
  border-radius: 12px;
  background: #ffffff;
  color: #475467;
  box-shadow: 0 5px 16px rgba(15, 23, 42, 0.06);
  font-weight: 800;
}

.pagination span,
.pagination a:hover {
  color: #ffffff;
  background: var(--color-brand);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: #111827;
}

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

.detail-hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(4px) saturate(1.1);
  transform: scale(1.04);
}

.detail-hero-bg img.is-missing {
  opacity: 0;
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(6, 78, 59, 0.94), rgba(17, 24, 39, 0.82));
}

.detail-shell {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0;
}

.breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 24px;
  color: rgba(255, 255, 255, 0.78);
  font-weight: 750;
}

.detail-grid {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 40px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  background: linear-gradient(135deg, #064e3b, #0f766e);
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.34);
  aspect-ratio: 3 / 4;
}

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

.detail-poster img.is-missing {
  opacity: 0;
}

.detail-info h1 {
  margin: 14px 0 16px;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.05em;
  font-weight: 900;
}

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

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

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-weight: 800;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.player-wrap {
  padding: 52px 0 0;
}

.video-card {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #020617;
  box-shadow: var(--shadow-card);
}

.video-card video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.big-play {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: grid;
  place-items: center;
  color: #065f46;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.36));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.big-play span {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.28);
  font-size: 28px;
  transform: translateX(2px);
}

.video-card.is-playing .big-play {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  padding: 42px 0 0;
}

.article-panel,
.side-panel {
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.article-panel {
  padding: 30px;
}

.article-panel h2,
.side-panel h2 {
  margin: 0 0 16px;
  font-size: 24px;
  line-height: 1.25;
  letter-spacing: -0.03em;
  font-weight: 900;
}

.article-panel p {
  color: #344054;
  font-size: 17px;
  margin: 0 0 20px;
}

.side-panel {
  padding: 22px;
}

.info-list {
  display: grid;
  gap: 12px;
}

.info-list div {
  padding-bottom: 12px;
  border-bottom: 1px solid var(--color-line);
}

.info-list strong {
  display: block;
  color: #667085;
  font-size: 13px;
}

.info-list span {
  display: block;
  color: #111827;
  font-weight: 800;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 72px 120px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card);
}

.rank-number {
  font-size: 28px;
  font-weight: 950;
  color: var(--color-brand);
  text-align: center;
}

.rank-thumb {
  overflow: hidden;
  border-radius: 16px;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #064e3b, #0f766e);
}

.rank-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rank-thumb img.is-missing {
  opacity: 0;
}

.rank-info h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 900;
}

.rank-info p {
  margin: 6px 0 0;
  color: var(--color-muted);
}

.search-panel {
  padding: 26px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
  margin-bottom: 28px;
}

.search-panel form {
  display: flex;
  gap: 12px;
}

.search-panel input {
  flex: 1;
  min-height: 52px;
  border: 1px solid var(--color-line);
  border-radius: 16px;
  padding: 0 16px;
  outline: none;
}

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

.site-footer {
  margin-top: 76px;
  color: #cbd5e1;
  background: #0f172a;
}

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

.footer-inner h2,
.footer-inner h3 {
  margin: 0 0 12px;
  color: #ffffff;
}

.footer-inner p,
.footer-inner a {
  color: #cbd5e1;
}

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

.copyright {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #94a3b8;
  font-size: 14px;
}

@media (max-width: 1060px) {
  .header-search {
    display: none;
  }

  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-poster {
    display: none;
  }

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

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

  .content-grid {
    grid-template-columns: 1fr;
  }
}

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

  .menu-button {
    display: grid;
    place-items: center;
  }

  .hero,
  .hero-track,
  .hero-inner {
    min-height: 560px;
  }

  .section-head {
    display: block;
  }

  .link-more {
    display: inline-flex;
    margin-top: 12px;
  }

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

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

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

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

  .rank-item {
    grid-template-columns: 52px 96px minmax(0, 1fr);
  }

  .rank-item .button {
    grid-column: 2 / 4;
  }

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

@media (max-width: 520px) {
  .header-inner,
  .page-shell,
  .hero-inner,
  .detail-shell,
  .footer-inner,
  .copyright {
    width: min(100% - 22px, 1180px);
  }

  .logo {
    font-size: 18px;
  }

  .hero h1 {
    font-size: 38px;
  }

  .hero-text,
  .detail-one-line {
    font-size: 17px;
  }

  .movie-grid,
  .movie-grid.compact,
  .related-grid,
  .category-strip {
    grid-template-columns: 1fr;
  }

  .search-panel form {
    display: grid;
  }
}
