
:root {
  --bg: #f8fafc;
  --ink: #0f172a;
  --muted: #64748b;
  --panel: #ffffff;
  --line: #e2e8f0;
  --dark: #020617;
  --cyan: #06b6d4;
  --cyan-dark: #0891b2;
  --blue: #3b82f6;
  --gold: #facc15;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(2, 6, 23, 0.92);
  color: #ffffff;
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 10px 25px rgba(6, 182, 212, 0.28);
}

.brand-text,
.footer-brand {
  font-size: 21px;
  background: linear-gradient(90deg, #22d3ee, #60a5fa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.nav-link {
  color: #dbeafe;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #22d3ee;
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  padding: 10px;
}

.menu-button span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 999px;
  background: #ffffff;
}

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

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

.hero-slider {
  position: relative;
  height: 70vh;
  min-height: 540px;
  overflow: hidden;
  background: var(--dark);
}

.hero-stage,
.hero-slide,
.hero-bg,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}

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

.hero-bg {
  background-size: cover;
  background-position: center;
  transform: scale(1.04);
  filter: saturate(1.05);
}

.hero-shade {
  background:
    radial-gradient(circle at 25% 30%, rgba(6, 182, 212, 0.28), transparent 26%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(2, 6, 23, 0.68) 44%, rgba(2, 6, 23, 0.2) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.08) 46%, rgba(2, 6, 23, 0.5));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 0 86px;
  color: #ffffff;
}

.hero-kicker {
  width: fit-content;
  margin-bottom: 16px;
  padding: 8px 14px;
  border-radius: 999px;
  color: #cffafe;
  background: rgba(8, 145, 178, 0.22);
  border: 1px solid rgba(34, 211, 238, 0.28);
  backdrop-filter: blur(12px);
}

.hero-content h1 {
  max-width: 900px;
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 76px);
  line-height: 1.05;
  letter-spacing: -0.045em;
  text-shadow: 0 12px 30px rgba(0, 0, 0, 0.48);
}

.hero-content p {
  max-width: 760px;
  margin: 0 0 22px;
  color: #e2e8f0;
  font-size: clamp(17px, 2vw, 22px);
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #0e7490;
  background: #ecfeff;
  font-size: 13px;
  font-weight: 700;
}

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

.primary-button,
.ghost-button,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 22px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 14px 34px rgba(6, 182, 212, 0.28);
}

.primary-button:hover,
.ghost-button:hover,
.section-more:hover {
  transform: translateY(-2px);
}

.ghost-button {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(10px);
}

.hero-arrow {
  position: absolute;
  z-index: 3;
  top: 50%;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.45);
  font-size: 38px;
  line-height: 1;
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(0, 0, 0, 0.7);
}

.hero-prev {
  left: 20px;
}

.hero-next {
  right: 20px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  transition: width 0.3s ease, background 0.3s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: #22d3ee;
}

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

.narrow-page {
  width: min(980px, calc(100% - 32px));
}

.content-section,
.toolbar-card,
.story-card,
.category-panel {
  margin: 42px 0;
}

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

.section-heading h2,
.page-hero h1,
.story-card h2 {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  letter-spacing: -0.035em;
}

.section-heading h2 {
  position: relative;
  padding-left: 16px;
  font-size: clamp(26px, 3vw, 36px);
}

.section-heading h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 5px;
  height: 32px;
  border-radius: 999px;
  background: var(--cyan);
}

.section-heading p,
.page-hero p,
.category-panel p,
.story-card p {
  margin: 6px 0 0;
  color: var(--muted);
}

.section-more {
  color: #0e7490;
  background: #cffafe;
}

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

.category-movie-grid {
  align-items: stretch;
}

.movie-card {
  min-width: 0;
}

.movie-card-link {
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.movie-poster,
.small-cover,
.rank-cover,
.detail-cover,
.play-overlay {
  background-size: cover;
  background-position: center;
  background-color: #0f172a;
}

.movie-poster {
  position: relative;
  aspect-ratio: 16 / 10;
  background-image: linear-gradient(135deg, #0f172a, #0e7490);
}

.score-badge,
.year-badge {
  position: absolute;
  top: 12px;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 3px 9px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  background: rgba(2, 6, 23, 0.7);
  backdrop-filter: blur(8px);
}

.score-badge {
  right: 12px;
  color: #fef3c7;
}

.year-badge {
  left: 12px;
}

.movie-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 16px;
}

.movie-card h3 {
  margin: 0;
  color: #0f172a;
  font-size: 18px;
  font-weight: 850;
  line-height: 1.35;
}

.movie-meta {
  margin: 8px 0 0;
  color: #64748b;
  font-size: 13px;
}

.movie-desc {
  display: -webkit-box;
  min-height: 48px;
  margin: 10px 0 14px;
  overflow: hidden;
  color: #334155;
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.category-chip,
.category-panel a {
  display: block;
  height: 100%;
  padding: 24px;
  border-radius: 20px;
  color: #ffffff;
  background:
    radial-gradient(circle at 20% 0%, rgba(34, 211, 238, 0.35), transparent 28%),
    linear-gradient(135deg, #0f172a, #1e293b 55%, #0e7490);
  box-shadow: var(--shadow);
  transition: transform 0.22s ease;
}

.category-chip:hover,
.category-panel a:hover {
  transform: translateY(-5px);
}

.category-chip strong,
.category-panel h2 {
  display: block;
  margin: 0 0 8px;
  font-size: 24px;
  font-weight: 900;
}

.category-chip span,
.category-panel p {
  display: block;
  color: #cbd5e1;
}

.category-mini-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.category-mini-links a {
  padding: 5px 10px;
  border-radius: 999px;
  color: #cffafe;
  background: rgba(255, 255, 255, 0.1);
}

.rank-section {
  padding: 34px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 12px 36px rgba(15, 23, 42, 0.08);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  transition: transform 0.2s ease, border 0.2s ease;
}

.rank-row:hover {
  transform: translateX(4px);
  border-color: #67e8f9;
}

.rank-row.large {
  grid-template-columns: 48px 70px minmax(160px, 1fr) minmax(180px, auto) auto;
}

.rank-no {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  font-weight: 900;
}

.rank-cover {
  width: 70px;
  aspect-ratio: 16 / 10;
  border-radius: 12px;
}

.rank-title {
  font-weight: 850;
}

.rank-meta,
.rank-heat {
  color: #64748b;
  font-size: 14px;
}

.page-hero {
  margin: 34px 0 24px;
  padding: 36px;
  border-radius: 24px;
  color: #ffffff;
  background:
    radial-gradient(circle at 10% 20%, rgba(34, 211, 238, 0.35), transparent 30%),
    linear-gradient(135deg, #020617, #1e293b 55%, #0e7490);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  color: #ffffff;
  font-size: clamp(34px, 4vw, 52px);
}

.page-hero p {
  max-width: 760px;
  color: #dbeafe;
  font-size: 17px;
}

.breadcrumb {
  margin-bottom: 14px;
  color: #a5f3fc;
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #ffffff;
}

.toolbar-card {
  padding: 20px;
  border-radius: 20px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.sticky-toolbar {
  position: sticky;
  top: 82px;
  z-index: 20;
}

.search-box {
  display: grid;
  gap: 8px;
  color: #0f172a;
  font-weight: 800;
}

.search-box input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  outline: none;
  color: #0f172a;
  background: #f8fafc;
}

.search-box input:focus {
  border-color: #22d3ee;
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.18);
}

.detail-page {
  width: 100%;
}

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

.detail-backdrop,
.detail-overlay {
  position: absolute;
  inset: 0;
}

.detail-backdrop {
  background-size: cover;
  background-position: center;
  filter: blur(16px) saturate(1.1);
  transform: scale(1.08);
  opacity: 0.6;
}

.detail-overlay {
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.62)),
    radial-gradient(circle at 70% 20%, rgba(34, 211, 238, 0.24), transparent 28%);
}

.detail-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: 620px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 320px 1fr;
  align-items: end;
  gap: 42px;
  padding: 86px 0 58px;
}

.detail-cover {
  aspect-ratio: 2 / 3;
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.38);
  background-color: #0f172a;
}

.detail-info h1 {
  margin: 0 0 18px;
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.detail-line {
  max-width: 780px;
  margin: 0 0 18px;
  color: #e2e8f0;
  font-size: 20px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.detail-meta span {
  padding: 7px 12px;
  border-radius: 999px;
  color: #cffafe;
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.detail-tags {
  margin-bottom: 26px;
}

.player-section,
.detail-content,
.related-section {
  width: min(1180px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

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

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #000000;
  box-shadow: var(--shadow);
}

.movie-player {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: #ffffff;
  text-align: center;
  cursor: pointer;
}

.play-overlay::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.62);
}

.play-overlay strong,
.play-circle {
  position: relative;
  z-index: 1;
}

.play-circle {
  width: 88px;
  height: 88px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  font-size: 34px;
  box-shadow: 0 18px 42px rgba(6, 182, 212, 0.32);
}

.play-overlay strong {
  max-width: 80%;
  font-size: 24px;
}

.play-overlay.is-hidden {
  display: none;
}

.detail-content {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  margin-top: 34px;
}

.story-card {
  padding: 28px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.story-card h2 {
  font-size: 26px;
}

.story-card p {
  color: #334155;
  font-size: 16px;
}

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

.small-movie {
  display: grid;
  grid-template-columns: 86px 1fr;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.small-movie:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
}

.small-cover {
  aspect-ratio: 16 / 10;
  border-radius: 12px;
}

.small-movie strong,
.small-movie span {
  display: block;
}

.small-movie strong {
  color: #0f172a;
  line-height: 1.35;
}

.small-movie span {
  margin-top: 4px;
  color: #64748b;
  font-size: 13px;
}

.site-footer {
  margin-top: 56px;
  padding: 42px 0;
  color: #cbd5e1;
  background: #020617;
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-inner p {
  max-width: 620px;
  margin: 10px 0 0;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: flex-end;
}

.footer-links a {
  color: #e0f2fe;
}

[data-filter-card].is-filtered {
  display: none;
}

@media (max-width: 1024px) {
  .movie-grid,
  .related-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .detail-inner {
    grid-template-columns: 240px 1fr;
  }

  .rank-row.large {
    grid-template-columns: 44px 64px 1fr;
  }

  .rank-row.large .rank-meta,
  .rank-row.large .rank-heat {
    grid-column: 3;
  }
}

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

  .menu-button {
    display: block;
  }

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

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

  .hero-arrow {
    display: none;
  }

  .movie-grid,
  .category-grid,
  .category-panels,
  .related-grid,
  .detail-content {
    grid-template-columns: 1fr;
  }

  .section-heading,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .detail-inner {
    grid-template-columns: 1fr;
    align-items: end;
  }

  .detail-cover {
    width: 220px;
  }

  .rank-row,
  .rank-row.large {
    grid-template-columns: 42px 1fr;
  }

  .rank-cover {
    display: none;
  }

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

  .sticky-toolbar {
    top: 76px;
  }
}
