:root {
  --bg: #f8fafc;
  --bg-soft: #eef2f7;
  --surface: #ffffff;
  --surface-dark: #0f172a;
  --surface-dark-2: #1e293b;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --emerald: #059669;
  --emerald-light: #10b981;
  --teal: #0d9488;
  --cyan: #0891b2;
  --orange: #f97316;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 10px 25px rgba(15, 23, 42, 0.08);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 38%, #f8fafc 100%);
  line-height: 1.6;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 8% 8%, rgba(16, 185, 129, 0.15), transparent 28%),
    radial-gradient(circle at 92% 2%, rgba(8, 145, 178, 0.14), transparent 30%);
  z-index: -1;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.92);
  color: #ffffff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(18px);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--emerald-light), var(--teal));
  box-shadow: 0 12px 26px rgba(16, 185, 129, 0.35);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-copy strong {
  font-size: 1.25rem;
}

.brand-copy em {
  margin-top: 4px;
  color: #94a3b8;
  font-size: 0.75rem;
  font-style: normal;
  font-weight: 500;
}

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

.nav-link,
.mobile-link {
  color: #cbd5e1;
  font-weight: 650;
  transition: 0.25s ease;
}

.nav-link {
  padding: 10px 14px;
  border-radius: 999px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #ffffff;
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 6px;
  padding: 0 16px 16px;
  background: rgba(15, 23, 42, 0.98);
}

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

.mobile-link {
  padding: 12px 14px;
  border-radius: 14px;
}

.hero {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: #0f172a;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.75s ease, transform 1s ease;
  pointer-events: none;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.05);
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.96) 0%, rgba(15, 23, 42, 0.82) 44%, rgba(15, 23, 42, 0.25) 100%),
    linear-gradient(0deg, rgba(15, 23, 42, 0.96) 0%, transparent 46%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 70vh;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) 360px;
  align-items: center;
  gap: 42px;
  color: #ffffff;
  padding: 84px 0;
}

.hero-kicker,
.section-kicker,
.page-kicker {
  color: #6ee7b7;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.78rem;
  font-weight: 800;
}

.hero h1 {
  margin: 14px 0 18px;
  max-width: 790px;
  font-size: clamp(2.5rem, 6vw, 5.6rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-summary {
  max-width: 700px;
  color: #dbeafe;
  font-size: clamp(1rem, 2vw, 1.2rem);
}

.hero-actions,
.inline-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
}

.btn-primary,
.btn-secondary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: 0.25s ease;
}

.btn-primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--emerald), var(--teal));
  box-shadow: 0 16px 30px rgba(5, 150, 105, 0.28);
}

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

.btn-secondary {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
}

.btn-ghost {
  color: var(--emerald);
  background: rgba(5, 150, 105, 0.1);
}

.hero-panel {
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.58);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.hero-panel h2 {
  margin: 0 0 16px;
  font-size: 1.12rem;
}

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

.hero-mini-card {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
  transition: 0.25s ease;
}

.hero-mini-card:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: translateX(4px);
}

.hero-mini-card img {
  width: 72px;
  height: 88px;
  object-fit: cover;
  border-radius: 14px;
}

.hero-mini-card strong {
  display: block;
  color: #ffffff;
  font-size: 0.95rem;
}

.hero-mini-card span {
  color: #cbd5e1;
  font-size: 0.82rem;
}

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

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
  transition: 0.25s ease;
}

.hero-dot.is-active {
  width: 54px;
  background: #10b981;
}

.main-section {
  padding: 72px 0;
}

.main-section.compact {
  padding: 48px 0;
}

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

.section-heading h2,
.page-heading h1 {
  margin: 4px 0 6px;
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.section-heading span,
.page-heading p {
  color: var(--muted);
}

.section-more {
  flex-shrink: 0;
  color: var(--emerald);
  font-weight: 800;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(16, 185, 129, 0.42);
  box-shadow: var(--shadow);
}

.poster-frame {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #1e293b);
}

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

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

.year-badge,
.score-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(10px);
}

.year-badge {
  left: 12px;
  top: 12px;
}

.score-badge {
  right: 12px;
  bottom: 12px;
  background: rgba(249, 115, 22, 0.92);
}

.rank-badge {
  left: 12px;
  bottom: 12px;
  background: rgba(5, 150, 105, 0.92);
}

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

.movie-title {
  display: block;
  overflow: hidden;
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 850;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-title:hover {
  color: var(--emerald);
}

.movie-meta {
  margin: 6px 0 8px;
  color: var(--muted);
  font-size: 0.88rem;
}

.movie-line {
  min-height: 48px;
  margin: 0 0 14px;
  display: -webkit-box;
  overflow: hidden;
  color: #475569;
  font-size: 0.92rem;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.tag-row span,
.meta-pill,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  color: #047857;
  background: #d1fae5;
  font-size: 0.78rem;
  font-weight: 750;
}

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

.channel-card {
  position: relative;
  overflow: hidden;
  min-height: 172px;
  padding: 24px;
  border: 1px solid rgba(226, 232, 240, 0.88);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
  transition: 0.25s ease;
}

.channel-card::before {
  content: "";
  position: absolute;
  right: -38px;
  top: -42px;
  width: 130px;
  height: 130px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(8, 145, 178, 0.18));
}

.channel-card:hover {
  transform: translateY(-5px);
  border-color: rgba(16, 185, 129, 0.38);
}

.channel-card h3 {
  position: relative;
  margin: 0 0 10px;
  font-size: 1.3rem;
}

.channel-card p {
  position: relative;
  margin: 0;
  color: var(--muted);
}

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

.rank-item {
  display: grid;
  grid-template-columns: 64px 88px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(226, 232, 240, 0.88);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
  transition: 0.25s ease;
}

.rank-item:hover {
  transform: translateX(4px);
  border-color: rgba(16, 185, 129, 0.38);
}

.rank-number {
  color: var(--emerald);
  font-size: 1.3rem;
  font-weight: 900;
}

.rank-item img {
  width: 88px;
  height: 112px;
  object-fit: cover;
  border-radius: 16px;
}

.rank-item h3 {
  margin: 0 0 6px;
  font-size: 1.05rem;
}

.rank-item p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.page-hero,
.detail-hero {
  padding: 78px 0 54px;
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.94)),
    radial-gradient(circle at 20% 10%, rgba(16, 185, 129, 0.24), transparent 28%);
}

.page-heading {
  margin-bottom: 0;
}

.page-heading p {
  max-width: 760px;
  color: #cbd5e1;
}

.breadcrumb {
  margin-bottom: 18px;
  color: #94a3b8;
  font-size: 0.92rem;
}

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

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

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

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

.detail-copy h1 {
  margin: 10px 0 14px;
  font-size: clamp(2.3rem, 5vw, 4.8rem);
  line-height: 1.02;
  letter-spacing: -0.05em;
}

.detail-intro {
  max-width: 780px;
  color: #dbeafe;
  font-size: 1.08rem;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}

.meta-pill {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.content-card {
  padding: 30px;
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.content-card + .content-card {
  margin-top: 22px;
}

.content-card h2,
.player-section h2 {
  margin: 0 0 18px;
  font-size: clamp(1.45rem, 3vw, 2.1rem);
  letter-spacing: -0.03em;
}

.content-card p {
  margin: 0;
  color: #334155;
  font-size: 1.02rem;
}

.content-card p + p {
  margin-top: 16px;
}

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

.player-section {
  padding: 64px 0 0;
}

.site-player {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: 0 28px 70px rgba(2, 6, 23, 0.28);
  aspect-ratio: 16 / 9;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.22), rgba(2, 6, 23, 0.76));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-circle {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  padding-left: 5px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--emerald-light), var(--teal));
  box-shadow: 0 22px 40px rgba(16, 185, 129, 0.32);
  font-size: 2rem;
}

.player-overlay strong {
  font-size: 1.2rem;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) repeat(4, minmax(130px, 180px));
  gap: 12px;
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
}

.filter-panel input,
.filter-panel select {
  min-height: 48px;
  width: 100%;
  padding: 0 14px;
  border: 1px solid #dbeafe;
  border-radius: 16px;
  color: var(--text);
  background: #ffffff;
  outline: none;
  transition: 0.2s ease;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--emerald-light);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

.search-status {
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 700;
}

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

.pagination a,
.pagination span,
.pagination i {
  min-width: 40px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 14px;
  background: #ffffff;
  color: var(--text);
  box-shadow: var(--shadow-soft);
  font-style: normal;
  font-weight: 800;
}

.pagination a.is-current,
.pagination a:hover {
  color: #ffffff;
  background: linear-gradient(135deg, var(--emerald), var(--teal));
}

.pagination span {
  color: #94a3b8;
}

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

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
}

.footer-brand {
  color: #ffffff;
  font-size: 1.2rem;
}

.site-footer p {
  margin: 6px 0 0;
  color: #94a3b8;
}

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

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

@media (max-width: 1024px) {
  .hero-content,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .hero-panel {
    max-width: 560px;
  }

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

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

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

  .menu-toggle {
    display: block;
  }

  .nav-shell {
    min-height: 66px;
  }

  .brand-copy em {
    display: none;
  }

  .hero,
  .hero-content {
    min-height: auto;
  }

  .hero-content {
    padding: 72px 0 104px;
  }

  .hero-panel {
    display: none;
  }

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

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

  .rank-item {
    grid-template-columns: 48px 72px 1fr;
  }

  .rank-item img {
    width: 72px;
    height: 96px;
  }

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

  .content-card {
    padding: 22px;
  }

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

@media (max-width: 520px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .movie-grid,
  .channel-grid,
  .rank-list {
    grid-template-columns: 1fr;
  }

  .hero h1,
  .detail-copy h1 {
    letter-spacing: -0.04em;
  }

  .play-circle {
    width: 62px;
    height: 62px;
    font-size: 1.55rem;
  }
}
