* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: #111827;
  background: #f9fafb;
  line-height: 1.6;
}

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: 80;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.9);
}

.nav-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 72px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #f97316, #ef4444);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 14px;
  background: linear-gradient(135deg, #fb923c, #ef4444);
  box-shadow: 0 14px 28px rgba(249, 115, 22, 0.28);
}

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

.main-nav > a,
.nav-menu > a {
  padding: 24px 0;
  transition: color 0.2s ease;
}

.main-nav a:hover,
.main-nav .is-active {
  color: #f97316;
}

.nav-menu {
  position: relative;
}

.nav-dropdown {
  position: absolute;
  top: 64px;
  left: 50%;
  width: 220px;
  padding: 10px;
  transform: translateX(-50%) translateY(12px);
  opacity: 0;
  pointer-events: none;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.15);
  border: 1px solid #f3f4f6;
  transition: all 0.2s ease;
}

.nav-menu:hover .nav-dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

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

.nav-dropdown a:hover {
  background: #fff7ed;
  color: #ea580c;
}

.header-search {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.wide-search input,
.catalog-tools input,
.catalog-tools select {
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  background: #fff;
  padding: 11px 16px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.wide-search input:focus,
.catalog-tools input:focus,
.catalog-tools select:focus {
  border-color: #fb923c;
  box-shadow: 0 0 0 4px rgba(251, 146, 60, 0.14);
}

.header-search button,
.wide-search button {
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  padding: 11px 18px;
  background: #f97316;
  color: #fff;
  font-weight: 700;
  transition: background 0.2s ease, transform 0.2s ease;
}

.header-search button:hover,
.wide-search button:hover,
.primary-btn:hover {
  background: #ea580c;
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  border: 0;
  background: #fff7ed;
  color: #ea580c;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  cursor: pointer;
}

.mobile-panel {
  position: fixed;
  z-index: 90;
  inset: 72px 16px auto 16px;
  padding: 14px;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 26px 80px rgba(15, 23, 42, 0.18);
  border: 1px solid #f3f4f6;
}

.mobile-panel a {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  color: #374151;
  font-weight: 700;
}

.mobile-panel a:hover {
  background: #fff7ed;
  color: #ea580c;
}

.hero-carousel {
  position: relative;
  height: 640px;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(135deg, #f97316, #ef4444 55%, #ec4899);
}

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 72% 20%, rgba(255, 255, 255, 0.20), transparent 32%),
    linear-gradient(90deg, rgba(17, 24, 39, 0.88), rgba(127, 29, 29, 0.66), rgba(17, 24, 39, 0.42));
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  height: 100%;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) 360px;
  align-items: center;
  gap: 56px;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: inherit;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.03em;
  backdrop-filter: blur(8px);
}

.hero-copy h1,
.page-hero h1 {
  margin: 20px 0 18px;
  font-size: clamp(42px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.055em;
}

.hero-copy p,
.page-hero p {
  margin: 0;
  max-width: 720px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 19px;
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 800;
  transition: all 0.2s ease;
}

.primary-btn {
  color: #fff;
  background: #f97316;
  box-shadow: 0 18px 36px rgba(249, 115, 22, 0.25);
}

.ghost-btn {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.48);
  backdrop-filter: blur(12px);
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: translateY(-1px);
}

.ghost-btn.light {
  color: #fff;
}

.hero-poster {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 30px;
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.36);
  transform: rotate(2deg);
  transition: transform 0.3s ease;
}

.hero-poster:hover {
  transform: rotate(0deg) translateY(-4px);
}

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

.hero-poster span {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  padding: 12px 16px;
  text-align: center;
  border-radius: 999px;
  background: rgba(249, 115, 22, 0.94);
  color: #fff;
  font-weight: 800;
}

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

.hero-dots button {
  width: 42px;
  height: 5px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
}

.hero-dots button.is-active {
  background: #fff;
}

.home-search-band {
  max-width: 1200px;
  margin: -42px auto 0;
  position: relative;
  z-index: 10;
  padding: 28px;
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.12);
  display: grid;
  grid-template-columns: 1fr minmax(320px, 520px);
  gap: 22px;
  align-items: center;
}

.home-search-band h2,
.section-head h2,
.content-card h2,
.player-section h2 {
  margin: 0 0 6px;
  font-size: 30px;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.home-search-band p,
.section-head p {
  margin: 0;
  color: #6b7280;
}

.wide-search {
  display: flex;
  gap: 10px;
}

.wide-search input {
  flex: 1;
}

.section-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 72px 24px;
}

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

.section-head > a {
  color: #f97316;
  font-weight: 800;
}

.section-head.dark h2 {
  color: #fff;
}

.section-head.dark p {
  color: #9ca3af;
}

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

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

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

.card-cover {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #111827;
}

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

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

.card-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.62), transparent 62%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .card-cover::after {
  opacity: 1;
}

.play-dot {
  position: absolute;
  z-index: 2;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  transform: translate(-50%, -50%) scale(0.86);
  display: grid;
  place-items: center;
  color: #fff;
  background: #f97316;
  opacity: 0;
  transition: all 0.25s ease;
}

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

.duration,
.rank-badge {
  position: absolute;
  z-index: 3;
  bottom: 10px;
  right: 10px;
  padding: 4px 8px;
  border-radius: 8px;
  color: #fff;
  background: rgba(0, 0, 0, 0.72);
  font-size: 12px;
  font-weight: 800;
}

.rank-badge {
  left: 10px;
  right: auto;
  background: #f97316;
}

.card-body {
  padding: 17px;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 10px;
}

.card-tags a,
.card-tags span,
.detail-tags span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #fff7ed;
  color: #ea580c;
  font-size: 12px;
  font-weight: 800;
}

.card-tags span,
.detail-tags span {
  background: #f3f4f6;
  color: #4b5563;
}

.movie-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.3;
}

.movie-card h3 a:hover {
  color: #f97316;
}

.movie-card p {
  margin: 0 0 12px;
  color: #6b7280;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  color: #6b7280;
  font-size: 13px;
}

.hot-section {
  background: linear-gradient(135deg, #111827, #1f2937 45%, #111827);
}

.hot-inner {
  padding-top: 70px;
  padding-bottom: 70px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 46px 118px 1fr;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: 20px;
  background: rgba(31, 41, 55, 0.9);
  color: #fff;
  transition: transform 0.2s ease, background 0.2s ease;
}

.rank-item:hover {
  transform: translateY(-3px);
  background: rgba(55, 65, 81, 0.95);
}

.rank-item img {
  width: 118px;
  height: 76px;
  border-radius: 14px;
  object-fit: cover;
}

.rank-num {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #f97316;
  font-size: 18px;
  font-weight: 900;
}

.rank-text strong,
.rank-text small {
  display: block;
}

.rank-text small {
  margin-top: 5px;
  color: #d1d5db;
}

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

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

.category-tile {
  position: relative;
  min-height: 168px;
  display: flex;
  flex-direction: column;
  justify-content: end;
  overflow: hidden;
  border-radius: 24px;
  padding: 22px;
  color: #fff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 56px rgba(15, 23, 42, 0.18);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  transition: transform 0.45s ease;
}

.category-tile:hover img {
  transform: scale(1.08);
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(17, 24, 39, 0.88), rgba(17, 24, 39, 0.35));
}

.category-tile span,
.category-tile em {
  position: relative;
  z-index: 2;
}

.category-tile span {
  font-size: 22px;
  font-weight: 900;
}

.category-tile em {
  margin-top: 6px;
  color: rgba(255, 255, 255, 0.82);
  font-style: normal;
}

.featured-section {
  background: #fff7ed;
}

.featured-grid,
.top-three {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.page-main,
.detail-main {
  min-height: 60vh;
}

.page-hero {
  min-height: 360px;
  padding: 82px 24px;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, #f97316, #ef4444 70%, #ec4899);
  display: grid;
  place-items: center;
}

.page-hero.slim {
  min-height: 300px;
}

.page-hero > * {
  max-width: 820px;
}

.category-hero {
  background: linear-gradient(135deg, #111827, #f97316 58%, #ef4444);
}

.dark-hero {
  background: linear-gradient(135deg, #111827, #374151);
}

.center-actions {
  justify-content: center;
}

.catalog-tools {
  margin-bottom: 24px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
}

.catalog-tools input {
  flex: 1;
  border-radius: 18px;
}

.catalog-tools select {
  border-radius: 18px;
}

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

.category-list a {
  padding: 22px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-list a:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 42px rgba(15, 23, 42, 0.14);
}

.category-list strong,
.category-list span {
  display: block;
}

.category-list strong {
  color: #111827;
  font-size: 20px;
}

.category-list span {
  margin-top: 6px;
  color: #6b7280;
}

.breadcrumb {
  max-width: 1200px;
  margin: 0 auto;
  padding: 26px 24px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #6b7280;
}

.breadcrumb a {
  color: #f97316;
  font-weight: 800;
}

.detail-hero {
  max-width: 1200px;
  margin: 28px auto 0;
  padding: 0 24px 48px;
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 42px;
  align-items: center;
}

.detail-poster {
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.18);
}

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

.detail-info .eyebrow {
  background: #fff7ed;
  color: #ea580c;
}

.detail-info h1 {
  margin: 20px 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.lead {
  margin: 0 0 20px;
  color: #4b5563;
  font-size: 19px;
}

.detail-meta,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff;
  color: #4b5563;
  box-shadow: 0 7px 16px rgba(15, 23, 42, 0.06);
  font-weight: 750;
}

.detail-tags {
  margin: 18px 0 26px;
}

.player-section,
.content-card {
  max-width: 1200px;
  margin: 0 auto 36px;
  padding: 0 24px;
}

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

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

.play-overlay {
  position: absolute;
  inset: 0;
  border: 0;
  cursor: pointer;
  display: grid;
  place-items: center;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.68), rgba(0, 0, 0, 0.18));
}

.play-overlay span {
  width: 92px;
  height: 92px;
  padding-left: 7px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #fff;
  background: #f97316;
  font-size: 38px;
  box-shadow: 0 20px 44px rgba(249, 115, 22, 0.38);
  transition: transform 0.2s ease, background 0.2s ease;
}

.play-overlay:hover span {
  transform: scale(1.08);
  background: #ea580c;
}

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

.video-message {
  position: absolute;
  left: 20px;
  bottom: 20px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(17, 24, 39, 0.84);
  color: #fff;
  font-weight: 700;
}

.content-card {
  background: #fff;
  border-radius: 28px;
  padding: 34px;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

.content-card p {
  color: #374151;
  font-size: 17px;
}

.related-wrap {
  padding-top: 36px;
}

.search-panel {
  position: fixed;
  z-index: 120;
  inset: 0;
  padding: 96px 18px 18px;
  background: rgba(17, 24, 39, 0.54);
  backdrop-filter: blur(8px);
}

.search-panel-inner {
  max-width: 860px;
  max-height: min(720px, calc(100vh - 120px));
  margin: 0 auto;
  overflow: auto;
  border-radius: 26px;
  background: #fff;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.24);
}

.search-panel-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #fff;
  border-bottom: 1px solid #f3f4f6;
}

.search-close {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 12px;
  background: #fff7ed;
  color: #ea580c;
  cursor: pointer;
  font-size: 24px;
}

.search-results {
  padding: 12px;
}

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

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

.search-result-item img {
  width: 88px;
  height: 62px;
  border-radius: 12px;
  object-fit: cover;
}

.search-result-item strong,
.search-result-item small {
  display: block;
}

.search-result-item small {
  margin-top: 4px;
  color: #6b7280;
}

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

.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  padding: 54px 24px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 32px;
}

.site-footer h3 {
  margin: 0 0 12px;
  color: #fff;
}

.site-footer a:not(.footer-logo) {
  display: block;
  margin: 7px 0;
  color: #d1d5db;
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 20px 24px;
  text-align: center;
  color: #9ca3af;
}

@media (max-width: 1080px) {
  .header-search {
    display: none;
  }

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

  .hero-content {
    grid-template-columns: 1fr 280px;
  }

  .detail-hero {
    grid-template-columns: 280px 1fr;
  }
}

@media (max-width: 820px) {
  .nav-wrap {
    height: 66px;
    padding: 0 16px;
  }

  .main-nav {
    display: none;
  }

  .nav-toggle {
    display: grid;
    place-items: center;
    margin-left: auto;
  }

  .site-logo {
    font-size: 19px;
  }

  .hero-carousel {
    height: 720px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    align-content: center;
    gap: 26px;
    padding-top: 28px;
    padding-bottom: 72px;
  }

  .hero-poster {
    max-width: 230px;
    justify-self: start;
  }

  .home-search-band {
    margin: -24px 16px 0;
    grid-template-columns: 1fr;
  }

  .wide-search,
  .catalog-tools,
  .section-head {
    align-items: stretch;
    flex-direction: column;
  }

  .movie-grid,
  .featured-grid,
  .top-three,
  .rank-grid,
  .category-grid,
  .category-grid.large,
  .category-list,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .rank-item img {
    width: 92px;
  }

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

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

  .page-hero {
    min-height: 280px;
    padding: 64px 18px;
  }

  .section-wrap {
    padding: 54px 18px;
  }

  .content-card {
    padding: 24px;
  }
}

@media (max-width: 520px) {
  .hero-copy h1,
  .page-hero h1 {
    font-size: 38px;
  }

  .hero-copy p,
  .page-hero p,
  .lead {
    font-size: 16px;
  }

  .home-search-band {
    padding: 20px;
  }

  .wide-search {
    gap: 8px;
  }

  .wide-search button {
    padding-left: 14px;
    padding-right: 14px;
  }

  .detail-info h1 {
    font-size: 34px;
  }

  .player-section,
  .content-card {
    padding-left: 16px;
    padding-right: 16px;
  }
}
