:root {
  --orange: #ea580c;
  --orange-dark: #c2410c;
  --red: #dc2626;
  --yellow: #fde047;
  --ink: #111827;
  --muted: #6b7280;
  --soft: #f9fafb;
  --line: #e5e7eb;
  --card: #ffffff;
  --shadow: 0 18px 45px rgba(17, 24, 39, 0.12);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #f3f4f6;
  font-family: ui-sans-serif, system-ui, -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;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(16px);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--orange);
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.03em;
  white-space: nowrap;
}

.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: 0 12px 30px rgba(234, 88, 12, 0.28);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  color: #374151;
  font-weight: 600;
}

.main-nav a,
.nav-dropdown-button {
  border: 0;
  padding: 22px 0;
  background: transparent;
  color: #374151;
  transition: color 0.2s ease;
}

.main-nav a:hover,
.nav-dropdown-button:hover {
  color: var(--orange);
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% - 8px);
  left: 0;
  min-width: 180px;
  padding: 10px;
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all 0.2s ease;
}

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

.nav-dropdown-menu a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
}

.nav-dropdown-menu a:hover {
  color: var(--orange);
  background: #fff7ed;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-shell {
  position: relative;
  width: 260px;
}

.search-input {
  width: 100%;
  border: 1px solid #d1d5db;
  outline: 0;
  border-radius: 999px;
  padding: 11px 18px;
  color: #111827;
  background: #fff;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.search-input:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 4px rgba(234, 88, 12, 0.12);
}

.search-results {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: min(420px, 92vw);
  max-height: 430px;
  overflow: auto;
  padding: 8px;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow);
  display: none;
}

.search-results.is-open {
  display: block;
}

.search-result-item {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  padding: 10px;
  border-radius: 14px;
  transition: background 0.2s ease;
}

.search-result-item:hover {
  background: #fff7ed;
}

.search-result-thumb {
  width: 58px;
  height: 42px;
  border-radius: 10px;
  overflow: hidden;
  background: linear-gradient(135deg, #fb923c, #dc2626);
}

.search-result-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.search-result-title {
  font-weight: 800;
  color: #111827;
}

.search-result-meta {
  color: var(--muted);
  font-size: 13px;
}

.menu-toggle {
  display: none;
  border: 0;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #fff7ed;
  color: var(--orange);
  font-size: 24px;
  line-height: 1;
}

.mobile-nav {
  display: none;
  padding: 0 0 16px;
  border-top: 1px solid var(--line);
}

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

.mobile-nav a {
  display: block;
  padding: 12px 0;
  color: #374151;
  font-weight: 700;
}

.mobile-search {
  position: relative;
  margin: 12px 0;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 650px;
  color: #fff;
  background: linear-gradient(135deg, #ea580c 0%, #dc2626 58%, #be123c 100%);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  width: 340px;
  height: 340px;
  border-radius: 999px;
  opacity: 0.32;
  filter: blur(18px);
  mix-blend-mode: screen;
  animation: blob 12s infinite alternate ease-in-out;
}

.hero::before {
  top: 82px;
  right: 12%;
  background: #fde047;
}

.hero::after {
  left: 10%;
  bottom: 70px;
  background: #fb923c;
  animation-delay: 2s;
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 500px);
  gap: 42px;
  align-items: center;
  min-height: 650px;
  padding: 70px 0;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: #ffedd5;
  font-weight: 700;
  backdrop-filter: blur(10px);
}

.hero h1 {
  margin: 22px 0 22px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 1.06;
  letter-spacing: -0.06em;
}

.hero h1 span {
  color: var(--yellow);
}

.hero p {
  max-width: 680px;
  margin: 0 0 30px;
  color: #fff7ed;
  font-size: clamp(18px, 2vw, 24px);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  border: 2px solid transparent;
  padding: 12px 24px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px) scale(1.02);
}

.btn-primary {
  color: var(--orange);
  background: #fff;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
}

.btn-primary:hover {
  background: #fff7ed;
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.9);
}

.btn-ghost:hover {
  color: var(--orange);
  background: #fff;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
}

.hero-stat strong {
  display: block;
  font-size: 30px;
  line-height: 1;
}

.hero-stat span {
  color: #ffedd5;
  font-size: 14px;
}

.hero-slider {
  position: relative;
  min-height: 470px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 0 28px 60px rgba(15, 23, 42, 0.24);
  opacity: 0;
  transform: translateX(20px) scale(0.98);
  transition: opacity 0.42s ease, transform 0.42s ease;
  pointer-events: none;
}

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

.hero-slide-media {
  position: relative;
  min-height: 310px;
  background: linear-gradient(135deg, rgba(253, 224, 71, 0.4), rgba(220, 38, 38, 0.6));
}

.hero-slide-media img {
  width: 100%;
  height: 100%;
  min-height: 310px;
  object-fit: cover;
}

.hero-slide-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.72), transparent 55%);
}

.hero-slide-body {
  padding: 24px;
  background: rgba(17, 24, 39, 0.86);
}

.hero-slide-body h2 {
  margin: 0 0 8px;
  font-size: 26px;
}

.hero-slide-body p {
  display: -webkit-box;
  margin: 0 0 18px;
  overflow: hidden;
  color: #e5e7eb;
  font-size: 15px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.hero-tags,
.card-tags,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  color: #9a3412;
  background: #ffedd5;
  font-size: 12px;
  font-weight: 800;
}

.hero-slide-body .tag {
  color: #fff7ed;
  background: rgba(234, 88, 12, 0.68);
}

.hero-dots {
  position: absolute;
  right: 24px;
  bottom: 24px;
  z-index: 4;
  display: flex;
  gap: 8px;
}

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

.hero-dot.is-active {
  width: 30px;
  background: #fff;
}

.section {
  padding: 68px 0;
}

.section-white {
  background: #fff;
}

.section-soft {
  background: #f9fafb;
}

.section-dark {
  color: #fff;
  background: #111827;
}

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

.section-title {
  margin: 0;
  font-size: clamp(28px, 4vw, 38px);
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-dark .section-desc {
  color: #d1d5db;
}

.more-link {
  color: var(--orange);
  font-weight: 800;
  white-space: nowrap;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transition: transform 0.26s ease, box-shadow 0.26s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 52px rgba(15, 23, 42, 0.16);
}

.card-media {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(135deg, #fb923c, #dc2626);
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.01);
  transition: transform 0.5s ease, opacity 0.2s ease;
}

.movie-card:hover .card-media img {
  transform: scale(1.1);
}

img.is-missing {
  opacity: 0;
}

.card-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.66), transparent 60%);
  opacity: 0.78;
}

.play-badge {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 46px;
  opacity: 0.94;
  transform: scale(0.9);
  transition: transform 0.25s ease;
}

.movie-card:hover .play-badge {
  transform: scale(1.04);
}

.card-year {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 3;
  border-radius: 999px;
  padding: 5px 10px;
  color: #fff;
  background: rgba(234, 88, 12, 0.86);
  font-size: 12px;
  font-weight: 800;
}

.card-body {
  padding: 18px;
}

.card-body h3 {
  display: -webkit-box;
  min-height: 58px;
  margin: 0 0 8px;
  overflow: hidden;
  color: #111827;
  font-size: 20px;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-meta {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 14px;
}

.card-text {
  display: -webkit-box;
  min-height: 50px;
  margin: 0 0 14px;
  overflow: hidden;
  color: #4b5563;
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 190px;
  border-radius: 24px;
  padding: 26px;
  color: #fff;
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 60px rgba(234, 88, 12, 0.22);
}

.category-card::after {
  content: "";
  position: absolute;
  width: 150px;
  height: 150px;
  right: -36px;
  bottom: -42px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
}

.category-card h3 {
  position: relative;
  z-index: 2;
  margin: 0 0 10px;
  font-size: 25px;
}

.category-card p {
  position: relative;
  z-index: 2;
  margin: 0;
  color: #ffedd5;
}

.page-hero {
  color: #fff;
  background: linear-gradient(135deg, #ea580c, #dc2626);
  padding: 72px 0;
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(36px, 6vw, 58px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: #ffedd5;
  font-size: 19px;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) auto;
  gap: 16px;
  align-items: center;
  margin-bottom: 26px;
  padding: 18px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
}

.filter-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.filter-pill {
  border: 0;
  border-radius: 999px;
  padding: 9px 14px;
  color: #9a3412;
  background: #ffedd5;
  font-weight: 800;
}

.filter-pill.is-active {
  color: #fff;
  background: var(--orange);
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 78px 180px 1fr auto;
  align-items: center;
  gap: 20px;
  border-radius: 22px;
  padding: 16px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.rank-num {
  color: var(--orange);
  font-size: 30px;
  font-weight: 900;
  text-align: center;
}

.ranking-thumb {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 16px;
  background: linear-gradient(135deg, #fb923c, #dc2626);
}

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

.ranking-content h3 {
  margin: 0 0 6px;
  font-size: 22px;
}

.ranking-content p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.detail-hero {
  color: #fff;
  background: #030712;
}

.player-wrap {
  padding: 36px 0 44px;
}

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.12));
  transition: opacity 0.24s ease, visibility 0.24s ease;
}

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

.play-overlay span {
  display: grid;
  place-items: center;
  width: 96px;
  height: 96px;
  border-radius: 999px;
  background: rgba(234, 88, 12, 0.94);
  box-shadow: 0 20px 42px rgba(234, 88, 12, 0.35);
  font-size: 42px;
  transform: translateX(3px);
}

.detail-title-block {
  padding: 34px 0 20px;
}

.detail-title-block h1 {
  margin: 0 0 12px;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.detail-title-block p {
  max-width: 920px;
  margin: 0;
  color: #d1d5db;
  font-size: 18px;
}

.detail-grid {
  display: grid;
  grid-template-columns: 310px 1fr;
  gap: 28px;
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(135deg, #fb923c, #dc2626);
  box-shadow: var(--shadow);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.detail-panel {
  border-radius: 24px;
  padding: 28px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.detail-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.meta-box {
  border-radius: 16px;
  padding: 14px 16px;
  background: #f9fafb;
}

.meta-box span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.meta-box strong {
  display: block;
  color: #111827;
  font-size: 18px;
}

.article-block {
  margin-top: 24px;
}

.article-block h2 {
  margin: 0 0 12px;
  font-size: 25px;
}

.article-block p {
  margin: 0;
  color: #374151;
}

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

.site-footer {
  color: #d1d5db;
  background: #111827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 30px;
  padding: 52px 0 34px;
}

.footer-brand {
  color: #fff;
  font-size: 22px;
  font-weight: 900;
}

.footer-grid p {
  margin: 12px 0 0;
  color: #9ca3af;
}

.footer-grid h3 {
  margin: 0 0 12px;
  color: #fff;
  font-size: 17px;
}

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

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 18px 0;
  color: #9ca3af;
  font-size: 14px;
  text-align: center;
}

.search-page-shell {
  display: grid;
  gap: 22px;
}

.search-page-input {
  border: 0;
  outline: 0;
  border-radius: 22px;
  padding: 18px 22px;
  font-size: 20px;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
}

.search-page-results {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.empty-state {
  border-radius: 22px;
  padding: 36px;
  color: var(--muted);
  background: #fff;
  text-align: center;
}

@keyframes blob {
  0% {
    transform: translate(0, 0) scale(1);
  }
  100% {
    transform: translate(28px, -26px) scale(1.16);
  }
}

@media (max-width: 1024px) {
  .main-nav,
  .header-actions {
    display: none;
  }

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

  .hero-inner,
  .detail-grid {
    grid-template-columns: 1fr;
  }

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

  .movie-grid,
  .movie-grid.compact,
  .search-page-results {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

  .ranking-item {
    grid-template-columns: 58px 145px 1fr;
  }

  .ranking-item .btn {
    grid-column: 2 / -1;
    justify-self: start;
  }
}

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

  .logo {
    font-size: 20px;
  }

  .hero,
  .hero-inner {
    min-height: auto;
  }

  .hero-inner {
    padding: 50px 0;
  }

  .hero-stats {
    gap: 18px;
  }

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

  .section {
    padding: 48px 0;
  }

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

  .movie-grid,
  .movie-grid.compact,
  .category-cards,
  .related-grid,
  .search-page-results,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .filter-actions {
    justify-content: flex-start;
  }

  .ranking-item {
    grid-template-columns: 48px 1fr;
  }

  .ranking-thumb {
    grid-column: 1 / -1;
    order: -1;
  }

  .ranking-item .btn {
    grid-column: 1 / -1;
  }

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