:root {
  --page-bg: #fffaf3;
  --surface: #ffffff;
  --ink: #172033;
  --muted: #667085;
  --line: rgba(17, 24, 39, 0.09);
  --accent: #ea580c;
  --accent-2: #f59e0b;
  --accent-soft: #fff7ed;
  --dark: #0f172a;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(255, 237, 213, 0.9), transparent 32rem),
    linear-gradient(180deg, #ffffff 0%, var(--page-bg) 48%, #ffffff 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
}

.header-inner,
.footer-inner,
.main-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

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

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

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  flex: none;
  border-radius: 14px;
  color: white;
  font-weight: 900;
  background: linear-gradient(135deg, var(--accent-2), var(--accent));
  box-shadow: 0 12px 30px rgba(234, 88, 12, 0.34);
}

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

.brand-text strong {
  font-size: 1.12rem;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.76rem;
}

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

.nav-link,
.mobile-link {
  border-radius: 999px;
  color: #344054;
  font-weight: 700;
  transition: 0.2s ease;
}

.nav-link {
  padding: 10px 15px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--accent);
  background: var(--accent-soft);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  flex: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  border: 0;
  border-radius: 14px;
  background: var(--accent-soft);
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  border-radius: 4px;
  background: var(--accent);
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

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

.mobile-link {
  display: block;
  padding: 12px 14px;
  background: white;
}

.main-shell {
  padding: 34px 0 56px;
}

.hero {
  position: relative;
  min-height: min(720px, 72vh);
  overflow: hidden;
  border-radius: 0 0 38px 38px;
  background: #0f172a;
  color: white;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  background-position: center;
  background-size: cover;
  transform: scale(1.04);
}

.hero-bg::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.68) 42%, rgba(15, 23, 42, 0.12)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.78), transparent 48%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0 98px;
}

.hero-copy {
  width: min(680px, 100%);
}

.eyebrow,
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  color: var(--accent);
  background: var(--accent-soft);
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.hero-badge {
  color: white;
  padding: 9px 14px;
  background: rgba(234, 88, 12, 0.88);
  backdrop-filter: blur(12px);
}

.eyebrow {
  padding: 8px 12px;
}

.hero h1 {
  margin: 22px 0 18px;
  font-size: clamp(2.45rem, 8vw, 5.6rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.82;
}

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

.btn,
button.btn {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  padding: 12px 22px;
  color: white;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  font-weight: 900;
  box-shadow: 0 18px 34px rgba(234, 88, 12, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px) scale(1.01);
  box-shadow: 0 20px 40px rgba(234, 88, 12, 0.36);
}

.btn.ghost {
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.32);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: none;
  backdrop-filter: blur(14px);
}

.detail-actions .btn.ghost {
  color: var(--accent);
  border-color: rgba(234, 88, 12, 0.22);
  background: var(--accent-soft);
}

.hero-search {
  display: flex;
  width: min(620px, 100%);
  margin-top: 26px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(18px);
}

.hero-search input,
.search-panel input,
.search-panel select,
.filter-input {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 18px;
  outline: none;
  color: var(--ink);
  background: white;
}

.hero-search input {
  border: 0;
  color: white;
  background: transparent;
}

.hero-search input::placeholder {
  color: rgba(255, 255, 255, 0.72);
}

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

.hero-dot {
  width: 26px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
  transition: 0.2s ease;
}

.hero-dot.is-active {
  width: 48px;
  background: white;
}

.hero-side-card {
  position: absolute;
  right: max(24px, calc((100vw - 1180px) / 2));
  bottom: 84px;
  z-index: 3;
  width: min(360px, calc(100% - 48px));
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-side-card img {
  width: 100%;
  height: 190px;
  object-fit: cover;
}

.hero-side-card div {
  padding: 16px;
}

.hero-side-card strong {
  display: block;
  margin-bottom: 4px;
}

.hero-side-card span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.88rem;
}

.content-section {
  margin-top: 42px;
}

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

.section-heading h1,
.section-heading h2 {
  margin: 8px 0 0;
  font-size: clamp(1.8rem, 4vw, 2.7rem);
  letter-spacing: -0.04em;
}

.section-more {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 10px 14px;
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 800;
}

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

.movie-card {
  min-width: 0;
}

.movie-card a {
  display: block;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card a:hover {
  border-color: rgba(234, 88, 12, 0.28);
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.poster-frame {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  margin: 0;
  background: linear-gradient(135deg, #fff7ed, #e2e8f0);
}

.poster-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.48s ease;
}

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

.poster-frame::after {
  position: absolute;
  inset: 0;
  content: "";
  opacity: 0;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.78), transparent 54%);
  transition: opacity 0.24s ease;
}

.movie-card a:hover .poster-frame::after {
  opacity: 1;
}

.duration-pill,
.rank-badge,
.play-hover {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
}

.duration-pill {
  top: 10px;
  left: 10px;
  padding: 5px 9px;
  color: white;
  background: rgba(15, 23, 42, 0.72);
  font-size: 0.75rem;
  backdrop-filter: blur(10px);
}

.rank-badge {
  top: 10px;
  right: 10px;
  padding: 5px 9px;
  color: white;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  font-size: 0.78rem;
}

.play-hover {
  left: 50%;
  top: 50%;
  display: grid;
  width: 60px;
  height: 60px;
  place-items: center;
  color: var(--accent);
  background: rgba(255, 255, 255, 0.94);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.72);
  transition: 0.24s ease;
}

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

.card-body {
  padding: 16px;
}

.card-body h3 {
  display: -webkit-box;
  min-height: 48px;
  margin: 0 0 8px;
  overflow: hidden;
  color: #101828;
  font-size: 1.05rem;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-body p {
  display: -webkit-box;
  min-height: 42px;
  margin: 0 0 12px;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.55;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.card-meta span,
.tag-row span,
.meta-pill {
  border-radius: 999px;
  padding: 5px 9px;
  color: #475467;
  background: #f2f4f7;
  font-size: 0.76rem;
  font-weight: 800;
}

.tag-row {
  margin-top: 10px;
}

.tag-row span:first-child,
.meta-pill.hot {
  color: var(--accent);
  background: var(--accent-soft);
}

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

.category-card {
  display: block;
  min-height: 148px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 247, 237, 0.88), rgba(255, 255, 255, 0.96)),
    white;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.07);
  transition: 0.24s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(234, 88, 12, 0.28);
  box-shadow: var(--shadow);
}

.category-card span {
  color: var(--accent);
  font-weight: 900;
}

.category-card h3 {
  margin: 12px 0 8px;
  font-size: 1.35rem;
}

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

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

.ranking-item {
  display: grid;
  grid-template-columns: 78px 96px 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: white;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.ranking-no {
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  border-radius: 18px;
  color: white;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  font-weight: 950;
}

.ranking-cover {
  width: 86px;
  height: 112px;
  overflow: hidden;
  border-radius: 16px;
  background: #f2f4f7;
}

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

.ranking-info h3 {
  margin: 0 0 8px;
  font-size: 1.18rem;
}

.ranking-info p {
  display: -webkit-box;
  margin: 0 0 10px;
  overflow: hidden;
  color: var(--muted);
  line-height: 1.6;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.page-hero,
.detail-hero {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.22), transparent 28rem),
    linear-gradient(135deg, #ffffff, #fff7ed);
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.08);
}

.page-hero {
  padding: clamp(28px, 5vw, 52px);
}

.page-hero h1 {
  max-width: 900px;
  margin: 10px 0;
  font-size: clamp(2.1rem, 5vw, 4.4rem);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.page-hero p {
  max-width: 780px;
  color: var(--muted);
  font-size: 1.06rem;
  line-height: 1.8;
}

.search-panel,
.filter-panel {
  display: grid;
  gap: 12px;
  margin: 24px 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: white;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.search-panel {
  grid-template-columns: 1fr 180px 180px auto;
}

.filter-panel {
  grid-template-columns: 1fr 160px 160px 160px;
}

.result-count {
  margin: 16px 0;
  color: var(--muted);
  font-weight: 800;
}

.detail-hero {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: clamp(22px, 4vw, 42px);
  padding: clamp(18px, 4vw, 34px);
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  background: #f2f4f7;
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.18);
}

.detail-poster img {
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
}

.detail-copy h1 {
  margin: 14px 0 12px;
  font-size: clamp(2.2rem, 5vw, 4.5rem);
  line-height: 1.02;
  letter-spacing: -0.06em;
}

.detail-copy p {
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.85;
}

.detail-meta,
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.breadcrumbs {
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 0.92rem;
}

.detail-meta {
  margin: 16px 0;
}

.player-card,
.text-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: white;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
}

.text-card {
  padding: clamp(20px, 4vw, 30px);
}

.text-card h2 {
  margin: 0 0 12px;
  font-size: 1.7rem;
}

.text-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.9;
}

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

.player-box video {
  width: 100%;
  height: 100%;
  background: #050816;
  object-fit: contain;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-items: center;
  border: 0;
  color: white;
  background: linear-gradient(0deg, rgba(5, 8, 22, 0.82), rgba(5, 8, 22, 0.34));
  cursor: pointer;
  transition: opacity 0.24s ease;
}

.player-box.is-playing .player-overlay {
  opacity: 0;
  pointer-events: none;
}

.player-button {
  display: grid;
  width: 88px;
  height: 88px;
  place-items: center;
  border-radius: 999px;
  color: var(--accent);
  background: white;
  font-size: 2rem;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
}

.player-title {
  padding: 20px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: white;
  background: #0f172a;
}

.player-title h2 {
  margin: 0 0 6px;
}

.player-title p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
}

.site-footer {
  border-top: 1px solid var(--line);
  background: #101828;
  color: white;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 34px 0;
}

.footer-inner p {
  max-width: 620px;
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.68);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-links a {
  border-radius: 999px;
  padding: 9px 12px;
  color: rgba(255, 255, 255, 0.78);
  background: rgba(255, 255, 255, 0.08);
}

.empty-state {
  padding: 28px;
  border: 1px dashed rgba(234, 88, 12, 0.32);
  border-radius: 22px;
  color: var(--muted);
  background: var(--accent-soft);
  text-align: center;
}

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

  .hero-side-card {
    display: none;
  }

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

  .search-panel,
  .filter-panel {
    grid-template-columns: 1fr 1fr;
  }
}

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

  .menu-toggle {
    display: inline-flex;
  }

  .hero {
    min-height: 680px;
    border-radius: 0 0 28px 28px;
  }

  .hero-content {
    padding-top: 58px;
  }

  .hero-search {
    border-radius: 24px;
    flex-direction: column;
  }

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

  .section-heading,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .ranking-item {
    grid-template-columns: 54px 78px 1fr;
  }

  .ranking-item .btn {
    grid-column: 1 / -1;
  }

  .ranking-cover {
    width: 74px;
    height: 98px;
  }

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

  .detail-poster img {
    min-height: auto;
  }

  .search-panel,
  .filter-panel {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 460px) {
  .header-inner,
  .footer-inner,
  .main-shell,
  .hero-content {
    width: min(100% - 22px, 1180px);
  }

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

  .brand-text small {
    display: none;
  }

  .player-button {
    width: 72px;
    height: 72px;
  }
}
