:root {
  --orange: #f97316;
  --orange-dark: #c2410c;
  --amber: #f59e0b;
  --yellow: #facc15;
  --rose: #fb7185;
  --ink: #111827;
  --muted: #6b7280;
  --soft: #fff7ed;
  --line: #fed7aa;
  --card: #ffffff;
  --shadow: 0 20px 45px rgba(124, 45, 18, 0.13);
  --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", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(135deg, #fff7ed 0%, #fffbeb 45%, #ffffff 100%);
  min-height: 100vh;
}

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: linear-gradient(90deg, #f97316, #f59e0b, #eab308);
  color: #ffffff;
  box-shadow: 0 12px 32px rgba(194, 65, 12, 0.24);
}

.nav-shell {
  max-width: 1320px;
  margin: 0 auto;
  min-height: 76px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

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

.brand-mark,
.footer-brand span {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--orange);
  background: #ffffff;
  box-shadow: inset 0 -4px 12px rgba(249, 115, 22, 0.18);
}

.brand-text {
  font-size: 22px;
  line-height: 1;
}

.brand-text small {
  display: block;
  margin-top: 5px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 600;
}

.top-search,
.mobile-search {
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}

.top-search {
  flex: 1;
  max-width: 460px;
}

.top-search input,
.mobile-search input,
.search-box input,
.filter-panel input {
  width: 100%;
  border: 2px solid rgba(255, 255, 255, 0.72);
  outline: none;
  border-radius: 999px;
  padding: 12px 18px;
  background: rgba(255, 255, 255, 0.92);
  color: #1f2937;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.top-search input:focus,
.mobile-search input:focus,
.search-box input:focus,
.filter-panel input:focus {
  border-color: #ffffff;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(255, 237, 213, 0.65);
}

.top-search button,
.mobile-search button,
.search-box button,
.cta-button,
.ghost-button {
  border: none;
  border-radius: 999px;
  padding: 12px 22px;
  cursor: pointer;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.top-search button,
.mobile-search button,
.search-box button {
  background: #7c2d12;
  color: #ffffff;
}

.top-search button:hover,
.mobile-search button:hover,
.search-box button:hover,
.cta-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

.desktop-nav a,
.mobile-panel nav a {
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.92);
  transition: background 0.2s ease, color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-panel nav a:hover,
.mobile-panel nav a.is-active {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.mobile-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}

.mobile-toggle span {
  width: 22px;
  height: 2px;
  border-radius: 999px;
  background: #ffffff;
}

.mobile-panel {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 24px 18px;
}

.mobile-panel nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.container,
.hero-inner,
.section-inner,
.footer-grid {
  width: min(1320px, calc(100% - 40px));
  margin: 0 auto;
}

.hero {
  position: relative;
  min-height: 640px;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(115deg, #c2410c 0%, #f97316 43%, #facc15 100%);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  filter: blur(18px);
  animation: pulseGlow 5.5s ease-in-out infinite;
}

.hero::before {
  top: -120px;
  left: 14%;
}

.hero::after {
  right: 9%;
  bottom: -170px;
  animation-delay: 1.6s;
}

.hero-inner {
  position: relative;
  z-index: 2;
  padding: 76px 0 54px;
}

.hero-slider {
  position: relative;
  min-height: 500px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  align-items: center;
  gap: 42px;
  opacity: 0;
  transform: translateX(28px);
  pointer-events: none;
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.hero-slide.is-active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.hero-eyebrow,
.section-eyebrow,
.detail-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.18);
  color: #fff7ed;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.hero h2 {
  margin: 0 0 16px;
  font-size: clamp(26px, 3.2vw, 42px);
  line-height: 1.08;
}

.hero p {
  max-width: 740px;
  margin: 0 0 20px;
  color: rgba(255, 247, 237, 0.92);
  font-size: 18px;
}

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

.cta-button {
  color: #c2410c;
  background: #ffffff;
  box-shadow: 0 18px 30px rgba(124, 45, 18, 0.18);
}

.ghost-button {
  color: #ffffff;
  background: rgba(124, 45, 18, 0.38);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
}

.hero-card {
  position: relative;
  min-height: 410px;
  border-radius: 34px;
  overflow: hidden;
  box-shadow: 0 35px 80px rgba(124, 45, 18, 0.34);
  background-image: linear-gradient(180deg, rgba(17, 24, 39, 0.18), rgba(17, 24, 39, 0.82)), var(--poster-image), linear-gradient(135deg, #7c2d12, #f97316);
  background-size: cover;
  background-position: center;
  transform: rotate(1deg);
}

.hero-card::after {
  content: "";
  position: absolute;
  inset: 20px;
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-card-content {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 28px;
  z-index: 1;
}

.hero-card-content strong {
  display: block;
  font-size: 28px;
  margin-bottom: 8px;
}

.hero-card-content span {
  display: inline-flex;
  margin-right: 8px;
  margin-top: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 13px;
  font-weight: 700;
}

.hero-dots {
  position: absolute;
  left: 0;
  bottom: 8px;
  z-index: 3;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 38px;
  height: 8px;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
  cursor: pointer;
}

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

.section {
  padding: 70px 0;
}

.section.white {
  background: #ffffff;
}

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

.section.hot {
  background: linear-gradient(135deg, #fff1f2, #fff7ed 48%, #fffbeb);
}

.section.rank-section {
  color: #ffffff;
  background: linear-gradient(120deg, #eab308, #f97316, #dc2626);
}

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

.section-title h1,
.section-title h2 {
  margin: 0;
  font-size: clamp(30px, 3.5vw, 46px);
  letter-spacing: -0.04em;
}

.section-title p {
  margin: 12px 0 0;
  color: var(--muted);
  max-width: 760px;
}

.rank-section .section-title p,
.rank-section .section-title h2 {
  color: #ffffff;
}

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

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

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

.movie-link {
  display: block;
  height: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--card);
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-link:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow);
}

.poster-frame,
.rank-thumb,
.detail-poster {
  position: relative;
  background-image: linear-gradient(135deg, rgba(124, 45, 18, 0.2), rgba(249, 115, 22, 0.88)), var(--poster-image), linear-gradient(135deg, #7c2d12, #f59e0b);
  background-size: cover;
  background-position: center;
}

.poster-frame {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.poster-frame::after,
.rank-thumb::after,
.detail-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 72% 24%, rgba(255, 255, 255, 0.22), transparent 35%);
  pointer-events: none;
}

.quality-badge,
.score-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  color: #ffffff;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.18);
}

.quality-badge {
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  background: rgba(249, 115, 22, 0.95);
}

.score-badge {
  right: 12px;
  top: 12px;
  padding: 6px 10px;
  background: rgba(17, 24, 39, 0.76);
}

.rank-badge {
  left: 12px;
  bottom: 12px;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f97316, #dc2626);
}

.poster-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
  font-size: 34px;
  color: #ffffff;
  opacity: 0;
  transform: scale(0.86);
  transition: opacity 0.2s ease, transform 0.2s ease;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.movie-link:hover .poster-play {
  opacity: 1;
  transform: scale(1);
}

.movie-info {
  padding: 18px;
}

.movie-info h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.25;
}

.movie-meta,
.movie-desc {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.movie-desc {
  margin-top: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.tag-row span,
.meta-pill,
.chip {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #fff7ed;
  color: #c2410c;
  font-weight: 800;
  font-size: 12px;
  padding: 7px 10px;
}

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

.category-overview-card {
  min-width: 0;
}

.category-card {
  min-height: 160px;
  padding: 24px;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow);
}

.category-icon {
  width: 58px;
  height: 58px;
  margin-bottom: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(135deg, #f97316, #f59e0b);
}

.category-card h3 {
  margin: 0 0 10px;
  font-size: 20px;
}

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

.category-sample {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0 0;
}

.chip {
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #fed7aa;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.chip:hover,
.chip.is-active {
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #f59e0b);
  transform: translateY(-2px);
}

.filter-panel,
.search-box {
  margin: 26px 0 32px;
  padding: 18px;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
}

.filter-panel input,
.search-box input {
  border-color: #fed7aa;
}

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

.rank-item {
  min-width: 0;
}

.rank-link {
  display: grid;
  grid-template-columns: auto 152px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  min-height: 138px;
  padding: 14px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  box-shadow: 0 12px 30px rgba(124, 45, 18, 0.15);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.rank-link:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 50px rgba(124, 45, 18, 0.2);
}

.list-rank {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #dc2626);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 20px;
}

.rank-thumb {
  height: 98px;
  border-radius: 16px;
}

.rank-text h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.rank-text p {
  margin: 0;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rank-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
  font-size: 13px;
  color: var(--muted);
}

.rank-meta strong {
  color: #f97316;
}

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

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

.detail-hero {
  padding: 42px 0 70px;
  background: linear-gradient(135deg, #fff7ed, #fffbeb 62%, #ffffff);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.8fr);
  gap: 30px;
}

.player-card,
.detail-card,
.content-card,
.related-card {
  border-radius: 28px;
  background: #ffffff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.video-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000000;
  cursor: pointer;
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  border: none;
  color: #ffffff;
  background: radial-gradient(circle at center, rgba(249, 115, 22, 0.24), rgba(0, 0, 0, 0.62));
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  z-index: 3;
}

.play-overlay strong {
  width: 82px;
  height: 82px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 6px;
  font-size: 34px;
  color: #f97316;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.25);
}

.play-overlay span {
  font-weight: 900;
  font-size: 18px;
}

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

.player-title {
  padding: 22px 24px 26px;
}

.player-title h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 3.8vw, 46px);
  letter-spacing: -0.04em;
}

.player-title p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.detail-card {
  padding: 22px;
}

.detail-poster {
  aspect-ratio: 4 / 3;
  border-radius: 22px;
  margin-bottom: 20px;
}

.detail-facts {
  display: grid;
  gap: 12px;
}

.detail-facts div {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid #ffedd5;
  color: var(--muted);
}

.detail-facts strong {
  color: var(--ink);
}

.content-card {
  margin-top: 28px;
  padding: 30px;
}

.content-card h2,
.related-card h2 {
  margin: 0 0 18px;
  font-size: 28px;
  letter-spacing: -0.03em;
}

.content-card p {
  margin: 0 0 22px;
  color: #374151;
  line-height: 1.95;
  font-size: 16px;
}

.related-card {
  margin-top: 28px;
  padding: 28px;
}

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

.empty-state {
  display: none;
  padding: 36px;
  text-align: center;
  border-radius: 24px;
  background: #ffffff;
  color: var(--muted);
  box-shadow: var(--shadow);
}

.back-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 46px;
  height: 46px;
  border: none;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #dc2626);
  box-shadow: 0 14px 28px rgba(194, 65, 12, 0.24);
  cursor: pointer;
  display: none;
  z-index: 90;
}

.back-top.is-visible {
  display: block;
}

.site-footer {
  color: #d1d5db;
  background: linear-gradient(135deg, #111827, #1f2937);
  padding: 54px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 40px;
}

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

.footer-grid p {
  margin: 0;
  color: #9ca3af;
  line-height: 1.8;
}

.footer-grid h3 {
  margin: 0 0 16px;
  color: #ffffff;
}

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

.footer-links a {
  color: #d1d5db;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: #fb923c;
}

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

@keyframes pulseGlow {
  0%, 100% {
    transform: scale(0.92);
    opacity: 0.72;
  }
  50% {
    transform: scale(1.08);
    opacity: 1;
  }
}

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

  .mobile-toggle {
    display: inline-flex;
    margin-left: auto;
  }

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

  .hero-slider {
    min-height: 760px;
  }

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

  .movie-grid,
  .movie-grid.large-grid,
  .category-grid,
  .rank-list,
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .nav-shell {
    min-height: 68px;
    padding: 0 16px;
  }

  .brand-text {
    font-size: 18px;
  }

  .container,
  .hero-inner,
  .section-inner,
  .footer-grid {
    width: min(100% - 28px, 1320px);
  }

  .hero {
    min-height: 760px;
  }

  .hero-inner {
    padding-top: 48px;
  }

  .hero-slider {
    min-height: 680px;
  }

  .hero h1 {
    font-size: 42px;
  }

  .hero p {
    font-size: 16px;
  }

  .section {
    padding: 46px 0;
  }

  .section-header {
    align-items: start;
    flex-direction: column;
  }

  .movie-grid,
  .movie-grid.large-grid,
  .category-grid,
  .rank-list,
  .footer-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .rank-link {
    grid-template-columns: auto 92px minmax(0, 1fr);
    gap: 12px;
  }

  .rank-thumb {
    height: 74px;
  }

  .detail-hero {
    padding-top: 28px;
  }

  .content-card,
  .related-card,
  .detail-card {
    padding: 22px;
  }

  .play-overlay strong {
    width: 64px;
    height: 64px;
    font-size: 26px;
  }
}
