:root {
  --bg: #030712;
  --bg-soft: #0b1120;
  --panel: rgba(31, 41, 55, 0.42);
  --panel-strong: rgba(17, 24, 39, 0.86);
  --line: rgba(148, 163, 184, 0.14);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --subtle: #94a3b8;
  --faint: #64748b;
  --white: #ffffff;
  --accent: #e5e7eb;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
  --radius-lg: 28px;
  --radius: 18px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 18% 8%, rgba(148, 163, 184, 0.16), transparent 26rem),
    radial-gradient(circle at 84% 18%, rgba(75, 85, 99, 0.22), transparent 28rem),
    linear-gradient(180deg, #020617 0%, #030712 48%, #050816 100%);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

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

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

.nav-wrap {
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

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

.brand-mark {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: inline-grid;
  place-items: center;
  color: #111827;
  background: linear-gradient(135deg, #f8fafc, #94a3b8);
  box-shadow: 0 14px 36px rgba(148, 163, 184, 0.25);
  font-size: 15px;
  transform: rotate(-2deg);
}

.brand.compact .brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 12px;
}

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

.brand-text strong {
  font-weight: 300;
  letter-spacing: 0.08em;
  font-size: 21px;
}

.brand-text small {
  color: var(--faint);
  margin-top: 5px;
  font-size: 12px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  flex-wrap: wrap;
}

.desktop-nav a,
.mobile-nav a {
  color: var(--subtle);
  padding: 10px 13px;
  border-radius: 12px;
  transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
  font-size: 14px;
}

.desktop-nav a:hover,
.mobile-nav a:hover {
  color: var(--white);
  background: rgba(31, 41, 55, 0.72);
  transform: translateY(-1px);
}

.mobile-nav {
  display: none;
  gap: 8px;
  overflow-x: auto;
  padding: 0 16px 14px;
  scrollbar-width: none;
}

.mobile-nav::-webkit-scrollbar {
  display: none;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.8s ease, transform 0.8s ease;
  transform: scale(1.015);
}

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

.hero-slide > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.84) contrast(1.02);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, rgba(3, 7, 18, 1) 0%, rgba(3, 7, 18, 0.82) 38%, rgba(3, 7, 18, 0.22) 100%),
    linear-gradient(90deg, rgba(3, 7, 18, 0.82) 0%, rgba(3, 7, 18, 0.42) 48%, rgba(3, 7, 18, 0.06) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  padding-bottom: clamp(56px, 11vh, 112px);
}

.hero-copy {
  width: min(720px, 100%);
}

.hero-label,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--subtle);
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-label span {
  width: 24px;
  height: 1px;
  background: var(--subtle);
}

.hero-copy h1 {
  margin: 18px 0 18px;
  font-weight: 300;
  letter-spacing: -0.05em;
  line-height: 0.98;
  font-size: clamp(42px, 7.5vw, 86px);
}

.hero-copy p {
  margin: 0;
  color: var(--muted);
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.8;
  max-width: 680px;
}

.hero-tags,
.tag-list,
.detail-meta,
.filter-chips {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

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

.hero-tags span,
.tag-list span,
.detail-meta span,
.filter-chips button {
  color: var(--muted);
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(31, 41, 55, 0.58);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 13px;
  backdrop-filter: blur(10px);
}

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

.primary-btn,
.glass-btn,
.section-link,
.search-line button {
  border: 0;
  border-radius: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.primary-btn,
.search-line button {
  background: var(--white);
  color: #111827;
  font-weight: 650;
}

.glass-btn,
.section-link {
  color: var(--text);
  background: rgba(31, 41, 55, 0.56);
  border: 1px solid rgba(148, 163, 184, 0.18);
  backdrop-filter: blur(12px);
}

.primary-btn:hover,
.glass-btn:hover,
.section-link:hover,
.search-line button:hover {
  transform: translateY(-2px);
}

.hero-dots {
  position: absolute;
  right: min(5vw, 56px);
  bottom: 34px;
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 4;
}

.hero-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.58);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: var(--white);
}

.quick-search-panel {
  margin-top: -34px;
  position: relative;
  z-index: 6;
}

.global-search-form,
.filter-bar {
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
  border-radius: 22px;
  padding: 18px;
  backdrop-filter: blur(18px);
}

.global-search-form label {
  color: var(--muted);
  display: block;
  margin: 0 0 10px;
  font-size: 14px;
}

.search-line {
  display: flex;
  gap: 12px;
}

.search-line input,
.filter-bar input {
  width: 100%;
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(2, 6, 23, 0.56);
  border-radius: 14px;
  padding: 14px 16px;
  outline: none;
}

.search-line input:focus,
.filter-bar input:focus {
  border-color: rgba(226, 232, 240, 0.42);
}

.page-section {
  padding: 72px 0;
}

.tinted-section {
  background: linear-gradient(180deg, transparent 0%, rgba(15, 23, 42, 0.38) 48%, transparent 100%);
}

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

.section-head h2,
.page-hero h1,
.final-callout h2,
.content-card h2 {
  font-weight: 300;
  letter-spacing: -0.04em;
  margin: 8px 0 0;
}

.section-head h2 {
  font-size: clamp(28px, 4vw, 42px);
}

.section-head p,
.page-hero p,
.final-callout p,
.content-card p,
.category-overview-card p {
  color: var(--subtle);
  line-height: 1.8;
}

.feature-grid,
.movie-grid,
.category-grid,
.category-overview-grid {
  display: grid;
  gap: 22px;
}

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

.movie-grid {
  grid-template-columns: repeat(auto-fill, minmax(232px, 1fr));
}

.category-grid {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

.movie-rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(250px, 320px);
  gap: 22px;
  overflow-x: auto;
  padding: 6px 4px 20px;
  scroll-snap-type: x proximity;
}

.movie-rail::-webkit-scrollbar {
  height: 8px;
}

.movie-rail::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.24);
  border-radius: 999px;
}

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--line);
  backdrop-filter: blur(16px);
  transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.movie-card:hover {
  transform: translateY(-6px) scale(1.015);
  background: rgba(31, 41, 55, 0.68);
  box-shadow: var(--shadow);
  border-color: rgba(226, 232, 240, 0.24);
}

.movie-card a {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.movie-card.horizontal a,
.movie-card.ranking a {
  flex-direction: row;
}

.movie-thumb {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #111827;
}

.movie-card.ranking .movie-thumb {
  width: 220px;
  min-width: 220px;
  aspect-ratio: 16 / 11;
}

.movie-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease, filter 0.5s ease;
}

.movie-card:hover .movie-thumb img {
  transform: scale(1.08);
  filter: saturate(1.1);
}

.thumb-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 38%, rgba(0, 0, 0, 0.82) 100%);
}

.year-badge,
.rank-badge {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  background: rgba(0, 0, 0, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
}

.year-badge {
  right: 12px;
  bottom: 12px;
  border-radius: 10px;
  padding: 5px 9px;
  font-size: 12px;
}

.rank-badge {
  left: 12px;
  top: 12px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-weight: 700;
}

.movie-info {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  flex: 1;
}

.movie-info h3 {
  font-size: 18px;
  line-height: 1.35;
  margin: 0;
  font-weight: 550;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card.large .movie-info h3 {
  font-size: 22px;
}

.movie-info p {
  margin: 0;
  color: var(--subtle);
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta {
  display: flex;
  gap: 8px;
  color: var(--faint);
  font-size: 12px;
  flex-wrap: wrap;
  margin-top: auto;
}

.movie-meta span:not(:last-child)::after {
  content: "·";
  margin-left: 8px;
  color: var(--faint);
}

.tag-list {
  gap: 7px;
}

.tag-list span {
  font-size: 12px;
  padding: 5px 8px;
}

.category-tile,
.final-callout,
.category-overview-card,
.content-card,
.player-panel {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 16px 55px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(16px);
}

.category-tile {
  position: relative;
  min-height: 190px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  isolation: isolate;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  border-color: rgba(226, 232, 240, 0.28);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  filter: saturate(0.86);
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(3, 7, 18, 0.94), rgba(3, 7, 18, 0.22));
  z-index: -1;
}

.category-tile span {
  font-size: 24px;
  font-weight: 300;
}

.category-tile strong {
  color: var(--subtle);
  font-size: 14px;
  line-height: 1.7;
  margin-top: 8px;
  font-weight: 400;
}

.final-callout {
  padding: clamp(28px, 5vw, 56px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.09), transparent 28rem),
    linear-gradient(135deg, rgba(31, 41, 55, 0.84), rgba(3, 7, 18, 0.92));
}

.sub-page {
  padding-bottom: 64px;
}

.page-hero {
  padding: 92px 0 34px;
}

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

.compact-hero p {
  max-width: 760px;
  font-size: 17px;
}

.crumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--faint);
  margin-bottom: 22px;
  font-size: 14px;
}

.crumbs a:hover {
  color: var(--white);
}

.filter-bar {
  margin-top: 28px;
  box-shadow: none;
}

.filter-bar.wide {
  max-width: 780px;
}

.filter-chips {
  margin-top: 14px;
}

.filter-chips button {
  cursor: pointer;
}

.filter-chips button:hover {
  color: var(--white);
  border-color: rgba(226, 232, 240, 0.35);
}

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

.category-list {
  align-items: stretch;
}

.category-overview-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding-bottom: 74px;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 210px 1fr;
  min-height: 220px;
}

.category-cover-link {
  min-height: 100%;
}

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

.category-overview-card > div {
  padding: 24px;
}

.category-overview-card h2 {
  margin: 8px 0 10px;
  font-weight: 300;
  font-size: 30px;
}

.sample-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.sample-links a {
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 11px;
  font-size: 13px;
}

.sample-links a:hover {
  color: var(--white);
  border-color: rgba(226, 232, 240, 0.3);
}

.ranking-list {
  display: grid;
  gap: 18px;
}

.ranking-list .movie-card {
  border-radius: 22px;
}

.detail-page {
  padding-bottom: 70px;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 92px 0 58px;
  min-height: 560px;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.detail-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(14px) saturate(0.82);
  transform: scale(1.08);
}

.detail-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, rgba(3, 7, 18, 1) 0%, rgba(3, 7, 18, 0.86) 52%, rgba(3, 7, 18, 0.58) 100%),
    linear-gradient(90deg, rgba(3, 7, 18, 0.72), rgba(3, 7, 18, 0.24));
}

.detail-title-row {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 34px;
  align-items: end;
}

.detail-poster {
  aspect-ratio: 3 / 4;
  width: 100%;
  object-fit: cover;
  border-radius: 24px;
  border: 1px solid rgba(226, 232, 240, 0.18);
  box-shadow: var(--shadow);
}

.detail-title-row h1 {
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.05em;
  margin: 12px 0 18px;
  font-size: clamp(40px, 6vw, 76px);
}

.detail-title-row p {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.8;
  max-width: 820px;
}

.detail-meta {
  margin: 20px 0 10px;
}

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

.detail-main {
  margin-top: -28px;
  position: relative;
  z-index: 2;
}

.player-panel {
  padding: 14px;
  background: rgba(15, 23, 42, 0.86);
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000;
  aspect-ratio: 16 / 9;
}

.media-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000;
}

.player-start {
  position: absolute;
  inset: 0;
  border: 0;
  cursor: pointer;
  color: var(--white);
  background:
    radial-gradient(circle at 50% 45%, rgba(255, 255, 255, 0.18), transparent 11rem),
    linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.66));
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-direction: column;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.play-icon {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #111827;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  padding-left: 4px;
  font-size: 26px;
}

.player-shell.is-playing .player-start {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.content-card {
  margin-top: 24px;
  padding: clamp(24px, 4vw, 42px);
}

.content-card h2 {
  font-size: clamp(26px, 3.5vw, 36px);
}

.content-card h2 + p {
  margin-top: 14px;
}

.movie-text p {
  font-size: 17px;
}

.related-section {
  padding-bottom: 0;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(3, 7, 18, 0.9);
  margin-top: 40px;
  padding: 48px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
}

.footer-brand p {
  color: var(--subtle);
  line-height: 1.8;
  margin: 18px 0 0;
  max-width: 430px;
}

.site-footer h3 {
  margin: 0 0 16px;
  font-size: 16px;
  font-weight: 500;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
}

.footer-links a {
  color: var(--subtle);
  font-size: 14px;
}

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

.footer-bottom {
  margin-top: 34px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 13px;
}

@media (max-width: 1100px) {
  .desktop-nav a:nth-last-child(-n + 4) {
    display: none;
  }

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

@media (max-width: 860px) {
  .nav-wrap {
    height: 68px;
  }

  .desktop-nav {
    display: none;
  }

  .mobile-nav {
    display: flex;
  }

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

  .hero-slider {
    min-height: 72vh;
  }

  .hero-content {
    padding-bottom: 76px;
  }

  .hero-dots {
    left: 16px;
    right: auto;
    bottom: 28px;
  }

  .search-line,
  .section-head,
  .final-callout,
  .footer-bottom {
    align-items: stretch;
    flex-direction: column;
  }

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

  .movie-card.ranking a {
    flex-direction: column;
  }

  .movie-card.ranking .movie-thumb {
    width: 100%;
    min-width: 100%;
  }

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

  .category-cover-link {
    height: 220px;
  }

  .detail-title-row {
    grid-template-columns: 1fr;
    align-items: start;
  }

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

@media (max-width: 560px) {
  .container {
    width: min(100% - 24px, 1240px);
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  .page-section {
    padding: 52px 0;
  }

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

  .hero-copy h1,
  .detail-title-row h1,
  .compact-hero h1 {
    letter-spacing: -0.035em;
  }

  .hero-tags span,
  .detail-meta span,
  .filter-chips button {
    font-size: 12px;
  }

  .player-panel {
    padding: 8px;
    border-radius: 18px;
  }

  .player-shell {
    border-radius: 14px;
  }

  .play-icon {
    width: 64px;
    height: 64px;
  }
}
