:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.78);
  --panel-strong: rgba(15, 23, 42, 0.94);
  --line: rgba(148, 163, 184, 0.18);
  --text: #e5e7eb;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --emerald: #34d399;
  --cyan: #22d3ee;
  --gold: #fbbf24;
  --rose: #fb7185;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 18% 0%, rgba(16, 185, 129, 0.18), transparent 28rem),
    radial-gradient(circle at 90% 8%, rgba(34, 211, 238, 0.16), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
  color: var(--text);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.04) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 78%);
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.86);
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 40px rgba(2, 6, 23, 0.28);
}

.site-header-inner,
.footer-inner,
.page-wrap,
.hero-wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 72px;
}

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.04em;
  color: #ffffff;
}

.logo-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--emerald), var(--cyan));
  color: #001b18;
  box-shadow: 0 14px 34px rgba(34, 211, 238, 0.22);
}

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

.desktop-nav a,
.mobile-nav a,
.footer-links a {
  color: var(--soft);
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.desktop-nav a {
  padding: 9px 13px;
  border-radius: 999px;
}

.desktop-nav a:hover,
.mobile-nav a:hover,
.footer-links a:hover {
  color: #ffffff;
  background: rgba(52, 211, 153, 0.1);
}

.header-search {
  display: flex;
  align-items: center;
  min-width: 280px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
}

.header-search input {
  width: 100%;
  min-width: 0;
  padding: 10px 14px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
}

.header-search button,
.primary-btn,
.secondary-btn,
.play-cover,
.filter-button {
  cursor: pointer;
  border: 0;
  color: #001b18;
  background: linear-gradient(135deg, var(--emerald), var(--cyan));
  box-shadow: 0 16px 32px rgba(34, 211, 238, 0.18);
}

.header-search button {
  align-self: stretch;
  padding: 0 18px;
  font-weight: 800;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.86);
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 2px;
  background: var(--text);
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.96);
}

.mobile-nav a {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
}

.mobile-nav.open {
  display: block;
}

.hero-section {
  position: relative;
  overflow: hidden;
  padding: 34px 0 28px;
}

.hero-shell {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 36px;
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.84), rgba(2, 6, 23, 0.96));
  box-shadow: var(--shadow);
}

.hero-slide {
  display: none;
  min-height: 560px;
}

.hero-slide.active {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 32px;
  align-items: stretch;
  animation: fadeUp 0.55s ease both;
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 54px;
}

.eyebrow {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 13px;
  border: 1px solid rgba(52, 211, 153, 0.28);
  border-radius: 999px;
  background: rgba(52, 211, 153, 0.1);
  color: var(--emerald);
  font-weight: 800;
}

.hero-copy h1,
.hero-copy h2 {
  margin: 0;
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero-copy h1 {
  max-width: 760px;
  font-size: clamp(42px, 6vw, 82px);
  color: #ffffff;
}

.hero-copy h2 {
  margin-top: 14px;
  font-size: clamp(28px, 3.5vw, 50px);
  color: var(--emerald);
}

.hero-copy p {
  max-width: 700px;
  margin: 22px 0 0;
  color: var(--soft);
  font-size: 18px;
  line-height: 1.85;
}

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

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

.secondary-btn {
  border: 1px solid rgba(148, 163, 184, 0.28);
  color: var(--text);
  background: rgba(15, 23, 42, 0.72);
  box-shadow: none;
}

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

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.hero-tags span,
.tag-row span,
.detail-tags a,
.info-chip,
.meta-pill {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: var(--soft);
}

.hero-tags span,
.info-chip,
.meta-pill {
  padding: 7px 12px;
  font-size: 13px;
}

.hero-visual {
  position: relative;
  min-height: 100%;
  padding: 28px 28px 28px 0;
}

.hero-poster {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 500px;
  overflow: hidden;
  border-radius: 30px;
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.16), rgba(34, 211, 238, 0.1));
}

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

.hero-poster::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(180deg, transparent 35%, rgba(2, 6, 23, 0.88) 100%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.18), transparent 42%);
}

.hero-rank-box {
  position: absolute;
  right: 50px;
  bottom: 50px;
  z-index: 3;
  width: min(360px, calc(100% - 70px));
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 24px;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(18px);
}

.hero-rank-box h3 {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: 18px;
}

.mini-rank-item {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
}

.mini-rank-item span {
  color: var(--emerald);
  font-weight: 900;
}

.mini-rank-item strong {
  overflow: hidden;
  color: #ffffff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.hero-dots {
  position: absolute;
  left: 54px;
  bottom: 34px;
  z-index: 4;
  display: flex;
  gap: 10px;
}

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

.hero-dot.active {
  background: linear-gradient(90deg, var(--emerald), var(--cyan));
}

.page-wrap {
  padding: 34px 0 72px;
}

.section-block {
  margin-top: 54px;
}

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

.section-head h2,
.page-title h1,
.detail-title h1 {
  margin: 0;
  color: #ffffff;
  letter-spacing: -0.03em;
}

.section-head h2 {
  font-size: clamp(26px, 3vw, 38px);
}

.section-head p,
.page-title p,
.detail-title p,
.category-intro,
.empty-state {
  color: var(--muted);
  line-height: 1.75;
}

.section-link {
  color: var(--emerald);
  font-weight: 900;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.22);
  transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  border-color: rgba(52, 211, 153, 0.4);
  transform: translateY(-5px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

.poster-frame {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4.25;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.12), rgba(34, 211, 238, 0.08));
}

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

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

.poster-frame::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, transparent 55%, rgba(2, 6, 23, 0.88));
}

.card-year,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.card-year {
  right: 12px;
  bottom: 12px;
  padding: 6px 9px;
  background: rgba(2, 6, 23, 0.82);
  color: var(--soft);
}

.rank-badge {
  top: 12px;
  left: 12px;
  padding: 7px 10px;
  background: linear-gradient(135deg, var(--gold), #fb923c);
  color: #241000;
}

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

.movie-meta-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
}

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

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

.movie-card p {
  min-height: 66px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.58;
}

.tag-row,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag-row span,
.detail-tags a {
  padding: 5px 9px;
  font-size: 12px;
}

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

.channel-card {
  min-height: 180px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(circle at 80% 12%, rgba(34, 211, 238, 0.14), transparent 44%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.88), rgba(2, 6, 23, 0.88));
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.channel-card:hover {
  border-color: rgba(52, 211, 153, 0.42);
  transform: translateY(-4px);
}

.channel-card h3 {
  margin: 0 0 10px;
  color: #ffffff;
  font-size: 22px;
}

.channel-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.channel-card span {
  display: inline-flex;
  margin-top: 24px;
  color: var(--emerald);
  font-weight: 900;
}

.page-title {
  display: grid;
  gap: 14px;
  margin-bottom: 30px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at 12% 18%, rgba(52, 211, 153, 0.16), transparent 36%),
    rgba(15, 23, 42, 0.72);
}

.page-title h1 {
  font-size: clamp(34px, 4vw, 58px);
}

.filter-panel {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 24px 0 28px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
}

.filter-panel input {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  outline: 0;
  padding: 0 18px;
  background: rgba(2, 6, 23, 0.56);
  color: var(--text);
}

.filter-button {
  min-width: 110px;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 70px 76px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.ranking-row:hover {
  border-color: rgba(52, 211, 153, 0.42);
  transform: translateX(4px);
}

.ranking-number {
  color: var(--gold);
  font-size: 24px;
  font-weight: 950;
  text-align: center;
}

.ranking-cover {
  width: 76px;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 14px;
  background: rgba(52, 211, 153, 0.12);
}

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

.ranking-main h2 {
  margin: 0 0 8px;
  color: #ffffff;
  font-size: 20px;
}

.ranking-main p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.ranking-meta {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.heat-score {
  min-width: 86px;
  color: var(--emerald);
  font-weight: 950;
  text-align: right;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--emerald);
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(280px, 390px) minmax(0, 1fr);
  gap: 34px;
  align-items: stretch;
}

.detail-poster {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 30px;
  background: rgba(15, 23, 42, 0.8);
  box-shadow: var(--shadow);
}

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

.detail-title {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at 0% 0%, rgba(52, 211, 153, 0.18), transparent 36%),
    rgba(15, 23, 42, 0.72);
}

.detail-title h1 {
  font-size: clamp(34px, 5vw, 68px);
  line-height: 1.08;
}

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

.watch-panel {
  margin-top: 42px;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 30px;
  background: #000000;
  box-shadow: var(--shadow);
}

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

.play-cover {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: #001b18;
  font-size: 20px;
  font-weight: 950;
  background:
    radial-gradient(circle at 50% 45%, rgba(52, 211, 153, 0.56), rgba(2, 6, 23, 0.68) 34%, rgba(2, 6, 23, 0.84) 100%);
}

.play-cover strong {
  display: grid;
  width: 78px;
  height: 78px;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--emerald), var(--cyan));
  color: #001b18;
  font-size: 34px;
  box-shadow: 0 20px 50px rgba(34, 211, 238, 0.26);
}

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

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 28px;
  margin-top: 42px;
}

.article-panel,
.side-panel {
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.72);
}

.article-panel {
  padding: 30px;
}

.article-panel h2,
.side-panel h2 {
  margin: 0 0 16px;
  color: #ffffff;
  font-size: 24px;
}

.article-panel p {
  margin: 0 0 20px;
  color: var(--soft);
  font-size: 16px;
  line-height: 1.9;
}

.side-panel {
  padding: 22px;
  height: fit-content;
}

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

.related-item {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.34);
}

.related-item img {
  width: 58px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 10px;
}

.related-item strong {
  display: block;
  color: #ffffff;
  line-height: 1.35;
}

.related-item span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.88);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0;
  color: var(--muted);
}

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

.empty-state {
  display: none;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
  text-align: center;
}

.empty-state.show {
  display: block;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

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

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

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

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

@media (max-width: 900px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .hero-slide.active,
  .detail-hero {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    padding: 34px;
  }

  .hero-visual {
    padding: 0 24px 80px;
  }

  .hero-rank-box {
    right: 34px;
    bottom: 34px;
  }

  .hero-dots {
    left: 34px;
  }

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

  .ranking-row {
    grid-template-columns: 48px 64px 1fr;
  }

  .heat-score {
    grid-column: 3;
    text-align: left;
  }
}

@media (max-width: 640px) {
  .site-header-inner,
  .footer-inner,
  .page-wrap,
  .hero-wrap {
    width: min(100% - 24px, 1180px);
  }

  .hero-shell,
  .page-title,
  .detail-title,
  .detail-poster,
  .video-shell {
    border-radius: 22px;
  }

  .hero-slide,
  .hero-slide.active {
    min-height: 0;
  }

  .hero-copy {
    padding: 28px 22px;
  }

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

  .hero-poster,
  .hero-poster img {
    min-height: 360px;
  }

  .hero-rank-box {
    position: static;
    width: auto;
    margin: 18px 24px 80px;
  }

  .hero-dots {
    bottom: 24px;
  }

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

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

  .filter-panel {
    flex-direction: column;
  }

  .filter-button {
    width: 100%;
  }

  .detail-content,
  .detail-hero {
    gap: 18px;
  }

  .detail-title,
  .article-panel,
  .side-panel,
  .page-title {
    padding: 22px;
  }

  .ranking-row {
    grid-template-columns: 42px 58px 1fr;
    gap: 12px;
  }
}
