html {
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: #f8fafc;
  background:
    radial-gradient(circle at 20% 8%, rgba(8, 145, 178, 0.28), transparent 34rem),
    radial-gradient(circle at 82% 16%, rgba(234, 88, 12, 0.18), transparent 28rem),
    linear-gradient(135deg, #020617 0%, #0f172a 48%, #111827 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.5rem;
  padding: 0.85rem clamp(1rem, 4vw, 3rem);
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(2, 6, 23, 0.84);
  backdrop-filter: blur(20px);
}

.brand,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.brand-mark {
  display: grid;
  width: 2.45rem;
  height: 2.45rem;
  place-items: center;
  border-radius: 1rem;
  color: #fff;
  background: linear-gradient(135deg, #06b6d4, #f97316);
  box-shadow: 0 14px 40px rgba(6, 182, 212, 0.28);
}

.brand-text {
  font-size: 1.08rem;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-link {
  padding: 0.55rem 0.78rem;
  border-radius: 999px;
  color: #cbd5e1;
  font-size: 0.95rem;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
  background: rgba(8, 145, 178, 0.25);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 999px;
  padding: 0.5rem 0.9rem;
  color: #fff;
  background: rgba(15, 23, 42, 0.92);
  cursor: pointer;
}

main {
  overflow: hidden;
}

.hero {
  position: relative;
  padding: clamp(1rem, 3vw, 2rem) clamp(1rem, 4vw, 3rem) 2rem;
}

.hero-stage {
  position: relative;
  min-height: clamp(33rem, 72vh, 48rem);
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 2.2rem;
  background: #020617;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.36);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: end;
  padding: clamp(1.4rem, 5vw, 5rem);
  opacity: 0;
  transform: scale(1.02);
  pointer-events: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.45;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 75% 24%, rgba(34, 211, 238, 0.22), transparent 26rem),
    linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.68) 52%, rgba(2, 6, 23, 0.28)),
    linear-gradient(0deg, rgba(2, 6, 23, 0.96), transparent 62%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 54rem;
}

.eyebrow {
  margin: 0 0 0.65rem;
  color: #67e8f9;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(2.5rem, 6vw, 6rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-summary {
  max-width: 46rem;
  margin: 1.4rem 0 0;
  color: #dbeafe;
  font-size: clamp(1rem, 1.6vw, 1.3rem);
}

.hero-actions,
.detail-tags,
.filter-row,
.year-strip,
.tag-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.hero-actions {
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.75rem 1.1rem;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn.primary {
  color: #020617;
  background: linear-gradient(135deg, #67e8f9, #f97316);
  box-shadow: 0 18px 40px rgba(249, 115, 22, 0.22);
}

.btn.ghost,
.btn.text {
  border: 1px solid rgba(148, 163, 184, 0.24);
  color: #e2e8f0;
  background: rgba(15, 23, 42, 0.64);
}

.btn.text {
  background: transparent;
}

.hero-dots {
  position: absolute;
  right: clamp(1rem, 4vw, 3rem);
  bottom: clamp(1rem, 4vw, 3rem);
  z-index: 3;
  display: flex;
  gap: 0.5rem;
}

.hero-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.25);
  cursor: pointer;
}

.hero-dot.active {
  width: 2rem;
  background: #67e8f9;
}

.hero-mini-row {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.hero-mini {
  display: grid;
  grid-template-columns: 4.2rem 1fr;
  align-items: center;
  gap: 0.85rem;
  min-height: 5.2rem;
  padding: 0.55rem;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 1.2rem;
  background: rgba(15, 23, 42, 0.68);
}

.hero-mini img {
  height: 4.1rem;
  border-radius: 0.85rem;
  object-fit: cover;
}

.hero-mini span {
  color: #e2e8f0;
  font-weight: 700;
}

.section,
.page-hero,
.detail-hero {
  width: min(1440px, calc(100% - 2rem));
  margin: 0 auto;
  padding: clamp(2.5rem, 6vw, 5rem) 0;
}

.section-glow {
  position: relative;
}

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

.section-head.stacked {
  display: block;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1.1;
}

.section-head p:not(.eyebrow),
.page-hero p,
.category-copy p,
.footer-inner p {
  color: #cbd5e1;
}

.section-link {
  color: #67e8f9;
  font-weight: 800;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15.2rem, 1fr));
  gap: 1.1rem;
}

.featured-grid {
  grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr));
}

.small-grid,
.all-grid {
  grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr));
}

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 1.35rem;
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.78), rgba(15, 23, 42, 0.88));
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(103, 232, 249, 0.55);
  box-shadow: 0 26px 58px rgba(6, 182, 212, 0.16);
}

.poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(8, 145, 178, 0.24), rgba(249, 115, 22, 0.2));
}

.poster img,
.detail-poster img {
  height: 100%;
  object-fit: cover;
  transition: transform 0.28s ease;
}

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

.poster-badge {
  position: absolute;
  top: 0.7rem;
  right: 0.7rem;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  color: #020617;
  background: #67e8f9;
  font-size: 0.78rem;
  font-weight: 900;
}

.card-body {
  padding: 1rem;
}

.card-title {
  display: -webkit-box;
  min-height: 2.9rem;
  overflow: hidden;
  color: #fff;
  font-size: 1.08rem;
  font-weight: 850;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-title:hover {
  color: #67e8f9;
}

.card-meta,
.card-text {
  margin: 0.45rem 0 0;
  color: #94a3b8;
  font-size: 0.92rem;
}

.card-text {
  display: -webkit-box;
  min-height: 3.1rem;
  overflow: hidden;
  color: #cbd5e1;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tag-row {
  margin-top: 0.85rem;
}

.tag-row span,
.detail-tags span,
.detail-tags a,
.year-strip span {
  max-width: 100%;
  overflow: hidden;
  padding: 0.3rem 0.58rem;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  color: #bae6fd;
  background: rgba(15, 23, 42, 0.72);
  font-size: 0.78rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1rem;
}

.category-tile,
.article-card,
.category-block,
.search-panel,
.rank-list,
.rank-table {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 1.5rem;
  background: rgba(15, 23, 42, 0.68);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
}

.category-tile {
  display: block;
  min-height: 12rem;
  padding: 1.2rem;
  background:
    radial-gradient(circle at 100% 0%, rgba(249, 115, 22, 0.18), transparent 14rem),
    rgba(15, 23, 42, 0.7);
}

.category-tile span,
.category-tile strong,
.category-tile em {
  display: block;
}

.category-tile span {
  font-size: 1.25rem;
  font-weight: 850;
}

.category-tile strong {
  margin-top: 0.5rem;
  color: #67e8f9;
  font-size: 2.5rem;
  line-height: 1;
}

.category-tile p {
  color: #cbd5e1;
}

.category-tile em {
  color: #fb923c;
  font-style: normal;
  font-weight: 700;
}

.rank-list,
.rank-table {
  overflow: hidden;
}

.rank-item,
.rank-row {
  display: grid;
  grid-template-columns: 4rem 1fr auto;
  align-items: center;
  gap: 1rem;
  padding: 0.95rem 1rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.rank-row {
  grid-template-columns: 4.4rem minmax(12rem, 1.2fr) minmax(12rem, 2fr) auto;
}

.rank-item:last-child,
.rank-row:last-child {
  border-bottom: 0;
}

.rank-item:hover,
.rank-row:hover {
  background: rgba(8, 145, 178, 0.14);
}

.rank-num {
  color: #fb923c;
  font-size: 1.2rem;
  font-weight: 900;
}

.rank-main strong,
.rank-title {
  display: block;
  color: #fff;
  font-weight: 850;
}

.rank-main em,
.rank-meta {
  color: #94a3b8;
  font-style: normal;
  font-size: 0.92rem;
}

.rank-score {
  color: #67e8f9;
  font-weight: 900;
}

.page-hero,
.detail-hero {
  position: relative;
  padding-top: clamp(2rem, 5vw, 4rem);
}

.page-hero.slim {
  padding-bottom: 2rem;
}

.page-hero::before,
.detail-hero::before {
  content: "";
  position: absolute;
  inset: 0 auto auto 0;
  width: 38rem;
  height: 18rem;
  border-radius: 999px;
  background: rgba(8, 145, 178, 0.18);
  filter: blur(80px);
  pointer-events: none;
}

.breadcrumb {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
  color: #94a3b8;
  font-size: 0.92rem;
}

.breadcrumb a:hover {
  color: #67e8f9;
}

.search-panel {
  display: grid;
  gap: 0.9rem;
  margin-bottom: 1.2rem;
  padding: 1rem;
}

.search-input {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 1rem;
  padding: 0.9rem 1rem;
  color: #fff;
  background: rgba(2, 6, 23, 0.62);
  outline: none;
}

.search-input:focus {
  border-color: #67e8f9;
  box-shadow: 0 0 0 3px rgba(103, 232, 249, 0.12);
}

.filter-btn {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.72);
  cursor: pointer;
}

.filter-btn.active,
.filter-btn:hover {
  color: #020617;
  background: #67e8f9;
}

.empty-state {
  display: none;
  margin: 1rem 0 0;
  color: #fbbf24;
  font-weight: 800;
}

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

.categories-list {
  display: grid;
  gap: 1.2rem;
}

.category-block {
  display: grid;
  grid-template-columns: minmax(16rem, 0.75fr) minmax(0, 1.8fr);
  gap: 1.2rem;
  padding: 1rem;
}

.category-copy {
  padding: 1rem;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(13rem, 22rem) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
}

.detail-poster {
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 1.8rem;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.34);
}

.detail-copy {
  position: relative;
  z-index: 1;
}

.detail-copy h1 {
  max-width: 62rem;
}

.lead {
  max-width: 58rem;
  color: #dbeafe;
  font-size: clamp(1rem, 1.55vw, 1.28rem);
}

.player-section {
  padding-top: 0;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 1.6rem;
  background: #020617;
  box-shadow: 0 26px 76px rgba(0, 0, 0, 0.35);
}

.movie-video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #020617;
  cursor: pointer;
}

.player-start {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  color: #fff;
  background: radial-gradient(circle at center, rgba(8, 145, 178, 0.18), rgba(2, 6, 23, 0.46));
  cursor: pointer;
}

.player-start span {
  display: grid;
  width: clamp(4.2rem, 9vw, 6.5rem);
  height: clamp(4.2rem, 9vw, 6.5rem);
  place-items: center;
  border-radius: 999px;
  color: #020617;
  background: linear-gradient(135deg, #67e8f9, #f97316);
  font-size: clamp(1.7rem, 4vw, 2.6rem);
  box-shadow: 0 18px 48px rgba(6, 182, 212, 0.28);
}

.player-shell.is-playing .player-start {
  display: none;
}

.detail-text {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.2rem;
  padding-top: 0;
}

.article-card {
  padding: clamp(1.2rem, 2.6vw, 2rem);
}

.article-card h2 {
  margin: 0 0 0.8rem;
  font-size: 1.45rem;
}

.article-card p {
  margin: 0;
  color: #cbd5e1;
}

.site-footer {
  margin-top: 3rem;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(2, 6, 23, 0.68);
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(16rem, 1fr) minmax(16rem, 1.4fr);
  gap: 2rem;
  width: min(1440px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 2rem 0;
}

.footer-links {
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
  align-content: start;
}

.footer-links a {
  padding: 0.4rem 0.7rem;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  color: #cbd5e1;
}

.footer-links a:hover {
  color: #67e8f9;
  border-color: rgba(103, 232, 249, 0.5);
}

.hide-card {
  display: none !important;
}

@media (max-width: 1180px) {
  .hero-mini-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

@media (max-width: 820px) {
  .site-header {
    align-items: flex-start;
  }

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

  .main-nav {
    position: absolute;
    left: 1rem;
    right: 1rem;
    top: 4.7rem;
    display: none;
    justify-content: flex-start;
    padding: 0.85rem;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 1.2rem;
    background: rgba(2, 6, 23, 0.94);
  }

  .main-nav.open {
    display: flex;
  }

  .hero-stage {
    min-height: 36rem;
    border-radius: 1.4rem;
  }

  .hero-slide {
    padding: 1.3rem;
  }

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

  .hero-dots {
    left: 1.3rem;
    right: auto;
  }

  .hero-mini-row,
  .detail-layout,
  .detail-text,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .rank-row {
    grid-template-columns: 3.5rem 1fr;
  }

  .rank-row .rank-meta,
  .rank-row .rank-score {
    grid-column: 2;
  }
}

@media (max-width: 560px) {
  .section,
  .page-hero,
  .detail-hero {
    width: min(100% - 1rem, 1440px);
  }

  .hero {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

  .movie-grid,
  .featured-grid,
  .small-grid,
  .all-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
  }

  .card-body {
    padding: 0.75rem;
  }

  .card-title {
    min-height: 2.7rem;
    font-size: 0.96rem;
  }

  .card-text,
  .tag-row {
    display: none;
  }

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

  .rank-item {
    grid-template-columns: 3.3rem 1fr;
  }

  .rank-score {
    grid-column: 2;
  }
}
