:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --text: #111827;
  --muted: #64748b;
  --line: #e5e7eb;
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --cyan: #06b6d4;
  --emerald: #10b981;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --soft-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(18px);
}

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

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

.brand-icon {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 12px 22px rgba(37, 99, 235, 0.28);
  font-size: 14px;
}

.brand-text {
  font-size: 20px;
}

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

.nav-link {
  border: 0;
  background: transparent;
  color: #475569;
  cursor: pointer;
  font-size: 15px;
  font-weight: 700;
  padding: 8px 0;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--cyan);
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-panel {
  position: absolute;
  top: 100%;
  right: 0;
  min-width: 180px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #ffffff;
  box-shadow: var(--soft-shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.2s ease;
}

.nav-dropdown:hover .nav-dropdown-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown-panel a,
.mobile-panel a,
.footer-links a {
  display: block;
  color: #475569;
  font-size: 14px;
  padding: 8px 10px;
  border-radius: 10px;
}

.nav-dropdown-panel a:hover,
.mobile-panel a:hover,
.footer-links a:hover {
  color: var(--blue);
  background: #eff6ff;
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.mobile-menu-button span {
  width: 20px;
  height: 2px;
  background: #1f2937;
  border-radius: 999px;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 12px;
  padding: 12px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--soft-shadow);
}

.mobile-panel.open {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
}

.home-hero,
.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(circle at 20% 10%, rgba(6, 182, 212, 0.35), transparent 30%), linear-gradient(135deg, #1d4ed8, #0f172a 70%);
  color: #ffffff;
}

.home-hero {
  min-height: 620px;
  isolation: isolate;
}

.hero-glow {
  position: absolute;
  border-radius: 999px;
  filter: blur(10px);
  opacity: 0.65;
  z-index: 0;
}

.hero-glow-one {
  width: 260px;
  height: 260px;
  left: 8%;
  top: 14%;
  background: rgba(6, 182, 212, 0.38);
}

.hero-glow-two {
  width: 360px;
  height: 360px;
  right: -120px;
  bottom: -120px;
  background: rgba(37, 99, 235, 0.5);
}

.hero-slide {
  position: absolute;
  inset: 0;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(280px, 0.82fr);
  align-items: center;
  gap: 56px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(24px);
  transition: opacity 0.65s ease, transform 0.65s ease, visibility 0.65s ease;
  z-index: 1;
}

.hero-slide.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: max-content;
  max-width: 100%;
  border-radius: 999px;
  padding: 6px 12px;
  background: rgba(6, 182, 212, 0.12);
  color: #67e8f9;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.hero-copy h1,
.page-hero h1,
.detail-article h1 {
  margin: 18px 0 8px;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.hero-copy h2 {
  margin: 0 0 16px;
  color: #bfdbfe;
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.18;
}

.hero-copy p,
.page-hero p {
  max-width: 720px;
  color: #dbeafe;
  font-size: 18px;
}

.hero-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
}

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

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.32);
}

.ghost-button {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.08);
}

.ghost-button.dark {
  color: var(--blue);
  border-color: #bfdbfe;
  background: #eff6ff;
}

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

.hero-poster {
  position: relative;
  min-height: 430px;
  border-radius: 28px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.5);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.35);
}

.hero-poster img {
  width: 100%;
  height: 100%;
  min-height: 430px;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.hero-poster:hover img {
  transform: scale(1.04);
}

.hero-poster span {
  position: absolute;
  left: 18px;
  bottom: 18px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.72);
  padding: 8px 14px;
  font-weight: 800;
  backdrop-filter: blur(10px);
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 34px;
  z-index: 2;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero-controls button {
  border: 0;
  color: #ffffff;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
}

.hero-controls > button {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 28px;
  line-height: 1;
}

.hero-dots {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  padding: 0;
  opacity: 0.55;
}

.hero-dot.active {
  width: 28px;
  opacity: 1;
  background: #67e8f9;
}

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

.alt-section {
  width: 100%;
  max-width: none;
  padding-left: max(16px, calc((100% - 1180px) / 2));
  padding-right: max(16px, calc((100% - 1180px) / 2));
  background: #ffffff;
}

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

.section-heading h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 38px);
  letter-spacing: -0.03em;
}

.section-heading p {
  margin: 6px 0 0;
  color: var(--muted);
}

.section-link {
  color: var(--blue);
  font-weight: 800;
}

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

.movie-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.88);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: #bfdbfe;
  box-shadow: var(--soft-shadow);
}

.movie-cover {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: #dbeafe;
}

.movie-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.movie-card:hover .movie-cover img {
  transform: scale(1.05);
}

.play-mark,
.rank-badge {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 900;
}

.play-mark {
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0.88);
  background: rgba(15, 23, 42, 0.66);
  opacity: 0;
  backdrop-filter: blur(8px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

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

.rank-badge {
  top: 12px;
  left: 12px;
  min-width: 34px;
  height: 34px;
  border-radius: 12px;
  padding: 0 10px;
  background: linear-gradient(135deg, #f97316, #ef4444);
  box-shadow: 0 10px 22px rgba(239, 68, 68, 0.28);
}

.movie-info {
  padding: 16px;
}

.movie-meta,
.detail-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.movie-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #f1f5f9;
  padding: 4px 9px;
}

.movie-info h3 {
  margin: 10px 0 8px;
  font-size: 18px;
  line-height: 1.32;
}

.movie-info h3 a:hover,
.rank-body h3 a:hover {
  color: var(--blue);
}

.movie-info p,
.rank-body p,
.detail-article p {
  color: #475569;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag-row span {
  border-radius: 999px;
  color: #0369a1;
  background: #e0f2fe;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 800;
}

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

.category-grid.wide {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 230px;
  border-radius: 24px;
  background: #0f172a;
  box-shadow: var(--soft-shadow);
  isolation: isolate;
}

.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
  transition: transform 0.35s ease, opacity 0.35s ease;
  z-index: -1;
}

.category-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.05), rgba(15, 23, 42, 0.82));
  z-index: -1;
}

.category-card:hover img {
  transform: scale(1.06);
  opacity: 0.72;
}

.category-card span,
.category-card p {
  position: absolute;
  left: 18px;
  right: 18px;
  color: #ffffff;
}

.category-card span {
  bottom: 78px;
  font-size: 22px;
  font-weight: 900;
}

.category-card p {
  bottom: 18px;
  margin: 0;
  color: #dbeafe;
  font-size: 14px;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 190px 190px;
  gap: 14px;
  align-items: end;
  margin-bottom: 24px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.04);
}

.filter-bar label {
  display: grid;
  gap: 7px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  height: 44px;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  color: #0f172a;
  background: #ffffff;
  padding: 0 14px;
  outline: 0;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

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

.compact-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.rank-item {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  gap: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.rank-cover {
  overflow: hidden;
  border-radius: 16px;
  aspect-ratio: 3 / 4;
  background: #dbeafe;
}

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

.rank-body strong {
  display: inline-flex;
  min-width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #ef4444);
  font-size: 15px;
}

.rank-body h3 {
  margin: 8px 0;
  font-size: 20px;
  line-height: 1.3;
}

.page-hero {
  padding: 88px max(16px, calc((100% - 1180px) / 2));
}

.small-hero,
.ranking-hero,
.category-hero {
  min-height: 300px;
  display: flex;
  align-items: center;
}

.detail-hero {
  padding: 36px max(16px, calc((100% - 1180px) / 2)) 64px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #bfdbfe;
  margin-bottom: 24px;
  font-size: 14px;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 28px;
  align-items: start;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000000;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.32);
  aspect-ratio: 16 / 9;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #ffffff;
  cursor: pointer;
  background: radial-gradient(circle at center, rgba(15, 23, 42, 0.18), rgba(15, 23, 42, 0.58));
}

.player-overlay span {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 16px 38px rgba(6, 182, 212, 0.35);
  font-size: 30px;
}

.player-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-side {
  border-radius: 24px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(16px);
}

.detail-cover {
  width: 100%;
  border-radius: 18px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: #dbeafe;
}

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

.detail-content {
  padding-top: 52px;
}

.detail-article {
  max-width: 900px;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #ffffff;
  box-shadow: var(--soft-shadow);
}

.detail-article h1 {
  color: #0f172a;
  font-size: clamp(34px, 4vw, 54px);
}

.detail-article h2 {
  margin-top: 32px;
  font-size: 26px;
}

.lead-text {
  font-size: 20px;
  color: #334155;
}

.large-tags span {
  font-size: 13px;
}

.site-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 52px 0 26px;
}

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

.footer-brand {
  color: #ffffff;
  font-size: 20px;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 16px;
}

.site-footer p {
  max-width: 520px;
}

.footer-links.two-column {
  columns: 2;
}

.footer-links a {
  color: #cbd5e1;
  padding-left: 0;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 32px auto 0;
  padding-top: 24px;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  font-size: 14px;
}

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

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

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

  .hero-slide {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 80px 0 110px;
  }

  .hero-poster {
    min-height: 320px;
  }

  .hero-poster img {
    min-height: 320px;
  }

  .home-hero {
    min-height: 860px;
  }

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

  .detail-side {
    display: none;
  }
}

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

  .mobile-menu-button {
    display: inline-flex;
  }

  .brand-text {
    font-size: 17px;
  }

  .home-hero {
    min-height: 780px;
  }

  .hero-slide {
    padding: 54px 0 96px;
  }

  .hero-copy h1,
  .page-hero h1 {
    font-size: 34px;
  }

  .movie-grid,
  .rank-list,
  .compact-list {
    grid-template-columns: 1fr;
  }

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

  .filter-bar {
    grid-template-columns: 1fr;
  }

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

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

  .footer-links.two-column {
    columns: 1;
  }

  .detail-article {
    padding: 22px;
  }
}

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

  .rank-item {
    grid-template-columns: 96px minmax(0, 1fr);
  }

  .content-section {
    padding: 44px 0;
  }

  .alt-section {
    padding-top: 44px;
    padding-bottom: 44px;
  }
}
