:root {
  --red: #dc2626;
  --red-dark: #b91c1c;
  --orange: #ea580c;
  --green-900: #14532d;
  --green-800: #166534;
  --green-100: #dcfce7;
  --ink: #111827;
  --muted: #6b7280;
  --soft: #fff7ed;
  --line: #e5e7eb;
  --card: #ffffff;
  --shadow: 0 18px 45px rgba(17, 24, 39, 0.12);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #ffffff;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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: 50;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.8);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

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

.brand-text {
  display: grid;
  line-height: 1.2;
}

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

.brand-text small,
.footer-brand small {
  color: var(--muted);
  font-size: 12px;
}

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

.site-nav a {
  padding: 10px 14px;
  color: #374151;
  font-size: 14px;
  font-weight: 700;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

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

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  background: #f3f4f6;
  color: #374151;
  font-size: 22px;
  cursor: pointer;
}

.hero-wrap,
.page-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 48%, #fef2f2 100%);
}

.hero-wrap {
  min-height: 660px;
  display: grid;
  align-items: center;
  padding: 72px 0 48px;
}

.hero-bg {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 999px;
  filter: blur(60px);
  opacity: 0.42;
}

.hero-bg-one {
  left: -120px;
  top: 80px;
  background: #fb923c;
}

.hero-bg-two {
  right: -110px;
  bottom: -60px;
  background: #f87171;
}

.hero-container {
  position: relative;
  z-index: 2;
}

.hero-slide {
  display: none;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.72fr);
  align-items: center;
  gap: 56px;
}

.hero-slide.active {
  display: grid;
  animation: fadeUp 0.55s ease both;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 9px 16px;
  border-radius: 999px;
  color: #374151;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 12px 32px rgba(17, 24, 39, 0.1);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.hero-copy h1,
.page-hero h1 {
  margin: 20px 0 18px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 1.04;
  letter-spacing: -0.05em;
  background: linear-gradient(90deg, var(--red), var(--orange), var(--red));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-copy p,
.page-hero p {
  margin: 0;
  max-width: 760px;
  color: #4b5563;
  font-size: clamp(17px, 2.5vw, 23px);
}

.hero-meta,
.detail-meta,
.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.hero-meta span,
.detail-meta span,
.movie-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 10px;
  border-radius: 999px;
  color: #7f1d1d;
  background: #fee2e2;
  font-size: 13px;
  font-weight: 700;
}

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

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

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

.ghost-btn {
  color: var(--red-dark);
  background: #ffffff;
  border: 2px solid var(--red);
}

.text-btn {
  min-height: 44px;
  color: var(--red-dark);
  background: transparent;
}

.primary-btn:hover,
.ghost-btn:hover,
.text-btn:hover,
.panel-more:hover {
  transform: translateY(-2px);
}

.hero-art {
  position: relative;
  min-height: 440px;
  display: grid;
  place-items: center;
}

.hero-poster {
  width: min(360px, 100%);
  aspect-ratio: 2 / 3;
  border-radius: 32px;
  overflow: hidden;
  background: linear-gradient(135deg, #fee2e2, #ffedd5);
  box-shadow: var(--shadow);
  transform: rotate(2deg);
  transition: transform 0.25s ease;
}

.hero-poster:hover {
  transform: rotate(0deg) translateY(-4px);
}

.hero-poster img,
.poster-link img,
.compact-card img,
.ranking-poster img,
.detail-poster img,
.category-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-dots {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 12px;
}

.hero-dots button {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #fecaca;
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dots button.active {
  width: 34px;
  background: var(--red);
}

.section {
  padding: 84px 0;
}

.section-soft {
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 55%, #fef2f2 100%);
}

.section-heading {
  max-width: 760px;
  margin: 0 auto 42px;
  text-align: center;
}

.section-heading.align-left {
  margin-left: 0;
  text-align: left;
}

.section-heading span,
.panel-title span {
  color: var(--red);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section-heading h2,
.panel-title h2 {
  margin: 8px 0 10px;
  color: #111827;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.12;
}

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

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

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

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

.movie-card {
  overflow: hidden;
  border-radius: 20px;
  background: var(--card);
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.09);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 44px rgba(17, 24, 39, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #fee2e2, #ffedd5);
}

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

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

.poster-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 8px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--red);
  font-size: 12px;
  font-weight: 800;
}

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

.movie-card h3 {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.35;
}

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

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

.movie-tags {
  display: grid;
  gap: 4px;
  margin-top: 10px;
  color: #9ca3af;
  font-size: 12px;
}

.category-chip {
  display: inline-flex;
  margin-top: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--red-dark);
  background: #fff1f2;
  font-size: 12px;
  font-weight: 800;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 36px;
  align-items: start;
}

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

.category-tile,
.category-overview-card a {
  display: grid;
  min-height: 150px;
  padding: 22px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.category-overview-card a:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 42px rgba(17, 24, 39, 0.13);
}

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

.category-tile span,
.category-overview-card p {
  color: var(--muted);
  font-size: 14px;
}

.rank-panel {
  position: sticky;
  top: 96px;
  padding: 26px;
  border-radius: 28px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--green-900), var(--green-800));
  box-shadow: var(--shadow);
}

.rank-panel h2,
.rank-panel .panel-title span {
  color: #ffffff;
}

.rank-panel ol {
  display: grid;
  gap: 12px;
  margin: 20px 0;
  padding: 0;
  list-style: none;
}

.rank-panel li a {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
}

.rank-panel li a:hover {
  background: rgba(255, 255, 255, 0.14);
}

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

.rank-panel strong,
.rank-panel em {
  display: block;
  min-width: 0;
}

.rank-panel em {
  color: var(--green-100);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 12px;
  font-style: normal;
}

.panel-more {
  width: 100%;
  color: var(--green-900);
  background: #ffffff;
}

.search-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 14px;
  margin-bottom: 28px;
}

.search-bar input,
.search-bar select {
  width: 100%;
  min-height: 52px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--ink);
  background: #ffffff;
  font: inherit;
  outline: none;
  box-shadow: 0 8px 24px rgba(17, 24, 39, 0.06);
}

.search-bar input:focus,
.search-bar select:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.1);
}

.compact-hero {
  padding: 86px 0;
}

.compact-hero h1 {
  font-size: clamp(42px, 6vw, 68px);
}

.category-overview-card a {
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 20px;
  min-height: 190px;
}

.category-preview {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  overflow: hidden;
  border-radius: 18px;
  background: #fee2e2;
}

.category-preview img {
  min-height: 86px;
  background: #ffedd5;
}

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

.compact-card {
  position: relative;
  overflow: hidden;
  min-height: 190px;
  border-radius: 20px;
  background: #111827;
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.13);
}

.compact-card img {
  position: absolute;
  inset: 0;
  opacity: 0.78;
  transition: transform 0.35s ease;
}

.compact-card span {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  color: #ffffff;
  font-weight: 900;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
}

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

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

.ranking-item {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  padding: 18px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.08);
}

.ranking-poster {
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 18px;
  background: #fee2e2;
}

.ranking-body h2 {
  margin: 10px 0 8px;
  font-size: 24px;
}

.ranking-body h2 a:hover {
  color: var(--red);
}

.ranking-body p {
  margin: 0;
  color: var(--muted);
}

.detail-hero {
  padding: 72px 0;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 50%, #fef2f2 100%);
}

.detail-layout {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 44px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  aspect-ratio: 2 / 3;
  background: #fee2e2;
  box-shadow: var(--shadow);
}

.detail-copy h1 {
  margin: 14px 0 12px;
  font-size: clamp(38px, 5vw, 66px);
  line-height: 1.08;
}

.one-line {
  max-width: 820px;
  margin: 0;
  color: #4b5563;
  font-size: 20px;
}

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

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

.player-section {
  padding-top: 48px;
}

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

.movie-player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #030712;
}

.play-button {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  transform: translate(-50%, -50%);
  min-width: 150px;
  min-height: 54px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(90deg, var(--red), var(--orange));
  box-shadow: 0 18px 36px rgba(220, 38, 38, 0.34);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.play-button.is-hidden {
  display: none;
}

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

.detail-content article,
.detail-content aside {
  padding: 28px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.08);
}

.detail-content h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.detail-content p {
  margin: 0 0 24px;
  color: #4b5563;
  font-size: 17px;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag-cloud span {
  padding: 7px 12px;
  border-radius: 999px;
  color: var(--red-dark);
  background: #fee2e2;
  font-size: 13px;
  font-weight: 800;
}

.site-footer {
  color: #ffffff;
  background: linear-gradient(135deg, var(--green-900), var(--green-800));
}

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

.site-footer p,
.site-footer a,
.site-footer small {
  color: var(--green-100);
}

.site-footer h2 {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: 18px;
}

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

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

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

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

@media (max-width: 900px) {
  .nav-toggle {
    display: inline-grid;
    place-items: center;
  }

  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 76px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: var(--shadow);
  }

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

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

  .hero-art {
    min-height: 360px;
  }

  .rank-panel {
    position: static;
  }

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

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

@media (max-width: 700px) {
  .hero-wrap {
    min-height: auto;
    padding: 48px 0 36px;
  }

  .section {
    padding: 58px 0;
  }

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

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

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

  .ranking-item {
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 14px;
  }

  .ranking-body h2 {
    font-size: 19px;
  }

  .detail-copy h1,
  .hero-copy h1,
  .page-hero h1 {
    letter-spacing: -0.03em;
  }
}

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

  .brand-text small {
    display: none;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .primary-btn,
  .ghost-btn,
  .text-btn {
    width: 100%;
  }

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

  .movie-card h3 {
    font-size: 14px;
  }

  .movie-card p,
  .movie-tags {
    font-size: 12px;
  }
}
