:root {
  color-scheme: dark;
  --bg: #07111f;
  --bg-soft: #0d1b2f;
  --panel: rgba(15, 29, 50, 0.82);
  --panel-strong: rgba(12, 25, 46, 0.94);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #a8b3c7;
  --blue: #38bdf8;
  --blue-strong: #2563eb;
  --violet: #8b5cf6;
  --gold: #fbbf24;
  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius: 16px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 18% 8%, rgba(56, 189, 248, 0.16), transparent 34%),
    radial-gradient(circle at 88% 18%, rgba(139, 92, 246, 0.2), transparent 30%),
    linear-gradient(180deg, #050b16 0%, var(--bg) 48%, #08101f 100%);
  color: var(--text);
  min-height: 100vh;
}

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(5, 11, 22, 0.82);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  width: min(1260px, calc(100% - 28px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--blue), var(--blue-strong) 55%, var(--violet));
  box-shadow: 0 16px 36px rgba(37, 99, 235, 0.35);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.main-nav::-webkit-scrollbar {
  display: none;
}

.main-nav a {
  padding: 10px 12px;
  color: var(--muted);
  border-radius: 999px;
  white-space: nowrap;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.main-nav a:hover,
.main-nav a.is-active {
  color: var(--text);
  background: rgba(56, 189, 248, 0.12);
  transform: translateY(-1px);
}

.nav-search {
  position: relative;
  width: min(280px, 28vw);
}

.nav-search input,
.hero-search-line input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.76);
  color: var(--text);
  outline: none;
  padding: 12px 16px;
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.nav-search input:focus,
.hero-search-line input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: rgba(56, 189, 248, 0.72);
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.12);
  background: rgba(15, 23, 42, 0.94);
}

.global-results {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: min(420px, 90vw);
  max-height: 460px;
  overflow: auto;
  display: none;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(7, 17, 31, 0.98);
  box-shadow: var(--shadow);
}

.global-results.is-open {
  display: grid;
  gap: 8px;
}

.search-item {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 12px;
  align-items: center;
  padding: 8px;
  border-radius: 14px;
  background: rgba(148, 163, 184, 0.08);
}

.search-item img {
  width: 54px;
  height: 72px;
  object-fit: cover;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.18), rgba(139, 92, 246, 0.18));
}

.search-item strong {
  display: block;
  margin-bottom: 4px;
}

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

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(148, 163, 184, 0.08);
  color: var(--text);
}

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

.hero {
  position: relative;
  overflow: hidden;
  min-height: 680px;
  isolation: isolate;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 80% 20%, rgba(56, 189, 248, 0.22), transparent 35%),
    radial-gradient(circle at 20% 80%, rgba(139, 92, 246, 0.18), transparent 38%);
}

.hero-inner {
  width: min(1260px, calc(100% - 32px));
  margin: 0 auto;
  padding: 68px 0 46px;
  min-height: 680px;
  position: relative;
}

.hero-slide {
  position: absolute;
  inset: 68px 0 46px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.62fr);
  gap: 38px;
  align-items: center;
  opacity: 0;
  transform: translateX(24px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: -26px;
  z-index: -1;
  border-radius: 44px;
  background:
    linear-gradient(90deg, rgba(5, 11, 22, 0.92) 0%, rgba(5, 11, 22, 0.74) 46%, rgba(5, 11, 22, 0.5) 100%),
    var(--hero-image) center / cover;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05), var(--shadow);
  filter: saturate(1.12);
}

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

.hero-copy {
  padding: 46px;
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--blue);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 13px;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 14px 0 18px;
  font-size: clamp(38px, 7vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-copy p,
.page-hero p,
.detail-one-line {
  max-width: 680px;
  color: #d4deee;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.8;
}

.hero-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 28px 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  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 {
  background: linear-gradient(135deg, var(--blue), var(--blue-strong));
  color: white;
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.34);
}

.btn-ghost {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.hero-tags,
.detail-tags,
.rank-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.detail-tags span,
.rank-tags span,
.detail-meta span {
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  padding: 7px 11px;
  color: #dbeafe;
  background: rgba(15, 23, 42, 0.58);
  font-size: 13px;
}

.hero-poster {
  position: relative;
  justify-self: center;
  width: min(360px, 100%);
  aspect-ratio: 2 / 3;
  border-radius: 30px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.18), rgba(139, 92, 246, 0.18));
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

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

.hero-poster span {
  position: absolute;
  right: 18px;
  bottom: 18px;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.9);
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.42);
}

.hero-panel {
  position: absolute;
  left: 46px;
  right: 46px;
  bottom: 28px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  pointer-events: auto;
}

.hero-search-card {
  width: min(440px, 100%);
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(7, 17, 31, 0.72);
  backdrop-filter: blur(18px);
}

.hero-search-card h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.hero-search-card p {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.7;
}

.hero-dots {
  display: flex;
  gap: 10px;
}

.hero-dots button {
  width: 42px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.26);
  cursor: pointer;
}

.hero-dots button.is-active {
  background: var(--blue);
}

.category-strip {
  padding: 24px 0 8px;
}

.category-strip .container {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.category-strip a {
  padding: 10px 16px;
  border-radius: 999px;
  color: #dbeafe;
  border: 1px solid rgba(56, 189, 248, 0.18);
  background: rgba(56, 189, 248, 0.09);
}

.section {
  padding: 64px 0;
}

.section-soft {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.36), rgba(15, 23, 42, 0));
  border-block: 1px solid rgba(148, 163, 184, 0.08);
}

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

.section-head h2 {
  margin: 8px 0 8px;
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.04em;
}

.section-head p {
  margin: 0;
  max-width: 680px;
  color: var(--muted);
  line-height: 1.8;
}

.section-link {
  color: var(--blue);
  font-weight: 800;
  white-space: nowrap;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 180px 180px;
  gap: 12px;
  margin-bottom: 24px;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.76), rgba(15, 23, 42, 0.44));
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.22);
  transition: transform 0.22s ease, border 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(56, 189, 248, 0.35);
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.3);
}

.card-cover {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 20%, rgba(56, 189, 248, 0.2), transparent 46%),
    linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(15, 23, 42, 0.98));
}

.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease, opacity 0.25s ease;
}

.movie-card:hover .card-cover img {
  transform: scale(1.06);
}

.card-play {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  color: white;
  background: rgba(37, 99, 235, 0.86);
  transform: translate(-50%, -50%) scale(0.72);
  opacity: 0;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.movie-card:hover .card-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.rank-badge {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 2;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #111827;
  background: linear-gradient(135deg, #fde68a, var(--gold));
  font-weight: 900;
}

.card-body {
  padding: 14px;
}

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

.card-meta {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: 12px;
  line-height: 1.5;
}

.card-text {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.movie-card-compact .card-text {
  display: none;
}

.page-main {
  padding-top: 20px;
}

.page-hero {
  padding: 62px 0 24px;
}

.page-hero h1 {
  max-width: 900px;
}

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

.category-card {
  min-height: 230px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(135deg, rgba(5, 11, 22, 0.95), rgba(15, 23, 42, 0.62)),
    var(--cat-image) center / cover;
  box-shadow: var(--shadow);
}

.category-card a {
  display: flex;
  min-height: 230px;
  flex-direction: column;
  justify-content: end;
  padding: 28px;
}

.category-card span {
  width: fit-content;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--blue);
  background: rgba(56, 189, 248, 0.12);
}

.category-card h2 {
  margin: 16px 0 8px;
  font-size: 28px;
}

.category-card p {
  margin: 0;
  color: #dbeafe;
  line-height: 1.8;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 58px 86px 1fr;
  gap: 16px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.64);
}

.rank-num {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(56, 189, 248, 0.12);
  color: var(--blue);
  font-weight: 900;
}

.rank-poster {
  display: block;
  width: 86px;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.18), rgba(139, 92, 246, 0.18));
}

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

.rank-content h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.rank-content p {
  margin: 0 0 12px;
  color: var(--muted);
  line-height: 1.7;
}

.detail-hero {
  position: relative;
  padding: 64px 0 32px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(5, 11, 22, 0.98), rgba(5, 11, 22, 0.72), rgba(5, 11, 22, 0.98)),
    var(--detail-image) center / cover;
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 120px;
  background: linear-gradient(180deg, transparent, var(--bg));
}

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

.breadcrumb {
  display: inline-flex;
  margin-bottom: 24px;
  color: var(--blue);
  font-weight: 800;
}

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

.detail-cover {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 30px;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.18), rgba(139, 92, 246, 0.18));
  box-shadow: var(--shadow);
}

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

.detail-copy h1 {
  font-size: clamp(40px, 7vw, 78px);
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 20px 0;
}

.player-card,
.article-card {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius-xl);
  background: rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  aspect-ratio: 16 / 9;
  background: #020617;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  background: #020617;
}

.video-start {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: white;
  cursor: pointer;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.32), rgba(2, 6, 23, 0.68));
}

.video-start span {
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--blue-strong));
  box-shadow: 0 24px 50px rgba(37, 99, 235, 0.42);
  font-size: 30px;
}

.video-start strong {
  font-size: 20px;
}

.video-shell.is-playing .video-start {
  display: none;
}

.article-section {
  padding-top: 0;
}

.article-card {
  padding: clamp(22px, 4vw, 42px);
}

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

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

.site-footer {
  margin-top: 40px;
  border-top: 1px solid var(--line);
  background: rgba(5, 11, 22, 0.88);
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0;
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 0.7fr;
  gap: 32px;
}

.site-footer p {
  color: var(--muted);
  line-height: 1.8;
  max-width: 560px;
}

.site-footer h3 {
  margin: 0 0 14px;
  font-size: 16px;
}

.site-footer a:not(.footer-brand) {
  display: block;
  margin: 9px 0;
  color: var(--muted);
}

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

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

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

@media (max-width: 880px) {
  .nav-wrap {
    flex-wrap: wrap;
    padding: 12px 0;
  }

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

  .main-nav {
    display: none;
    order: 4;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    overflow: visible;
    background: rgba(15, 23, 42, 0.92);
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 10px;
  }

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

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

  .hero,
  .hero-inner {
    min-height: 820px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    inset: 32px 0 170px;
    gap: 16px;
  }

  .hero-copy {
    padding: 30px;
  }

  .hero-poster {
    width: min(280px, 68vw);
  }

  .hero-panel {
    left: 20px;
    right: 20px;
    bottom: 24px;
    flex-direction: column;
    align-items: stretch;
  }

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

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

  .detail-cover {
    width: min(280px, 72vw);
  }

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

@media (max-width: 620px) {
  .movie-grid,
  .compact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .category-grid {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 42px 0;
  }

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

  .rank-row {
    grid-template-columns: 44px 70px 1fr;
    gap: 10px;
  }

  .rank-poster {
    width: 70px;
  }

  .rank-content h3 {
    font-size: 16px;
  }

  .rank-content p,
  .rank-tags {
    display: none;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 40px;
  }
}
