:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --brand: #f97316;
  --brand-dark: #ea580c;
  --dark: #0f172a;
  --dark-soft: #1e293b;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(135deg, #f8fafc 0%, #eef2f7 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(90deg, #1e293b, #0f172a);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18);
}

.header-inner {
  max-width: 1280px;
  height: 72px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.brand-mark,
.footer-brand span {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--brand), #fb923c);
  box-shadow: 0 10px 24px rgba(249, 115, 22, 0.32);
}

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

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 15px;
  color: #e2e8f0;
}

.desktop-nav a,
.mobile-nav a {
  transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-nav a:hover,
.mobile-nav a.is-active {
  color: #fb923c;
}

.header-search {
  position: relative;
  margin-left: auto;
  width: min(320px, 28vw);
}

.header-search input,
.mobile-search input,
.home-search-box input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 1px solid rgba(226, 232, 240, 0.28);
  outline: none;
  border-radius: 999px;
  padding: 11px 16px;
  color: #0f172a;
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.header-search input:focus,
.mobile-search input:focus,
.home-search-box input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.16);
}

.search-results,
.home-search-results {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  right: 0;
  display: none;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  color: #0f172a;
  box-shadow: var(--shadow);
  overflow: hidden;
  max-height: 430px;
  overflow-y: auto;
}

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

.search-results a,
.home-search-results a {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 12px;
  padding: 10px;
  border-bottom: 1px solid #f1f5f9;
}

.search-results a:hover,
.home-search-results a:hover {
  background: #fff7ed;
}

.search-results img,
.home-search-results img {
  width: 54px;
  height: 72px;
  border-radius: 10px;
  object-fit: cover;
}

.search-results strong,
.home-search-results strong {
  display: block;
  font-size: 14px;
  line-height: 1.3;
}

.search-results span,
.home-search-results span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.menu-button {
  display: none;
  border: 0;
  color: #fff;
  background: transparent;
  font-size: 26px;
}

.mobile-nav {
  display: none;
  padding: 14px 24px 22px;
  background: #0f172a;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

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

.mobile-search {
  position: relative;
  margin-bottom: 6px;
}

.hero {
  position: relative;
  min-height: 640px;
  overflow: hidden;
  background: linear-gradient(90deg, #0f172a, #1e293b);
}

.hero-slides,
.hero-slide {
  min-height: 640px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  align-items: center;
  gap: 48px;
  width: 100%;
  padding: 80px max(24px, calc((100vw - 1280px) / 2)) 70px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

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

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--hero-image);
  background-size: cover;
  background-position: center;
  transform: scale(1.05);
  opacity: 0.25;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96) 0%, rgba(15, 23, 42, 0.82) 48%, rgba(15, 23, 42, 0.5) 100%);
}

.hero-content,
.hero-poster {
  position: relative;
  z-index: 1;
}

.hero-kicker,
.section-heading span,
.page-hero span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: #fb923c;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1,
.hero h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(40px, 7vw, 78px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero h2 {
  margin-top: 12px;
  font-size: clamp(28px, 4vw, 48px);
}

.hero p {
  max-width: 760px;
  margin: 24px 0 0;
  color: #cbd5e1;
  font-size: clamp(16px, 2vw, 22px);
  line-height: 1.7;
}

.hero-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  margin-top: 24px;
}

.hero-tags span,
.tag-list span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-size: 12px;
  font-weight: 700;
}

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

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

.btn-primary {
  color: #fff;
  background: var(--brand);
  box-shadow: 0 16px 30px rgba(249, 115, 22, 0.28);
}

.btn-primary:hover {
  background: var(--brand-dark);
  transform: translateY(-2px);
}

.btn-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
}

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

.btn-primary.small {
  min-height: 38px;
  padding: 9px 16px;
  font-size: 14px;
}

.hero-poster {
  display: block;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.38);
  transform: rotate(2deg);
}

.hero-poster img {
  width: 100%;
  height: 480px;
  object-fit: cover;
}

.hero-poster span {
  position: absolute;
  right: 18px;
  top: 18px;
  padding: 8px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(15, 23, 42, 0.78);
  font-weight: 800;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
}

.hero-dot.is-active {
  width: 34px;
  background: var(--brand);
}

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

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

.section-heading.center {
  display: block;
  max-width: 760px;
  margin: 0 auto 26px;
  text-align: center;
}

.section-heading h2,
.page-hero h1,
.article-card h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.section-heading p,
.page-hero p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

.section-heading a {
  color: var(--brand-dark);
  font-weight: 800;
}

.search-feature {
  padding-bottom: 34px;
}

.home-search-box {
  position: relative;
  max-width: 780px;
  margin: 0 auto;
}

.home-search-box input {
  padding: 16px 22px;
  border-radius: 24px;
  font-size: 18px;
  box-shadow: var(--shadow);
}

.home-search-results {
  z-index: 15;
  top: calc(100% + 14px);
}

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

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

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

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

.movie-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  border-color: rgba(249, 115, 22, 0.4);
  box-shadow: 0 24px 50px rgba(15, 23, 42, 0.16);
}

.card-poster {
  position: relative;
  height: 260px;
  overflow: hidden;
  background: #0f172a;
}

.compact-grid .card-poster,
.catalog-grid .card-poster {
  height: 220px;
}

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

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

.card-poster::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 45%;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.72), transparent);
}

.card-badge,
.card-duration {
  position: absolute;
  z-index: 2;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.card-badge {
  left: 12px;
  top: 12px;
  background: var(--brand);
}

.card-duration {
  right: 12px;
  bottom: 12px;
  background: rgba(15, 23, 42, 0.78);
}

.card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
}

.card-body h3 {
  margin: 0;
  min-height: 2.6em;
  color: #0f172a;
  font-size: 17px;
  line-height: 1.32;
}

.card-body p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  color: var(--muted);
  font-size: 13px;
}

.card-meta strong {
  color: var(--brand-dark);
}

.category-band {
  padding: 72px max(24px, calc((100vw - 1280px) / 2));
  background: linear-gradient(120deg, #1e293b, #0f172a);
}

.section-heading.dark h2,
.section-heading.dark a {
  color: #fff;
}

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

.category-card {
  min-height: 210px;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(8px);
  transition: transform 0.25s ease, background 0.25s ease;
}

.category-card:hover {
  transform: translateY(-6px) scale(1.02);
  background: rgba(249, 115, 22, 0.88);
}

.category-card span {
  display: block;
  font-size: 20px;
  font-weight: 900;
}

.category-card p {
  min-height: 66px;
  margin: 12px 0;
  color: #e2e8f0;
  line-height: 1.6;
}

.category-card div {
  display: grid;
  gap: 6px;
  font-size: 13px;
  color: #ffedd5;
}

.latest-section {
  max-width: none;
  background: #f1f5f9;
}

.latest-section > * {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 58px 130px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-row:hover {
  transform: translateX(5px);
  box-shadow: var(--shadow);
}

.rank-number {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, #fb923c, #ea580c);
  font-weight: 900;
}

.rank-row img {
  width: 130px;
  height: 82px;
  border-radius: 12px;
  object-fit: cover;
}

.rank-info h3 {
  margin: 0 0 6px;
  font-size: 18px;
}

.rank-info p {
  margin: 0 0 6px;
  color: var(--muted);
  line-height: 1.5;
}

.rank-info span {
  color: #94a3b8;
  font-size: 13px;
}

.rank-score {
  color: var(--brand-dark);
  font-size: 20px;
  font-weight: 900;
}

.page-hero {
  position: relative;
  min-height: 330px;
  display: flex;
  align-items: center;
  padding: 72px max(24px, calc((100vw - 1280px) / 2));
  color: #fff;
  background: linear-gradient(120deg, #0f172a, #1e293b 60%, #431407);
}

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

.page-hero p {
  max-width: 760px;
  color: #cbd5e1;
  font-size: 18px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 180px 180px 180px;
  gap: 14px;
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.empty-state {
  display: none;
  margin-top: 24px;
  padding: 28px;
  border-radius: 18px;
  color: var(--muted);
  text-align: center;
  background: #fff;
}

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

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

.category-overview-card {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.category-overview-head h2 {
  margin: 0 0 8px;
  font-size: 26px;
}

.category-overview-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

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

.category-preview-row a {
  overflow: hidden;
  border-radius: 16px;
  background: #0f172a;
}

.category-preview-row img {
  width: 100%;
  height: 110px;
  object-fit: cover;
  opacity: 0.88;
}

.category-preview-row span {
  display: block;
  padding: 8px;
  color: #fff;
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.breadcrumb {
  max-width: 1280px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px auto 0;
  padding: 0 24px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--brand-dark);
  font-weight: 700;
}

.detail-layout {
  max-width: 1280px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  margin: 24px auto 0;
  padding: 0 24px;
}

.player-panel,
.detail-side,
.article-card {
  border: 1px solid var(--line);
  border-radius: 26px;
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.player-stage {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.movie-video {
  width: 100%;
  height: 100%;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  cursor: pointer;
  background: #000;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.player-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}

.play-circle {
  position: absolute;
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  background: var(--brand);
  font-size: 36px;
  box-shadow: 0 18px 44px rgba(249, 115, 22, 0.32);
  transform: scale(1);
  transition: transform 0.2s ease, background 0.2s ease;
}

.player-cover:hover .play-circle {
  transform: scale(1.08);
  background: var(--brand-dark);
}

.player-caption {
  padding: 24px;
}

.player-caption h1 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.2;
}

.player-caption p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.detail-side {
  padding: 18px;
}

.detail-cover {
  width: 100%;
  height: 420px;
  border-radius: 20px;
  object-fit: cover;
}

.detail-facts {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.detail-facts div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #f1f5f9;
}

.detail-facts span {
  color: var(--muted);
}

.detail-facts strong {
  text-align: right;
}

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

.article-card {
  padding: 30px;
}

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

.article-card h2:first-child {
  margin-top: 0;
}

.article-card p {
  color: #334155;
  line-height: 1.9;
  font-size: 17px;
}

.tag-list.large {
  margin-top: 24px;
}

.site-footer {
  margin-top: 48px;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-inner {
  max-width: 1280px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 34px;
  margin: 0 auto;
  padding: 54px 24px 32px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-size: 20px;
  font-weight: 900;
}

.footer-column h2 {
  margin: 0 0 16px;
  color: #fff;
  font-size: 18px;
}

.footer-column p {
  color: #94a3b8;
  line-height: 1.8;
}

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

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 18px 24px 28px;
  text-align: center;
  color: #94a3b8;
  font-size: 14px;
}

@media (max-width: 1100px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

  .menu-button {
    display: inline-flex;
    margin-left: auto;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .hero-poster {
    display: none;
  }

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

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

  .detail-side {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 18px;
  }

  .detail-cover {
    height: 300px;
  }

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

@media (max-width: 760px) {
  .header-inner {
    height: 64px;
    padding: 0 16px;
  }

  .brand-name {
    font-size: 18px;
  }

  .hero,
  .hero-slides,
  .hero-slide {
    min-height: 600px;
  }

  .hero-slide {
    padding: 58px 18px 80px;
  }

  .hero h1,
  .hero h2 {
    font-size: 38px;
  }

  .hero p {
    font-size: 16px;
  }

  .section,
  .category-band {
    padding: 48px 16px;
  }

  .section-heading {
    display: block;
  }

  .section-heading a {
    display: inline-flex;
    margin-top: 14px;
  }

  .movie-grid,
  .compact-grid,
  .catalog-grid,
  .category-grid,
  .category-overview-grid {
    grid-template-columns: 1fr;
  }

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

  .rank-row {
    grid-template-columns: 44px 88px 1fr;
  }

  .rank-row img {
    width: 88px;
    height: 76px;
  }

  .rank-score {
    grid-column: 2 / 4;
    font-size: 16px;
  }

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

  .page-hero {
    min-height: 260px;
    padding: 54px 18px;
  }

  .detail-layout,
  .breadcrumb {
    padding-left: 16px;
    padding-right: 16px;
  }

  .detail-side {
    display: block;
  }

  .detail-cover {
    height: 360px;
  }

  .play-circle {
    width: 68px;
    height: 68px;
    font-size: 28px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    padding: 42px 16px 24px;
  }
}
