:root {
  --bg: #020617;
  --panel: #0f172a;
  --panel-soft: rgba(15, 23, 42, 0.78);
  --panel-strong: rgba(15, 23, 42, 0.95);
  --line: rgba(148, 163, 184, 0.18);
  --line-strong: rgba(34, 211, 238, 0.34);
  --text: #e2e8f0;
  --muted: #94a3b8;
  --faint: #64748b;
  --cyan: #22d3ee;
  --blue: #60a5fa;
  --green: #34d399;
  --gold: #facc15;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
  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;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.16), transparent 34rem),
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.12), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.92), rgba(15, 23, 42, 0.96));
  backdrop-filter: blur(14px);
}

.nav-shell {
  height: 68px;
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: var(--text);
  white-space: nowrap;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 12px;
  color: #00131a;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 0 28px rgba(34, 211, 238, 0.35);
  font-size: 14px;
}

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

.desktop-nav a,
.mobile-panel a {
  padding: 10px 12px;
  border-radius: 12px;
  color: #cbd5e1;
  font-size: 14px;
  transition: 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-panel a:hover {
  color: var(--cyan);
  background: rgba(15, 23, 42, 0.85);
}

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

.header-search input,
.hero-search-card input,
.filter-bar input,
.filter-bar select {
  color: var(--text);
  background: rgba(15, 23, 42, 0.82);
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 14px;
  outline: none;
  transition: 0.2s ease;
}

.header-search input {
  width: 240px;
  padding: 10px 12px;
}

.header-search input:focus,
.hero-search-card input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.12);
}

.header-search button,
.hero-search-card button,
.filter-bar button,
.btn {
  border: 0;
  cursor: pointer;
  border-radius: 14px;
  font-weight: 700;
  transition: 0.2s ease;
}

.header-search button,
.hero-search-card button,
.filter-bar button,
.btn.primary {
  color: #00131a;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 14px 36px rgba(34, 211, 238, 0.22);
}

.header-search button {
  padding: 10px 14px;
}

.menu-toggle {
  display: none;
  margin-left: auto;
  width: 42px;
  height: 42px;
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.85);
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 8px 0 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
}

.mobile-panel.is-open {
  display: grid;
  gap: 6px;
}

.hero-section {
  width: min(1280px, calc(100% - 32px));
  margin: 28px auto 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 22px;
}

.hero-carousel {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 30px;
  background: #0f172a;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.95) 0%, rgba(2, 6, 23, 0.72) 44%, rgba(2, 6, 23, 0.16) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.1), rgba(2, 6, 23, 0.86));
}

.hero-content {
  position: absolute;
  left: clamp(24px, 5vw, 72px);
  bottom: clamp(34px, 7vw, 90px);
  width: min(640px, calc(100% - 48px));
}

.hero-kicker,
.detail-kicker,
.section-heading span,
.page-hero span,
.category-card-large span {
  color: var(--cyan);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-content h1 {
  margin: 16px 0 16px;
  font-size: clamp(40px, 7vw, 76px);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.hero-content p,
.page-hero p,
.detail-one-line,
.detail-section p,
.footer-grid p,
.category-card-large p {
  color: #cbd5e1;
  line-height: 1.8;
}

.hero-content p {
  max-width: 620px;
  font-size: 17px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 12px 18px;
}

.btn.ghost {
  color: #dbeafe;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(15, 23, 42, 0.72);
}

.btn:hover,
.header-search button:hover,
.hero-search-card button:hover,
.filter-bar button:hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
}

.hero-dots {
  position: absolute;
  left: clamp(24px, 5vw, 72px);
  bottom: 28px;
  display: flex;
  gap: 8px;
  z-index: 3;
}

.hero-dots button {
  width: 30px;
  height: 5px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  background: rgba(203, 213, 225, 0.35);
}

.hero-dots button.active {
  width: 52px;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.hero-panel,
.ranking-panel,
.player-card,
.detail-info,
.detail-section,
.category-card-large,
.page-hero,
.filter-bar,
.movie-card,
.ranking-item,
.category-tile {
  border: 1px solid var(--line);
  background: var(--panel-soft);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.hero-panel {
  border-radius: 30px;
  padding: 22px;
}

.hero-panel h2 {
  margin: 0 0 18px;
  font-size: 22px;
}

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

.hero-mini {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.72);
  transition: 0.2s ease;
}

.hero-mini:hover {
  transform: translateX(3px);
  border-color: var(--line-strong);
}

.hero-mini img {
  width: 76px;
  height: 94px;
  border-radius: 14px;
  object-fit: cover;
}

.hero-mini strong,
.hero-mini em {
  display: block;
}

.hero-mini strong {
  font-size: 15px;
  line-height: 1.4;
}

.hero-mini em {
  margin-top: 6px;
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.hero-search-card {
  margin-top: 18px;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.1), rgba(96, 165, 250, 0.08));
}

.hero-search-card form {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.hero-search-card input {
  width: 100%;
  padding: 12px 14px;
}

.hero-search-card button {
  padding: 12px 16px;
}

.section-block,
.page-main {
  padding: 54px 0;
}

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

.section-heading.compact {
  align-items: center;
}

.section-heading h2 {
  margin: 6px 0 0;
  font-size: clamp(26px, 4vw, 40px);
  letter-spacing: -0.04em;
}

.section-heading a {
  color: var(--cyan);
  font-weight: 800;
}

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

.category-tile {
  min-height: 126px;
  padding: 20px;
  border-radius: 24px;
  transition: 0.2s ease;
}

.category-tile:hover,
.movie-card:hover,
.category-card-large:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: 0 24px 80px rgba(34, 211, 238, 0.14);
}

.category-tile span {
  display: block;
  margin-bottom: 10px;
  color: var(--cyan);
  font-weight: 800;
}

.category-tile strong {
  color: #cbd5e1;
  font-weight: 500;
  line-height: 1.6;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 160px 160px auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 20px;
  padding: 16px;
  border-radius: 22px;
}

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

.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
}

.filter-bar button {
  min-height: 44px;
  padding: 10px 16px;
}

.filter-count {
  min-height: 22px;
  margin: -8px 0 16px;
  color: var(--muted);
  font-size: 14px;
}

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

.home-grid,
.category-page-grid,
.archive-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  transition: 0.22s ease;
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #0f172a;
}

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

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

.movie-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.02), rgba(2, 6, 23, 0.88));
}

.movie-category,
.movie-duration,
.movie-play {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: #ecfeff;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(10px);
}

.movie-category {
  left: 10px;
  top: 10px;
  padding: 6px 9px;
  color: var(--cyan);
  font-size: 12px;
  font-weight: 800;
}

.movie-duration {
  right: 10px;
  bottom: 10px;
  padding: 5px 8px;
  font-size: 12px;
}

.movie-play {
  left: 50%;
  top: 50%;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.9);
  color: #00131a;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  transition: 0.2s ease;
}

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

.movie-info {
  padding: 14px;
}

.movie-info h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.45;
}

.movie-info h3 a:hover {
  color: var(--cyan);
}

.movie-line {
  min-height: 46px;
  margin: 8px 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.movie-meta span,
.detail-meta span,
.tag-row span,
.chip-row a {
  padding: 5px 8px;
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(30, 41, 59, 0.82);
  font-size: 12px;
}

.ranking-panel {
  position: sticky;
  top: 92px;
  border-radius: 26px;
  padding: 20px;
}

.ranking-list {
  list-style: none;
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
}

.ranking-item {
  overflow: hidden;
  border-radius: 18px;
}

.ranking-link {
  display: grid;
  grid-template-columns: 46px 54px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px;
}

.ranking-num {
  color: var(--gold);
  font-weight: 900;
  font-size: 18px;
}

.ranking-link img {
  width: 54px;
  height: 72px;
  border-radius: 12px;
  object-fit: cover;
}

.ranking-body strong,
.ranking-body em {
  display: block;
}

.ranking-body strong {
  line-height: 1.4;
}

.ranking-body em {
  margin-top: 6px;
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.ranking-score {
  color: var(--green);
  font-weight: 900;
}

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

.page-main {
  min-height: 70vh;
}

.page-hero {
  margin-bottom: 26px;
  padding: clamp(26px, 5vw, 48px);
  border-radius: 30px;
  overflow: hidden;
  position: relative;
}

.page-hero::before {
  content: "";
  position: absolute;
  inset: -40% auto auto 60%;
  width: 420px;
  height: 420px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.16);
  filter: blur(40px);
}

.page-hero h1 {
  position: relative;
  margin: 12px 0;
  font-size: clamp(34px, 6vw, 62px);
  letter-spacing: -0.05em;
}

.page-hero p,
.page-hero span,
.page-hero .chip-row {
  position: relative;
}

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

.category-card-large {
  display: grid;
  gap: 18px;
  padding: 24px;
  border-radius: 26px;
  transition: 0.2s ease;
}

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

.category-card-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.category-card-links a {
  padding: 8px 10px;
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.72);
}

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

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

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

.chip-row {
  margin-top: 18px;
}

.chip-row a:hover {
  color: var(--cyan);
}

.detail-main {
  padding-top: 28px;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  gap: 24px;
  align-items: stretch;
}

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  min-height: 420px;
  background: #000;
}

.movie-player {
  width: 100%;
  height: 100%;
  min-height: 420px;
  display: block;
  background: #000;
  object-fit: contain;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  color: var(--text);
  border: 0;
  cursor: pointer;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.72));
  transition: 0.22s ease;
}

.play-overlay span {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #00131a;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 24px 70px rgba(34, 211, 238, 0.32);
}

.play-overlay strong {
  font-size: 18px;
}

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

.detail-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 28px;
  border-radius: 28px;
}

.detail-info h1 {
  margin: 14px 0;
  font-size: clamp(32px, 5vw, 58px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.detail-one-line {
  font-size: 17px;
}

.detail-meta {
  margin: 18px 0;
}

.tag-row span {
  color: var(--cyan);
}

.detail-section {
  margin-top: 24px;
  padding: 24px;
  border-radius: 24px;
}

.detail-section h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.detail-section p {
  margin: 0;
}

.prev-next {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.prev-next a {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.72);
}

.prev-next a:hover {
  color: var(--cyan);
  border-color: var(--line-strong);
}

.site-footer {
  margin-top: 30px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.84), rgba(2, 6, 23, 0.98));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 32px;
  padding: 42px 0;
}

.footer-brand {
  margin-bottom: 14px;
}

.footer-grid h2 {
  margin: 0 0 14px;
  font-size: 18px;
}

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

.footer-links a {
  color: var(--muted);
}

.footer-links a:hover {
  color: var(--cyan);
}

.footer-bottom {
  padding: 18px;
  text-align: center;
  color: var(--faint);
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

[data-card].is-hidden {
  display: none;
}

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

  .hero-panel,
  .ranking-panel {
    position: static;
  }

  .category-grid,
  .movie-grid,
  .home-grid,
  .category-page-grid,
  .archive-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

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

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

  .hero-carousel {
    min-height: 560px;
  }

  .category-grid,
  .movie-grid,
  .home-grid,
  .category-page-grid,
  .archive-grid,
  .category-overview-grid,
  .ranking-list-page,
  .footer-grid,
  .prev-next {
    grid-template-columns: 1fr 1fr;
  }

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

@media (max-width: 560px) {
  .site-shell,
  .hero-section,
  .mobile-panel {
    width: min(100% - 22px, 1180px);
  }

  .hero-section {
    margin-top: 14px;
  }

  .hero-carousel {
    min-height: 520px;
    border-radius: 22px;
  }

  .hero-content {
    left: 18px;
    bottom: 56px;
    width: calc(100% - 36px);
  }

  .hero-dots {
    left: 18px;
    bottom: 22px;
  }

  .category-grid,
  .movie-grid,
  .home-grid,
  .category-page-grid,
  .archive-grid,
  .category-overview-grid,
  .ranking-list-page,
  .footer-grid,
  .prev-next {
    grid-template-columns: 1fr;
  }

  .ranking-link {
    grid-template-columns: 36px 50px 1fr;
  }

  .ranking-score {
    grid-column: 3;
  }

  .player-card,
  .movie-player {
    min-height: 260px;
  }
}
