:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --bg-card: #111827;
  --bg-glass: rgba(15, 23, 42, 0.78);
  --text: #e5e7eb;
  --muted: #94a3b8;
  --line: rgba(148, 163, 184, 0.2);
  --teal: #14b8a6;
  --teal-light: #5eead4;
  --amber: #f59e0b;
  --rose: #fb7185;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(20, 184, 166, 0.17), transparent 34rem),
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.13), transparent 28rem),
    var(--bg);
  color: var(--text);
  line-height: 1.65;
}

body.nav-open {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

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

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--teal), var(--amber));
  color: #04111d;
  box-shadow: 0 16px 36px rgba(20, 184, 166, 0.25);
}

.brand-copy {
  display: grid;
  line-height: 1.2;
}

.brand-copy strong {
  color: #ffffff;
  font-size: 1.22rem;
  letter-spacing: 0.02em;
}

.brand-copy em {
  color: var(--muted);
  font-size: 0.76rem;
  font-style: normal;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

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

.nav-link:hover,
.nav-link.active {
  color: #ffffff;
  background: rgba(20, 184, 166, 0.16);
}

.site-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(310px, 26vw);
}

.site-search input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.82);
  color: var(--text);
  outline: none;
  padding: 11px 15px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.site-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: rgba(94, 234, 212, 0.85);
  box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.14);
  background: rgba(15, 23, 42, 0.96);
}

.site-search button,
.primary-btn,
.ghost-btn,
.play-now {
  border: 0;
  border-radius: 999px;
  padding: 11px 18px;
  background: linear-gradient(135deg, var(--teal), var(--teal-light));
  color: #04201d;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 18px 34px rgba(20, 184, 166, 0.24);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.site-search button:hover,
.primary-btn:hover,
.play-now:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 42px rgba(20, 184, 166, 0.34);
}

.ghost-btn {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: none;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.84);
  color: #ffffff;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: #ffffff;
  border-radius: 99px;
}

.nav-channels {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  gap: 10px;
  padding: 0 0 12px;
  overflow-x: auto;
}

.nav-channels a {
  flex: 0 0 auto;
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.9rem;
}

.nav-channels a:hover {
  color: #ffffff;
  border-color: rgba(94, 234, 212, 0.55);
}

main {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
}

.hero-carousel {
  position: relative;
  min-height: 72vh;
  margin: 28px auto 52px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: var(--radius-lg);
  background: #020617;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.72fr);
  align-items: stretch;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 0.7s ease;
  pointer-events: none;
}

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

.hero-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.22;
  filter: blur(4px) saturate(1.2);
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.74) 52%, rgba(2, 6, 23, 0.38) 100%),
    radial-gradient(circle at 18% 25%, rgba(20, 184, 166, 0.22), transparent 26rem);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  align-self: center;
  padding: clamp(34px, 6vw, 76px);
  max-width: 770px;
}

.hero-poster {
  position: relative;
  z-index: 2;
  align-self: center;
  justify-self: center;
  width: min(360px, 78%);
  aspect-ratio: 2 / 3;
  border-radius: 26px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.52);
  transform: rotate(2deg);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

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

.eyebrow {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 18px;
  padding: 7px 12px;
  border-radius: 999px;
  color: #99f6e4;
  background: rgba(20, 184, 166, 0.16);
  border: 1px solid rgba(94, 234, 212, 0.22);
  font-weight: 700;
}

.hero-content h1,
.hero-content h2,
.page-hero h1,
.detail-title h1 {
  margin: 0;
  color: #ffffff;
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero-content h1,
.hero-content h2 {
  font-size: clamp(2.6rem, 6vw, 5.4rem);
}

.hero-content p {
  max-width: 720px;
  margin: 22px 0 0;
  color: #cbd5e1;
  font-size: clamp(1rem, 2vw, 1.2rem);
}

.hero-meta,
.detail-meta,
.movie-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
}

.hero-meta {
  margin-top: 22px;
}

.hero-meta span,
.detail-meta span,
.movie-meta-row span,
.tag-row span,
.info-list span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
  color: #dbeafe;
  padding: 6px 10px;
  font-size: 0.86rem;
}

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

.hero-dots {
  position: absolute;
  z-index: 4;
  left: clamp(34px, 6vw, 76px);
  bottom: 28px;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--teal-light);
}

.section-block {
  margin: 44px 0;
}

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

.section-head h2,
.page-hero h1,
.detail-section h2 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1.15;
}

.section-head p,
.page-hero p,
.detail-section p,
.category-card p,
.movie-card p,
.footer-shell p {
  color: var(--muted);
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.17);
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.76);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.18);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(94, 234, 212, 0.45);
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.3);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.9);
}

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

.movie-card:hover .poster-wrap img {
  transform: scale(1.07);
  filter: saturate(1.15) contrast(1.05);
}

.rating-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #1c1300;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  font-weight: 900;
  font-size: 0.86rem;
}

.movie-card-body {
  padding: 15px;
}

.movie-card h3 {
  margin: 10px 0 8px;
  color: #ffffff;
  font-size: 1.04rem;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: var(--teal-light);
}

.movie-card p {
  display: -webkit-box;
  min-height: 3.2em;
  margin: 0 0 12px;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 0.92rem;
}

.movie-meta-row {
  color: var(--muted);
  font-size: 0.82rem;
}

.movie-meta-row span {
  padding: 4px 8px;
  color: #cbd5e1;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-row span {
  padding: 4px 8px;
  color: #99f6e4;
  background: rgba(20, 184, 166, 0.11);
}

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

.category-card {
  min-height: 190px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border: 1px solid rgba(148, 163, 184, 0.17);
  border-radius: var(--radius-md);
  background:
    linear-gradient(135deg, rgba(20, 184, 166, 0.13), rgba(245, 158, 11, 0.08)),
    rgba(15, 23, 42, 0.78);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.2);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  border-color: rgba(94, 234, 212, 0.45);
}

.category-card h3 {
  margin: 0;
  color: #ffffff;
  font-size: 1.34rem;
}

.category-card p {
  margin: 12px 0 18px;
}

.category-card span {
  color: var(--teal-light);
  font-weight: 800;
}

.rank-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
  gap: 22px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 48px 86px minmax(0, 1fr) 56px;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.72);
  transition: background 0.2s ease, transform 0.2s ease;
}

.rank-item:hover {
  background: rgba(20, 184, 166, 0.12);
  transform: translateX(5px);
}

.rank-number {
  color: var(--amber);
  font-size: 1.18rem;
  font-weight: 900;
}

.rank-item img {
  width: 86px;
  height: 56px;
  object-fit: cover;
  border-radius: 12px;
}

.rank-copy {
  min-width: 0;
  display: grid;
}

.rank-copy strong {
  overflow: hidden;
  color: #ffffff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-copy em {
  overflow: hidden;
  color: var(--muted);
  font-size: 0.86rem;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-score {
  justify-self: end;
  color: #1c1300;
  background: #fbbf24;
  padding: 5px 9px;
  border-radius: 999px;
  font-weight: 900;
}

.page-hero {
  margin: 34px 0 28px;
  padding: clamp(28px, 5vw, 54px);
  border: 1px solid rgba(148, 163, 184, 0.17);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(135deg, rgba(20, 184, 166, 0.16), rgba(2, 6, 23, 0.74)),
    rgba(15, 23, 42, 0.82);
  box-shadow: var(--shadow);
}

.page-hero p {
  max-width: 820px;
  margin: 14px 0 0;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
  margin: 28px 0 16px;
  color: var(--muted);
  font-size: 0.93rem;
}

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

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

.player-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: var(--radius-lg);
  background: #000000;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.player-card video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000000;
}

.play-layer {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  background:
    radial-gradient(circle, rgba(20, 184, 166, 0.22), transparent 12rem),
    rgba(2, 6, 23, 0.34);
  color: #ffffff;
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.play-layer span {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--teal), var(--amber));
  color: #04111d;
  font-size: 2.25rem;
  font-weight: 900;
  padding-left: 6px;
  box-shadow: 0 22px 60px rgba(20, 184, 166, 0.32);
}

.player-card.is-playing .play-layer {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-side {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.17);
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.75);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
}

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

.detail-title {
  margin: 24px 0;
}

.detail-title h1 {
  font-size: clamp(2rem, 4vw, 3.35rem);
}

.detail-title p {
  max-width: 920px;
  color: #cbd5e1;
  font-size: 1.08rem;
}

.info-list {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.info-list div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
  color: var(--muted);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  padding-bottom: 10px;
}

.info-list strong {
  color: #ffffff;
}

.detail-section {
  margin: 34px 0;
  padding: 26px;
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.64);
}

.detail-section p {
  margin: 13px 0 0;
  color: #cbd5e1;
}

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

.footer-shell {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-brand {
  color: #ffffff;
  font-size: 1.15rem;
}

.footer-shell p {
  max-width: 560px;
  margin: 10px 0 0;
}

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

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

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

[hidden] {
  display: none !important;
}

@media (max-width: 1080px) {
  .grid-cards,
  .channel-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .hero-slide {
    grid-template-columns: 1fr;
  }

  .hero-poster {
    display: none;
  }
}

@media (max-width: 820px) {
  .nav-shell {
    min-height: 66px;
  }

  .site-search {
    display: none;
  }

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

  .nav-menu {
    position: fixed;
    inset: 66px 16px auto 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.98);
    box-shadow: var(--shadow);
  }

  body.nav-open .nav-menu {
    display: flex;
  }

  .nav-link {
    padding: 13px 14px;
  }

  .hero-carousel {
    min-height: 620px;
    margin-top: 18px;
  }

  .hero-content {
    padding: 34px 24px 72px;
  }

  .hero-dots {
    left: 24px;
  }

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

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

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

@media (max-width: 520px) {
  main,
  .nav-shell,
  .nav-channels,
  .footer-shell {
    width: min(100% - 22px, 1240px);
  }

  .brand-copy em {
    display: none;
  }

  .hero-content h1,
  .hero-content h2 {
    font-size: 2.35rem;
  }

  .grid-cards,
  .channel-grid {
    grid-template-columns: 1fr;
  }

  .rank-item {
    grid-template-columns: 38px 68px minmax(0, 1fr);
  }

  .rank-score {
    display: none;
  }

  .rank-item img {
    width: 68px;
    height: 48px;
  }

  .detail-section {
    padding: 20px;
  }
}
