:root {
  --orange: #ea580c;
  --orange-dark: #c2410c;
  --red: #dc2626;
  --blue: #2563eb;
  --cyan: #0891b2;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --soft: #f8fafc;
  --card: #ffffff;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
  color: var(--ink);
  background: #f3f4f6;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #ffffff;
  background: linear-gradient(90deg, var(--orange), var(--red));
  box-shadow: 0 8px 30px rgba(185, 28, 28, 0.25);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
}

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

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

.brand-text {
  font-size: 26px;
  letter-spacing: 0.02em;
}

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

.desktop-nav a {
  font-weight: 700;
  color: rgba(255, 255, 255, 0.9);
  transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active {
  color: #ffedd5;
  transform: translateY(-1px);
}

.mobile-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.13);
}

.mobile-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  background: #ffffff;
  border-radius: 99px;
}

.mobile-nav {
  display: none;
  padding: 0 0 16px;
}

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

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

.mobile-nav a {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
}

.hero-slider {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: linear-gradient(135deg, #7c2d12, #991b1b);
}

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

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.52) 48%, rgba(0, 0, 0, 0.16));
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 72px;
  transform: translateX(-50%);
  color: #ffffff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 8px 15px;
  border-radius: 999px;
  color: #ffffff;
  background: var(--red);
  font-size: 14px;
  font-weight: 800;
}

.hero-content h1,
.page-hero h1,
.detail-heading h1 {
  max-width: 820px;
  margin: 0 0 16px;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero-content p,
.page-hero p,
.detail-heading p {
  max-width: 760px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
}

.hero-meta,
.card-meta,
.info-grid,
.rank-info div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-meta span,
.card-meta span,
.rank-info div span {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: rgba(255, 255, 255, 0.92);
  font-size: 13px;
  font-weight: 700;
}

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

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

.primary-button,
.rank-action {
  color: #ffffff;
  background: var(--orange);
  box-shadow: 0 12px 28px rgba(234, 88, 12, 0.35);
}

.primary-button:hover,
.rank-action:hover {
  background: var(--orange-dark);
  transform: translateY(-2px);
}

.ghost-button {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
}

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

.hero-arrow {
  position: absolute;
  top: 50%;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
  font-size: 42px;
  line-height: 1;
  transform: translateY(-50%);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

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

.filter-panel {
  position: relative;
  z-index: 3;
  margin-top: -34px;
}

.filter-inner {
  display: grid;
  grid-template-columns: 1fr 170px 170px auto;
  gap: 12px;
  padding: 18px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.search-field input,
.filter-inner select,
.filter-inner button {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  color: var(--ink);
}

.search-field input {
  padding: 0 16px;
}

.filter-inner select {
  padding: 0 12px;
}

.filter-inner button {
  padding: 0 18px;
  border: 0;
  color: #ffffff;
  background: var(--orange);
  font-weight: 800;
}

.content-section,
.category-overview {
  padding: 64px 0;
}

.white-section {
  background: #ffffff;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 30px;
}

.section-title span {
  width: 10px;
  height: 34px;
  border-radius: 999px;
  background: var(--orange);
}

.section-title h2 {
  flex: 1;
  margin: 0;
  font-size: 32px;
  letter-spacing: -0.03em;
}

.section-title a {
  color: var(--orange);
  font-weight: 800;
}

.light-title h2,
.light-title a {
  color: #ffffff;
}

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

.full-grid {
  align-items: stretch;
}

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.card-media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #111827, #7c2d12);
}

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

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

.duration-badge,
.type-badge {
  position: absolute;
  padding: 4px 8px;
  border-radius: 8px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.duration-badge {
  right: 10px;
  bottom: 10px;
  background: rgba(0, 0, 0, 0.78);
}

.type-badge {
  top: 10px;
  left: 10px;
  background: rgba(234, 88, 12, 0.95);
}

.card-body {
  padding: 18px;
}

.card-title {
  display: block;
  overflow: hidden;
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.card-desc {
  display: -webkit-box;
  min-height: 48px;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--muted);
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta span {
  background: #f3f4f6;
  color: #4b5563;
}

.card-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.card-tags span,
.tag-list span {
  padding: 4px 9px;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-size: 12px;
  font-weight: 800;
}

.blue-rail {
  padding: 56px 0;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
}

.rail-scroll {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  padding-bottom: 10px;
}

.rail-card {
  width: 290px;
  flex: 0 0 auto;
}

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

.category-tile,
.category-card-large {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 150px;
  padding: 22px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #fff7ed, #ffffff);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.category-card-large:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.category-tile strong,
.category-card-large h2 {
  color: var(--orange-dark);
  font-size: 22px;
}

.category-tile span,
.category-card-large p {
  color: #4b5563;
}

.category-card-head h2 {
  margin: 0 0 8px;
}

.category-card-head p {
  margin: 0;
}

.category-card-links {
  display: grid;
  gap: 8px;
  margin-top: auto;
}

.category-card-links a {
  color: #374151;
  font-weight: 700;
}

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

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

.movie-card-horizontal {
  display: grid;
  grid-template-columns: 42% 1fr;
}

.movie-card-horizontal .card-media {
  height: 100%;
  aspect-ratio: auto;
}

.page-hero,
.detail-top {
  padding: 64px 0;
  color: #ffffff;
  background: linear-gradient(90deg, var(--orange), var(--red));
}

.small-hero,
.category-hero,
.rank-hero {
  padding: 82px 0;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 14px;
}

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

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

.rank-row {
  display: grid;
  grid-template-columns: 58px 150px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 16px;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}

.rank-number {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: var(--orange);
  font-size: 20px;
  font-weight: 900;
}

.rank-cover {
  overflow: hidden;
  border-radius: 14px;
  aspect-ratio: 16 / 10;
  background: #111827;
}

.rank-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rank-info a {
  display: inline-block;
  margin-bottom: 7px;
  font-size: 20px;
  font-weight: 900;
}

.rank-info a:hover {
  color: var(--orange);
}

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

.detail-heading {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-end;
}

.detail-main {
  padding: 42px 0 0;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) 360px;
  gap: 28px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000000;
  box-shadow: var(--shadow);
}

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

.play-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 10px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.18));
  transition: opacity 0.2s ease;
}

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

.play-icon {
  display: grid;
  width: 82px;
  height: 82px;
  place-items: center;
  border-radius: 999px;
  background: var(--orange);
  box-shadow: 0 16px 40px rgba(234, 88, 12, 0.4);
  font-size: 32px;
}

.play-cover strong {
  font-size: 20px;
}

.detail-card,
.side-card {
  margin-top: 24px;
  padding: 24px;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}

.detail-card h2,
.side-card h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

.detail-card p {
  margin: 0;
  color: #374151;
  font-size: 17px;
  line-height: 1.85;
}

.detail-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.detail-title-row a {
  color: var(--orange);
  font-weight: 800;
}

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

.info-grid span {
  display: grid;
  gap: 4px;
  padding: 12px;
  border-radius: 14px;
  background: #f9fafb;
  color: #374151;
}

.info-grid strong {
  color: #111827;
}

.quote-card {
  border-left: 5px solid var(--orange);
}

.detail-side {
  min-width: 0;
}

.detail-poster {
  width: 100%;
  overflow: hidden;
  border-radius: 22px;
  background: #111827;
  box-shadow: var(--shadow);
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

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

.related-item {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 12px;
  align-items: center;
}

.related-item img {
  width: 112px;
  height: 70px;
  border-radius: 12px;
  object-fit: cover;
  background: #111827;
}

.related-item strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--ink);
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.related-item:hover strong {
  color: var(--orange);
}

.related-item em {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

.site-footer {
  color: #d1d5db;
  background: #111827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 34px;
  padding: 54px 0;
}

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

.site-footer h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.site-footer p {
  margin: 0;
  color: #cbd5e1;
}

.site-footer ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer a:hover {
  color: #fed7aa;
}

.footer-bottom {
  padding: 18px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #9ca3af;
  text-align: center;
}

[hidden] {
  display: none !important;
}

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

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

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

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

  .side-card {
    margin-top: 0;
  }
}

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

  .mobile-toggle {
    display: block;
  }

  .hero-slider {
    height: 560px;
  }

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

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

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

  .rank-row {
    grid-template-columns: 46px 110px 1fr;
  }

  .rank-action {
    grid-column: 2 / -1;
  }

  .detail-heading {
    display: block;
  }

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

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

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

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

  .hero-slider {
    height: 520px;
  }

  .hero-content {
    bottom: 70px;
  }

  .hero-content h1,
  .page-hero h1,
  .detail-heading h1 {
    font-size: 34px;
  }

  .hero-arrow {
    display: none;
  }

  .movie-grid,
  .horizontal-grid,
  .category-tile-grid,
  .category-large-grid,
  .footer-grid,
  .info-grid {
    grid-template-columns: 1fr;
  }

  .rank-row {
    grid-template-columns: 42px 92px 1fr;
    gap: 12px;
  }

  .rank-info p {
    display: none;
  }

  .related-item {
    grid-template-columns: 96px 1fr;
  }
}