:root {
  color-scheme: dark;
  --bg: #050505;
  --bg-soft: #0b0f17;
  --panel: rgba(17, 24, 39, 0.82);
  --panel-solid: #111827;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f9fafb;
  --muted: #9ca3af;
  --orange: #f97316;
  --red: #dc2626;
  --gold: #fbbf24;
  --green: #10b981;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: radial-gradient(circle at 10% 0%, rgba(249, 115, 22, 0.2), transparent 30%), var(--bg);
  color: var(--text);
  line-height: 1.6;
}

body.nav-open {
  overflow: hidden;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid var(--line);
  background: rgba(5, 5, 5, 0.86);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: 0 12px 32px rgba(249, 115, 22, 0.32);
}

.brand-text {
  font-size: 21px;
  background: linear-gradient(90deg, #fb923c, #ef4444);
  -webkit-background-clip: text;
  color: transparent;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  padding: 10px 16px;
  color: #d1d5db;
  border-radius: 12px;
  font-size: 14px;
  transition: 0.22s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
  background: linear-gradient(135deg, var(--orange), var(--red));
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: #1f2937;
  font-size: 22px;
}

.hero-carousel {
  position: relative;
  min-height: 720px;
  overflow: hidden;
  background: #050505;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.75s ease, transform 1.1s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(4px) saturate(1.1);
  opacity: 0.42;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.54), rgba(0, 0, 0, 0.88)), linear-gradient(0deg, #050505 0%, transparent 35%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 640px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 72px;
  align-items: center;
  padding-top: 64px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--orange);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 13px;
}

.hero-copy h1,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  font-size: clamp(42px, 8vw, 92px);
  line-height: 0.95;
  letter-spacing: -0.07em;
}

.hero-desc {
  width: min(700px, 100%);
  color: #e5e7eb;
  font-size: 19px;
  margin: 24px 0 18px;
}

.hero-tags,
.tag-row,
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.hero-tags span,
.tag-row span,
.tag-cloud span {
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #e5e7eb;
  background: rgba(255, 255, 255, 0.06);
  font-size: 13px;
}

.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: 14px;
  font-weight: 800;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

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

.btn.primary {
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: 0 16px 42px rgba(249, 115, 22, 0.32);
}

.btn.ghost {
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(17, 24, 39, 0.66);
}

.hero-poster {
  position: relative;
  display: block;
  border-radius: 28px;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.18), rgba(220, 38, 38, 0.16));
  box-shadow: var(--shadow);
  transform: rotate(2deg);
}

.hero-poster img,
.poster img,
.category-tile img,
.category-cover img,
.rank-poster img,
.detail-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-poster span {
  position: absolute;
  right: 14px;
  bottom: 14px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.72);
  color: var(--gold);
  font-weight: 900;
}

.hero-control {
  position: relative;
  z-index: 5;
  margin-top: -82px;
}

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

.hero-dot {
  display: grid;
  grid-template-columns: 48px 1fr;
  align-items: center;
  gap: 10px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 8px;
  color: #fff;
  text-align: left;
  background: rgba(17, 24, 39, 0.7);
  backdrop-filter: blur(14px);
  cursor: pointer;
}

.hero-dot.active {
  border-color: rgba(249, 115, 22, 0.9);
  box-shadow: 0 12px 35px rgba(249, 115, 22, 0.18);
}

.hero-dot img {
  width: 48px;
  height: 64px;
  object-fit: cover;
  border-radius: 10px;
}

.hero-dot span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 800;
}

.home-search {
  margin-top: -1px;
  background: linear-gradient(180deg, #050505, #0b0f17);
  padding: 34px 0;
}

.search-panel {
  display: grid;
  grid-template-columns: 1fr minmax(300px, 520px);
  gap: 28px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 26px;
  background: rgba(17, 24, 39, 0.72);
  box-shadow: var(--shadow);
}

.search-panel h2 {
  margin: 0;
  font-size: clamp(24px, 4vw, 40px);
  letter-spacing: -0.05em;
}

.quick-search,
.search-form {
  display: flex;
  gap: 10px;
}

.quick-search input,
.search-form input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 15px 16px;
  color: #fff;
  background: rgba(5, 5, 5, 0.54);
  outline: none;
}

.quick-search button,
.search-form button {
  border: 0;
  border-radius: 16px;
  padding: 0 22px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--orange), var(--red));
  cursor: pointer;
}

.section {
  padding: 70px 0;
}

.alt-section {
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.62), rgba(5, 5, 5, 0.1));
}

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

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

.section-head p:not(.eyebrow) {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--orange);
  font-weight: 900;
}

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

.movie-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 220px;
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 12px;
  scrollbar-width: thin;
}

.movie-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  background: rgba(17, 24, 39, 0.74);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.26);
  transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(249, 115, 22, 0.54);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
}

.poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.18), rgba(220, 38, 38, 0.12));
}

.score {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 8px;
  border-radius: 999px;
  color: #111827;
  background: var(--gold);
  font-weight: 900;
  font-size: 12px;
}

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

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

.movie-card h3 a:hover,
.rank-main h3 a:hover,
.category-card h2 a:hover {
  color: #fb923c;
}

.movie-meta {
  margin: 8px 0;
  color: var(--muted);
  font-size: 13px;
}

.movie-desc {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 12px;
  overflow: hidden;
  color: #d1d5db;
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.compact-card .movie-card-body {
  padding: 14px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 82px 52px 1fr auto;
  gap: 18px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 12px;
  background: rgba(17, 24, 39, 0.74);
}

.rank-poster {
  display: block;
  height: 116px;
  border-radius: 14px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.06);
}

.rank-no {
  color: transparent;
  font-size: 34px;
  font-weight: 1000;
  -webkit-text-stroke: 1px rgba(249, 115, 22, 0.86);
}

.rank-main h3 {
  margin: 0;
  font-size: 20px;
}

.rank-main p {
  margin: 5px 0;
  color: var(--muted);
}

.rank-score {
  min-width: 104px;
  text-align: right;
}

.rank-score strong {
  display: block;
  color: var(--gold);
  font-size: 26px;
}

.rank-score span {
  color: var(--muted);
  font-size: 12px;
}

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

.category-tile {
  position: relative;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  border-radius: 24px;
  padding: 18px;
  isolation: isolate;
}

.category-tile img {
  position: absolute;
  inset: 0;
  z-index: -2;
  opacity: 0.58;
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.1));
}

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

.category-tile small,
.category-tile em {
  color: #d1d5db;
  font-style: normal;
}

.category-tile em {
  display: -webkit-box;
  margin-top: 8px;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.page-hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(circle at 20% 20%, rgba(249, 115, 22, 0.28), transparent 32%), linear-gradient(135deg, #050505, #111827);
}

.small-hero {
  padding: 84px 0 62px;
}

.page-hero h1 {
  margin-bottom: 16px;
}

.page-hero p:not(.eyebrow) {
  width: min(820px, 100%);
  margin: 0;
  color: #d1d5db;
  font-size: 18px;
}

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

.category-card {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 14px;
  background: rgba(17, 24, 39, 0.74);
}

.category-cover {
  height: 210px;
  border-radius: 18px;
  overflow: hidden;
}

.category-card h2 {
  margin: 2px 0 8px;
  font-size: 25px;
}

.category-card p {
  color: var(--muted);
}

.category-count {
  display: inline-flex;
  margin-bottom: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--gold);
  background: rgba(251, 191, 36, 0.12);
  font-weight: 900;
}

.mini-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mini-links a {
  padding: 6px 10px;
  border-radius: 999px;
  color: #e5e7eb;
  background: rgba(255, 255, 255, 0.07);
  font-size: 13px;
}

.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
  padding: 15px 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(17, 24, 39, 0.66);
  color: #d1d5db;
}

.filter-bar a {
  color: var(--orange);
  font-weight: 900;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  min-height: 560px;
  background: #050505;
}

.detail-bg {
  position: absolute;
  inset: 0;
}

.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.32;
  filter: blur(3px);
}

.detail-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.93), rgba(0, 0, 0, 0.55)), linear-gradient(0deg, #050505, transparent 35%);
}

.detail-head {
  position: relative;
  z-index: 2;
  padding: 62px 0;
}

.breadcrumb {
  display: inline-flex;
  margin-bottom: 22px;
  color: #fb923c;
  font-weight: 900;
}

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

.detail-cover {
  aspect-ratio: 2 / 3;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: rgba(255, 255, 255, 0.06);
}

.detail-one-line {
  max-width: 820px;
  color: #e5e7eb;
  font-size: 20px;
}

.detail-main-grid,
.detail-text-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 22px;
  align-items: start;
}

.player-card,
.side-panel,
.detail-block {
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(17, 24, 39, 0.78);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.25);
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #000;
  aspect-ratio: 16 / 9;
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #fff;
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
}

.play-overlay span {
  width: 76px;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: 0 18px 45px rgba(249, 115, 22, 0.38);
  font-size: 28px;
}

.play-overlay strong {
  font-size: 18px;
}

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

.side-panel {
  padding: 22px;
}

.side-panel h2,
.detail-block h2 {
  margin: 0 0 14px;
  font-size: 22px;
}

.info-list {
  margin: 0;
}

.info-list div {
  display: grid;
  grid-template-columns: 68px 1fr;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.info-list div:last-child {
  border-bottom: 0;
}

.info-list dt {
  color: var(--muted);
}

.info-list dd {
  margin: 0;
  color: #fff;
}

.info-list a {
  color: #fb923c;
  font-weight: 900;
}

.detail-block {
  padding: 26px;
}

.detail-block p {
  margin: 0;
  color: #e5e7eb;
  font-size: 17px;
  line-height: 1.9;
}

.detail-block + .detail-block {
  margin-top: 18px;
}

.tag-cloud {
  gap: 10px;
}

.search-form {
  width: min(740px, 100%);
  margin-top: 24px;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: #080b10;
  padding: 46px 0 20px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
}

.footer-brand {
  margin-bottom: 14px;
}

.site-footer p,
.site-footer a {
  color: var(--muted);
}

.site-footer h2 {
  margin: 0 0 12px;
  font-size: 17px;
}

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

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 34px auto 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: #6b7280;
  font-size: 13px;
}

@media (max-width: 1000px) {
  .movie-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .hero-content,
  .detail-layout,
  .detail-main-grid,
  .detail-text-grid,
  .search-panel,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-poster,
  .detail-cover {
    width: min(320px, 100%);
  }

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

@media (max-width: 720px) {
  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .site-nav {
    position: fixed;
    inset: 68px 16px auto 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(17, 24, 39, 0.98);
    box-shadow: var(--shadow);
  }

  body.nav-open .site-nav {
    display: flex;
  }

  .hero-carousel {
    min-height: 760px;
  }

  .hero-content {
    min-height: 660px;
    gap: 24px;
    padding-top: 36px;
  }

  .hero-control {
    margin-top: -76px;
  }

  .hero-dots {
    display: flex;
    overflow-x: auto;
  }

  .hero-dot {
    min-width: 210px;
  }

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

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

  .rank-no,
  .rank-score {
    display: none;
  }

  .category-card {
    grid-template-columns: 1fr;
  }

  .category-cover {
    height: 260px;
  }

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

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

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

  .quick-search,
  .search-form {
    flex-direction: column;
  }

  .quick-search button,
  .search-form button {
    min-height: 48px;
  }

  .detail-layout {
    gap: 24px;
  }

  .detail-head {
    padding: 44px 0;
  }
}
