* {
  box-sizing: border-box;
}

:root {
  --orange: #ea580c;
  --orange-dark: #c2410c;
  --amber: #f59e0b;
  --text: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --soft: #f9fafb;
  --card: #ffffff;
  --shadow: 0 20px 45px rgba(17, 24, 39, 0.12);
  --radius: 22px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #ffffff 0%, #f9fafb 52%, #fff7ed 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 4px 20px rgba(17, 24, 39, 0.06);
  backdrop-filter: blur(12px);
}

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

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #fb923c, #f59e0b);
  box-shadow: 0 12px 28px rgba(234, 88, 12, 0.28);
}

.brand-copy {
  display: grid;
  line-height: 1.1;
}

.brand-copy strong {
  font-size: 20px;
  letter-spacing: -0.02em;
  background: linear-gradient(90deg, #ea580c, #d97706);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-copy em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

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

.nav-link,
.mobile-nav-link {
  color: #374151;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease;
}

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

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

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #374151;
  border-radius: 999px;
}

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

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

.mobile-nav-link {
  padding: 12px 16px;
  border-radius: 14px;
}

.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  color: var(--orange);
  background: #fff7ed;
}

.hero {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
  background-image: linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.08)), var(--hero-image);
  background-size: cover;
  background-position: center;
}

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

.hero-content {
  position: relative;
  z-index: 2;
  color: #ffffff;
}

.hero-copy {
  max-width: 660px;
  padding: 74px 0;
}

.hero-badge,
.eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(234, 88, 12, 0.9);
  box-shadow: 0 10px 24px rgba(234, 88, 12, 0.22);
  font-size: 14px;
  font-weight: 800;
}

.hero-copy h1 {
  margin: 22px 0 18px;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero-copy p {
  margin: 0 0 26px;
  max-width: 620px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.75;
}

.hero-meta,
.detail-meta,
.meta-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
}

.hero-meta span,
.detail-meta span {
  display: inline-flex;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

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

.btn-primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--orange), var(--amber));
  box-shadow: 0 16px 30px rgba(234, 88, 12, 0.28);
}

.btn-primary:hover {
  box-shadow: 0 20px 40px rgba(234, 88, 12, 0.38);
}

.btn-ghost {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(10px);
}

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

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

.hero-dot.is-active {
  width: 34px;
  background: #ffffff;
}

.quick-search {
  margin-top: -42px;
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px;
  border: 1px solid rgba(229, 231, 235, 0.8);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.quick-search h2,
.section-heading h2,
.page-hero h1,
.detail-copy h1,
.detail-article h2,
.detail-side h2 {
  margin: 0;
  letter-spacing: -0.03em;
}

.quick-search p,
.section-heading p,
.page-hero p,
.detail-copy p,
.detail-article p,
.category-tile p,
.movie-card-body p,
.ranking-copy p,
.site-footer p {
  color: var(--muted);
  line-height: 1.72;
}

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

.section-heading {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.section-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--orange), var(--amber));
  box-shadow: 0 12px 28px rgba(234, 88, 12, 0.22);
}

.section-heading h2 {
  font-size: clamp(26px, 3vw, 36px);
}

.section-heading p {
  margin: 6px 0 0;
}

.movie-rail {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  padding: 0 2px 20px;
  scroll-snap-type: x mandatory;
}

.movie-rail .movie-card {
  min-width: 245px;
  scroll-snap-align: start;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.07);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(234, 88, 12, 0.28);
  box-shadow: var(--shadow);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #111827;
}

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

.movie-card:hover .poster-link img {
  transform: scale(1.06);
}

.poster-glow {
  position: absolute;
  inset: auto 0 0;
  height: 48%;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.72));
}

.play-chip {
  position: absolute;
  right: 14px;
  bottom: 14px;
  padding: 8px 12px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(234, 88, 12, 0.92);
  font-size: 12px;
  font-weight: 800;
}

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

.meta-line {
  color: #9ca3af;
  font-size: 12px;
  font-weight: 700;
}

.meta-line span:not(:last-child)::after {
  content: "·";
  margin-left: 8px;
  color: #d1d5db;
}

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

.movie-card-body h3 a:hover,
.ranking-copy h2 a:hover,
.side-links a:hover {
  color: var(--orange);
}

.movie-card-body p {
  margin: 0 0 14px;
  min-height: 48px;
  font-size: 14px;
}

.tag-row,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-row span,
.detail-tags span {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  color: #9a3412;
  background: #fff7ed;
  font-size: 12px;
  font-weight: 800;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 34px;
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(17, 24, 39, 0.06);
}

.ranking-item strong {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--orange), var(--amber));
}

.ranking-item span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 800;
}

.ranking-item em {
  grid-column: 2;
  margin-top: -8px;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

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

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

.category-tile {
  min-height: 158px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #ffffff 0%, #fff7ed 100%);
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.07);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-tile span {
  display: block;
  margin-bottom: 10px;
  font-size: 21px;
  font-weight: 900;
}

.category-tile p {
  margin: 0;
  font-size: 14px;
}

.page-main {
  min-height: 70vh;
}

.page-hero {
  margin-top: 34px;
  padding: 52px;
  border-radius: 30px;
  color: #ffffff;
  background: radial-gradient(circle at 80% 20%, rgba(245, 158, 11, 0.44), transparent 30%), linear-gradient(135deg, #111827 0%, #431407 100%);
  box-shadow: var(--shadow);
}

.compact-page-hero h1,
.category-page-hero h1 {
  margin-top: 12px;
  font-size: clamp(36px, 5vw, 56px);
}

.compact-page-hero p,
.category-page-hero p {
  max-width: 720px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 180px 180px;
  gap: 14px;
  margin-bottom: 24px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 26px rgba(17, 24, 39, 0.05);
}

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

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 14px;
  color: var(--text);
  background: #ffffff;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(234, 88, 12, 0.55);
  box-shadow: 0 0 0 4px rgba(234, 88, 12, 0.12);
}

.empty-state {
  display: none;
  margin: 28px 0 0;
  padding: 18px;
  border-radius: 18px;
  color: var(--muted);
  background: #ffffff;
  border: 1px solid var(--line);
}

.empty-state.is-visible {
  display: block;
}

.ranking-card {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.06);
}

.ranking-poster {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  aspect-ratio: 2 / 3;
  background: #111827;
}

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

.ranking-poster span {
  position: absolute;
  left: 10px;
  top: 10px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--orange), var(--amber));
  font-weight: 900;
}

.ranking-copy h2 {
  margin: 10px 0;
  font-size: clamp(22px, 3vw, 30px);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 56px 0;
  color: #ffffff;
  background-image: linear-gradient(90deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.66), rgba(0, 0, 0, 0.28)), var(--detail-image);
  background-size: cover;
  background-position: center;
}

.detail-hero-inner {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border: 4px solid rgba(255, 255, 255, 0.16);
  border-radius: 26px;
  box-shadow: var(--shadow);
  aspect-ratio: 2 / 3;
  background: #111827;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  color: rgba(255, 255, 255, 0.72);
  font-weight: 700;
}

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

.detail-copy h1 {
  font-size: clamp(38px, 6vw, 66px);
  line-height: 1.08;
}

.detail-copy p {
  max-width: 820px;
  margin: 18px 0 20px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
}

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

.player-section {
  padding: 36px 0 0;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #050505;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.7));
  cursor: pointer;
  z-index: 2;
}

.player-cover strong {
  max-width: 80%;
  text-align: center;
  font-size: clamp(20px, 4vw, 34px);
}

.player-play {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, var(--orange), var(--amber));
  box-shadow: 0 18px 42px rgba(234, 88, 12, 0.38);
  font-size: 32px;
}

.player-box.is-playing .player-cover {
  display: none;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  padding-top: 42px;
}

.detail-article,
.detail-side {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.05);
}

.detail-article h2:not(:first-child) {
  margin-top: 28px;
}

.detail-article p {
  margin: 14px 0 0;
  font-size: 17px;
}

.side-links {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.side-links a {
  padding: 12px 14px;
  border-radius: 14px;
  background: #fff7ed;
  color: #9a3412;
  font-weight: 800;
}

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

.site-footer {
  margin-top: 70px;
  padding: 36px 0;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.84);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  margin-bottom: 10px;
  color: var(--orange);
  font-size: 22px;
}

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

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-weight: 800;
}

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

[hidden],
.is-hidden {
  display: none !important;
}

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

  .menu-toggle {
    display: block;
  }

  .quick-search,
  .split-section,
  .detail-layout,
  .footer-inner {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: flex-start;
  }

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

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

  .detail-hero-inner {
    grid-template-columns: 190px minmax(0, 1fr);
  }
}

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

  .brand-copy em {
    display: none;
  }

  .hero {
    min-height: 76vh;
  }

  .hero-slide {
    background-image: linear-gradient(180deg, rgba(0, 0, 0, 0.66), rgba(0, 0, 0, 0.9)), var(--hero-image);
  }

  .hero-copy {
    padding: 58px 0 96px;
  }

  .quick-search {
    margin-top: -30px;
    padding: 20px;
  }

  .movie-grid,
  .category-grid,
  .small-category-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .page-hero {
    padding: 34px 22px;
    border-radius: 24px;
  }

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

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

  .player-box {
    border-radius: 20px;
  }
}
