:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: #0f172a;
  --panel-soft: #111827;
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --subtle: #64748b;
  --amber: #f59e0b;
  --amber-light: #fbbf24;
  --orange: #ea580c;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.38);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 10% 0%, rgba(245, 158, 11, 0.14), transparent 32rem),
    radial-gradient(circle at 90% 20%, rgba(234, 88, 12, 0.12), transparent 30rem),
    var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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;
  border-bottom: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.86);
  backdrop-filter: blur(18px);
}

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

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  color: #fff;
  box-shadow: 0 12px 32px rgba(245, 158, 11, 0.32);
}

.brand-text,
.footer-brand {
  font-size: 22px;
  background: linear-gradient(90deg, var(--amber-light), var(--orange));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav-link,
.mobile-link {
  color: #cbd5e1;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

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

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--amber-light);
  background: rgba(255, 255, 255, 0.08);
}

.header-search {
  width: 220px;
}

.header-search input,
.mobile-search input,
.filter-input,
.search-band-form input,
.filter-selects select {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  outline: none;
  color: var(--text);
  background: rgba(15, 23, 42, 0.92);
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.header-search input,
.mobile-search input {
  padding: 10px 16px;
}

.header-search input:focus,
.mobile-search input:focus,
.filter-input:focus,
.search-band-form input:focus,
.filter-selects select:focus {
  border-color: rgba(245, 158, 11, 0.8);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  border: 0;
  border-radius: 12px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.mobile-toggle span {
  width: 20px;
  height: 2px;
  background: var(--amber-light);
  border-radius: 99px;
}

.mobile-panel {
  display: none;
  padding: 14px 24px 22px;
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.96);
}

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

.mobile-link {
  display: block;
  padding: 12px 16px;
  margin-bottom: 6px;
}

.hero {
  position: relative;
  height: min(760px, 72vh);
  min-height: 540px;
  overflow: hidden;
  background: #020617;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}

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

.hero-slide > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.72) 38%, rgba(2, 6, 23, 0.22) 100%),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.18) 46%, rgba(2, 6, 23, 0.64) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 680px;
  padding-top: 46px;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 12px;
  padding: 6px 12px;
  border: 1px solid rgba(245, 158, 11, 0.34);
  border-radius: 999px;
  color: var(--amber-light);
  background: rgba(245, 158, 11, 0.12);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero p,
.page-hero p,
.detail-one-line {
  max-width: 760px;
  margin: 24px 0 0;
  color: #cbd5e1;
  font-size: clamp(17px, 2vw, 21px);
}

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

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

.hero-tags span,
.tag-row span,
.detail-meta span {
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(15, 23, 42, 0.72);
}

.hero-tags span,
.detail-meta span {
  padding: 7px 13px;
}

.tag-row span {
  padding: 4px 9px;
  font-size: 12px;
}

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

.primary-btn,
.ghost-btn,
.search-band-form button,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border 0.2s ease, color 0.2s ease;
}

.primary-btn,
.search-band-form button {
  border: 0;
  color: #fff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 16px 36px rgba(245, 158, 11, 0.25);
}

.ghost-btn,
.text-link {
  border: 1px solid rgba(245, 158, 11, 0.28);
  color: var(--amber-light);
  background: rgba(255, 255, 255, 0.06);
}

.primary-btn:hover,
.ghost-btn:hover,
.search-band-form button:hover,
.text-link:hover {
  transform: translateY(-2px);
}

.hero-dots {
  position: absolute;
  right: 6vw;
  bottom: 44px;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

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

.home-search-band,
.content-section,
.page-hero,
.detail-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.home-search-band {
  margin-top: -58px;
  position: relative;
  z-index: 2;
}

.home-search-card {
  padding: 28px;
  border: 1px solid rgba(245, 158, 11, 0.24);
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 41, 59, 0.88));
  box-shadow: var(--shadow);
}

.home-search-card h2 {
  margin: 0;
  font-size: 28px;
}

.home-search-card p {
  margin: 8px 0 18px;
  color: var(--muted);
}

.search-band-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
}

.search-band-form input {
  min-height: 50px;
  padding: 0 18px;
}

.content-section {
  padding-top: 74px;
  padding-bottom: 12px;
}

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

.section-head h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 40px);
  letter-spacing: -0.04em;
}

.section-head a {
  color: var(--amber-light);
  font-weight: 700;
}

.movie-grid {
  display: grid;
  gap: 22px;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.88);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.24);
  transition: transform 0.24s ease, border 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(245, 158, 11, 0.42);
  box-shadow: 0 22px 52px rgba(0, 0, 0, 0.36);
}

.movie-poster {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0f172a;
}

.movie-poster img,
.category-tile img,
.category-cover img,
.compact-link img,
.detail-backdrop,
.detail-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.movie-poster img {
  transition: transform 0.45s ease;
}

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

.poster-shade,
.category-overlay,
.category-cover span {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.9), transparent 66%);
}

.poster-play {
  position: absolute;
  left: 16px;
  bottom: 16px;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  background: rgba(245, 158, 11, 0.92);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.34);
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  min-width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  font-weight: 900;
  box-shadow: 0 10px 24px rgba(245, 158, 11, 0.28);
}

.movie-body {
  padding: 17px;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--subtle);
  font-size: 13px;
}

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

.movie-body h3 a:hover {
  color: var(--amber-light);
}

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

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

.category-tile {
  position: relative;
  min-height: 160px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: var(--panel);
}

.category-tile img {
  position: absolute;
  inset: 0;
  transition: transform 0.45s ease;
}

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

.category-tile strong,
.category-tile small {
  position: absolute;
  left: 18px;
  right: 18px;
  z-index: 2;
}

.category-tile strong {
  bottom: 42px;
  font-size: 22px;
}

.category-tile small {
  bottom: 18px;
  color: #cbd5e1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.page-hero {
  padding-top: 76px;
  padding-bottom: 56px;
}

.slim-hero,
.category-hero,
.search-hero,
.ranking-hero {
  min-height: 320px;
  display: flex;
  align-items: center;
}

.page-hero > div {
  max-width: 840px;
}

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

.category-card-large {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius-xl);
  background: rgba(15, 23, 42, 0.86);
}

.category-cover {
  position: relative;
  display: block;
  height: 240px;
  overflow: hidden;
}

.category-info {
  padding: 24px;
}

.category-info h2 {
  margin: 0 0 10px;
  font-size: 28px;
}

.category-info p {
  margin: 0 0 18px;
  color: var(--muted);
}

.compact-list {
  display: grid;
  gap: 10px;
  margin-bottom: 20px;
}

.compact-link {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 12px;
  align-items: center;
  padding: 8px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 14px;
  background: rgba(2, 6, 23, 0.36);
}

.compact-link img {
  aspect-ratio: 16 / 10;
  border-radius: 10px;
}

.compact-link strong {
  display: block;
  line-height: 1.25;
}

.compact-link small {
  display: block;
  margin-top: 4px;
  color: var(--subtle);
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 14px;
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.74);
}

.filter-input {
  min-height: 48px;
  padding: 0 18px;
}

.filter-selects {
  display: flex;
  gap: 10px;
}

.filter-selects select {
  min-height: 48px;
  min-width: 140px;
  padding: 0 16px;
}

.empty-state {
  display: none;
  margin-top: 30px;
  padding: 42px;
  border: 1px dashed rgba(148, 163, 184, 0.24);
  border-radius: var(--radius-lg);
  color: var(--muted);
  text-align: center;
}

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

.detail-top {
  position: relative;
  overflow: hidden;
  min-height: 660px;
  padding: 70px 0 90px;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0.34;
  filter: blur(1px);
}

.detail-mask {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.74), rgba(2, 6, 23, 0.92)),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.1) 60%, rgba(2, 6, 23, 0.94) 100%);
}

.detail-inner {
  position: relative;
  z-index: 2;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
  margin-bottom: 32px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--amber-light);
}

.detail-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 42px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  aspect-ratio: 3 / 4;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(245, 158, 11, 0.22);
  box-shadow: var(--shadow);
}

.detail-copy {
  max-width: 780px;
}

.detail-meta {
  margin-top: 24px;
}

.detail-tags {
  margin-bottom: 30px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(245, 158, 11, 0.24);
  background: #000;
  box-shadow: var(--shadow);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #fff;
  background:
    radial-gradient(circle, rgba(245, 158, 11, 0.18), rgba(2, 6, 23, 0.62)),
    rgba(0, 0, 0, 0.24);
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.play-ring {
  width: 92px;
  height: 92px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 20px 48px rgba(245, 158, 11, 0.36);
  font-size: 34px;
}

.article-section {
  padding-top: 42px;
}

.detail-article {
  padding: 34px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius-xl);
  background: rgba(15, 23, 42, 0.8);
}

.detail-article h2 {
  margin: 0 0 14px;
  font-size: 28px;
}

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

.detail-article p {
  margin: 0;
  color: #cbd5e1;
  font-size: 17px;
}

.site-footer {
  margin-top: 88px;
  border-top: 1px solid rgba(245, 158, 11, 0.18);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.72), #000);
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 42px 24px;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-inner p {
  max-width: 560px;
  margin: 12px 0 0;
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-content: flex-start;
}

.footer-links a {
  color: #cbd5e1;
}

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

@media (max-width: 1100px) {
  .featured-grid,
  .compact-grid,
  .page-grid,
  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

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

  .mobile-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .hero {
    height: 620px;
  }

  .hero-gradient {
    background:
      linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.58) 54%, rgba(2, 6, 23, 0.88) 100%),
      linear-gradient(90deg, rgba(2, 6, 23, 0.86), rgba(2, 6, 23, 0.28));
  }

  .hero-content {
    align-items: end;
    padding-bottom: 82px;
  }

  .hero-copy {
    padding-top: 0;
  }

  .hero-dots {
    left: 24px;
    right: auto;
  }

  .featured-grid,
  .compact-grid,
  .page-grid,
  .category-grid,
  .category-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .filter-selects {
    flex-wrap: wrap;
  }

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

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

  .footer-inner {
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .header-inner,
  .hero-content,
  .home-search-band,
  .content-section,
  .page-hero,
  .detail-inner,
  .footer-inner {
    padding-left: 16px;
    padding-right: 16px;
  }

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

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

  .search-band-form {
    grid-template-columns: 1fr;
  }

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

  .featured-grid,
  .compact-grid,
  .page-grid,
  .category-grid,
  .category-overview {
    grid-template-columns: 1fr;
  }

  .movie-poster {
    aspect-ratio: 16 / 9;
  }

  .category-cover {
    height: 190px;
  }

  .filter-selects select {
    flex: 1 1 100%;
  }

  .detail-top {
    min-height: auto;
    padding-top: 46px;
  }

  .play-ring {
    width: 76px;
    height: 76px;
    font-size: 28px;
  }
}
