:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --primary: #0284c7;
  --primary-dark: #0369a1;
  --accent: #f43f5e;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 46%, #f1f5f9 100%);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #0f172a;
  font-size: 20px;
  font-weight: 800;
  white-space: nowrap;
}

.brand-mark {
  display: inline-grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  box-shadow: 0 10px 24px rgba(14, 165, 233, 0.28);
  font-size: 15px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.nav-link {
  color: #475569;
  font-size: 15px;
  font-weight: 600;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary);
}

.quick-search {
  display: flex;
  align-items: center;
  width: 300px;
  padding: 4px;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  background: #f8fafc;
}

.quick-search input,
.hero-search input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 0;
  outline: 0;
  color: #0f172a;
  background: transparent;
}

.quick-search input {
  padding: 8px 12px;
  font-size: 14px;
}

.quick-search button,
.hero-search button,
.primary-btn,
.clear-filter {
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.22);
  cursor: pointer;
}

.quick-search button {
  padding: 8px 16px;
  white-space: nowrap;
}

.menu-toggle {
  display: none;
  border: 0;
  border-radius: 12px;
  background: #f1f5f9;
  color: #0f172a;
  width: 42px;
  height: 42px;
  font-size: 20px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
}

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

.mobile-panel a {
  padding: 12px 14px;
  border-radius: 14px;
  color: #475569;
  background: #f8fafc;
}

.hero {
  position: relative;
  height: 72vh;
  min-height: 560px;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #334155);
}

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

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

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(2, 6, 23, 0.58) 45%, rgba(2, 6, 23, 0.22) 100%), linear-gradient(0deg, rgba(2, 6, 23, 0.95) 0%, transparent 48%);
}

.hero-content {
  position: absolute;
  left: max(24px, calc((100vw - 1240px) / 2));
  bottom: 118px;
  width: min(720px, calc(100% - 48px));
  color: #ffffff;
}

.hero-badge,
.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(14, 165, 233, 0.92);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-badge {
  padding: 8px 13px;
  margin-bottom: 18px;
  backdrop-filter: blur(10px);
}

.eyebrow {
  padding: 6px 10px;
  margin-bottom: 10px;
  color: #0369a1;
  background: #e0f2fe;
}

.hero-content h1 {
  margin: 0 0 18px;
  font-size: clamp(42px, 6vw, 72px);
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -0.045em;
  text-shadow: 0 16px 36px rgba(0, 0, 0, 0.42);
}

.hero-content p {
  max-width: 700px;
  margin: 0 0 20px;
  color: #dbeafe;
  font-size: 19px;
  line-height: 1.8;
}

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

.hero-meta span,
.detail-meta span {
  padding: 8px 13px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  backdrop-filter: blur(10px);
}

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

.hero-tags {
  margin: 18px 0 26px;
}

.hero-tags span,
.detail-tags a,
.tag-row span {
  padding: 6px 10px;
  border-radius: 999px;
  color: #0369a1;
  background: #e0f2fe;
  font-size: 12px;
  font-weight: 700;
}

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

.primary-btn,
.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  font-weight: 800;
}

.secondary-btn {
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 5;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.52);
  font-size: 36px;
  cursor: pointer;
  transform: translateY(-50%);
}

.hero-control.prev {
  left: 22px;
}

.hero-control.next {
  right: 22px;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.active {
  width: 34px;
  background: #ffffff;
}

.hero-search {
  position: absolute;
  right: max(24px, calc((100vw - 1240px) / 2));
  bottom: 116px;
  display: flex;
  width: min(420px, calc(100% - 48px));
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(16px);
}

.hero-search input {
  padding: 0 18px;
  color: #ffffff;
}

.hero-search input::placeholder {
  color: #dbeafe;
}

.hero-search button {
  padding: 12px 22px;
  white-space: nowrap;
}

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

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

.section-block {
  padding: 66px 0 0;
}

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

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

.section-heading h2,
.section-heading h3,
.page-hero h1,
.detail-side h1 {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  letter-spacing: -0.035em;
}

.section-heading h2,
.page-hero h1 {
  font-size: clamp(30px, 4vw, 46px);
}

.section-heading h3 {
  font-size: 24px;
}

.section-heading a,
.channel-row a,
.tile-links a,
.breadcrumb a {
  color: var(--primary);
  font-weight: 800;
}

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

.movie-card {
  min-width: 0;
}

.movie-card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.07);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card-link:hover {
  border-color: #bae6fd;
  box-shadow: var(--shadow);
  transform: translateY(-4px);
}

.poster {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #cbd5e1, #f8fafc);
}

.poster.wide {
  aspect-ratio: 16 / 10;
  width: 220px;
  flex: 0 0 220px;
}

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

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

.poster::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, transparent 42%, rgba(2, 6, 23, 0.62));
  opacity: 0;
  transition: opacity 0.25s ease;
}

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

.type-pill,
.rank-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.66);
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.rank-badge {
  left: 10px;
  right: auto;
  background: linear-gradient(135deg, #f97316, #ef4444);
}

.play-ring {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(14, 165, 233, 0.92);
  box-shadow: 0 14px 30px rgba(14, 165, 233, 0.34);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.86);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.movie-info {
  padding: 14px;
}

.movie-info h3 {
  display: -webkit-box;
  min-height: 42px;
  margin: 0 0 9px;
  overflow: hidden;
  color: #0f172a;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.4;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-info p {
  display: -webkit-box;
  margin: 0 0 12px;
  overflow: hidden;
  color: #64748b;
  font-size: 14px;
  line-height: 1.7;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.meta-row {
  color: #64748b;
  font-size: 12px;
}

.meta-row span {
  max-width: 100%;
}

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

.movie-card.horizontal .movie-card-link {
  display: flex;
  align-items: stretch;
}

.movie-card.horizontal .movie-info {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 18px;
}

.movie-card.horizontal .movie-info h3 {
  min-height: auto;
  font-size: 18px;
  -webkit-line-clamp: 1;
}

.category-showcase {
  margin-top: 70px;
  padding: 42px;
  border: 1px solid #dbeafe;
  border-radius: 32px;
  background: linear-gradient(135deg, #eff6ff, #f8fafc);
}

.channel-row + .channel-row {
  margin-top: 42px;
}

.scroll-cards {
  display: grid;
  grid-auto-columns: minmax(180px, 1fr);
  grid-auto-flow: column;
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 12px;
}

.ranking-section {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 30px;
  align-items: start;
  padding-bottom: 20px;
}

.ranking-panel,
.latest-panel,
.page-hero,
.filter-panel,
.synopsis-card {
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.07);
}

.ranking-panel,
.latest-panel {
  padding: 28px;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 13px;
  border-radius: 16px;
  background: #f8fafc;
}

.rank-row:hover {
  background: #e0f2fe;
}

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

.rank-row strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-row em {
  color: #64748b;
  font-style: normal;
  font-size: 13px;
}

.latest-list,
.rank-card-list {
  display: grid;
  gap: 16px;
}

.page-hero {
  position: relative;
  overflow: hidden;
  padding: 44px;
}

.page-hero::before {
  position: absolute;
  right: -80px;
  top: -80px;
  width: 240px;
  height: 240px;
  border-radius: 999px;
  background: #bae6fd;
  content: "";
  opacity: 0.55;
}

.page-hero h1,
.page-hero p,
.page-hero .eyebrow {
  position: relative;
  z-index: 1;
}

.page-hero p {
  max-width: 760px;
  margin: 14px 0 0;
  color: #475569;
  line-height: 1.8;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 22px;
  color: #64748b;
  font-size: 14px;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 190px 190px auto;
  gap: 14px;
  align-items: end;
  margin: 28px 0;
  padding: 18px;
}

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

.filter-panel input,
.filter-panel select {
  height: 46px;
  padding: 0 14px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background: #f8fafc;
}

.clear-filter {
  height: 46px;
  padding: 0 20px;
  font-weight: 800;
}

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

.category-tile {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.07);
}

.category-tile > a {
  display: grid;
  grid-template-columns: 150px 1fr;
  min-height: 190px;
}

.category-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-tile > a > div {
  padding: 22px;
}

.category-tile h2 {
  margin: 0 0 10px;
  font-size: 24px;
  font-weight: 900;
}

.category-tile p {
  margin: 0;
  color: #64748b;
  line-height: 1.7;
}

.tile-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 22px 22px;
}

.tile-links a {
  padding: 7px 10px;
  border-radius: 999px;
  background: #f0f9ff;
  font-size: 12px;
}

.player-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.55fr);
  gap: 28px;
  align-items: stretch;
}

.player-module {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #020617;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.main-video,
.player-cover,
.player-cover img {
  width: 100%;
  height: 100%;
}

.main-video {
  display: block;
  background: #020617;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #020617;
}

.player-cover.hidden {
  display: none;
}

.player-cover img {
  object-fit: cover;
  opacity: 0.68;
}

.big-play {
  position: absolute;
  display: grid;
  width: 86px;
  height: 86px;
  place-items: center;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  box-shadow: 0 18px 44px rgba(14, 165, 233, 0.36);
  font-size: 28px;
}

.detail-side {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 32px;
  border: 1px solid #e2e8f0;
  border-radius: 30px;
  background: #ffffff;
  box-shadow: 0 12px 36px rgba(15, 23, 42, 0.07);
}

.detail-side h1 {
  font-size: clamp(32px, 4vw, 50px);
  line-height: 1.08;
}

.detail-side p {
  color: #475569;
  line-height: 1.8;
}

.detail-meta span {
  color: #0369a1;
  background: #e0f2fe;
}

.detail-tags {
  margin-top: 18px;
}

.detail-content {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.8fr;
  gap: 22px;
  margin-top: 32px;
}

.synopsis-card {
  padding: 28px;
}

.synopsis-card h2 {
  margin: 0 0 12px;
  font-size: 22px;
  font-weight: 900;
}

.synopsis-card p {
  margin: 0;
  color: #475569;
  line-height: 1.9;
}

.site-footer {
  margin-top: 80px;
  border-top: 1px solid #e2e8f0;
  background: linear-gradient(180deg, #ffffff, #f1f5f9);
}

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

.footer-main p {
  max-width: 620px;
  color: #64748b;
  line-height: 1.8;
}

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

.footer-links a {
  padding: 10px 13px;
  border-radius: 999px;
  color: #0369a1;
  background: #e0f2fe;
  font-weight: 800;
}

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 34px;
  border-top: 1px solid #e2e8f0;
  color: #64748b;
  font-size: 14px;
}

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

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

  .quick-search {
    margin-left: auto;
  }

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

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

  .ranking-section,
  .player-layout,
  .detail-content {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 760px) {
  .nav-shell {
    height: auto;
    min-height: 64px;
    gap: 12px;
    padding: 10px 0;
  }

  .brand span:last-child {
    font-size: 17px;
  }

  .quick-search {
    display: none;
  }

  .hero {
    height: auto;
    min-height: 680px;
  }

  .hero-content {
    left: 20px;
    bottom: 150px;
    width: calc(100% - 40px);
  }

  .hero-content h1 {
    font-size: 42px;
  }

  .hero-content p {
    font-size: 16px;
  }

  .hero-search {
    left: 20px;
    right: auto;
    bottom: 72px;
    width: calc(100% - 40px);
  }

  .hero-control {
    display: none;
  }

  .section-heading,
  .footer-shell {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .movie-card.horizontal .movie-card-link {
    display: block;
  }

  .poster.wide {
    width: 100%;
    aspect-ratio: 16 / 10;
  }

  .category-showcase,
  .page-hero,
  .filter-panel,
  .ranking-panel,
  .latest-panel,
  .detail-side,
  .synopsis-card {
    padding: 22px;
    border-radius: 22px;
  }

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

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

  .category-tile > a {
    grid-template-columns: 120px 1fr;
  }

  .rank-row {
    grid-template-columns: 36px 1fr;
  }

  .rank-row em {
    grid-column: 2;
  }

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