:root {
  --color-blue-950: #071a33;
  --color-blue-900: #0b2a55;
  --color-blue-800: #123f7a;
  --color-blue-700: #1d5daa;
  --color-blue-100: #dbeafe;
  --color-amber-500: #f59e0b;
  --color-amber-400: #fbbf24;
  --color-stone-950: #1c1917;
  --color-stone-800: #292524;
  --color-stone-700: #44403c;
  --color-stone-600: #57534e;
  --color-stone-200: #e7e5e4;
  --color-stone-100: #f5f5f4;
  --color-white: #ffffff;
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.12);
  --shadow-hover: 0 24px 70px rgba(15, 23, 42, 0.18);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 12px;
  --container: 1200px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 48%, #eff6ff 100%);
  color: var(--color-stone-800);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.88);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(18px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 74px;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 14px;
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-blue-700), var(--color-amber-500));
  box-shadow: 0 12px 24px rgba(29, 93, 170, 0.28);
  font-size: 24px;
}

.brand-text {
  display: grid;
  gap: 2px;
}

.brand-text strong {
  color: transparent;
  background: linear-gradient(135deg, var(--color-blue-800), var(--color-amber-500));
  background-clip: text;
  -webkit-background-clip: text;
  font-size: 21px;
  letter-spacing: 0.02em;
}

.brand-text small {
  color: var(--color-blue-700);
  font-size: 12px;
  font-weight: 700;
}

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

.nav-link,
.mobile-nav-link {
  border-radius: 12px;
  color: var(--color-stone-700);
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link {
  padding: 10px 15px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  color: var(--color-blue-800);
  background: #eff6ff;
}

.nav-link:hover {
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 1px solid var(--color-stone-200);
  border-radius: 12px;
  background: var(--color-white);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 999px;
  background: var(--color-blue-900);
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--color-stone-200);
  background: var(--color-white);
}

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

.mobile-nav-link {
  padding: 14px 24px;
}

.home-hero {
  position: relative;
  overflow: hidden;
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-blue-950) 0%, var(--color-blue-900) 45%, var(--color-blue-800) 100%);
}

.hero-bg-orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(18px);
  opacity: 0.35;
  pointer-events: none;
}

.orb-one {
  width: 320px;
  height: 320px;
  right: 8%;
  top: 12%;
  background: var(--color-amber-400);
}

.orb-two {
  width: 260px;
  height: 260px;
  left: -80px;
  bottom: -70px;
  background: #60a5fa;
}

.hero-shell {
  position: relative;
  min-height: 610px;
  padding: 64px 0 72px;
}

.hero-slide {
  display: none;
  align-items: center;
  grid-template-columns: minmax(0, 1.12fr) minmax(280px, 0.88fr);
  gap: 52px;
  min-height: 460px;
}

.hero-slide.is-active {
  display: grid;
  animation: heroFade 0.65s ease both;
}

@keyframes heroFade {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding: 7px 13px;
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.12);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero-copy p {
  max-width: 720px;
  margin: 0 0 24px;
  color: rgba(219, 234, 254, 0.9);
  font-size: clamp(16px, 2vw, 20px);
}

.hero-actions,
.detail-copy .primary-button {
  margin-top: 28px;
}

.primary-button,
.ghost-button,
.rank-action,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  min-height: 50px;
  padding: 0 24px;
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-amber-500), #f97316);
  box-shadow: 0 14px 32px rgba(249, 115, 22, 0.28);
}

.ghost-button {
  min-height: 50px;
  padding: 0 24px;
  color: var(--color-white);
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
}

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

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

.hero-poster {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 32px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.03));
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.38);
}

.hero-poster::after,
.poster-link::after,
.detail-poster::after,
.rank-cover::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(7, 26, 51, 0) 45%, rgba(7, 26, 51, 0.62) 100%);
  pointer-events: none;
}

.hero-poster img,
.poster-link img,
.detail-poster img,
.rank-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: linear-gradient(135deg, var(--color-blue-900), var(--color-amber-500));
  transition: transform 0.5s ease;
}

.hero-poster:hover img,
.movie-card:hover .poster-link img,
.rank-item:hover .rank-cover img {
  transform: scale(1.05);
}

.hero-controls {
  position: absolute;
  left: 0;
  bottom: 32px;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 38px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--color-amber-400);
}

.content-section,
.listing-section,
.detail-content {
  padding: 70px 0;
}

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

.section-heading h2 {
  margin: 0 0 8px;
  color: var(--color-stone-800);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.section-heading p {
  margin: 0;
  color: var(--color-stone-600);
}

.section-more {
  color: var(--color-blue-700);
  white-space: nowrap;
}

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

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius-xl);
  background: var(--color-white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(29, 93, 170, 0.28);
  box-shadow: var(--shadow-hover);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #dbeafe, #fff7ed);
}

.poster-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--color-white);
  background: rgba(7, 26, 51, 0.72);
  font-size: 12px;
  font-weight: 800;
}

.poster-play {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 999px;
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-amber-500), #f97316);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.25);
}

.movie-card-body {
  padding: 18px;
}

.movie-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--color-blue-700);
  font-size: 13px;
  font-weight: 800;
}

.movie-meta span,
.detail-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #eff6ff;
}

.movie-card h2 {
  margin: 13px 0 8px;
  color: var(--color-stone-800);
  font-size: 19px;
  line-height: 1.28;
}

.movie-card p {
  display: -webkit-box;
  min-height: 50px;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--color-stone-600);
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-row span {
  padding: 4px 9px;
  border-radius: 999px;
  color: #92400e;
  background: #fef3c7;
  font-size: 12px;
  font-weight: 800;
}

.hero-tags span,
.detail-tags span {
  color: #fffbeb;
  background: rgba(251, 191, 36, 0.18);
}

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

.category-tile {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.category-covers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  min-height: 88px;
}

.category-covers img {
  width: 100%;
  height: 88px;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--color-blue-900), var(--color-amber-500));
}

.category-tile h2 {
  margin: 0;
  font-size: 22px;
}

.category-tile p {
  min-height: 52px;
  margin: 0;
  color: var(--color-stone-600);
  font-size: 14px;
}

.category-tile span {
  color: var(--color-blue-700);
  font-weight: 800;
}

.page-hero {
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-blue-950), var(--color-blue-800));
}

.page-hero .container {
  padding: 72px 0;
}

.page-hero h1 {
  margin-bottom: 14px;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(219, 234, 254, 0.9);
  font-size: 18px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto auto;
  gap: 16px;
  align-items: center;
  margin-bottom: 30px;
  padding: 18px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.search-box {
  position: relative;
}

.search-box span {
  position: absolute;
  left: 16px;
  top: 50%;
  color: var(--color-stone-600);
  transform: translateY(-50%);
}

.search-box input,
.sort-box select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--color-stone-200);
  border-radius: 14px;
  color: var(--color-stone-800);
  background: var(--color-white);
  outline: 0;
}

.search-box input {
  padding: 0 16px 0 44px;
}

.search-box input:focus,
.sort-box select:focus {
  border-color: var(--color-amber-500);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-button {
  min-height: 42px;
  padding: 0 13px;
  border: 0;
  border-radius: 999px;
  color: var(--color-blue-800);
  background: #eff6ff;
  font-weight: 800;
  cursor: pointer;
}

.filter-button.is-active,
.filter-button:hover {
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-blue-700), var(--color-blue-900));
}

.sort-box {
  display: grid;
  grid-template-columns: auto 160px;
  gap: 10px;
  align-items: center;
  color: var(--color-stone-600);
  font-weight: 800;
}

.sort-box select {
  padding: 0 12px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 68px 118px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius-xl);
  background: var(--color-white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.rank-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.rank-number {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 18px;
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-amber-500), var(--color-blue-700));
  font-size: 24px;
  font-weight: 900;
}

.rank-cover {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 16px;
  background: linear-gradient(135deg, #dbeafe, #fff7ed);
}

.rank-content h2 {
  margin: 10px 0 6px;
  font-size: 22px;
  line-height: 1.25;
}

.rank-content p {
  margin: 0 0 12px;
  color: var(--color-stone-600);
}

.rank-action {
  min-height: 44px;
  padding: 0 18px;
  color: var(--color-blue-800);
  background: #eff6ff;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  color: var(--color-white);
  background: var(--color-blue-950);
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  background-position: center;
  background-size: cover;
  filter: saturate(1.05);
}

.detail-hero-inner {
  position: relative;
  padding: 48px 0 72px;
}

.back-link {
  display: inline-flex;
  margin-bottom: 30px;
  color: #bfdbfe;
  font-weight: 800;
}

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

.detail-poster {
  position: relative;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border-radius: 28px;
  background: linear-gradient(135deg, var(--color-blue-900), var(--color-amber-500));
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
}

.detail-copy h1 {
  max-width: 860px;
}

.detail-one-line {
  max-width: 820px;
  margin: 0 0 22px;
  color: rgba(219, 234, 254, 0.92);
  font-size: 20px;
}

.detail-meta span {
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.12);
}

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

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000000;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.22);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: var(--color-white);
  background: radial-gradient(circle at center, rgba(29, 93, 170, 0.22), rgba(7, 26, 51, 0.75));
  cursor: pointer;
}

.player-shell.is-playing .player-overlay {
  display: none;
}

.play-circle {
  display: grid;
  width: 86px;
  height: 86px;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--color-amber-500), #f97316);
  box-shadow: 0 16px 38px rgba(249, 115, 22, 0.38);
  font-size: 32px;
}

.player-overlay strong {
  font-size: 20px;
}

.detail-text-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr;
  gap: 22px;
  margin-top: 28px;
}

.detail-panel {
  padding: 28px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius-xl);
  background: var(--color-white);
  box-shadow: var(--shadow-soft);
}

.detail-panel h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.detail-panel p {
  margin: 0;
  color: var(--color-stone-700);
  font-size: 17px;
  line-height: 1.85;
}

.accent-panel {
  background: linear-gradient(135deg, #eff6ff, #fffbeb);
}

.site-footer {
  color: #bfdbfe;
  background: linear-gradient(135deg, var(--color-blue-950), var(--color-blue-900));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 38px;
  padding: 46px 0;
}

.footer-brand {
  margin-bottom: 14px;
  color: var(--color-white);
  font-size: 24px;
}

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

.site-footer h2 {
  margin: 0 0 14px;
  color: var(--color-white);
  font-size: 18px;
}

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

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

.footer-bottom {
  display: flex;
  justify-content: center;
  gap: 18px;
  padding: 18px;
  border-top: 1px solid rgba(191, 219, 254, 0.18);
  color: #93c5fd;
  font-size: 14px;
}

[hidden] {
  display: none !important;
}

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

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

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

  .menu-toggle {
    display: block;
  }

  .hero-slide,
  .detail-layout,
  .detail-text-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-shell {
    min-height: auto;
  }

  .hero-poster,
  .detail-poster {
    max-width: 360px;
    width: 100%;
    margin: 0 auto;
  }

  .movie-grid,
  .featured-grid,
  .all-movie-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .sort-box {
    grid-template-columns: 1fr;
  }

  .rank-item {
    grid-template-columns: 54px 92px 1fr;
  }

  .rank-action {
    grid-column: 2 / -1;
  }
}

@media (max-width: 620px) {
  .container {
    width: min(100% - 22px, var(--container));
  }

  .header-inner {
    min-height: 66px;
  }

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

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

  .brand-text small {
    display: none;
  }

  .home-hero .container {
    width: min(100% - 22px, var(--container));
  }

  .hero-shell {
    padding: 42px 0 58px;
  }

  .hero-slide {
    gap: 30px;
  }

  .hero-controls {
    bottom: 20px;
  }

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

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

  .section-heading {
    display: grid;
  }

  .movie-grid,
  .featured-grid,
  .all-movie-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .rank-item {
    grid-template-columns: 48px 82px 1fr;
    gap: 12px;
    padding: 12px;
  }

  .rank-number {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    font-size: 19px;
  }

  .rank-content h2 {
    font-size: 18px;
  }

  .rank-content p,
  .rank-content .tag-row {
    display: none;
  }

  .detail-panel {
    padding: 20px;
  }

  .footer-bottom {
    display: grid;
    text-align: center;
  }
}
