:root {
  --brand-orange: #f97316;
  --brand-red: #ef4444;
  --brand-pink: #ec4899;
  --ink: #1f2937;
  --muted: #6b7280;
  --soft: #fff7ed;
  --line: rgba(31, 41, 55, 0.09);
  --shadow: 0 18px 45px rgba(17, 24, 39, 0.16);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  color: #ffffff;
  background: linear-gradient(90deg, var(--brand-orange), var(--brand-red), var(--brand-pink));
  box-shadow: 0 16px 38px rgba(239, 68, 68, 0.28);
}

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

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-size: 21px;
  font-weight: 900;
  color: var(--brand-red);
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.16);
}

.brand strong {
  display: block;
  font-size: 24px;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.brand small {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  opacity: 0.9;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  font-weight: 700;
}

.desktop-nav a,
.drop-button {
  border: 0;
  color: #ffffff;
  background: transparent;
  cursor: pointer;
  transition: color 0.18s ease, opacity 0.18s ease;
}

.desktop-nav a:hover,
.drop-button:hover {
  color: #fef3c7;
}

.dropdown {
  position: relative;
}

.dropdown-panel {
  position: absolute;
  top: calc(100% + 18px);
  left: 0;
  width: 210px;
  padding: 10px;
  border-radius: 16px;
  color: var(--ink);
  background: #ffffff;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: 0.18s ease;
}

.dropdown:hover .dropdown-panel {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.dropdown-panel a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--ink);
}

.dropdown-panel a:hover {
  color: var(--brand-orange);
  background: #fff7ed;
}

.header-search {
  width: 230px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(14px);
}

.header-search input {
  width: 100%;
  border: 0;
  outline: 0;
  color: #ffffff;
  background: transparent;
}

.header-search input::placeholder {
  color: rgba(255, 255, 255, 0.74);
}

.header-search button,
.mobile-toggle {
  border: 0;
  color: #ffffff;
  background: transparent;
  cursor: pointer;
}

.mobile-toggle {
  display: none;
  font-size: 28px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
}

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

.mobile-nav a {
  display: block;
  padding: 10px 0;
  color: #ffffff;
  font-weight: 700;
}

.page {
  min-height: 70vh;
}

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

.hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(135deg, #fb923c, #ef4444, #ec4899);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  z-index: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.25);
  filter: blur(55px);
}

.hero::before {
  width: 320px;
  height: 320px;
  top: 42px;
  left: 7%;
}

.hero::after {
  width: 420px;
  height: 420px;
  right: 4%;
  bottom: -120px;
}

.hero-shell {
  position: relative;
  z-index: 1;
  min-height: 620px;
  display: grid;
  align-items: center;
  padding: 54px 0 42px;
}

.hero-slide {
  display: none;
  grid-template-columns: minmax(0, 1.06fr) minmax(280px, 0.74fr);
  align-items: center;
  gap: 44px;
}

.hero-slide.is-active {
  display: grid;
}

.hero-copy {
  max-width: 720px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
}

.hero h1,
.hero h2 {
  margin: 0 0 18px;
  font-size: clamp(40px, 6vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.055em;
}

.hero p {
  margin: 0;
  max-width: 620px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

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

.button-primary {
  color: var(--brand-red);
  background: #ffffff;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.18);
}

.button-primary:hover {
  background: #fff7ed;
}

.button-ghost {
  color: #ffffff;
  border: 2px solid rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(12px);
}

.hero-poster-wrap {
  position: relative;
}

.hero-poster {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 30px;
  box-shadow: 0 34px 70px rgba(0, 0, 0, 0.34);
  background: rgba(255, 255, 255, 0.16);
}

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.72));
}

.hero-poster-meta {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 2;
}

.hero-poster-meta strong {
  display: block;
  font-size: 21px;
  line-height: 1.25;
}

.hero-thumbs {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin-top: 28px;
}

.hero-thumb {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 18px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  cursor: pointer;
  text-align: left;
  backdrop-filter: blur(12px);
}

.hero-thumb.is-active {
  background: rgba(255, 255, 255, 0.28);
}

.hero-thumb span {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  font-weight: 800;
}

.section {
  padding: 54px 0;
}

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

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

.section-title {
  margin: 0;
  font-size: clamp(27px, 3vw, 42px);
  letter-spacing: -0.04em;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(17, 24, 39, 0.1);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.card-poster {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #fed7aa, #fecdd3);
}

.card-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 48%, rgba(0, 0, 0, 0.72));
  opacity: 0.88;
}

.card-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 4px 8px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.68);
  font-size: 12px;
  font-weight: 800;
}

.card-play {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--brand-red);
  background: rgba(255, 255, 255, 0.92);
  transform: translate(-50%, -50%) scale(0.9);
  opacity: 0;
  transition: 0.2s ease;
}

.movie-card:hover .card-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.card-body {
  padding: 14px;
}

.card-title {
  margin: 0 0 8px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  min-height: 44px;
  font-size: 16px;
  line-height: 1.35;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 13px;
}

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

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

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-size: 12px;
  font-weight: 800;
}

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

.category-card {
  min-height: 190px;
  padding: 22px;
  border-radius: 24px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand-orange), var(--brand-red), var(--brand-pink));
  box-shadow: 0 18px 38px rgba(239, 68, 68, 0.2);
  transition: transform 0.2s ease;
}

.category-card:hover {
  transform: translateY(-5px);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 10px;
  font-size: 24px;
}

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.7;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 60px 74px minmax(0, 1fr) 104px;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 10px 26px rgba(17, 24, 39, 0.07);
}

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

.rank-cover {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 12px;
  background: #ffedd5;
}

.rank-title {
  margin: 0 0 6px;
  font-size: 18px;
}

.rank-info {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.rank-heat {
  justify-self: end;
  color: #dc2626;
  font-weight: 900;
}

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

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  letter-spacing: -0.045em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
  line-height: 1.8;
}

.filter-box {
  margin: 28px 0 24px;
  display: flex;
  gap: 12px;
}

.filter-box input {
  width: min(480px, 100%);
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: none;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.06);
}

.detail-wrap {
  padding: 42px 0 64px;
}

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

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

.player-card {
  overflow: hidden;
  border-radius: 28px;
  background: #111827;
  box-shadow: 0 28px 60px rgba(17, 24, 39, 0.24);
}

.player-box {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.player-box video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000000;
}

.play-layer {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: rgba(0, 0, 0, 0.2);
}

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

.play-button {
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: 999px;
  color: var(--brand-red);
  background: rgba(255, 255, 255, 0.94);
  font-size: 36px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 20px 46px rgba(0, 0, 0, 0.3);
  transition: transform 0.18s ease;
}

.play-button:hover {
  transform: scale(1.06);
}

.detail-grid {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 28px;
  margin-top: 30px;
}

.detail-poster {
  overflow: hidden;
  aspect-ratio: 3 / 4;
  border-radius: 24px;
  background: #ffedd5;
  box-shadow: 0 18px 42px rgba(17, 24, 39, 0.16);
}

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

.detail-content h1 {
  margin: 0 0 14px;
  font-size: clamp(32px, 4.5vw, 54px);
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.info-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 20px;
}

.info-chip {
  padding: 8px 12px;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-weight: 800;
  font-size: 13px;
}

.content-block {
  margin-top: 24px;
}

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

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

.site-footer {
  color: #d1d5db;
  background: linear-gradient(180deg, #1f2937, #111827);
}

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

.footer-inner h2,
.footer-inner h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.footer-inner p,
.footer-inner a {
  color: #d1d5db;
  line-height: 1.8;
}

.footer-links {
  display: grid;
  gap: 8px;
}

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

.search-panel {
  padding: 28px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(17, 24, 39, 0.08);
}

.search-main {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.search-main input {
  flex: 1;
  min-height: 52px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: none;
}

.search-main button {
  min-width: 118px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(90deg, var(--brand-orange), var(--brand-red));
  font-weight: 900;
  cursor: pointer;
}

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

.empty-text {
  color: var(--muted);
  line-height: 1.8;
}

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

  .mobile-toggle {
    display: block;
  }

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

  .hero-poster-wrap {
    max-width: 420px;
  }

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

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

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

@media (max-width: 760px) {
  .header-inner {
    min-height: 68px;
  }

  .brand strong {
    font-size: 20px;
  }

  .hero-shell {
    min-height: auto;
    padding: 42px 0 28px;
  }

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

  .section-head,
  .filter-box,
  .search-main {
    align-items: stretch;
    flex-direction: column;
  }

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

  .rank-item {
    grid-template-columns: 44px 58px minmax(0, 1fr);
  }

  .rank-heat {
    grid-column: 3;
    justify-self: start;
  }

  .detail-content {
    padding: 20px;
  }

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

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

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