:root {
  --bg-start: #fff7ed;
  --bg-mid: #fdf2f8;
  --bg-end: #fffbeb;
  --text: #1f2937;
  --muted: #6b7280;
  --line: rgba(248, 113, 113, 0.16);
  --orange: #f97316;
  --orange-dark: #ea580c;
  --pink: #ec4899;
  --rose: #f43f5e;
  --green: #10b981;
  --shadow: 0 18px 50px rgba(120, 53, 15, 0.12);
  --soft-shadow: 0 10px 24px rgba(120, 53, 15, 0.10);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: linear-gradient(135deg, var(--bg-start), var(--bg-mid) 48%, var(--bg-end));
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(255, 247, 237, 0.96), rgba(253, 242, 248, 0.96));
  border-bottom: 1px solid rgba(249, 115, 22, 0.14);
  box-shadow: 0 8px 22px rgba(194, 65, 12, 0.08);
  backdrop-filter: blur(18px);
}

.header-inner {
  height: 72px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
}

.brand-text {
  font-size: 24px;
  background: linear-gradient(90deg, var(--orange), var(--pink));
  -webkit-background-clip: text;
  color: transparent;
  white-space: nowrap;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 12px 28px rgba(249, 115, 22, 0.28);
}

.brand-mark span {
  width: 0;
  height: 0;
  margin-left: 3px;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid white;
}

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

.nav-link,
.mobile-nav-link {
  position: relative;
  padding: 10px 12px;
  color: #374151;
  font-weight: 700;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  color: var(--orange-dark);
  background: rgba(249, 115, 22, 0.09);
}

.header-search {
  margin-left: auto;
  display: flex;
  align-items: center;
  border: 1px solid rgba(249, 115, 22, 0.20);
  background: white;
  border-radius: 999px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(251, 146, 60, 0.10);
}

.header-search input,
.mobile-search input,
.hero-search input,
.search-page-form input,
.filter-panel input,
.filter-panel select {
  border: 0;
  outline: 0;
  background: white;
  color: var(--text);
}

.header-search input {
  width: 230px;
  padding: 12px 16px;
}

.header-search button,
.mobile-search button,
.hero-search button,
.search-page-form button {
  border: 0;
  color: white;
  cursor: pointer;
  font-weight: 800;
  background: linear-gradient(135deg, var(--orange), var(--pink));
}

.header-search button {
  padding: 12px 18px;
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: rgba(249, 115, 22, 0.10);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  background: var(--orange-dark);
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  padding: 0 16px 18px;
}

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

.mobile-search {
  display: flex;
  overflow: hidden;
  margin-top: 8px;
  border-radius: 999px;
  background: white;
}

.mobile-search input {
  flex: 1;
  padding: 12px 14px;
}

.mobile-search button {
  padding: 12px 18px;
}

.hero-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 24px;
  padding-top: 32px;
}

.hero-carousel {
  position: relative;
  height: 520px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  background: #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 0.7s ease, transform 0.7s ease;
  pointer-events: none;
}

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

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.48) 42%, rgba(0, 0, 0, 0.08));
}

.hero-content {
  position: absolute;
  inset: 0;
  width: min(650px, 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 56px;
  color: white;
}

.hero-label {
  width: max-content;
  margin-bottom: 18px;
  padding: 7px 16px;
  border-radius: 999px;
  background: var(--orange);
  font-size: 14px;
  font-weight: 800;
}

.hero-content h1 {
  margin: 0 0 16px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.hero-content p {
  margin: 0 0 20px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
  line-height: 1.8;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.hero-tags,
.detail-meta,
.movie-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.detail-meta span,
.movie-tags span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: inherit;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
}

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

.primary-button,
.ghost-button,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  min-width: 132px;
  padding: 14px 24px;
  color: white;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 16px 32px rgba(249, 115, 22, 0.30);
}

.ghost-button {
  min-width: 132px;
  padding: 13px 22px;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.36);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
}

.primary-button:hover,
.ghost-button:hover,
.section-more:hover,
.movie-card:hover,
.category-card:hover,
.ranking-item:hover {
  transform: translateY(-3px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  color: white;
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.20);
  backdrop-filter: blur(10px);
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.32);
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: var(--orange);
}

.hero-side {
  display: grid;
  align-content: start;
  gap: 16px;
}

.hero-search,
.quick-links,
.detail-card,
.player-card,
.side-card,
.side-poster,
.filter-panel {
  border: 1px solid rgba(249, 115, 22, 0.12);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--soft-shadow);
  backdrop-filter: blur(12px);
}

.hero-search {
  padding: 22px;
}

.hero-search label {
  display: block;
  margin-bottom: 12px;
  font-size: 20px;
  font-weight: 900;
}

.hero-search div,
.search-page-form {
  display: flex;
  overflow: hidden;
  border: 1px solid rgba(249, 115, 22, 0.18);
  border-radius: 999px;
  background: white;
}

.hero-search input,
.search-page-form input {
  min-width: 0;
  flex: 1;
  padding: 14px 16px;
}

.hero-search button,
.search-page-form button {
  padding: 14px 20px;
}

.quick-links {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.quick-links a {
  padding: 15px 16px;
  border-radius: 16px;
  color: #7c2d12;
  font-weight: 800;
  background: linear-gradient(90deg, rgba(255, 237, 213, 0.95), rgba(252, 231, 243, 0.95));
}

.content-section {
  padding: 48px 0 10px;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.2;
}

.section-more {
  padding: 10px 16px;
  color: var(--orange-dark);
  background: white;
  box-shadow: 0 8px 18px rgba(249, 115, 22, 0.12);
}

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

.movie-card {
  display: grid;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: white;
  box-shadow: var(--soft-shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  box-shadow: 0 22px 42px rgba(120, 53, 15, 0.18);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #fed7aa, #fbcfe8);
}

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

.movie-card:hover .poster-wrap img {
  transform: scale(1.06);
}

.poster-shade {
  position: absolute;
  inset: 0;
  opacity: 0;
  background: rgba(0, 0, 0, 0.38);
  transition: opacity 0.2s ease;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: white;
  background: rgba(249, 115, 22, 0.92);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.86);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.movie-badge,
.movie-duration {
  position: absolute;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 999px;
  color: white;
  font-size: 12px;
  font-weight: 800;
}

.movie-badge {
  left: 10px;
  top: 10px;
  background: var(--orange);
}

.movie-duration {
  right: 10px;
  bottom: 10px;
  background: rgba(0, 0, 0, 0.66);
}

.movie-info {
  display: grid;
  gap: 8px;
  padding: 16px;
}

.movie-info strong {
  font-size: 17px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  transition: color 0.2s ease;
}

.movie-card:hover .movie-info strong {
  color: var(--orange-dark);
}

.movie-desc {
  min-height: 44px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.movie-meta {
  color: #9ca3af;
  font-size: 13px;
}

.movie-tags span {
  color: #9a3412;
  background: #ffedd5;
}

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

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

.category-card {
  position: relative;
  min-height: 166px;
  display: grid;
  align-content: end;
  gap: 8px;
  overflow: hidden;
  padding: 26px;
  border-radius: var(--radius-md);
  color: white;
  box-shadow: var(--soft-shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:after {
  content: "";
  position: absolute;
  right: -26px;
  top: -26px;
  width: 118px;
  height: 118px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.20);
}

.category-tone-1 { background: linear-gradient(135deg, #60a5fa, #06b6d4); }
.category-tone-2 { background: linear-gradient(135deg, #a855f7, #ec4899); }
.category-tone-3 { background: linear-gradient(135deg, #ef4444, #f97316); }
.category-tone-4 { background: linear-gradient(135deg, #fb7185, #e11d48); }
.category-tone-5 { background: linear-gradient(135deg, #10b981, #14b8a6); }
.category-tone-6 { background: linear-gradient(135deg, #f59e0b, #f97316); }

.category-icon {
  position: absolute;
  top: 22px;
  left: 22px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: white;
  font-style: normal;
  font-weight: 900;
  background: rgba(255, 255, 255, 0.22);
}

.category-card strong {
  position: relative;
  z-index: 2;
  font-size: 24px;
}

.category-card em {
  position: relative;
  z-index: 2;
  color: rgba(255, 255, 255, 0.88);
  font-size: 14px;
  font-style: normal;
  line-height: 1.65;
}

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

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

.ranking-item {
  display: grid;
  grid-template-columns: 54px 104px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: var(--radius-md);
  background: white;
  box-shadow: var(--soft-shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.rank-num {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: white;
  font-weight: 900;
  background: linear-gradient(135deg, var(--orange), var(--pink));
}

.ranking-item img {
  width: 104px;
  height: 68px;
  object-fit: cover;
  border-radius: 14px;
}

.ranking-copy {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.ranking-copy strong,
.ranking-copy em,
.ranking-copy small {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.ranking-copy em {
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

.ranking-copy small {
  color: #9ca3af;
}

.page-hero {
  padding: 78px 0;
  color: white;
  text-align: center;
}

.page-hero-orange { background: linear-gradient(135deg, #fb923c, #ec4899); }
.page-hero-pink { background: linear-gradient(135deg, #ec4899, #a855f7); }
.page-hero-green { background: linear-gradient(135deg, #10b981, #059669); }
.page-hero-category { background: linear-gradient(135deg, #f97316, #f43f5e); }

.page-hero span {
  display: inline-flex;
  margin-bottom: 12px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-weight: 800;
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 54px);
}

.page-hero p {
  width: min(780px, 100%);
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.90);
  font-size: 18px;
  line-height: 1.8;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) repeat(3, 160px);
  gap: 12px;
  margin-bottom: 24px;
  padding: 16px;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid rgba(249, 115, 22, 0.18);
  border-radius: 14px;
}

.empty-state {
  padding: 36px;
  border-radius: var(--radius-md);
  color: var(--muted);
  text-align: center;
  background: white;
  box-shadow: var(--soft-shadow);
}

.detail-wrap {
  padding-top: 30px;
}

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

.breadcrumb a {
  color: var(--orange-dark);
  font-weight: 700;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 24px;
  align-items: start;
}

.detail-main {
  display: grid;
  gap: 18px;
}

.player-card {
  padding: 12px;
  background: #111827;
}

.player-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 18px;
  background: #020617;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  cursor: pointer;
  color: white;
  background: radial-gradient(circle at center, rgba(249, 115, 22, 0.28), rgba(0, 0, 0, 0.58));
}

.player-overlay span {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  padding-left: 5px;
  border-radius: 999px;
  color: white;
  font-size: 36px;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.32);
}

.player-overlay.is-hidden {
  display: none;
}

.detail-card {
  padding: 26px;
}

.detail-card h1 {
  margin: 0 0 16px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.18;
}

.detail-card h2,
.side-card h2 {
  margin: 26px 0 12px;
  font-size: 24px;
}

.detail-card p,
.side-card p {
  color: #4b5563;
  line-height: 1.9;
}

.lead-text {
  padding: 18px;
  border-left: 4px solid var(--orange);
  border-radius: 14px;
  background: #fff7ed;
  font-size: 17px;
}

.detail-meta span {
  color: #9a3412;
  background: #ffedd5;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.detail-tags span {
  color: #be123c;
  background: #ffe4e6;
}

.detail-sidebar {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 18px;
}

.side-poster {
  overflow: hidden;
  padding: 10px;
}

.side-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 16px;
}

.side-card {
  padding: 22px;
}

.side-card h2 {
  margin-top: 0;
}

.side-card a {
  color: var(--orange-dark);
  font-weight: 800;
}

.search-page-form {
  width: min(680px, 100%);
  margin: 26px auto 0;
  background: white;
}

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

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 30px;
  padding: 48px 0;
}

.footer-brand {
  color: white;
  font-size: 20px;
}

.site-footer p {
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.8;
}

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

.site-footer a:not(.footer-brand) {
  display: block;
  margin: 9px 0;
  color: rgba(255, 255, 255, 0.74);
  transition: color 0.2s ease;
}

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

.footer-bottom {
  padding: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
  color: rgba(255, 255, 255, 0.62);
  text-align: center;
}

@media (max-width: 1100px) {
  .hero-section,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .hero-side,
  .detail-sidebar {
    position: static;
  }

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

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

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .header-inner {
    height: 66px;
  }

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

  .hero-section {
    padding-top: 18px;
  }

  .hero-carousel {
    height: 460px;
  }

  .hero-content {
    padding: 34px 26px;
  }

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

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

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

  .hero-carousel {
    height: 430px;
    border-radius: 20px;
  }

  .hero-arrow {
    display: none;
  }

  .hero-mask {
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.30));
  }

  .hero-content {
    justify-content: end;
    padding: 26px;
  }

  .hero-content h1 {
    font-size: 34px;
  }

  .hero-content p {
    font-size: 15px;
  }

  .movie-grid,
  .category-grid,
  .ranking-grid,
  .ranking-grid-wide,
  .footer-grid,
  .filter-panel {
    grid-template-columns: 1fr;
  }

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

  .ranking-item img {
    width: 88px;
    height: 60px;
  }

  .page-hero {
    padding: 52px 0;
  }

  .detail-card,
  .side-card {
    padding: 20px;
  }

  .player-card {
    padding: 8px;
  }

  .player-overlay span {
    width: 70px;
    height: 70px;
    font-size: 30px;
  }
}
