* {
  box-sizing: border-box;
}

:root {
  --page-bg: #fff7ed;
  --soft-bg: #fff1f2;
  --sky-bg: #f0f9ff;
  --text: #1f2937;
  --muted: #64748b;
  --line: rgba(148, 163, 184, 0.28);
  --amber: #f59e0b;
  --rose: #f43f5e;
  --sky: #0ea5e9;
  --dark: #111827;
  --card: rgba(255, 255, 255, 0.86);
  --shadow: 0 24px 70px rgba(15, 23, 42, 0.14);
  --radius: 28px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 12% 5%, rgba(251, 191, 36, 0.24), transparent 28rem),
    radial-gradient(circle at 88% 0%, rgba(244, 63, 94, 0.18), transparent 30rem),
    linear-gradient(135deg, #fffbeb 0%, #fff1f2 46%, #f0f9ff 100%);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  backdrop-filter: blur(20px);
  background: rgba(255, 247, 237, 0.78);
  border-bottom: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 12px 38px rgba(15, 23, 42, 0.08);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: #7c2d12;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: white;
  font-size: 14px;
  background: linear-gradient(135deg, var(--amber), var(--rose));
  box-shadow: 0 12px 28px rgba(244, 63, 94, 0.25);
}

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

.site-nav a {
  padding: 10px 16px;
  border-radius: 999px;
  color: #475569;
  font-weight: 700;
  transition: all 0.25s ease;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: white;
  background: linear-gradient(135deg, var(--amber), var(--rose));
  box-shadow: 0 12px 26px rgba(244, 63, 94, 0.18);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 16px;
  border: 1px solid rgba(244, 63, 94, 0.16);
  background: rgba(255, 255, 255, 0.86);
  color: #9f1239;
  cursor: pointer;
}

.hero-carousel {
  position: relative;
  height: 640px;
  overflow: hidden;
  background: #111827;
}

.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.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(88, 28, 12, 0.94), rgba(136, 19, 55, 0.84), rgba(8, 47, 73, 0.65)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.68), transparent 42%);
}

.hero-content {
  position: absolute;
  left: max(32px, calc((100% - 1180px) / 2));
  top: 50%;
  width: min(720px, calc(100% - 64px));
  transform: translateY(-50%);
  color: white;
}

.eyebrow {
  margin: 0 0 14px;
  color: #fde68a;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow.dark {
  color: #be123c;
}

.hero-content h1,
.hero-content h2 {
  margin: 0 0 18px;
  font-size: clamp(42px, 6vw, 82px);
  line-height: 1.02;
  font-weight: 950;
  text-shadow: 0 12px 36px rgba(0, 0, 0, 0.26);
}

.hero-title {
  margin: 0 0 18px;
  font-size: clamp(20px, 2.6vw, 32px);
  color: #fff7ed;
  font-weight: 800;
}

.hero-summary {
  max-width: 660px;
  margin: 0 0 30px;
  font-size: 17px;
  line-height: 1.9;
  color: rgba(255, 255, 255, 0.86);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.center-actions {
  justify-content: center;
  margin-top: 28px;
}

.primary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 900;
  transition: all 0.25s ease;
}

.primary-button {
  color: white;
  background: linear-gradient(135deg, var(--amber), var(--rose));
  box-shadow: 0 18px 38px rgba(244, 63, 94, 0.32);
}

.ghost-button {
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(12px);
}

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

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

.hero-dots button {
  width: 42px;
  height: 8px;
  padding: 0;
  border-radius: 999px;
  border: 0;
  background: rgba(255, 255, 255, 0.38);
  cursor: pointer;
  transition: all 0.25s ease;
}

.hero-dots button.is-active {
  width: 70px;
  background: white;
}

.intro-search {
  margin-top: -48px;
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
  gap: 24px;
  align-items: center;
  padding: 30px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.intro-search h2,
.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 50px);
  line-height: 1.12;
  color: #7c2d12;
}

.intro-search p,
.page-hero p,
.category-card p,
.section-heading p {
  color: var(--muted);
  line-height: 1.8;
}

.search-panel {
  position: relative;
}

.search-panel input {
  width: 100%;
  height: 58px;
  padding: 0 54px 0 22px;
  border-radius: 999px;
  border: 1px solid rgba(244, 63, 94, 0.2);
  outline: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.search-panel input:focus {
  border-color: rgba(244, 63, 94, 0.56);
  box-shadow: 0 0 0 4px rgba(244, 63, 94, 0.1);
}

.search-icon {
  position: absolute;
  top: 50%;
  right: 20px;
  transform: translateY(-50%);
  color: #be123c;
  font-size: 24px;
  font-weight: 900;
}

.category-links {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 34px 0 8px;
}

.category-links a {
  white-space: nowrap;
  padding: 11px 18px;
  border-radius: 999px;
  color: #9f1239;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(244, 63, 94, 0.14);
  font-weight: 800;
  transition: all 0.25s ease;
}

.category-links a:hover {
  color: white;
  background: linear-gradient(135deg, var(--amber), var(--rose));
}

.page-section,
.page-main {
  padding: 54px 0;
}

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

.heading-dot {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--rose), var(--sky));
  box-shadow: 0 16px 30px rgba(14, 165, 233, 0.22);
}

.section-heading h2,
.ranking-panel h2 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 40px);
  color: #7c2d12;
}

.section-heading p {
  margin: 6px 0 0;
}

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

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

.listing-grid {
  margin-top: 28px;
}

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: var(--card);
  box-shadow: 0 18px 52px rgba(15, 23, 42, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 72px rgba(15, 23, 42, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #1f2937;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.card-badge,
.rank-mark {
  position: absolute;
  top: 12px;
  border-radius: 999px;
  color: white;
  font-size: 12px;
  font-weight: 900;
  padding: 6px 10px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.94), rgba(244, 63, 94, 0.94));
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.18);
}

.card-badge {
  left: 12px;
}

.rank-mark {
  right: 12px;
}

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
  color: #64748b;
  font-size: 12px;
}

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

.card-body h3 a:hover {
  color: #be123c;
}

.card-body p {
  min-height: 46px;
  margin: 0 0 13px;
  color: #64748b;
  line-height: 1.6;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-row span,
.footer-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  color: #9f1239;
  background: rgba(255, 228, 230, 0.86);
  font-size: 12px;
  font-weight: 800;
}

.category-strip {
  margin-bottom: 48px;
}

.strip-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}

.strip-head h3 {
  margin: 0;
  font-size: 26px;
  color: #be123c;
}

.strip-head a {
  color: #0f766e;
  font-weight: 900;
}

.ranking-preview {
  padding-bottom: 80px;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 52px 76px minmax(0, 1fr) auto 60px;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
  transition: all 0.25s ease;
}

.ranking-row:hover {
  transform: translateX(4px);
  background: white;
}

.ranking-number {
  font-size: 20px;
  font-weight: 950;
  color: #be123c;
  text-align: center;
}

.ranking-row img {
  width: 76px;
  height: 52px;
  border-radius: 14px;
  object-fit: cover;
}

.ranking-title {
  min-width: 0;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ranking-info {
  color: #64748b;
  font-size: 13px;
}

.ranking-score {
  justify-self: end;
  color: #92400e;
  font-weight: 950;
}

.page-hero {
  padding: 54px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
  overflow: hidden;
  position: relative;
}

.page-hero::after {
  content: "";
  position: absolute;
  right: -80px;
  top: -90px;
  width: 240px;
  height: 240px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.24), rgba(244, 63, 94, 0.22));
}

.small-hero .search-panel {
  max-width: 520px;
  margin-top: 24px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: #64748b;
  font-size: 14px;
}

.breadcrumb a {
  color: #be123c;
  font-weight: 800;
}

.category-card-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 22px;
  margin-top: 28px;
}

.category-card {
  overflow: hidden;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 46px rgba(15, 23, 42, 0.1);
}

.category-card a {
  position: relative;
  display: block;
  min-height: 150px;
  overflow: hidden;
  color: white;
}

.category-card img {
  width: 100%;
  height: 170px;
  object-fit: cover;
  filter: brightness(0.72);
  transition: transform 0.5s ease;
}

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

.category-card span {
  position: absolute;
  left: 18px;
  bottom: 18px;
  font-size: 22px;
  font-weight: 950;
  text-shadow: 0 10px 22px rgba(0, 0, 0, 0.32);
}

.category-card p {
  margin: 0;
  padding: 16px;
  font-size: 14px;
}

.ranking-panel {
  margin-top: 46px;
  padding: 28px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: var(--shadow);
}

.ranking-panel h2 {
  margin-bottom: 22px;
}

.watch-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.55fr);
  gap: 28px;
  align-items: stretch;
}

.player-card,
.movie-facts,
.detail-content article,
.detail-nav {
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow);
}

.player-card {
  padding: 14px;
}

.video-box {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #020617;
  aspect-ratio: 16 / 9;
}

.video-box video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  cursor: pointer;
}

.video-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: white;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.55), rgba(15, 23, 42, 0.18));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.video-overlay span {
  width: 84px;
  height: 84px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 5px;
  border-radius: 999px;
  font-size: 34px;
  background: linear-gradient(135deg, var(--amber), var(--rose));
  box-shadow: 0 20px 46px rgba(0, 0, 0, 0.28);
}

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

.movie-facts {
  padding: 28px;
}

.movie-facts h1 {
  margin: 0 0 16px;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.12;
  color: #7c2d12;
}

.detail-one-line {
  margin: 0 0 20px;
  color: #475569;
  line-height: 1.8;
  font-weight: 700;
}

.fact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 20px;
}

.fact-grid span {
  display: grid;
  gap: 5px;
  padding: 12px;
  border-radius: 16px;
  color: #64748b;
  background: rgba(255, 241, 242, 0.82);
  font-size: 12px;
}

.fact-grid strong {
  color: #111827;
  font-size: 14px;
}

.detail-tags span {
  min-height: 30px;
}

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 28px;
}

.detail-content article {
  padding: 28px;
}

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

.detail-content p {
  margin: 0;
  color: #475569;
  line-height: 2;
}

.detail-nav {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 24px;
  padding: 18px;
}

.detail-nav a {
  color: #be123c;
  font-weight: 900;
}

.site-footer {
  margin-top: 40px;
  color: #cbd5e1;
  background: linear-gradient(135deg, #1f2937, #111827);
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 28px;
  padding: 54px 0 36px;
}

.footer-brand {
  color: white;
  margin-bottom: 16px;
}

.site-footer p {
  color: #94a3b8;
  line-height: 1.8;
}

.site-footer h2 {
  margin: 0 0 16px;
  color: white;
  font-size: 17px;
}

.site-footer a {
  display: block;
  margin: 0 0 10px;
  color: #cbd5e1;
  transition: color 0.25s ease;
}

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

.footer-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

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

.js-card.is-hidden {
  display: none;
}

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

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

  .watch-layout,
  .detail-content,
  .intro-search {
    grid-template-columns: 1fr;
  }
}

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

  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 82px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow);
  }

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

  .site-nav a {
    text-align: center;
  }

  .hero-carousel {
    height: 620px;
  }

  .hero-content {
    top: 52%;
    left: 24px;
    width: calc(100% - 48px);
  }

  .hero-summary {
    -webkit-line-clamp: 4;
  }

  .intro-search {
    margin-top: -34px;
    padding: 22px;
  }

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

  .page-hero {
    padding: 30px;
  }

  .ranking-row {
    grid-template-columns: 42px 68px minmax(0, 1fr) 48px;
  }

  .ranking-info {
    display: none;
  }

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

@media (max-width: 560px) {
  .container,
  .header-inner,
  .footer-grid {
    width: min(100% - 22px, 1180px);
  }

  .brand {
    font-size: 18px;
  }

  .hero-carousel {
    height: 580px;
  }

  .hero-content h1,
  .hero-content h2 {
    font-size: 38px;
  }

  .hero-title {
    font-size: 20px;
  }

  .hero-actions {
    align-items: stretch;
  }

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

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

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

  .detail-nav {
    flex-direction: column;
  }
}
