:root {
  --teal-900: #0f3f3d;
  --teal-800: #115e59;
  --teal-700: #0f766e;
  --teal-600: #0d9488;
  --cyan-600: #0891b2;
  --cyan-500: #06b6d4;
  --amber-500: #f59e0b;
  --amber-300: #fcd34d;
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --gray-950: #030712;
  --gray-900: #111827;
  --gray-700: #374151;
  --gray-600: #4b5563;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --white: #ffffff;
  --shadow-lg: 0 22px 45px rgba(15, 23, 42, 0.16);
  --shadow-md: 0 14px 30px rgba(15, 23, 42, 0.12);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--gray-900);
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 46%, #f8fafc 100%);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--teal-700), var(--cyan-600));
  box-shadow: 0 10px 28px rgba(8, 145, 178, 0.22);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  color: var(--teal-900);
  background: linear-gradient(135deg, var(--amber-300), var(--amber-500));
  border-radius: 999px;
  box-shadow: 0 10px 20px rgba(245, 158, 11, 0.28);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-size: 20px;
  letter-spacing: 0.04em;
}

.brand-text em {
  margin-top: 4px;
  font-size: 12px;
  color: #ccfbf1;
  font-style: normal;
}

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

.nav-link {
  font-weight: 650;
  transition: color 0.25s ease;
}

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

.nav-search {
  display: flex;
  align-items: center;
}

.nav-search input,
.mobile-search input {
  width: 220px;
  border: 0;
  outline: 0;
  color: var(--white);
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px 0 0 999px;
  padding: 10px 14px;
  backdrop-filter: blur(8px);
}

.nav-search input::placeholder,
.mobile-search input::placeholder {
  color: #ccfbf1;
}

.nav-search button,
.mobile-search button {
  border: 0;
  color: var(--gray-950);
  background: var(--amber-500);
  padding: 10px 14px;
  border-radius: 0 999px 999px 0;
  cursor: pointer;
  font-weight: 800;
  transition: background 0.25s ease;
}

.nav-search button:hover,
.mobile-search button:hover {
  background: var(--amber-300);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: var(--white);
  background: rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  padding: 8px 11px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
}

.mobile-nav.open {
  display: grid;
  gap: 10px;
}

.mobile-link {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.12);
  font-weight: 700;
}

.mobile-link.active {
  color: var(--amber-300);
}

.mobile-search {
  display: flex;
}

.mobile-search input {
  width: 100%;
}

.hero {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  color: var(--white);
  background: var(--slate-950);
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(180deg, rgba(3, 7, 18, 0.2), rgba(3, 7, 18, 0.82)), var(--hero-bg);
  background-position: center;
  background-size: cover;
  transform: scale(1.02);
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 72% 30%, rgba(6, 182, 212, 0.35), transparent 34%), linear-gradient(90deg, rgba(2, 6, 23, 0.78), rgba(2, 6, 23, 0.35), rgba(2, 6, 23, 0.76));
}

.hero-content {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  min-height: 72vh;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) 360px;
  gap: 42px;
  align-items: end;
  padding: 100px 0 72px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  padding: 8px 14px;
  color: var(--amber-300);
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  backdrop-filter: blur(8px);
  font-weight: 800;
}

.hero h1,
.hero h2 {
  max-width: 760px;
  margin: 20px 0 14px;
  font-size: clamp(38px, 6vw, 74px);
  line-height: 0.98;
  letter-spacing: -0.04em;
}

.hero-desc {
  max-width: 680px;
  color: #e5e7eb;
  font-size: 18px;
  line-height: 1.85;
}

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

.btn-primary,
.btn-secondary,
.btn-light {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 850;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.btn-primary {
  color: var(--slate-950);
  background: linear-gradient(135deg, var(--amber-300), var(--amber-500));
  box-shadow: 0 18px 34px rgba(245, 158, 11, 0.25);
}

.btn-secondary {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(10px);
}

.btn-light {
  color: var(--teal-900);
  background: var(--white);
}

.btn-primary:hover,
.btn-secondary:hover,
.btn-light:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.hero-tags span,
.detail-tags span,
.meta-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  color: var(--teal-900);
  background: #ccfbf1;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 750;
}

.hero-poster {
  position: relative;
  border-radius: 26px;
  overflow: hidden;
  box-shadow: 0 34px 70px rgba(0, 0, 0, 0.38);
  transform: translateY(12px);
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.hero-poster::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(2, 6, 23, 0.82));
}

.hero-poster strong {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 22px;
  font-size: 22px;
}

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

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

.hero-dot.active {
  background: var(--amber-300);
}

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

.section {
  margin: 64px 0;
}

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

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 8px;
  font-size: clamp(26px, 3vw, 36px);
}

.section-title span {
  color: var(--amber-500);
}

.section-head p,
.lead {
  margin: 0;
  color: var(--gray-600);
  line-height: 1.8;
}

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

.category-tile {
  position: relative;
  overflow: hidden;
  padding: 26px;
  min-height: 148px;
  color: var(--white);
  background: linear-gradient(135deg, var(--teal-600), var(--cyan-600));
  border-radius: 24px;
  box-shadow: var(--shadow-md);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:nth-child(2n) {
  background: linear-gradient(135deg, #2563eb, var(--cyan-600));
}

.category-tile:nth-child(3n) {
  background: linear-gradient(135deg, #7c3aed, #db2777);
}

.category-tile:nth-child(4n) {
  background: linear-gradient(135deg, #f97316, #e11d48);
}

.category-tile:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.category-tile strong {
  display: block;
  font-size: 24px;
  margin-bottom: 10px;
}

.category-tile em {
  position: absolute;
  right: 18px;
  bottom: 10px;
  opacity: 0.25;
  font-size: 62px;
  font-style: normal;
}

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

.movie-card {
  overflow: hidden;
  background: var(--white);
  border-radius: 22px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.card-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--slate-900);
}

.card-cover img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 3;
  color: var(--slate-950);
  background: var(--amber-300);
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.22);
}

.play-chip {
  right: 12px;
  bottom: 12px;
  padding: 7px 12px;
  border-radius: 999px;
}

.rank-badge {
  top: 12px;
  left: 12px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
}

.card-body {
  padding: 16px;
}

.card-title {
  display: block;
  color: var(--gray-900);
  font-size: 18px;
  font-weight: 850;
  line-height: 1.35;
}

.card-title:hover {
  color: var(--teal-700);
}

.card-meta,
.card-tags {
  color: var(--gray-600);
  font-size: 13px;
}

.card-desc {
  display: -webkit-box;
  min-height: 44px;
  overflow: hidden;
  color: var(--gray-700);
  line-height: 1.55;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.rank-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  gap: 24px;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 42px 58px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 82px;
  padding: 12px;
  background: var(--white);
  border-radius: 18px;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.07);
}

.compact-card span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: var(--slate-950);
  background: var(--amber-300);
  border-radius: 12px;
  font-weight: 900;
}

.compact-card img {
  width: 58px;
  height: 58px;
  border-radius: 14px;
  object-fit: cover;
}

.compact-card strong {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.compact-card em {
  display: block;
  margin-top: 6px;
  color: var(--gray-600);
  font-size: 12px;
  font-style: normal;
}

.page-hero {
  color: var(--white);
  background: radial-gradient(circle at 20% 0%, rgba(6, 182, 212, 0.32), transparent 34%), linear-gradient(135deg, var(--slate-900), var(--teal-800));
  padding: 66px 0;
}

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

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 58px);
  letter-spacing: -0.03em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: #d1fae5;
  font-size: 18px;
  line-height: 1.8;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 180px;
  gap: 12px;
  margin: 28px 0;
  padding: 16px;
  background: var(--white);
  border-radius: 22px;
  box-shadow: var(--shadow-md);
}

.filter-bar input,
.filter-bar select,
.search-panel input,
.search-panel select {
  width: 100%;
  border: 1px solid var(--gray-200);
  outline: 0;
  border-radius: 14px;
  padding: 12px 14px;
  font: inherit;
}

.filter-empty {
  display: none;
  padding: 32px;
  color: var(--gray-600);
  text-align: center;
  background: var(--white);
  border-radius: 22px;
}

.filter-empty.show {
  display: block;
}

.detail-hero {
  position: relative;
  color: var(--white);
  background: var(--slate-950);
  overflow: hidden;
}

.detail-bg {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.62)), var(--detail-bg);
  background-position: center;
  background-size: cover;
  filter: blur(2px);
  transform: scale(1.03);
}

.detail-wrap {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 36px;
  align-items: end;
  padding: 64px 0;
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  box-shadow: 0 35px 70px rgba(0, 0, 0, 0.34);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: #ccfbf1;
  font-size: 14px;
}

.detail-info h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.03;
  letter-spacing: -0.04em;
}

.detail-meta {
  color: #d1fae5;
  font-weight: 700;
}

.detail-one-line {
  max-width: 780px;
  color: #e5e7eb;
  font-size: 18px;
  line-height: 1.75;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 20px 0 28px;
}

.content-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 56px auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 30px;
}

.content-card {
  background: var(--white);
  border-radius: 24px;
  padding: 28px;
  box-shadow: var(--shadow-md);
}

.content-card h2 {
  margin-top: 0;
  font-size: 28px;
}

.content-card p {
  color: var(--gray-700);
  line-height: 1.9;
  font-size: 16px;
}

.player-card {
  overflow: hidden;
  background: var(--slate-950);
  border-radius: 26px;
  box-shadow: var(--shadow-lg);
}

.video-frame {
  position: relative;
  background: #000;
}

.video-frame video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle, rgba(15, 23, 42, 0.12), rgba(2, 6, 23, 0.62));
  cursor: pointer;
  z-index: 3;
}

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

.player-button {
  border: 0;
  cursor: pointer;
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  color: var(--slate-950);
  background: linear-gradient(135deg, var(--amber-300), var(--amber-500));
  border-radius: 999px;
  box-shadow: 0 18px 40px rgba(245, 158, 11, 0.4);
  font-size: 34px;
  padding-left: 6px;
}

.player-caption {
  padding: 18px 22px;
  color: #d1fae5;
  background: linear-gradient(90deg, rgba(15, 118, 110, 0.4), rgba(8, 145, 178, 0.26));
}

.player-caption strong {
  display: block;
  color: var(--white);
  font-size: 20px;
  margin-bottom: 6px;
}

.side-card {
  position: sticky;
  top: 90px;
  align-self: start;
}

.meta-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.meta-list div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--gray-200);
}

.meta-list span {
  color: var(--gray-600);
}

.meta-list strong {
  text-align: right;
}

.meta-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

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

.search-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 160px 160px 160px;
  gap: 12px;
  margin: 30px 0;
  padding: 18px;
  background: var(--white);
  border-radius: 24px;
  box-shadow: var(--shadow-md);
}

.search-results {
  min-height: 320px;
}

.site-footer {
  margin-top: 80px;
  color: #cbd5e1;
  background: linear-gradient(180deg, var(--slate-800), var(--slate-950));
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 36px;
  padding: 50px 0 34px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--white);
  font-size: 20px;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 18px;
}

.site-footer p {
  line-height: 1.8;
}

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

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  font-size: 14px;
}

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

  .menu-toggle {
    display: inline-flex;
  }

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

  .hero-poster,
  .detail-poster {
    width: min(320px, 80vw);
  }

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

  .side-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .nav-shell {
    width: min(100% - 24px, 1180px);
    height: 62px;
  }

  .brand-text strong {
    font-size: 17px;
  }

  .hero,
  .hero-content {
    min-height: 82vh;
  }

  .hero-content {
    padding: 78px 0 70px;
    align-items: center;
  }

  .hero-poster {
    display: none;
  }

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

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

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

  .content-card {
    padding: 20px;
  }

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

@media (max-width: 480px) {
  .movie-grid,
  .category-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .card-cover img {
    aspect-ratio: 16 / 10;
  }

  .hero h1,
  .hero h2,
  .detail-info h1 {
    letter-spacing: -0.02em;
  }
}
