:root {
  color-scheme: light;
  --bg: #f8fafc;
  --panel: #ffffff;
  --ink: #111827;
  --muted: #6b7280;
  --soft: #f3f4f6;
  --line: #e5e7eb;
  --red: #dc2626;
  --orange: #f97316;
  --amber: #f59e0b;
  --radius: 22px;
  --shadow: 0 18px 55px rgba(17, 24, 39, 0.11);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

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

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

.header-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 210px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--red), var(--orange), var(--amber));
  box-shadow: 0 14px 32px rgba(220, 38, 38, 0.28);
}

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

.brand-copy strong {
  font-size: 21px;
  letter-spacing: -0.03em;
  background: linear-gradient(90deg, var(--red), var(--orange), var(--amber));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

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

.nav-link {
  padding: 10px 16px;
  border-radius: 14px;
  font-weight: 650;
  color: #374151;
  transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.nav-link:hover {
  color: var(--red);
  background: #fff1f2;
  transform: translateY(-1px);
}

.nav-link.active {
  color: #ffffff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  box-shadow: 0 10px 22px rgba(220, 38, 38, 0.22);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: #fff1f2;
  padding: 11px;
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--red);
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

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

.mobile-nav a:hover {
  background: #fff7ed;
  color: var(--red);
}

.mobile-nav.open {
  display: block;
}

.hero-section {
  position: relative;
  min-height: 650px;
  overflow: hidden;
  background: #111827;
  color: #ffffff;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.7s ease;
}

.hero-slide.active {
  opacity: 1;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.35;
  transform: scale(1.05);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 70% 20%, rgba(249, 115, 22, 0.35), transparent 30%),
    linear-gradient(110deg, rgba(17, 24, 39, 0.98), rgba(127, 29, 29, 0.78) 50%, rgba(17, 24, 39, 0.72));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: 650px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) 390px;
  gap: 46px;
  align-items: center;
  padding: 58px 0;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  width: max-content;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
  font-size: 13px;
  font-weight: 700;
}

.hero-title {
  max-width: 760px;
  margin: 18px 0 14px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.hero-desc {
  max-width: 720px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
}

.hero-meta,
.detail-meta,
.card-tags,
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #fff7ed;
  color: #b45309;
  font-size: 12px;
  font-weight: 700;
}

.hero-section .chip {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 18px;
  border-radius: 15px;
  border: 0;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn.primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  box-shadow: 0 16px 38px rgba(220, 38, 38, 0.32);
}

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

.btn.light {
  color: var(--red);
  background: #ffffff;
  border: 1px solid #fee2e2;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(17, 24, 39, 0.18);
}

.hero-panel {
  padding: 20px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(18px);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.25);
}

.hero-panel img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 22px;
  background: linear-gradient(135deg, #7f1d1d, #f97316);
}

.hero-panel h2,
.hero-panel h3 {
  margin: 18px 0 4px;
  font-size: 22px;
}

.hero-panel p {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
}

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

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

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

.page-hero {
  padding: 70px 0 36px;
  background:
    radial-gradient(circle at top right, rgba(249, 115, 22, 0.16), transparent 28%),
    linear-gradient(180deg, #ffffff, #f8fafc);
}

.page-hero h1,
.section-head h2 {
  margin: 0;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.page-hero p,
.section-head p {
  max-width: 760px;
  margin: 12px 0 0;
  color: var(--muted);
}

.section {
  padding: 54px 0;
}

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

.section-head .section-kicker {
  color: var(--red);
  background: #fff1f2;
  border-color: #fecaca;
}

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

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

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

.movie-card,
.category-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid rgba(229, 231, 235, 0.86);
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.06);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover,
.category-card:hover {
  transform: translateY(-6px);
  border-color: #fed7aa;
  box-shadow: var(--shadow);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, #7f1d1d, #f97316);
}

.poster-link img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.play-dot {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(220, 38, 38, 0.92);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.25);
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--red), var(--amber));
  font-weight: 900;
}

.card-body {
  padding: 15px;
}

.card-title {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-weight: 850;
  font-size: 16px;
}

.card-title:hover {
  color: var(--red);
}

.card-meta,
.card-desc {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.card-desc {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 43px;
}

.card-tags {
  margin-top: 12px;
}

.category-card {
  min-height: 180px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    radial-gradient(circle at top right, rgba(249, 115, 22, 0.18), transparent 42%),
    #ffffff;
}

.category-card strong {
  font-size: 22px;
}

.category-card p {
  color: var(--muted);
  margin: 10px 0 18px;
  font-size: 14px;
}

.category-card span {
  color: var(--red);
  font-weight: 800;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 170px 190px;
  gap: 14px;
  padding: 18px;
  margin: 0 0 26px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 14px 32px rgba(17, 24, 39, 0.06);
}

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

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: #f9fafb;
  color: #111827;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #fb923c;
  box-shadow: 0 0 0 4px rgba(251, 146, 60, 0.16);
}

.empty-state {
  display: none;
  margin: 28px 0;
  padding: 18px;
  text-align: center;
  border-radius: 18px;
  color: var(--muted);
  background: #ffffff;
  border: 1px dashed #fed7aa;
}

.empty-state.show {
  display: block;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 54px 72px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 20px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 10px 25px rgba(17, 24, 39, 0.05);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.rank-row:hover {
  transform: translateY(-3px);
  border-color: #fed7aa;
  box-shadow: var(--shadow);
}

.rank-num {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  font-weight: 900;
}

.rank-row img {
  width: 72px;
  height: 96px;
  object-fit: cover;
  border-radius: 14px;
  background: linear-gradient(135deg, #7f1d1d, #f97316);
}

.rank-info {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.rank-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-info em {
  font-style: normal;
  color: var(--muted);
  font-size: 13px;
}

.rank-arrow {
  color: var(--red);
  font-size: 28px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 18px;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) 370px;
  gap: 28px;
  align-items: start;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #030712;
  box-shadow: 0 24px 60px rgba(3, 7, 18, 0.32);
}

.player-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
  cursor: pointer;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(3, 7, 18, 0.25), rgba(3, 7, 18, 0.72));
  transition: opacity 0.24s ease, visibility 0.24s ease;
}

.player-shell.playing .player-cover {
  opacity: 0;
  visibility: hidden;
}

.player-button {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  box-shadow: 0 18px 42px rgba(220, 38, 38, 0.34);
  font-size: 34px;
}

.player-message {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  color: rgba(255, 255, 255, 0.86);
  text-align: center;
  font-size: 14px;
}

.detail-card {
  padding: 24px;
  border-radius: 28px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.detail-card h1 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.detail-card .lead {
  margin: 16px 0 0;
  color: #4b5563;
  font-size: 17px;
}

.content-block {
  margin-top: 24px;
  padding: 24px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid var(--line);
}

.content-block h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.content-block p {
  margin: 0;
  color: #374151;
}

.side-panel {
  display: grid;
  gap: 18px;
}

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

.side-card h2,
.side-card h3 {
  margin: 0 0 14px;
  font-size: 20px;
}

.side-card img {
  width: 100%;
  border-radius: 18px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: linear-gradient(135deg, #7f1d1d, #f97316);
}

.mini-list {
  display: grid;
  gap: 12px;
}

.mini-item {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.mini-item img {
  width: 58px;
  height: 76px;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, #7f1d1d, #f97316);
}

.mini-item strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
}

.mini-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.site-footer {
  margin-top: 56px;
  padding: 42px 0;
  background: #111827;
  color: #ffffff;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
}

.site-footer p,
.site-footer a,
.copyright {
  color: rgba(255, 255, 255, 0.72);
}

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

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

.hidden-card {
  display: none !important;
}

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

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

  .hero-panel {
    max-width: 420px;
  }
}

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

  .menu-toggle {
    display: block;
  }

  .header-inner {
    height: 68px;
  }

  .hero-section,
  .hero-content {
    min-height: 620px;
  }

  .hero-content {
    padding-top: 42px;
    gap: 28px;
  }

  .hero-panel {
    display: none;
  }

  .section-head {
    display: grid;
  }

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

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

  .detail-card,
  .content-block {
    padding: 18px;
    border-radius: 22px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .container,
  .header-inner,
  .hero-content,
  .mobile-nav {
    width: min(100% - 24px, 1180px);
  }

  .brand-copy em {
    display: none;
  }

  .brand-copy strong {
    font-size: 18px;
  }

  .movie-grid,
  .category-grid {
    gap: 14px;
  }

  .card-body {
    padding: 12px;
  }

  .card-desc {
    display: none;
  }

  .rank-row {
    grid-template-columns: 42px 58px minmax(0, 1fr) 18px;
    gap: 10px;
  }

  .rank-row img {
    width: 58px;
    height: 78px;
  }
}
