:root {
  --bg: #020617;
  --panel: #0f172a;
  --panel-soft: #111c34;
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --amber: #f59e0b;
  --orange: #ea580c;
  --blue: #38bdf8;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 20% 0%, rgba(245, 158, 11, 0.18), transparent 32rem),
    radial-gradient(circle at 80% 10%, rgba(56, 189, 248, 0.14), transparent 28rem),
    var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.58));
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  backdrop-filter: blur(18px);
}

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

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

.logo-mark {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 35%, #fde68a 0 22%, transparent 23%),
    conic-gradient(from 0deg, var(--amber), var(--orange), var(--blue), var(--amber));
  box-shadow: 0 0 28px rgba(245, 158, 11, 0.45);
}

.logo-text {
  font-size: 1.25rem;
  background: linear-gradient(90deg, #fbbf24, #fb923c, #38bdf8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links a,
.mobile-panel a {
  color: var(--soft);
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 0.95rem;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-links a:hover,
.mobile-panel a:hover {
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.1);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 0;
  border-radius: 12px;
  color: var(--text);
  background: rgba(15, 23, 42, 0.85);
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: var(--text);
  border-radius: 2px;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 12px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.98);
}

.mobile-panel.is-open {
  display: grid;
  gap: 4px;
}

.hero {
  position: relative;
  min-height: 76vh;
  padding-top: 68px;
  overflow: hidden;
  background: #020617;
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.78) 46%, rgba(2, 6, 23, 0.34) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 1), rgba(2, 6, 23, 0.22) 42%, rgba(2, 6, 23, 0.15)),
    var(--hero-image);
  background-size: cover;
  background-position: center;
  filter: saturate(1.08);
  transform: scale(1.02);
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: calc(76vh - 68px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.55fr);
  gap: 52px;
  align-items: center;
  padding: 58px 0 78px;
}

.hero-copy {
  max-width: 720px;
}

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

.eyebrow-tags span,
.tag-row span,
.detail-meta span,
.hero-meta span,
.card-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.24);
  color: #fbbf24;
  font-size: 0.82rem;
  line-height: 1.2;
}

.hero h1 {
  margin: 18px 0 16px;
  font-size: clamp(2.6rem, 6vw, 5.8rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
  text-shadow: 0 18px 44px rgba(0, 0, 0, 0.6);
}

.hero p,
.page-hero p,
.lead {
  color: var(--soft);
  font-size: clamp(1rem, 2vw, 1.2rem);
  max-width: 760px;
}

.hero-meta {
  margin: 24px 0 30px;
}

.primary-button,
.ghost-button,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border 0.2s ease, background 0.2s ease;
}

.primary-button {
  padding: 12px 24px;
  color: white;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  box-shadow: 0 16px 36px rgba(245, 158, 11, 0.28);
}

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

.ghost-button {
  padding: 11px 22px;
  color: var(--text);
  border: 1px solid rgba(248, 250, 252, 0.2);
  background: rgba(15, 23, 42, 0.48);
  backdrop-filter: blur(12px);
}

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

.hero-poster {
  position: relative;
  border-radius: 30px;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.28), rgba(56, 189, 248, 0.18));
  box-shadow: var(--shadow);
  transform: rotate(2deg);
}

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

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 46%, rgba(2, 6, 23, 0.7));
}

.hero-arrow {
  position: absolute;
  z-index: 4;
  top: 50%;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  color: white;
  background: rgba(2, 6, 23, 0.45);
  backdrop-filter: blur(12px);
  cursor: pointer;
  font-size: 2rem;
  line-height: 1;
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 18px;
  height: 4px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

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

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

.section-narrow {
  padding-top: 64px;
}

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

.section-kicker {
  margin: 0 0 8px;
  color: #fbbf24;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section h2,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.section h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
}

.text-link {
  color: #fbbf24;
  min-height: auto;
  font-size: 0.95rem;
}

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

.category-tile {
  display: grid;
  gap: 16px;
  min-height: 210px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.54));
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease, border 0.2s ease;
}

.category-tile:hover {
  transform: translateY(-4px);
  border-color: rgba(245, 158, 11, 0.42);
}

.tile-images {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.tile-images img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 14px;
  background: rgba(245, 158, 11, 0.12);
}

.tile-copy strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.15rem;
}

.tile-copy span {
  display: block;
  color: var(--muted);
  font-size: 0.92rem;
}

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

.movie-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
  transition: transform 0.2s ease, border 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(245, 158, 11, 0.38);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background:
    radial-gradient(circle at 25% 20%, rgba(245, 158, 11, 0.35), transparent 44%),
    linear-gradient(135deg, #111827, #020617);
}

.poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease, opacity 0.25s ease;
}

.poster.is-missing,
.detail-poster-card img.is-missing,
.hero-poster img.is-missing,
.tile-images img.is-missing {
  opacity: 0;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 32%, rgba(2, 6, 23, 0.78));
}

.play-icon {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: white;
  background: rgba(245, 158, 11, 0.88);
  transform: translate(-50%, -50%) scale(0.88);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.duration-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 999px;
  color: white;
  background: rgba(2, 6, 23, 0.75);
  font-size: 0.78rem;
  backdrop-filter: blur(10px);
}

.rank-badge {
  left: 12px;
  right: auto;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  font-weight: 800;
}

.card-body {
  padding: 18px;
}

.card-title {
  display: block;
  margin-bottom: 8px;
  color: white;
  font-size: 1.05rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-card:hover .card-title {
  color: #fbbf24;
}

.card-desc {
  min-height: 3.1em;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.92rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  margin-bottom: 12px;
}

.card-meta span {
  min-height: 24px;
  color: var(--soft);
  background: rgba(148, 163, 184, 0.09);
  border-color: rgba(148, 163, 184, 0.16);
  font-size: 0.76rem;
}

.tag-row span {
  min-height: 24px;
  font-size: 0.76rem;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 30px;
  align-items: start;
}

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

.ranking-panel,
.story-card,
.info-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.82);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.ranking-panel {
  position: sticky;
  top: 92px;
  padding: 22px;
}

.compact-head {
  margin-bottom: 16px;
}

.compact-head h2 {
  font-size: 1.4rem;
}

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

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

.rank-row:hover {
  color: white;
  background: rgba(245, 158, 11, 0.12);
}

.rank-number {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: white;
  background: rgba(245, 158, 11, 0.78);
  font-weight: 800;
}

.rank-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-score {
  color: #fbbf24;
  font-weight: 800;
}

.page-main {
  padding-top: 68px;
}

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

.page-hero h1,
.detail-copy h1 {
  font-size: clamp(2.2rem, 5vw, 4.6rem);
}

.filters {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 180px 180px;
  gap: 14px;
  margin-bottom: 28px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.74);
}

.filters label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.85rem;
}

.filters input,
.filters select {
  width: 100%;
  min-height: 44px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 14px;
  color: var(--text);
  background: rgba(2, 6, 23, 0.8);
  padding: 0 14px;
  outline: none;
}

.filters input:focus,
.filters select:focus {
  border-color: rgba(245, 158, 11, 0.62);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.12);
}

.detail-main {
  background:
    radial-gradient(circle at 20% 10%, rgba(245, 158, 11, 0.14), transparent 32rem),
    var(--bg);
}

.detail-hero {
  position: relative;
  padding-top: 68px;
  overflow: hidden;
  background-image:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.74)),
    var(--hero-image);
  background-size: cover;
  background-position: center;
}

.detail-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, var(--bg), transparent 42%);
}

.detail-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 56px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: 0.92rem;
}

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

.detail-top {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
}

.detail-poster-card {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.22), rgba(56, 189, 248, 0.16));
  box-shadow: var(--shadow);
}

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

.detail-copy .lead {
  margin: 18px 0 22px;
}

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

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

.player-section {
  padding-top: 44px;
}

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

.movie-player {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #000;
}

.player-start {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: white;
  background:
    radial-gradient(circle at center, rgba(245, 158, 11, 0.26), transparent 18rem),
    linear-gradient(180deg, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.78));
  cursor: pointer;
}

.player-start.is-hidden {
  display: none;
}

.play-large {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  box-shadow: 0 18px 42px rgba(245, 158, 11, 0.36);
  font-size: 2rem;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 24px;
}

.story-card,
.info-card {
  padding: 28px;
}

.story-card h2,
.info-card h2 {
  margin: 0 0 14px;
  font-size: 1.5rem;
}

.story-card p {
  margin: 0 0 24px;
  color: var(--soft);
}

.story-card p:last-child {
  margin-bottom: 0;
}

.info-card dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px 16px;
  margin: 0;
}

.info-card dt {
  color: var(--muted);
}

.info-card dd {
  margin: 0;
  color: var(--text);
}

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

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

.footer-brand p {
  max-width: 560px;
  margin: 16px 0 0;
  color: var(--muted);
}

.footer-column h2 {
  margin: 0 0 14px;
  font-size: 1rem;
}

.footer-links {
  display: grid;
  gap: 8px;
}

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

.footer-links a:hover {
  color: #fbbf24;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 30px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: #64748b;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  font-size: 0.9rem;
}

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

@media (max-width: 1060px) {
  .hero-inner,
  .detail-top,
  .split-section,
  .detail-content,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-poster {
    display: none;
  }

  .ranking-panel {
    position: static;
  }

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

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

  .mobile-toggle {
    display: block;
  }

  .hero {
    min-height: 86vh;
  }

  .hero-inner {
    min-height: calc(86vh - 68px);
    padding-top: 42px;
  }

  .hero-arrow {
    display: none;
  }

  .section,
  .page-hero {
    width: min(100% - 24px, 1180px);
  }

  .section-head {
    align-items: start;
    flex-direction: column;
  }

  .movie-grid,
  .split-main .movie-grid,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

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

  .detail-poster-card {
    max-width: 280px;
  }

  .footer-bottom {
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .movie-grid,
  .split-main .movie-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .hero h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 2.3rem;
  }

  .card-desc {
    min-height: auto;
  }
}
