
:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.86);
  --panel-soft: rgba(30, 41, 59, 0.58);
  --line: rgba(148, 163, 184, 0.16);
  --text: #f8fafc;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --accent: #10b981;
  --accent-soft: rgba(16, 185, 129, 0.18);
  --accent-strong: #059669;
  --radius: 18px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.36);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 10% 0%, rgba(16, 185, 129, 0.14), transparent 32rem),
    radial-gradient(circle at 90% 8%, rgba(59, 130, 246, 0.12), transparent 34rem),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.top-nav {
  width: min(1180px, calc(100% - 32px));
  height: 64px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--accent-soft);
  color: #34d399;
  box-shadow: inset 0 0 0 1px rgba(52, 211, 153, 0.24);
  font-size: 13px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  color: #cbd5e1;
  font-size: 15px;
}

.nav-links a,
.mobile-nav a {
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active,
.mobile-nav a:hover,
.mobile-nav a.active {
  color: #ffffff;
}

.nav-categories {
  display: flex;
  gap: 18px;
  padding-left: 18px;
  border-left: 1px solid var(--line);
}

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
  color: #cbd5e1;
  font-size: 24px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--line);
  padding: 14px 20px 18px;
  background: #0f172a;
}

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

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

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

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.72) 45%, rgba(2, 6, 23, 0.24) 100%),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.1) 38%, rgba(2, 6, 23, 0.72) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding-top: 150px;
  max-width: 1180px;
}

.hero-content h1 {
  max-width: 760px;
  margin: 16px 0 18px;
  font-size: clamp(42px, 7vw, 74px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-content p {
  width: min(640px, 100%);
  color: #cbd5e1;
  font-size: 19px;
  line-height: 1.8;
  margin: 0 0 24px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 13px;
  color: #6ee7b7;
  background: var(--accent-soft);
  border: 1px solid rgba(52, 211, 153, 0.2);
  font-size: 14px;
  font-weight: 700;
}

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

.hero-tags {
  margin-bottom: 28px;
}

.hero-tags span,
.detail-meta span,
.detail-tags span,
.tag-row span,
.movie-card-meta span,
.pill-link {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--line);
  color: #cbd5e1;
  font-size: 12px;
}

.pill-link {
  color: #6ee7b7;
  background: var(--accent-soft);
  border-color: rgba(52, 211, 153, 0.2);
}

.primary-button,
.section-actions a,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  min-height: 46px;
  padding: 0 22px;
  font-weight: 800;
  box-shadow: 0 14px 36px rgba(16, 185, 129, 0.26);
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.primary-button:hover,
.section-actions a:hover {
  transform: translateY(-2px);
  background: var(--accent-strong);
}

.text-link {
  min-height: 34px;
  padding: 0;
  background: transparent;
  color: #34d399;
  box-shadow: none;
}

.text-link:hover {
  color: #6ee7b7;
}

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

.hero-controls button {
  width: 38px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  cursor: pointer;
}

.hero-controls button.active {
  background: #34d399;
}

main {
  width: 100%;
}

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

.search-panel {
  width: min(1180px, calc(100% - 32px));
  margin: -40px auto 64px;
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr minmax(280px, 440px);
  gap: 24px;
  align-items: center;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.search-panel h2 {
  margin: 0 0 8px;
  font-size: 26px;
}

.search-panel p {
  margin: 0;
  color: var(--muted);
}

.slim-panel {
  width: 100%;
  margin: 0 0 42px;
  grid-template-columns: minmax(260px, 1fr) auto;
}

.sticky-filter {
  position: sticky;
  top: 78px;
  z-index: 20;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 0 16px;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.18);
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #fff;
}

.search-box input::placeholder {
  color: var(--muted-2);
}

.filter-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.filter-chips button {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.38);
  color: #cbd5e1;
  padding: 8px 12px;
  cursor: pointer;
}

.filter-chips button.active {
  background: var(--accent-soft);
  color: #6ee7b7;
  border-color: rgba(52, 211, 153, 0.26);
}

.content-section,
.editor-rank-layout,
.category-grid,
.rank-page-list,
.detail-content,
.player-section {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 76px;
}

.inner-page .content-section,
.inner-page .category-grid,
.inner-page .rank-page-list,
.inner-page .detail-content,
.inner-page .player-section {
  width: 100%;
}

.section-heading {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 24px;
}

.section-heading > span {
  width: 5px;
  min-height: 34px;
  border-radius: 999px;
  background: var(--accent);
  margin-top: 4px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(24px, 4vw, 34px);
  line-height: 1.12;
}

.section-heading p {
  color: var(--muted);
  margin: 8px 0 0;
  line-height: 1.7;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--line);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.2);
  transition: transform 0.24s ease, border-color 0.24s ease, background 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(52, 211, 153, 0.28);
  background: rgba(30, 41, 59, 0.74);
}

.poster-link,
.poster-frame {
  display: block;
  position: relative;
  overflow: hidden;
}

.poster-frame {
  aspect-ratio: 2 / 3;
  background: #0f172a;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.88), transparent 54%);
  opacity: 0;
  transition: opacity 0.24s ease;
}

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

.play-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%) scale(0.72);
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.92);
  color: #fff;
  opacity: 0;
  transition: opacity 0.24s ease, transform 0.24s ease;
}

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

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

.movie-card h3 {
  margin: 12px 0 8px;
  font-size: 18px;
  line-height: 1.28;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card h3 a:hover {
  color: #34d399;
}

.movie-card p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card-meta {
  justify-content: space-between;
}

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

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

.editor-box,
.rank-box,
.detail-content article,
.player-section,
.category-card,
.rank-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
}

.editor-box,
.rank-box,
.detail-content article,
.player-section {
  padding: 24px;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border-radius: 16px;
  background: rgba(30, 41, 59, 0.46);
  border: 1px solid transparent;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.compact-card:hover {
  background: rgba(30, 41, 59, 0.82);
  border-color: rgba(52, 211, 153, 0.22);
}

.compact-card img {
  width: 112px;
  height: 88px;
  border-radius: 12px;
  object-fit: cover;
}

.compact-card strong,
.compact-card em {
  display: block;
}

.compact-card strong {
  margin-bottom: 8px;
}

.compact-card em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border-radius: 14px;
  background: rgba(2, 6, 23, 0.38);
}

.rank-item:hover span {
  color: #34d399;
}

.rank-item strong {
  color: #34d399;
}

.rank-item em {
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
}

.section-actions {
  margin-top: 24px;
  text-align: center;
}

.page-hero {
  min-height: 280px;
  margin-bottom: 42px;
  padding: 52px;
  border-radius: 28px;
  background:
    radial-gradient(circle at 84% 16%, rgba(16, 185, 129, 0.24), transparent 24rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.64));
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.compact-hero {
  min-height: 220px;
}

.page-hero h1 {
  margin: 12px 0 16px;
  font-size: clamp(36px, 6vw, 60px);
  line-height: 1;
  letter-spacing: -0.05em;
}

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

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

.category-card {
  overflow: hidden;
}

.category-cover {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 140px;
  overflow: hidden;
}

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

.category-card div {
  padding: 22px;
}

.category-card h2 {
  margin: 0 0 10px;
}

.category-card p {
  color: var(--muted);
  line-height: 1.7;
}

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

.rank-card {
  display: grid;
  grid-template-columns: 110px 60px 1fr;
  gap: 22px;
  align-items: center;
  padding: 16px;
}

.rank-cover img {
  width: 110px;
  height: 146px;
  object-fit: cover;
  border-radius: 14px;
}

.rank-card > strong {
  color: #34d399;
  font-size: 26px;
  text-align: center;
}

.rank-card h2 {
  margin: 0 0 10px;
}

.rank-card h2 a:hover {
  color: #34d399;
}

.rank-card p {
  color: var(--muted);
  line-height: 1.7;
  margin: 0 0 12px;
}

.rank-card span {
  color: #cbd5e1;
}

.detail-page {
  width: 100%;
  padding-top: 64px;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  min-height: 620px;
  background-image: var(--detail-bg);
  background-size: cover;
  background-position: center;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.76) 55%, rgba(2, 6, 23, 0.3) 100%),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.08) 40%, rgba(2, 6, 23, 0.88) 100%);
  backdrop-filter: blur(6px);
}

.detail-layout {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 86px 0 70px;
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
}

.detail-poster {
  width: 310px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  margin-bottom: 18px;
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #34d399;
}

.detail-info h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 70px);
  line-height: 1;
  letter-spacing: -0.06em;
}

.detail-one-line {
  max-width: 780px;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.82;
  margin: 0 0 22px;
}

.detail-meta,
.detail-tags {
  margin-bottom: 18px;
}

.player-section {
  margin-top: -40px;
  position: relative;
  z-index: 3;
}

.player-section h2 {
  margin: 0 0 18px;
}

.player-box {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.player-video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.play-layer {
  position: absolute;
  inset: 0;
  border: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.76), rgba(2, 6, 23, 0.22));
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.play-layer span {
  width: 86px;
  height: 86px;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.95);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  box-shadow: 0 20px 50px rgba(16, 185, 129, 0.34);
}

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

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.detail-content h2 {
  margin: 0 0 14px;
}

.detail-content p {
  margin: 0;
  color: #cbd5e1;
  line-height: 1.9;
}

.filter-card.is-hidden {
  display: none;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.72);
  margin-top: 80px;
}

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

.footer-brand p,
.site-footer li,
.copyright {
  color: var(--muted);
  line-height: 1.7;
}

.site-footer h2 {
  margin: 0 0 16px;
  font-size: 16px;
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 9px;
}

.site-footer a:hover {
  color: #34d399;
}

.copyright {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 30px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 14px;
}

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

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

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

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

  .menu-toggle {
    display: block;
  }

  .hero-slider {
    min-height: 620px;
  }

  .hero-content {
    padding-top: 132px;
  }

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

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

  .filter-chips {
    justify-content: flex-start;
  }

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

  .rank-card {
    grid-template-columns: 88px 44px 1fr;
    gap: 14px;
  }

  .rank-cover img {
    width: 88px;
    height: 118px;
  }

  .detail-layout {
    grid-template-columns: 1fr;
    padding-top: 56px;
  }

  .detail-poster {
    width: min(300px, 78vw);
  }
}

@media (max-width: 560px) {
  .top-nav,
  .inner-page,
  .content-section,
  .editor-rank-layout,
  .category-grid,
  .rank-page-list,
  .detail-content,
  .player-section,
  .footer-grid,
  .copyright,
  .detail-layout {
    width: min(100% - 24px, 1180px);
  }

  .hero-content {
    width: min(100% - 24px, 1180px);
    padding-top: 124px;
  }

  .hero-content h1,
  .detail-info h1,
  .page-hero h1 {
    letter-spacing: -0.04em;
  }

  .movie-grid,
  .small-grid {
    gap: 14px;
  }

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

  .movie-card h3 {
    font-size: 16px;
  }

  .movie-card p {
    -webkit-line-clamp: 2;
  }

  .page-hero {
    padding: 30px 22px;
    border-radius: 22px;
  }

  .rank-card {
    grid-template-columns: 82px 1fr;
  }

  .rank-card > strong {
    display: none;
  }

  .category-cover {
    grid-template-columns: repeat(2, 1fr);
    height: 180px;
  }

  .category-cover img {
    height: 90px;
  }

  .compact-card {
    grid-template-columns: 86px 1fr;
  }

  .compact-card img {
    width: 86px;
    height: 76px;
  }
}
