:root {
  color-scheme: light;
}

:root {
  --color-text: #1f2937;
  --color-muted: #6b7280;
  --color-soft: #f9fafb;
  --color-border: #e5e7eb;
  --color-card: #ffffff;
  --color-rose: #e11d48;
  --color-rose-dark: #be123c;
  --color-amber: #f59e0b;
  --shadow-card: 0 10px 25px rgba(15, 23, 42, 0.08);
  --shadow-card-hover: 0 18px 45px rgba(15, 23, 42, 0.16);
  --radius-lg: 18px;
  --radius-md: 12px;
  --wrap: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--color-text);
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 45%, #f9fafb 100%);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(229, 231, 235, 0.9);
  box-shadow: 0 6px 22px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(18px);
}

.site-nav-wrap {
  width: min(var(--wrap), calc(100% - 32px));
  min-height: 66px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #111827;
  font-size: 21px;
  font-weight: 800;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.site-logo:hover {
  color: var(--color-rose);
}

.site-logo-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-rose), var(--color-amber));
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(225, 29, 72, 0.28);
  font-size: 13px;
}

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

.site-nav a {
  color: #374151;
  font-size: 14px;
  font-weight: 700;
  transition: color 0.2s ease;
}

.site-nav a:hover {
  color: var(--color-rose);
}

.mobile-menu-button {
  width: 42px;
  height: 42px;
  display: none;
  border: 0;
  background: #fff1f2;
  border-radius: 12px;
  cursor: pointer;
}

.mobile-menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: var(--color-rose);
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  width: min(var(--wrap), calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 18px;
  border-top: 1px solid var(--color-border);
  flex-wrap: wrap;
}

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

.hero {
  position: relative;
  height: 70vh;
  min-height: 520px;
  overflow: hidden;
  background: linear-gradient(120deg, #7f1d1d, #881337 45%, #92400e);
}

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

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 28%, rgba(225, 29, 72, 0.32), transparent 28%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.76) 0%, rgba(0, 0, 0, 0.58) 42%, rgba(0, 0, 0, 0.16) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(var(--wrap), calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  color: #ffffff;
  max-width: 1180px;
}

.hero-content h1 {
  max-width: 760px;
  margin: 16px 0;
  font-size: clamp(38px, 7vw, 70px);
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.hero-content p {
  max-width: 690px;
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(17px, 2vw, 22px);
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 7px 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-rose), #f43f5e);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

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

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-rose), var(--color-rose-dark));
  box-shadow: 0 14px 28px rgba(225, 29, 72, 0.34);
}

.primary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
}

.ghost-button {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
}

.ghost-button.dark {
  color: var(--color-rose);
  border-color: rgba(225, 29, 72, 0.22);
  background: #fff1f2;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 2;
  width: 48px;
  height: 48px;
  border: 0;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  cursor: pointer;
  transform: translateY(-50%);
  font-size: 32px;
  line-height: 1;
  transition: background 0.2s ease;
}

.hero-control:hover {
  background: rgba(255, 255, 255, 0.34);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

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

.section {
  padding: 72px 0;
}

.section-soft {
  background: linear-gradient(90deg, #fff7ed, #fff1f2);
}

.section-rose {
  background: linear-gradient(135deg, #ffe4e6, #fffbeb, #fdf2f8);
}

.section-gray {
  background: #f9fafb;
}

.section-heading {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 36px);
  line-height: 1.2;
}

.section-heading p {
  margin: 6px 0 0;
  color: var(--color-muted);
}

.section-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: var(--color-rose);
  background: #fff1f2;
  border-radius: 14px;
  font-size: 23px;
}

.cards-grid {
  display: grid;
  gap: 24px;
}

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

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

.cards-grid-six {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px;
}

.movie-card {
  overflow: hidden;
  background: var(--color-card);
  border: 1px solid rgba(229, 231, 235, 0.82);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(225, 29, 72, 0.28);
  box-shadow: var(--shadow-card-hover);
}

.movie-card-cover {
  position: relative;
  display: block;
  height: 210px;
  overflow: hidden;
  background: #e5e7eb;
}

.movie-card-large .movie-card-cover {
  height: 270px;
}

.movie-card-compact .movie-card-cover {
  height: 160px;
}

.movie-card-cover::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 55%;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.62), transparent);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .movie-card-cover::after {
  opacity: 1;
}

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

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

.corner-pill,
.rank-badge {
  position: absolute;
  z-index: 1;
  top: 10px;
  padding: 5px 10px;
  color: #ffffff;
  background: rgba(225, 29, 72, 0.95);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.corner-pill {
  right: 10px;
}

.rank-badge {
  left: 10px;
  background: rgba(17, 24, 39, 0.82);
}

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

.movie-card-body h3 {
  margin: 0 0 9px;
  color: #111827;
  font-size: 18px;
  line-height: 1.32;
}

.movie-card-body h3 a:hover {
  color: var(--color-rose);
}

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

.movie-meta-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--color-muted);
  border-top: 1px solid #f3f4f6;
  padding-top: 12px;
  font-size: 12px;
}

.tag-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.tag-row span {
  display: inline-flex;
  padding: 4px 8px;
  color: var(--color-rose);
  background: #fff1f2;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.scroll-row {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  padding: 4px 0 20px;
  scroll-snap-type: x mandatory;
}

.scroll-row .movie-card {
  flex: 0 0 286px;
  scroll-snap-align: start;
}

.category-preview-list {
  display: grid;
  gap: 36px;
}

.category-preview {
  padding: 28px;
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.88);
  border-radius: 24px;
  box-shadow: var(--shadow-card);
}

.category-preview-head,
.overview-card-head {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-start;
  margin-bottom: 22px;
}

.category-preview-head h3,
.overview-card h2 {
  margin: 0 0 8px;
  font-size: 24px;
}

.category-preview-head p,
.overview-card p {
  margin: 0;
  color: var(--color-muted);
}

.category-preview-head a {
  color: var(--color-rose);
  font-weight: 800;
  white-space: nowrap;
}

.ranking-list {
  display: grid;
  gap: 10px;
  max-width: 760px;
}

.compact-movie-link {
  display: grid;
  grid-template-columns: 58px 1fr auto;
  align-items: center;
  gap: 14px;
  min-height: 54px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(225, 29, 72, 0.13);
  border-radius: 14px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.compact-movie-link:hover {
  transform: translateX(4px);
  background: #ffffff;
}

.mini-rank {
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-rose), var(--color-amber));
  border-radius: 999px;
  padding: 5px 8px;
  text-align: center;
  font-size: 12px;
  font-weight: 900;
}

.compact-title {
  font-weight: 800;
}

.compact-meta {
  color: var(--color-muted);
  font-size: 13px;
}

.section-more {
  margin-top: 28px;
}

.filter-panel,
.search-panel {
  margin-bottom: 28px;
  padding: 22px;
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: 18px;
  box-shadow: var(--shadow-card);
}

.filter-label,
.search-panel label {
  display: block;
  margin-bottom: 10px;
  font-weight: 900;
}

.filter-input,
.site-search-input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid var(--color-border);
  border-radius: 13px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.filter-input:focus,
.site-search-input:focus {
  border-color: var(--color-rose);
  box-shadow: 0 0 0 4px rgba(225, 29, 72, 0.1);
}

.filter-count,
.search-panel p {
  display: block;
  margin-top: 10px;
  color: var(--color-muted);
  font-size: 14px;
}

.page-hero {
  position: relative;
  overflow: hidden;
  padding: 92px 0;
  color: #ffffff;
  background:
    radial-gradient(circle at 18% 18%, rgba(251, 191, 36, 0.28), transparent 25%),
    linear-gradient(135deg, #881337, #9f1239 42%, #92400e);
}

.page-hero h1 {
  max-width: 840px;
  margin: 18px 0 14px;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 800px;
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 18px;
}

.small-hero {
  padding: 70px 0;
}

.overview-list {
  display: grid;
  gap: 28px;
}

.overview-card,
.prose-card,
.side-card {
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: 24px;
  box-shadow: var(--shadow-card);
}

.overview-card {
  padding: 28px;
}

.overview-count {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--color-rose);
  font-size: 13px;
  font-weight: 900;
}

.breadcrumb {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 24px 0;
  color: var(--color-muted);
  font-size: 14px;
}

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

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

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

.detail-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(18px) saturate(1.08);
  transform: scale(1.12);
  opacity: 0.38;
}

.detail-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 22% 32%, rgba(225, 29, 72, 0.36), transparent 28%),
    linear-gradient(90deg, rgba(17, 24, 39, 0.94), rgba(17, 24, 39, 0.72));
}

.detail-hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 42px;
  align-items: center;
  padding: 70px 0;
}

.detail-poster {
  overflow: hidden;
  border: 6px solid rgba(255, 255, 255, 0.16);
  border-radius: 26px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.4);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.detail-info h1 {
  margin: 18px 0;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.detail-one-line {
  max-width: 760px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 19px;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  max-width: 720px;
  margin-bottom: 20px;
}

.detail-meta-grid span {
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 12px;
  backdrop-filter: blur(10px);
}

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

.player-shell {
  position: relative;
  overflow: hidden;
  background: #020617;
  border-radius: 24px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.22);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 10px;
  color: #ffffff;
  border: 0;
  background:
    radial-gradient(circle, rgba(225, 29, 72, 0.25), transparent 24%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.78));
  cursor: pointer;
}

.player-overlay.is-hidden {
  display: none;
}

.play-icon {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-rose), var(--color-amber));
  border-radius: 999px;
  box-shadow: 0 18px 38px rgba(225, 29, 72, 0.42);
  font-size: 28px;
}

.source-list {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.source-button {
  min-height: 42px;
  padding: 0 18px;
  color: #374151;
  background: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  cursor: pointer;
  font-weight: 800;
}

.source-button.is-active,
.source-button:hover {
  color: #ffffff;
  background: var(--color-rose);
  border-color: var(--color-rose);
}

.detail-layout {
  display: grid;
  grid-template-columns: 1fr 330px;
  gap: 28px;
}

.prose-card,
.side-card {
  padding: 30px;
}

.prose-card h2 {
  margin: 0 0 14px;
  font-size: 25px;
}

.prose-card p {
  margin: 0 0 24px;
  color: #4b5563;
  font-size: 16px;
}

.side-card h2 {
  margin: 0 0 16px;
}

.side-card dl {
  margin: 0;
}

.side-card div {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #f3f4f6;
}

.side-card dt {
  color: var(--color-muted);
  font-weight: 700;
}

.side-card dd {
  margin: 0;
  font-weight: 800;
}

.side-card a {
  color: var(--color-rose);
}

.hidden-by-filter {
  display: none !important;
}

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

  .mobile-menu-button {
    display: block;
  }

  .cards-grid-four,
  .cards-grid-three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

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

@media (max-width: 720px) {
  .wrap,
  .site-nav-wrap,
  .mobile-nav {
    width: min(100% - 24px, var(--wrap));
  }

  .site-logo {
    font-size: 18px;
  }

  .hero {
    min-height: 560px;
  }

  .hero-content {
    width: min(100% - 28px, var(--wrap));
  }

  .hero-control {
    display: none;
  }

  .section {
    padding: 50px 0;
  }

  .cards-grid-four,
  .cards-grid-three,
  .cards-grid-six {
    grid-template-columns: 1fr;
  }

  .movie-card-cover,
  .movie-card-large .movie-card-cover,
  .movie-card-compact .movie-card-cover {
    height: 230px;
  }

  .category-preview-head,
  .overview-card-head {
    flex-direction: column;
  }

  .compact-movie-link {
    grid-template-columns: 48px 1fr;
  }

  .compact-meta {
    grid-column: 2;
  }

  .page-hero {
    padding: 64px 0;
  }

  .detail-hero-inner {
    padding: 46px 0;
  }

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

  .prose-card,
  .side-card,
  .overview-card,
  .category-preview,
  .filter-panel,
  .search-panel {
    padding: 22px;
  }
}
