:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --bg-card: rgba(15, 23, 42, 0.72);
  --line: rgba(148, 163, 184, 0.18);
  --line-strong: rgba(34, 211, 238, 0.28);
  --text: #f8fafc;
  --muted: #94a3b8;
  --muted-strong: #cbd5e1;
  --cyan: #22d3ee;
  --blue: #3b82f6;
  --purple: #8b5cf6;
  --orange: #fb923c;
  --yellow: #facc15;
  --radius: 18px;
  --shadow: 0 24px 80px rgba(2, 6, 23, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 10%, rgba(34, 211, 238, 0.12), transparent 34rem),
    radial-gradient(circle at 80% 0%, rgba(59, 130, 246, 0.12), transparent 34rem),
    linear-gradient(180deg, #020617 0%, #0f172a 44%, #020617 100%);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(2, 6, 23, 0.86);
  backdrop-filter: blur(18px);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--cyan), var(--blue), var(--purple));
  box-shadow: 0 0 28px rgba(34, 211, 238, 0.35);
}

.logo-text {
  font-size: 18px;
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.nav-links a {
  padding: 9px 13px;
  border-radius: 999px;
  color: var(--muted-strong);
  font-weight: 700;
  font-size: 14px;
  transition: 0.22s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: #fff;
  background: rgba(34, 211, 238, 0.12);
  box-shadow: inset 0 0 0 1px rgba(34, 211, 238, 0.18);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.8);
  color: #fff;
  cursor: pointer;
}

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

.mobile-menu a {
  display: block;
  padding: 11px 12px;
  border-radius: 12px;
  color: var(--muted-strong);
  font-weight: 700;
}

.mobile-menu a:hover {
  background: rgba(34, 211, 238, 0.12);
  color: #fff;
}

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

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

.hero {
  position: relative;
  overflow: hidden;
  padding: 74px 0 58px;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  filter: blur(8px);
  pointer-events: none;
}

.hero::before {
  inset: 10% auto auto 12%;
  width: 260px;
  height: 260px;
  background: rgba(34, 211, 238, 0.12);
}

.hero::after {
  right: 9%;
  bottom: 10%;
  width: 360px;
  height: 360px;
  background: rgba(59, 130, 246, 0.12);
}

.hero-inner {
  position: relative;
  z-index: 1;
}

.hero-copy {
  max-width: 820px;
  margin: 0 auto 38px;
  text-align: center;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 6px 12px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.08);
  color: var(--cyan);
  font-size: 13px;
  font-weight: 800;
}

.hero h1,
.page-title h1 {
  margin: 0;
  font-size: clamp(38px, 7vw, 70px);
  line-height: 1.06;
  letter-spacing: -0.05em;
}

.gradient-text {
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p,
.page-title p {
  margin: 18px auto 0;
  max-width: 760px;
  color: var(--muted-strong);
  font-size: 18px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.btn-primary {
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 18px 42px rgba(34, 211, 238, 0.2);
}

.btn-soft {
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.72);
  color: var(--muted-strong);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 48px rgba(34, 211, 238, 0.22);
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.hero-card {
  position: relative;
  min-height: 330px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--bg-card);
  box-shadow: var(--shadow);
  transform: translateY(0);
  transition: 0.35s ease;
}

.hero-card.is-active,
.hero-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-6px);
}

.hero-card img {
  width: 100%;
  height: 100%;
  min-height: 330px;
  object-fit: cover;
  transition: transform 0.55s ease;
}

.hero-card:hover img {
  transform: scale(1.08);
}

.hero-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.86));
}

.hero-card-body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  padding: 24px;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: var(--muted-strong);
  font-size: 12px;
  font-weight: 800;
}

.badge-cyan {
  background: rgba(34, 211, 238, 0.16);
  color: var(--cyan);
}

.hero-card h2,
.hero-card h3 {
  margin: 0 0 8px;
  font-size: 23px;
  line-height: 1.25;
}

.hero-card p {
  margin: 0 0 14px;
  color: #dbeafe;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.section {
  padding: 44px 0;
}

.section-soft {
  background: rgba(15, 23, 42, 0.42);
  border-block: 1px solid rgba(148, 163, 184, 0.08);
}

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

.section-head h2,
.section-head h1,
.block-title {
  margin: 0;
  font-size: clamp(26px, 3.5vw, 36px);
  line-height: 1.16;
}

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

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

.movie-card {
  min-width: 0;
}

.card {
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.64);
  box-shadow: 0 18px 52px rgba(2, 6, 23, 0.28);
  transition: transform 0.24s ease, border-color 0.24s ease, background 0.24s ease;
}

.card:hover {
  border-color: rgba(34, 211, 238, 0.28);
  background: rgba(15, 23, 42, 0.9);
  transform: translateY(-5px);
}

.poster {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #0f172a;
}

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

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

.poster .year {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.78);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

.card-title {
  margin: 0 0 10px;
  min-height: 46px;
  font-size: 17px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 168px;
  padding: 22px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.64));
  transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-card::before {
  content: "";
  position: absolute;
  inset: -40% -20% auto auto;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.12);
  transition: transform 0.32s ease;
}

.category-card:hover {
  border-color: rgba(34, 211, 238, 0.34);
  transform: translateY(-5px);
}

.category-card:hover::before {
  transform: scale(1.25);
}

.category-card h2,
.category-card h3 {
  position: relative;
  margin: 0 0 8px;
  font-size: 22px;
}

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

.category-count {
  position: relative;
  color: var(--cyan);
  font-weight: 900;
}

.page-title {
  padding: 54px 0 34px;
  text-align: center;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0 0 24px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.58);
}

.search-box {
  flex: 1;
  min-width: 220px;
  position: relative;
}

.search-box input {
  width: 100%;
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  outline: none;
  background: rgba(2, 6, 23, 0.64);
  color: #fff;
}

.search-box input:focus {
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.1);
}

.count-text {
  color: var(--muted-strong);
  font-weight: 800;
  white-space: nowrap;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 126px minmax(0, 1fr);
  gap: 14px;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.58);
  transition: 0.22s ease;
}

.compact-card:hover {
  border-color: rgba(34, 211, 238, 0.28);
  background: rgba(15, 23, 42, 0.88);
}

.compact-card img {
  width: 126px;
  height: 78px;
  object-fit: cover;
  border-radius: 12px;
}

.compact-card h3 {
  margin: 0 0 6px;
  font-size: 16px;
  line-height: 1.35;
}

.compact-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.rank-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin-right: 8px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--orange), var(--yellow));
  color: #111827;
  font-weight: 1000;
}

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

.stat-box {
  padding: 26px 18px;
  border: 1px solid rgba(34, 211, 238, 0.12);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.56);
  text-align: center;
}

.stat-num {
  display: block;
  margin-bottom: 6px;
  color: var(--cyan);
  font-size: 34px;
  font-weight: 1000;
}

.stat-label {
  color: var(--muted);
}

.detail-wrap {
  padding: 36px 0 56px;
}

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

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(300px, 0.6fr);
  gap: 28px;
  align-items: start;
}

.player-shell {
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 24px;
  background: #000;
  box-shadow: var(--shadow);
}

.player-box {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.72));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-start {
  width: 82px;
  height: 82px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  color: #fff;
  font-size: 30px;
  cursor: pointer;
  box-shadow: 0 18px 56px rgba(34, 211, 238, 0.36);
}

.player-meta {
  padding: 18px 20px 20px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(15, 23, 42, 0.78);
}

.player-meta h1 {
  margin: 0 0 8px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.18;
}

.player-meta p {
  margin: 0;
  color: var(--muted-strong);
}

.info-panel {
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.68);
  padding: 20px;
}

.info-panel img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 18px;
  margin-bottom: 18px;
}

.info-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.info-row {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 10px;
  color: var(--muted-strong);
}

.info-row span:first-child {
  color: var(--muted);
}

.article-block {
  margin-top: 26px;
  padding: 24px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.48);
}

.article-block h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.article-block p {
  margin: 0;
  color: var(--muted-strong);
}

.article-block p + p {
  margin-top: 12px;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.site-footer {
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.48), rgba(2, 6, 23, 0.92));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: 28px;
  padding: 42px 0;
}

.footer-grid h3 {
  margin: 0 0 12px;
  color: #fff;
}

.footer-grid p,
.footer-grid a {
  color: var(--muted);
  font-size: 14px;
}

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

.footer-bottom {
  padding: 18px 0 28px;
  color: var(--muted);
  border-top: 1px solid rgba(148, 163, 184, 0.08);
  font-size: 13px;
}

.is-hidden-card {
  display: none !important;
}

.empty-state {
  display: none;
  padding: 28px;
  border: 1px dashed rgba(148, 163, 184, 0.28);
  border-radius: 20px;
  color: var(--muted);
  text-align: center;
}

.empty-state.is-visible {
  display: block;
}

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

  .mobile-toggle {
    display: inline-grid;
    place-items: center;
  }

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

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

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

@media (max-width: 680px) {
  .nav-wrap {
    height: 62px;
  }

  .logo-text {
    font-size: 16px;
  }

  .hero {
    padding: 46px 0 36px;
  }

  .hero-grid,
  .movie-grid,
  .category-grid,
  .compact-list,
  .stats-strip,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .section-head,
  .toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .compact-card {
    grid-template-columns: 112px minmax(0, 1fr);
  }

  .compact-card img {
    width: 112px;
    height: 74px;
  }

  .hero-card,
  .hero-card img {
    min-height: 280px;
  }

  .player-start {
    width: 66px;
    height: 66px;
    font-size: 24px;
  }
}
