:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.84);
  --panel-strong: rgba(15, 23, 42, 0.96);
  --muted: #94a3b8;
  --text: #f8fafc;
  --soft: #cbd5e1;
  --line: rgba(148, 163, 184, 0.18);
  --cyan: #38bdf8;
  --blue: #0284c7;
  --amber: #f59e0b;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 6%, rgba(56, 189, 248, 0.22), transparent 30rem),
    radial-gradient(circle at 78% 12%, rgba(245, 158, 11, 0.16), transparent 26rem),
    linear-gradient(180deg, #020617 0%, #0f172a 42%, #020617 100%);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(20px);
}

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

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(56, 189, 248, 0.42);
  border-radius: 15px;
  color: #082f49;
  background: linear-gradient(135deg, #7dd3fc, #f59e0b);
  box-shadow: 0 10px 35px rgba(56, 189, 248, 0.24);
}

.brand-text {
  font-size: 20px;
}

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

.nav-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--soft);
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: white;
  background: rgba(56, 189, 248, 0.14);
  transform: translateY(-1px);
}

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

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: white;
}

.hero {
  padding: 28px 0 18px;
}

.hero-frame {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  min-height: 580px;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.22);
  border-radius: 34px;
  background: rgba(15, 23, 42, 0.74);
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 40px;
  align-items: center;
  padding: 58px;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.01);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero-bg img {
  height: 100%;
  object-fit: cover;
  filter: blur(26px) saturate(1.2);
  transform: scale(1.08);
  opacity: 0.34;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(15, 23, 42, 0.72) 52%, rgba(2, 6, 23, 0.82) 100%),
    radial-gradient(circle at 70% 25%, rgba(56, 189, 248, 0.22), transparent 28rem);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 760px;
  margin: 0 0 14px;
  font-size: clamp(34px, 6vw, 70px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero h2 {
  margin: 0 0 14px;
  color: #fde68a;
  font-size: clamp(24px, 3.4vw, 44px);
  line-height: 1.12;
}

.hero-summary {
  max-width: 720px;
  margin: 0 0 22px;
  color: var(--soft);
  font-size: 18px;
}

.hero-actions,
.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn.primary {
  color: #082f49;
  background: linear-gradient(135deg, #7dd3fc, #f59e0b);
  box-shadow: 0 14px 34px rgba(56, 189, 248, 0.25);
}

.btn.ghost {
  color: white;
  background: rgba(15, 23, 42, 0.68);
}

.btn.soft {
  color: #e0f2fe;
  background: rgba(2, 132, 199, 0.28);
}

.hero-poster {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 28px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.46);
}

.hero-poster img {
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.hero-poster span,
.play-dot {
  position: absolute;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  color: #082f49;
  background: linear-gradient(135deg, #7dd3fc, #f59e0b);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.4);
}

.hero-poster span {
  right: 18px;
  bottom: 18px;
}

.hero-thumbs {
  position: absolute;
  right: 28px;
  bottom: 24px;
  left: 28px;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  z-index: 4;
}

.hero-thumb {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--soft);
  background: rgba(2, 6, 23, 0.72);
  cursor: pointer;
}

.hero-thumb.active {
  color: white;
  border-color: rgba(56, 189, 248, 0.66);
  background: rgba(2, 132, 199, 0.34);
}

.hero-thumb img {
  width: 42px;
  height: 58px;
  flex: 0 0 auto;
  border-radius: 10px;
  object-fit: cover;
}

.hero-thumb span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.page-wrap {
  padding: 30px 0 58px;
}

.page-title {
  margin: 18px 0 28px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.24), rgba(15, 23, 42, 0.84));
  box-shadow: var(--shadow);
}

.page-title h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.12;
}

.page-title p {
  max-width: 850px;
  margin: 0;
  color: var(--soft);
  font-size: 17px;
}

.content-section {
  margin-top: 42px;
}

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

.section-head h2 {
  margin: 0 0 6px;
  font-size: clamp(24px, 3vw, 34px);
}

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

.section-more {
  flex: 0 0 auto;
  color: #7dd3fc;
  font-weight: 800;
}

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

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

.movie-card:hover {
  border-color: rgba(56, 189, 248, 0.46);
  background: rgba(15, 23, 42, 0.94);
  transform: translateY(-4px);
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  background: #0f172a;
}

.poster-wrap img {
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.play-dot {
  right: 14px;
  bottom: 14px;
  width: 46px;
  height: 46px;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.movie-card:hover .play-dot {
  opacity: 1;
  transform: translateY(0);
}

.movie-info {
  padding: 16px;
}

.movie-info h3,
.rank-body h3 {
  margin: 8px 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.movie-info p,
.rank-body p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.movie-meta,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.movie-meta span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 12px;
}

.movie-meta span {
  color: #bae6fd;
  background: rgba(2, 132, 199, 0.22);
}

.tag-row {
  margin-top: 12px;
}

.tag-row span {
  color: #fde68a;
  background: rgba(69, 26, 3, 0.42);
}

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

.category-card {
  min-height: 176px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(56, 189, 248, 0.18), transparent 11rem),
    rgba(15, 23, 42, 0.76);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.22);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 10px;
}

.category-card p {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 14px;
}

.category-card a {
  color: #7dd3fc;
  font-weight: 800;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 180px;
  gap: 14px;
  margin: 0 0 24px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
}

.filter-panel label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 44px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 14px;
  color: white;
  background: rgba(2, 6, 23, 0.74);
  padding: 0 14px;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(56, 189, 248, 0.7);
}

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

.rank-card {
  position: relative;
  display: grid;
  grid-template-columns: 96px 56px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.76);
}

.rank-cover img {
  aspect-ratio: 2 / 3;
  border-radius: 16px;
  object-fit: cover;
}

.rank-number {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 16px;
  color: #082f49;
  font-size: 18px;
  font-weight: 900;
  background: linear-gradient(135deg, #7dd3fc, #f59e0b);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 24px;
  align-items: start;
}

.player-card,
.detail-card,
.side-card {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
}

.player-card {
  overflow: hidden;
}

.video-shell {
  position: relative;
  background: black;
}

.video-shell video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: black;
  cursor: pointer;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: white;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.08), rgba(2, 6, 23, 0.78));
  cursor: pointer;
  z-index: 3;
}

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

.player-button {
  display: grid;
  width: 82px;
  height: 82px;
  place-items: center;
  border-radius: 50%;
  color: #082f49;
  font-size: 28px;
  font-weight: 900;
  background: linear-gradient(135deg, #7dd3fc, #f59e0b);
  box-shadow: 0 22px 58px rgba(0, 0, 0, 0.42);
}

.player-caption {
  padding: 18px 22px 22px;
}

.player-caption h1 {
  margin: 0 0 10px;
  font-size: clamp(28px, 4.8vw, 48px);
  line-height: 1.1;
}

.player-caption p {
  margin: 0;
  color: var(--soft);
}

.detail-card,
.side-card {
  padding: 24px;
}

.detail-card h2,
.side-card h2 {
  margin: 0 0 14px;
}

.detail-card p {
  color: var(--soft);
}

.info-table {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.info-item {
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.38);
}

.info-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.info-item strong {
  display: block;
  margin-top: 4px;
}

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

.related-item {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(2, 6, 23, 0.32);
}

.related-item img {
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  object-fit: cover;
}

.related-item h3 {
  margin: 0 0 6px;
  font-size: 15px;
}

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

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

.archive-link {
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.72);
}

.archive-link strong {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.archive-link span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

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

.footer-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.7fr);
  gap: 28px;
  padding: 34px 0;
  color: var(--muted);
}

.footer-inner strong {
  color: white;
  font-size: 20px;
}

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

.footer-links a {
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--soft);
}

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

@media (max-width: 980px) {
  .menu-toggle {
    display: block;
  }

  .nav {
    position: absolute;
    top: 72px;
    right: 16px;
    left: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(2, 6, 23, 0.96);
  }

  .nav.open {
    display: flex;
  }

  .hero-frame {
    min-height: 720px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 30px;
  }

  .hero-poster {
    max-width: 240px;
  }

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

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

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

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

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

@media (max-width: 640px) {
  .hero-frame {
    width: min(100% - 20px, 1180px);
    min-height: 760px;
    border-radius: 24px;
  }

  .hero-slide {
    padding: 22px;
  }

  .hero-thumbs {
    left: 16px;
    right: 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .movie-grid,
  .category-grid,
  .archive-list {
    grid-template-columns: 1fr;
  }

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

  .rank-number {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 40px;
    height: 40px;
  }

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

  .info-table {
    grid-template-columns: 1fr;
  }
}
