* {
  box-sizing: border-box;
}

:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --bg-card: rgba(15, 23, 42, 0.78);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: #10b981;
  --accent-strong: #059669;
  --amber: #f59e0b;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
  --radius: 22px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 18% 8%, rgba(16, 185, 129, 0.18), transparent 34rem),
    radial-gradient(circle at 85% 18%, rgba(99, 102, 241, 0.16), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 46%, #020617 100%);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

body.menu-open {
  overflow: hidden;
}

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

img {
  display: block;
  max-width: 100%;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.92));
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

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

.header-inner {
  width: min(1180px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 26px;
}

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border-radius: 13px;
  color: #ffffff;
  background: linear-gradient(135deg, #10b981, #059669);
  box-shadow: 0 12px 28px rgba(16, 185, 129, 0.3);
  font-size: 14px;
}

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

.desktop-nav a,
.mobile-nav a,
.footer-links a {
  color: #cbd5e1;
  font-weight: 650;
  transition: color 0.25s ease, background 0.25s ease;
}

.desktop-nav a {
  padding: 10px 14px;
  border-radius: 999px;
}

.desktop-nav a:hover,
.mobile-nav a:hover,
.footer-links a:hover {
  color: #ffffff;
  background: rgba(16, 185, 129, 0.12);
}

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

.nav-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #ffffff;
  background: transparent;
  padding: 10px 0 10px 16px;
}

.nav-search button {
  border: 0;
  color: #ffffff;
  background: var(--accent);
  padding: 10px 16px;
  font-weight: 800;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.82);
}

.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 10px;
  padding: 0 16px 18px;
}

.mobile-nav a {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.86);
}

.hero-slider {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  background: #020617;
}

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

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

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

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.86) 0%, rgba(0, 0, 0, 0.58) 44%, rgba(0, 0, 0, 0.18) 100%),
    linear-gradient(0deg, #020617 0%, transparent 38%);
}

.hero-content {
  position: absolute;
  z-index: 2;
  left: max(16px, calc((100vw - 1180px) / 2));
  top: 50%;
  width: min(650px, calc(100% - 32px));
  transform: translateY(-45%);
}

.eyebrow {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.eyebrow span,
.card-tags span,
.info-tags span,
.breadcrumb a,
.breadcrumb span {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: 999px;
  color: #a7f3d0;
  background: rgba(16, 185, 129, 0.13);
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 750;
}

.hero-content h1 {
  margin: 0 0 18px;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-content p {
  margin: 0 0 26px;
  color: #cbd5e1;
  font-size: clamp(16px, 2vw, 22px);
  max-width: 60ch;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  color: #cbd5e1;
  margin-bottom: 30px;
  font-weight: 650;
}

.hero-actions,
.section-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 13px;
  border: 1px solid var(--line);
  color: #ffffff;
  background: rgba(15, 23, 42, 0.78);
  font-weight: 850;
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.btn.primary {
  border-color: rgba(16, 185, 129, 0.62);
  background: linear-gradient(135deg, #10b981, #059669);
  box-shadow: 0 18px 36px rgba(16, 185, 129, 0.24);
}

.btn:hover {
  transform: translateY(-2px) scale(1.02);
  border-color: rgba(16, 185, 129, 0.5);
  background: rgba(16, 185, 129, 0.2);
}

.hero-arrow {
  position: absolute;
  z-index: 4;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.46);
  backdrop-filter: blur(10px);
  font-size: 28px;
}

.hero-arrow:hover {
  background: rgba(16, 185, 129, 0.78);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

.hero-dots {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 32px;
  display: flex;
  gap: 9px;
  transform: translateX(-50%);
}

.hero-dots button {
  width: 11px;
  height: 11px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.is-active {
  width: 34px;
  background: var(--accent);
}

.section {
  padding: 70px 0;
}

.section.alt {
  border: 1px solid var(--line);
  border-radius: 34px;
  background: rgba(15, 23, 42, 0.42);
  box-shadow: var(--shadow);
}

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

.section-kicker {
  margin: 0 0 8px;
  color: var(--accent);
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-head h2,
.page-hero h1,
.detail-title h1 {
  margin: 0;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.section-head p,
.page-hero p {
  margin: 10px 0 0;
  color: var(--muted);
  max-width: 760px;
}

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

.category-tile {
  position: relative;
  min-height: 168px;
  overflow: hidden;
  border-radius: 24px;
  padding: 26px;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, filter 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-6px) scale(1.015);
  filter: brightness(1.08);
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: auto -30px -46px auto;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.category-tile strong {
  position: relative;
  z-index: 1;
  display: block;
  font-size: 28px;
  line-height: 1.1;
  margin-bottom: 14px;
}

.category-tile span {
  position: relative;
  z-index: 1;
  color: rgba(255, 255, 255, 0.82);
}

.tile-emerald { background: linear-gradient(135deg, #059669, #064e3b); }
.tile-amber { background: linear-gradient(135deg, #d97706, #78350f); }
.tile-purple { background: linear-gradient(135deg, #7c3aed, #3b0764); }
.tile-blue { background: linear-gradient(135deg, #2563eb, #1e3a8a); }
.tile-red { background: linear-gradient(135deg, #dc2626, #7f1d1d); }
.tile-pink { background: linear-gradient(135deg, #db2777, #831843); }
.tile-cyan { background: linear-gradient(135deg, #0891b2, #164e63); }
.tile-indigo { background: linear-gradient(135deg, #4f46e5, #312e81); }

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--bg-card);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.22);
  transition: transform 0.26s ease, box-shadow 0.26s ease, border-color 0.26s ease;
}

.movie-card:hover {
  transform: translateY(-7px);
  border-color: rgba(16, 185, 129, 0.44);
  box-shadow: 0 22px 52px rgba(0, 0, 0, 0.36);
}

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

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.16), transparent);
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.play-hover {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 60px;
  height: 60px;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%) scale(0.8);
  border-radius: 50%;
  color: #ffffff;
  background: rgba(16, 185, 129, 0.92);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.badge {
  position: absolute;
  top: 12px;
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  border-radius: 8px;
  padding: 3px 8px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 850;
  backdrop-filter: blur(10px);
}

.badge-time {
  left: 12px;
  background: rgba(0, 0, 0, 0.58);
}

.badge-rate {
  right: 12px;
  background: rgba(245, 158, 11, 0.92);
}

.card-body {
  display: block;
  padding: 15px;
}

.card-body strong {
  display: -webkit-box;
  min-height: 56px;
  margin-bottom: 10px;
  overflow: hidden;
  color: #ffffff;
  font-size: 17px;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  transition: color 0.25s ease;
}

.movie-card:hover .card-body strong {
  color: #34d399;
}

.card-tags,
.info-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.card-tags span {
  padding: 4px 8px;
  border-color: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
  background: rgba(51, 65, 85, 0.82);
  font-size: 12px;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
}

.card-meta em,
.rank-item em,
.detail-meta em {
  font-style: normal;
}

.page-hero {
  padding: 72px 0 36px;
}

.page-hero-inner {
  border: 1px solid var(--line);
  border-radius: 34px;
  padding: clamp(30px, 5vw, 56px);
  background:
    radial-gradient(circle at top right, rgba(16, 185, 129, 0.24), transparent 28rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.86), rgba(2, 6, 23, 0.72));
  box-shadow: var(--shadow);
}

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

.channel-block {
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 22px;
  background: rgba(15, 23, 42, 0.5);
}

.channel-block h2 {
  margin: 0 0 8px;
  font-size: 24px;
}

.channel-block p {
  margin: 0 0 18px;
  color: var(--muted);
}

.filter-panel {
  margin: 0 0 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 18px;
  background: rgba(15, 23, 42, 0.64);
}

.filter-row {
  display: grid;
  grid-template-columns: 2fr repeat(4, 1fr);
  gap: 14px;
}

.filter-panel label {
  display: grid;
  gap: 6px;
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 800;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 45px;
  border: 1px solid var(--line);
  border-radius: 13px;
  outline: 0;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.58);
  padding: 0 13px;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(16, 185, 129, 0.62);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.12);
}

.filter-status {
  margin-top: 12px;
  color: #a7f3d0;
  font-weight: 750;
}

.rank-layout {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
}

.rank-panel {
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 18px;
  background: rgba(15, 23, 42, 0.58);
}

.rank-panel h2,
.content-card h2,
.sidebar-card h2,
.related-section h2 {
  margin: 0 0 18px;
  font-size: 24px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: auto 90px 1fr auto;
  align-items: center;
  gap: 14px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 16px;
  padding: 10px;
  background: rgba(2, 6, 23, 0.35);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.rank-item:hover {
  transform: translateX(4px);
  border-color: rgba(16, 185, 129, 0.42);
  background: rgba(16, 185, 129, 0.08);
}

.rank-item img {
  width: 90px;
  height: 58px;
  object-fit: cover;
  border-radius: 10px;
}

.rank-item strong {
  display: block;
  margin-bottom: 4px;
  color: #ffffff;
}

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

.rank-item b {
  color: #fbbf24;
}

.rank-num {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #dc2626);
  font-weight: 900;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}

.breadcrumb a,
.breadcrumb span {
  color: #cbd5e1;
  border-color: rgba(148, 163, 184, 0.18);
  background: rgba(15, 23, 42, 0.62);
}

.breadcrumb a:hover {
  color: #a7f3d0;
  border-color: rgba(16, 185, 129, 0.4);
}

.detail-page {
  padding: 36px 0 70px;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
}

.player-shell {
  overflow: hidden;
  border: 1px solid rgba(16, 185, 129, 0.22);
  border-radius: 28px;
  background: #000000;
  box-shadow: var(--shadow);
}

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

.site-player video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000000;
}

.player-start {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background:
    radial-gradient(circle, rgba(16, 185, 129, 0.24), transparent 22rem),
    linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.28));
}

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

.player-start span {
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 24px 54px rgba(16, 185, 129, 0.32);
  font-size: 34px;
}

.player-start strong {
  display: block;
  margin-top: 18px;
  font-size: clamp(22px, 3vw, 34px);
}

.player-start em {
  display: block;
  margin-top: 4px;
  color: #a7f3d0;
  font-style: normal;
  font-weight: 900;
}

.detail-title {
  margin: 28px 0 20px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 16px;
  color: #cbd5e1;
  font-weight: 700;
}

.info-tags {
  margin: 20px 0 0;
}

.info-tags span {
  color: #cbd5e1;
  border-color: rgba(148, 163, 184, 0.16);
  background: rgba(51, 65, 85, 0.62);
}

.content-card,
.sidebar-card,
.related-section {
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 24px;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.18);
}

.content-card {
  margin-top: 20px;
}

.content-card p {
  margin: 0;
  color: #cbd5e1;
  font-size: 17px;
}

.sidebar {
  display: grid;
  align-content: start;
  gap: 18px;
}

.sidebar-card dl {
  display: grid;
  gap: 12px;
  margin: 0;
}

.sidebar-card div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  padding-bottom: 12px;
}

.sidebar-card div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.sidebar-card dt {
  color: var(--muted);
}

.sidebar-card dd {
  margin: 0;
  color: #ffffff;
  font-weight: 850;
  text-align: right;
}

.related-section {
  margin-top: 32px;
}

.detail-actions button {
  border: 1px solid var(--line);
}

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

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

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

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  padding: 38px 0;
}

.site-footer p {
  max-width: 560px;
  margin: 12px 0 0;
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-content: flex-start;
  justify-content: flex-end;
}

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
}

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

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

  .detail-grid,
  .rank-layout,
  .channel-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .header-inner {
    min-height: 64px;
  }

  .desktop-nav {
    display: none;
  }

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

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

  .hero-slider {
    min-height: 78vh;
  }

  .hero-content {
    top: 53%;
  }

  .hero-arrow {
    display: none;
  }

  .hero-actions,
  .section-actions,
  .detail-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .section {
    padding: 44px 0;
  }

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

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

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

  .rank-item {
    grid-template-columns: auto 74px 1fr;
  }

  .rank-item b {
    grid-column: 3;
  }

  .rank-item img {
    width: 74px;
    height: 52px;
  }

  .footer-inner {
    flex-direction: column;
  }

  .footer-links {
    justify-content: flex-start;
  }
}
