:root {
  --site-primary: #10b981;
  --site-primary-dark: #059669;
  --site-secondary: #14b8a6;
  --site-accent: #06b6d4;
  --site-ink: #111827;
  --site-muted: #6b7280;
  --site-soft: #f3f4f6;
  --site-card: #ffffff;
  --site-line: #e5e7eb;
  --site-shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
  --site-radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--site-ink);
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 54%, #f8fafc 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

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

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.site-logo {
  font-size: 22px;
  white-space: nowrap;
}

.logo-mark {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 2px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--site-primary), var(--site-accent));
  box-shadow: 0 14px 26px rgba(16, 185, 129, 0.32);
}

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

.nav-link {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  color: #4b5563;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

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

.header-actions {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
}

.global-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}

.global-search input,
.filter-box input,
.filter-box select {
  border: 1px solid var(--site-line);
  border-radius: 14px;
  outline: none;
  background: #ffffff;
  color: #111827;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.global-search input {
  width: 240px;
  height: 42px;
  padding: 0 14px;
}

.global-search input:focus,
.filter-box input:focus,
.filter-box select:focus {
  border-color: var(--site-primary);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.14);
}

.global-search button,
.mobile-toggle {
  height: 42px;
  border: 0;
  border-radius: 14px;
  padding: 0 16px;
  font-weight: 800;
  color: #ffffff;
  background: linear-gradient(135deg, var(--site-primary), var(--site-secondary));
  cursor: pointer;
}

.search-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: min(420px, calc(100vw - 32px));
  max-height: 520px;
  overflow: auto;
  display: none;
  padding: 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--site-shadow);
  border: 1px solid rgba(229, 231, 235, 0.8);
}

.search-panel.is-open {
  display: grid;
  gap: 8px;
}

.search-result {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 12px;
  align-items: center;
  padding: 8px;
  border-radius: 14px;
  transition: background 0.2s ease;
}

.search-result:hover {
  background: #ecfdf5;
}

.search-result img {
  width: 64px;
  height: 44px;
  border-radius: 10px;
  object-fit: cover;
  background: #111827;
}

.search-result strong,
.search-result em {
  display: block;
}

.search-result strong {
  font-size: 14px;
  color: #111827;
}

.search-result em {
  margin-top: 3px;
  font-style: normal;
  font-size: 12px;
  color: var(--site-muted);
}

.mobile-toggle,
.mobile-panel {
  display: none;
}

.mobile-panel {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
}

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

.mobile-panel a:hover {
  background: #ecfdf5;
  color: var(--site-primary-dark);
}

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

.hero-carousel {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: linear-gradient(135deg, #064e3b 0%, #115e59 48%, #164e63 100%);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.84) 0%, rgba(0, 0, 0, 0.56) 43%, rgba(0, 0, 0, 0.08) 100%);
}

.hero-copy {
  position: absolute;
  top: 50%;
  left: max(24px, calc((100vw - 1180px) / 2));
  width: min(650px, calc(100% - 48px));
  transform: translateY(-50%);
  color: #ffffff;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  margin-bottom: 12px;
  color: var(--site-primary);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 76px);
  line-height: 0.96;
  letter-spacing: -0.055em;
}

.hero-copy p {
  max-width: 580px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 19px;
  line-height: 1.8;
}

.hero-tags,
.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag-chip,
.meta-row span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 12px;
  border-radius: 999px;
  color: #065f46;
  background: rgba(209, 250, 229, 0.96);
  font-size: 13px;
  font-weight: 800;
}

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

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

.primary-btn {
  color: #ffffff;
  background: linear-gradient(135deg, var(--site-primary), var(--site-secondary));
  box-shadow: 0 18px 35px rgba(16, 185, 129, 0.32);
}

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

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

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  color: #111827;
  background: rgba(255, 255, 255, 0.92);
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
  transform: translateY(-50%);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.22);
}

.hero-control.prev {
  left: 24px;
}

.hero-control.next {
  right: 24px;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

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

.section-wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0;
}

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

.section-head h2,
.page-hero h1,
.movie-profile h1,
.article-card h2 {
  margin: 0;
  color: #111827;
  letter-spacing: -0.035em;
}

.section-head h2 {
  font-size: clamp(28px, 3.6vw, 44px);
}

.section-head > a,
.related-section .section-head > a {
  color: var(--site-primary-dark);
  font-weight: 900;
}

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

.category-card,
.category-overview-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--site-radius);
  background: #ffffff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card:hover,
.category-overview-card:hover,
.movie-card:hover,
.compact-card:hover,
.rank-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--site-shadow);
}

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

.category-card span,
.category-overview-card strong,
.category-overview-card em {
  display: block;
}

.category-card span {
  padding: 18px;
}

.category-card strong,
.category-overview-card strong {
  display: block;
  margin-bottom: 8px;
  color: #111827;
  font-size: 20px;
}

.category-card em,
.category-overview-card em {
  color: var(--site-muted);
  font-style: normal;
  font-size: 14px;
  line-height: 1.7;
}

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

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

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

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #111827;
}

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

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

.poster-mask {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0);
  transition: background 0.25s ease;
}

.movie-card:hover .poster-mask {
  background: rgba(0, 0, 0, 0.34);
}

.play-dot {
  width: 54px;
  height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 4px;
  border-radius: 50%;
  color: var(--site-primary-dark);
  background: rgba(255, 255, 255, 0);
  opacity: 0;
  transform: scale(0.82);
  transition: opacity 0.25s ease, transform 0.25s ease, background 0.25s ease;
}

.movie-card:hover .play-dot {
  opacity: 1;
  transform: scale(1);
  background: rgba(255, 255, 255, 0.96);
}

.quality-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.7);
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  display: block;
  padding: 16px;
}

.card-body strong,
.card-body em,
.card-body span {
  display: block;
}

.card-body strong {
  margin-bottom: 8px;
  color: #111827;
  font-size: 17px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-body em {
  margin-bottom: 8px;
  color: var(--site-primary-dark);
  font-style: normal;
  font-size: 13px;
  font-weight: 800;
}

.card-body span {
  color: var(--site-muted);
  font-size: 14px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.large-card {
  height: 100%;
}

.large-card .poster-wrap {
  aspect-ratio: 16 / 11;
}

.large-card .card-body strong {
  font-size: 24px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 48px 110px 1fr;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.rank-num {
  font-size: 22px;
  font-weight: 900;
  color: var(--site-primary-dark);
  text-align: center;
}

.rank-item img {
  width: 110px;
  height: 72px;
  border-radius: 14px;
  object-fit: cover;
  background: #111827;
}

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

.rank-info strong {
  color: #111827;
  font-size: 17px;
  margin-bottom: 4px;
}

.rank-info em {
  color: var(--site-primary-dark);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  margin-bottom: 5px;
}

.rank-info span {
  color: var(--site-muted);
  font-size: 13px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.feature-strip {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: 22px;
}

.feature-side {
  display: grid;
  gap: 14px;
}

.compact-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.compact-card img {
  width: 120px;
  height: 78px;
  object-fit: cover;
  border-radius: 14px;
  background: #111827;
}

.compact-card strong,
.compact-card em {
  display: block;
}

.compact-card strong {
  color: #111827;
  font-size: 16px;
  margin-bottom: 6px;
}

.compact-card em {
  color: var(--site-muted);
  font-style: normal;
  font-size: 13px;
}

.page-hero {
  color: #ffffff;
  background: linear-gradient(135deg, #047857 0%, #0f766e 48%, #0e7490 100%);
}

.page-hero > div {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 70px 0;
}

.page-hero.small-hero > div {
  padding: 58px 0;
}

.page-hero h1 {
  color: #ffffff;
  font-size: clamp(38px, 5vw, 64px);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 14px;
  font-weight: 700;
}

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

.filter-box {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 180px 180px 160px;
  gap: 12px;
  margin-bottom: 24px;
  padding: 16px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

.filter-box input,
.filter-box select {
  height: 46px;
  padding: 0 14px;
}

.empty-filter {
  padding: 36px;
  text-align: center;
  border-radius: 20px;
  color: var(--site-muted);
  background: #ffffff;
}

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

.category-overview-card {
  padding: 18px;
}

.overview-thumbs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 18px;
}

.overview-thumbs img {
  width: 100%;
  height: 82px;
  object-fit: cover;
  border-radius: 12px;
  background: #111827;
}

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

.ranking-list .rank-item {
  grid-template-columns: 68px 150px 1fr;
}

.ranking-list .rank-item img {
  width: 150px;
  height: 96px;
}

.detail-top {
  background: #020617;
}

.detail-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 44px;
}

.breadcrumb.dark {
  color: rgba(255, 255, 255, 0.76);
}

.player-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 26px;
  background: #000000;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.38);
}

.movie-player {
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  cursor: pointer;
}

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

.player-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.76;
}

.player-gradient {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(16, 185, 129, 0.12), rgba(0, 0, 0, 0.74));
}

.player-button {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 92px;
  height: 92px;
  border: 0;
  border-radius: 50%;
  padding-left: 8px;
  color: var(--site-primary-dark);
  background: rgba(255, 255, 255, 0.96);
  font-size: 34px;
  cursor: pointer;
  transform: translate(-50%, -50%);
  box-shadow: 0 22px 42px rgba(0, 0, 0, 0.34);
  transition: transform 0.2s ease;
}

.player-button:hover {
  transform: translate(-50%, -50%) scale(1.06);
}

.player-error {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  padding: 14px 20px;
  border-radius: 14px;
  color: #ffffff;
  background: rgba(220, 38, 38, 0.9);
  transform: translate(-50%, -50%);
}

.detail-content {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0 70px;
}

.movie-profile {
  display: grid;
  grid-template-columns: 230px 1fr;
  gap: 28px;
  align-items: center;
  padding: 26px;
  border-radius: 28px;
  background: #ffffff;
  box-shadow: var(--site-shadow);
}

.profile-poster img {
  width: 230px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 22px;
  background: #111827;
}

.movie-profile h1 {
  margin-bottom: 16px;
  font-size: clamp(30px, 4.2vw, 52px);
}

.lead-text {
  margin: 0 0 18px;
  color: #374151;
  font-size: 18px;
  line-height: 1.85;
}

.meta-row {
  margin-bottom: 18px;
}

.article-card,
.related-section {
  margin-top: 26px;
  padding: 28px;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.article-card h2 {
  margin-bottom: 14px;
  font-size: 28px;
}

.article-card p {
  margin: 0;
  color: #374151;
  font-size: 17px;
  line-height: 2;
}

.related-section .section-head {
  margin-bottom: 20px;
}

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

.site-footer {
  color: #d1d5db;
  background: #111827;
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0;
  display: flex;
  justify-content: space-between;
  gap: 30px;
}

.footer-logo {
  color: #ffffff;
  font-size: 22px;
}

.site-footer p {
  max-width: 560px;
  margin: 12px 0 0;
  color: #9ca3af;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-content: flex-start;
  justify-content: flex-end;
}

.footer-links a {
  color: #d1d5db;
  font-weight: 700;
}

.footer-links a:hover {
  color: var(--site-primary);
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #9ca3af;
  text-align: center;
}

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

  .mobile-toggle {
    display: inline-flex;
    align-items: center;
  }

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

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

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

@media (max-width: 760px) {
  .site-nav {
    height: auto;
    min-height: 68px;
    flex-wrap: wrap;
    padding: 12px 0;
  }

  .site-logo {
    font-size: 18px;
  }

  .global-search {
    order: 3;
    width: 100%;
  }

  .global-search input {
    width: 100%;
  }

  .global-search button {
    flex: 0 0 auto;
  }

  .hero-carousel {
    height: 560px;
  }

  .hero-copy {
    top: auto;
    bottom: 78px;
    transform: none;
  }

  .hero-copy p {
    font-size: 16px;
  }

  .hero-control {
    display: none;
  }

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

  .movie-grid,
  .movie-grid.dense,
  .related-grid,
  .category-grid,
  .rank-grid,
  .category-overview-grid {
    grid-template-columns: 1fr;
  }

  .rank-item,
  .ranking-list .rank-item {
    grid-template-columns: 48px 92px 1fr;
  }

  .rank-item img,
  .ranking-list .rank-item img {
    width: 92px;
    height: 64px;
  }

  .feature-strip,
  .movie-profile,
  .footer-inner,
  .filter-box {
    grid-template-columns: 1fr;
  }

  .movie-profile {
    padding: 18px;
  }

  .profile-poster img {
    width: 100%;
    aspect-ratio: 16 / 9;
  }

  .article-card,
  .related-section {
    padding: 20px;
  }

  .player-shell {
    border-radius: 18px;
  }

  .player-button {
    width: 72px;
    height: 72px;
    font-size: 27px;
  }
}
