:root {
  color-scheme: dark;
  --bg: #030712;
  --panel: rgba(17, 24, 39, 0.82);
  --panel-strong: rgba(31, 41, 55, 0.92);
  --line: rgba(148, 163, 184, 0.16);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --blue: #3b82f6;
  --cyan: #22d3ee;
  --radius: 18px;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.18), transparent 34rem),
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.12), transparent 28rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(3, 7, 18, 0.82);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.header-inner {
  max-width: 1220px;
  height: 72px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: clamp(18px, 2.4vw, 25px);
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, #60a5fa, #22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.9), rgba(34, 211, 238, 0.8));
  color: #ffffff;
  font-size: 14px;
  box-shadow: 0 12px 34px rgba(37, 99, 235, 0.42);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  color: #cbd5e1;
  font-size: 14px;
  font-weight: 700;
}

.desktop-nav a,
.mobile-nav a {
  transition: color 0.22s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.mobile-nav a.active {
  color: #60a5fa;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(30, 41, 59, 0.86);
  color: white;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #e2e8f0;
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  padding: 0 22px 18px;
  border-top: 1px solid var(--line);
}

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

.hero {
  position: relative;
  height: min(760px, 100vh);
  min-height: 620px;
  overflow: hidden;
  background: #020617;
}

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

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(3, 7, 18, 0.92) 0%, rgba(3, 7, 18, 0.66) 38%, rgba(3, 7, 18, 0.22) 70%),
    linear-gradient(0deg, #030712 0%, rgba(3, 7, 18, 0.18) 42%, rgba(3, 7, 18, 0.62) 100%);
}

.hero-content {
  position: absolute;
  left: max(24px, calc((100vw - 1220px) / 2 + 22px));
  top: 50%;
  transform: translateY(-45%);
  width: min(680px, calc(100vw - 48px));
}

.hero-kicker,
.page-hero span {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(59, 130, 246, 0.32);
  background: rgba(59, 130, 246, 0.15);
  color: #93c5fd;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero p,
.page-hero p,
.detail-copy p {
  max-width: 720px;
  margin: 22px 0 0;
  color: #d1d5db;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.75;
}

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

.hero-tags {
  margin-top: 26px;
}

.tag-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border: 1px solid rgba(59, 130, 246, 0.24);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.58);
  color: #cbd5e1;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.primary-btn,
.ghost-btn,
.inline-filter button,
.search-form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  font-weight: 800;
  cursor: pointer;
}

.primary-btn,
.inline-filter button,
.search-form button {
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  color: #ffffff;
  box-shadow: 0 18px 44px rgba(37, 99, 235, 0.32);
}

.ghost-btn {
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(15, 23, 42, 0.55);
  color: #e5e7eb;
  backdrop-filter: blur(12px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 50px;
  height: 50px;
  border: 0;
  border-radius: 50%;
  background: rgba(2, 6, 23, 0.56);
  color: #ffffff;
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(10px);
  transition: background 0.22s ease, transform 0.22s ease;
}

.hero-arrow:hover {
  background: rgba(37, 99, 235, 0.72);
  transform: translateY(-2px);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dots button {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
  transition: width 0.22s ease, background 0.22s ease;
}

.hero-dots button.active {
  width: 34px;
  background: #3b82f6;
}

.search-band {
  max-width: 1220px;
  margin: -44px auto 0;
  position: relative;
  z-index: 8;
  padding: 22px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 520px);
  gap: 22px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.82);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.search-band strong {
  display: block;
  margin-bottom: 6px;
  font-size: 22px;
}

.search-band span,
.section-heading p,
.category-tile em,
.movie-card em,
.rank-info em,
.site-footer p,
.site-footer a,
.meta-panel dd,
.breadcrumb {
  color: var(--muted);
}

.search-form,
.inline-filter {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.search-form input,
.inline-filter input {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.72);
  color: var(--text);
  padding: 0 18px;
  outline: none;
}

.search-form input:focus,
.inline-filter input:focus {
  border-color: rgba(59, 130, 246, 0.7);
}

.page-main,
.detail-main {
  max-width: 1220px;
  margin: 0 auto;
  padding: 30px 22px 70px;
}

.content-section {
  max-width: 1220px;
  margin: 0 auto;
  padding: 74px 22px 0;
}

.page-main .content-section,
.detail-main .content-section {
  padding-left: 0;
  padding-right: 0;
}

.soft-panel {
  margin-top: 72px;
  padding-top: 48px;
  padding-bottom: 50px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.56), rgba(17, 24, 39, 0.14));
}

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

.section-heading span {
  color: #60a5fa;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.section-heading h2 {
  margin: 6px 0 0;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
}

.section-heading p {
  max-width: 680px;
  margin: 10px 0 0;
  line-height: 1.7;
}

.section-link {
  flex: 0 0 auto;
  color: #93c5fd;
  font-weight: 800;
}

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

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

.movie-card {
  display: block;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.25);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(59, 130, 246, 0.45);
  background: rgba(30, 41, 59, 0.9);
}

.poster-frame {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  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(0, 0, 0, 0.78), rgba(0, 0, 0, 0.04) 58%);
  opacity: 0;
  transition: opacity 0.25s 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;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.9);
  color: #ffffff;
  transform: translate(-50%, -50%) scale(0.72);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
  backdrop-filter: blur(8px);
}

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

.year-badge {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 5px 8px;
  border-radius: 8px;
  background: rgba(2, 6, 23, 0.78);
  color: #e5e7eb;
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(6px);
}

.card-body {
  display: block;
  padding: 16px;
}

.card-body strong {
  display: -webkit-box;
  min-height: 48px;
  overflow: hidden;
  color: #ffffff;
  font-size: 17px;
  line-height: 1.4;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  transition: color 0.22s ease;
}

.movie-card:hover .card-body strong {
  color: #60a5fa;
}

.card-body em {
  display: -webkit-box;
  min-height: 42px;
  margin: 8px 0 14px;
  overflow: hidden;
  font-size: 13px;
  font-style: normal;
  line-height: 1.6;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.compact-card .card-body strong {
  font-size: 15px;
}

.rail-scroll {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding: 4px 4px 14px;
  scrollbar-width: thin;
}

.rail-scroll .movie-card {
  width: 300px;
  flex: 0 0 300px;
}

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

.category-tile {
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  border-color: rgba(96, 165, 250, 0.48);
}

.tile-images {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 95px;
  overflow: hidden;
}

.tile-images img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
}

.tile-copy {
  display: block;
  padding: 18px;
}

.tile-copy strong {
  display: block;
  margin-bottom: 8px;
  font-size: 20px;
}

.tile-copy em {
  display: block;
  font-size: 13px;
  font-style: normal;
  line-height: 1.65;
}

.page-hero {
  position: relative;
  min-height: 300px;
  margin-top: 22px;
  padding: 52px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at 82% 18%, rgba(34, 211, 238, 0.18), transparent 24rem),
    linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.72));
  box-shadow: var(--shadow);
}

.page-hero h1 {
  font-size: clamp(38px, 6vw, 68px);
}

.inline-filter {
  max-width: 600px;
  margin-top: 30px;
}

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

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

.rank-row {
  display: grid;
  grid-template-columns: 42px 86px minmax(0, 1fr) 20px;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.72);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.rank-row:hover {
  transform: translateY(-3px);
  border-color: rgba(59, 130, 246, 0.42);
}

.rank-no {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.15);
  color: #93c5fd;
  font-weight: 900;
}

.rank-cover {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 12px;
  background: #111827;
}

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

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

.rank-info em {
  display: block;
  margin-top: 5px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  font-style: normal;
}

.rank-arrow {
  color: #60a5fa;
  font-size: 24px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 22px 0;
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #60a5fa;
}

.detail-hero {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at 20% 0%, rgba(59, 130, 246, 0.18), transparent 28rem),
    rgba(15, 23, 42, 0.76);
  box-shadow: var(--shadow);
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  aspect-ratio: 16 / 10;
  background: #111827;
}

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

.player-section {
  margin-top: 36px;
}

.player-box {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #000000;
  aspect-ratio: 16 / 9;
  box-shadow: var(--shadow);
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
  justify-content: center;
  border: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.22));
  color: #ffffff;
  cursor: pointer;
}

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

.play-circle {
  width: 88px;
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  font-size: 34px;
  box-shadow: 0 20px 50px rgba(37, 99, 235, 0.36);
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  margin-top: 36px;
}

.detail-article,
.meta-panel {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
  padding: 26px;
}

.detail-article h2,
.meta-panel h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

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

.meta-panel dl {
  margin: 0;
}

.meta-panel dt {
  margin-top: 16px;
  color: #e5e7eb;
  font-weight: 800;
}

.meta-panel dd {
  margin: 6px 0 0;
  line-height: 1.65;
}

.related-section {
  margin-top: 18px;
}

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

.footer-grid {
  max-width: 1220px;
  margin: 0 auto;
  padding: 46px 22px 30px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
}

.footer-brand {
  margin-bottom: 18px;
}

.site-footer p {
  max-width: 460px;
  line-height: 1.75;
}

.site-footer h3 {
  margin: 0 0 14px;
}

.site-footer a:not(.brand) {
  display: block;
  margin: 9px 0;
}

.site-footer a:hover {
  color: #60a5fa;
}

.copyright {
  max-width: 1220px;
  margin: 0 auto;
  padding: 18px 22px 28px;
  border-top: 1px solid var(--line);
  color: #64748b;
  font-size: 13px;
}

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

@media (max-width: 1080px) {
  .movie-grid,
  .four-grid,
  .category-grid,
  .ranking-list,
  .rank-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .detail-poster {
    max-width: 520px;
  }
}

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

  .menu-toggle {
    display: block;
  }

  .hero {
    min-height: 620px;
  }

  .hero-content {
    left: 22px;
    transform: translateY(-42%);
  }

  .hero-arrow {
    display: none;
  }

  .search-band,
  .search-form,
  .inline-filter,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .content-section,
  .page-main,
  .detail-main {
    padding-left: 16px;
    padding-right: 16px;
  }

  .movie-grid,
  .four-grid,
  .category-grid,
  .ranking-list,
  .rank-grid {
    grid-template-columns: 1fr;
  }

  .page-hero,
  .detail-hero,
  .detail-article,
  .meta-panel {
    padding: 24px;
    border-radius: 22px;
  }

  .rank-row {
    grid-template-columns: 34px 74px minmax(0, 1fr) 16px;
  }
}
