:root {
  color-scheme: light;
  --bg: #fff7ed;
  --bg-soft: #fef3c7;
  --surface: #ffffff;
  --surface-soft: #fffbeb;
  --text: #451a03;
  --muted: #92400e;
  --line: #fed7aa;
  --brand: #d97706;
  --brand-dark: #92400e;
  --accent: #dc2626;
  --accent-dark: #7f1d1d;
  --shadow: 0 20px 60px rgba(120, 53, 15, 0.14);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #fffbeb 0%, #fff7ed 42%, #f5f5f4 100%);
}

body.menu-open {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 251, 235, 0.92);
  border-bottom: 1px solid rgba(217, 119, 6, 0.2);
  box-shadow: 0 12px 30px rgba(120, 53, 15, 0.08);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 26px;
  font-weight: 900;
  color: var(--brand-dark);
  letter-spacing: -0.04em;
}

.brand-icon {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  border-radius: 14px;
  background: linear-gradient(135deg, #f59e0b, #b91c1c);
  box-shadow: 0 10px 28px rgba(185, 28, 28, 0.28);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  white-space: nowrap;
}

.nav-link,
.mobile-nav-link {
  font-weight: 700;
  color: var(--muted);
  transition: color 0.2s ease, background 0.2s ease;
}

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

.header-search,
.mobile-search,
.wide-search {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-search input,
.mobile-search input,
.wide-search input,
.filter-bar input,
.filter-bar select {
  border: 2px solid rgba(217, 119, 6, 0.28);
  outline: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.9);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input,
.mobile-search input {
  width: 245px;
  padding: 11px 16px;
  border-radius: 999px;
}

.header-search input:focus,
.mobile-search input:focus,
.wide-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.header-search button,
.mobile-search button,
.wide-search button {
  border: 0;
  color: #fff;
  background: linear-gradient(135deg, #d97706, #b91c1c);
  border-radius: 999px;
  padding: 11px 18px;
  cursor: pointer;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(217, 119, 6, 0.24);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: rgba(251, 191, 36, 0.18);
  cursor: pointer;
}

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

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

.mobile-panel.open {
  display: block;
}

.mobile-search {
  margin-bottom: 12px;
}

.mobile-search input {
  width: 100%;
}

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

.mobile-nav-link {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 247, 237, 0.8);
}

.hero {
  position: relative;
  min-height: 70vh;
  background: #111827;
  overflow: hidden;
}

.hero-stage,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  transition: opacity 1s ease;
  pointer-events: none;
}

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

.hero-slide img {
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
}

.hero-layer {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 76% 24%, rgba(245, 158, 11, 0.28), transparent 32%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.52) 46%, rgba(0, 0, 0, 0.18)),
    linear-gradient(0deg, rgba(0, 0, 0, 0.82), transparent 58%);
}

.hero-content {
  position: absolute;
  left: max(32px, calc((100vw - 1240px) / 2));
  bottom: 76px;
  width: min(780px, calc(100% - 64px));
  color: #fff;
}

.hero-label,
.eyebrow {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #fbbf24;
}

.hero-content h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 1.02;
  font-weight: 950;
  letter-spacing: -0.06em;
  text-shadow: 0 12px 42px rgba(0, 0, 0, 0.55);
}

.hero-summary {
  max-width: 680px;
  margin: 22px 0 0;
  color: #fef3c7;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.75;
}

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

.hero-tags {
  margin-top: 20px;
}

.hero-tags span,
.detail-tags a,
.card-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.hero-tags span {
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(12px);
}

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

.primary-button,
.glass-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-radius: 999px;
  padding: 0 24px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #b91c1c);
  box-shadow: 0 18px 34px rgba(185, 28, 28, 0.35);
}

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

.glass-button {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(14px);
}

.glass-button.dark {
  color: var(--brand-dark);
  border-color: rgba(146, 64, 14, 0.18);
  background: rgba(255, 255, 255, 0.74);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 52px;
  height: 52px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.34);
  cursor: pointer;
  font-size: 38px;
  line-height: 1;
  backdrop-filter: blur(8px);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
}

.hero-dot.active {
  background: #fbbf24;
}

.quick-search-panel,
.content-section {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
}

.quick-search-panel {
  position: relative;
  z-index: 10;
  margin-top: -38px;
}

.quick-search-inner {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(300px, 520px);
  gap: 26px;
  align-items: center;
  padding: 28px;
  border: 1px solid rgba(217, 119, 6, 0.22);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.quick-search-inner h2,
.section-head h2,
.page-hero h1,
.detail-info h1,
.detail-article h2 {
  margin: 0;
  color: var(--text);
  font-weight: 950;
  letter-spacing: -0.05em;
}

.quick-search-inner h2,
.section-head h2 {
  font-size: clamp(28px, 4vw, 42px);
}

.quick-search-inner span,
.section-head span,
.page-hero p {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.75;
}

.wide-search input {
  flex: 1;
  min-width: 0;
  padding: 15px 18px;
  border-radius: 18px;
}

.content-section {
  padding: 72px 0 0;
}

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

.section-more {
  color: var(--brand-dark);
  font-weight: 900;
}

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

.category-pill,
.category-card a {
  display: block;
  height: 100%;
  padding: 20px;
  border: 1px solid rgba(217, 119, 6, 0.2);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(254, 243, 199, 0.72));
  box-shadow: 0 16px 40px rgba(120, 53, 15, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-pill:hover,
.category-card a:hover,
.movie-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 58px rgba(120, 53, 15, 0.18);
}

.category-pill strong,
.category-card h2 {
  display: block;
  color: var(--accent-dark);
  font-size: 20px;
  font-weight: 950;
}

.category-pill span,
.category-card p {
  display: block;
  margin-top: 9px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(217, 119, 6, 0.18);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 14px 32px rgba(120, 53, 15, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card.hidden {
  display: none;
}

.card-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #451a03, #b91c1c);
}

.detail-poster,
.card-cover {
  isolation: isolate;
}

.card-cover img {
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.card-shadow {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgba(0, 0, 0, 0.72));
  opacity: 0.78;
}

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 900;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  min-height: 34px;
  padding: 0 14px;
  color: #fff;
  background: rgba(185, 28, 28, 0.9);
  backdrop-filter: blur(10px);
}

.rank-badge {
  top: 12px;
  left: 12px;
  min-width: 38px;
  height: 38px;
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #b91c1c);
  box-shadow: 0 10px 22px rgba(185, 28, 28, 0.32);
}

.card-body {
  padding: 18px;
}

.card-body h3 {
  margin: 0;
  min-height: 54px;
  color: var(--accent-dark);
  font-size: 19px;
  line-height: 1.4;
  font-weight: 950;
}

.card-body h3 a:hover {
  color: var(--brand-dark);
}

.card-body p {
  display: -webkit-box;
  min-height: 48px;
  margin: 10px 0 14px;
  overflow: hidden;
  color: #7c2d12;
  font-size: 14px;
  line-height: 1.7;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.card-tags {
  margin-top: 12px;
}

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

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 76% 20%, rgba(245, 158, 11, 0.32), transparent 32%),
    linear-gradient(135deg, #451a03, #7f1d1d 56%, #f59e0b);
}

.page-hero {
  padding: 92px 0 84px;
}

.slim-hero {
  padding: 76px 0 68px;
}

.page-hero-inner {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  color: #fff;
}

.page-hero h1 {
  color: #fff;
  font-size: clamp(40px, 7vw, 74px);
}

.page-hero p {
  max-width: 760px;
  color: #ffedd5;
  font-size: 18px;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 180px 180px;
  gap: 14px;
  margin-bottom: 28px;
  padding: 16px;
  border: 1px solid rgba(217, 119, 6, 0.18);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 28px rgba(120, 53, 15, 0.08);
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 16px;
}

.empty-state {
  display: none;
  margin: 30px 0;
  padding: 24px;
  border-radius: 20px;
  text-align: center;
  color: var(--muted);
  background: #fff7ed;
}

.empty-state.visible {
  display: block;
}

.detail-hero {
  min-height: 620px;
  color: #fff;
}

.detail-backdrop,
.detail-hero-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.detail-backdrop {
  object-fit: cover;
  filter: blur(4px) saturate(1.08);
  transform: scale(1.04);
}

.detail-hero-layer {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.52) 46%, rgba(0, 0, 0, 0.25)),
    linear-gradient(0deg, rgba(69, 26, 3, 0.86), transparent 50%);
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0 58px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  color: #fed7aa;
  font-weight: 800;
}

.breadcrumb a:hover {
  color: #fff;
}

.detail-top {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 42px;
  align-items: end;
  min-height: 470px;
  padding-top: 34px;
}

.detail-poster {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 28px;
  background: linear-gradient(135deg, #451a03, #b91c1c);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.38);
}

.detail-poster img {
  aspect-ratio: 3 / 4;
  height: auto;
  object-fit: cover;
}

.detail-info h1 {
  color: #fff;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.08;
}

.detail-line {
  max-width: 800px;
  margin: 18px 0 0;
  color: #ffedd5;
  font-size: 19px;
  line-height: 1.8;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.detail-meta span {
  padding: 8px 13px;
  border-radius: 999px;
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.detail-tags {
  margin-top: 18px;
}

.detail-tags a {
  color: #fff;
  background: rgba(245, 158, 11, 0.32);
}

.player-section {
  width: min(1100px, calc(100% - 32px));
  margin: -46px auto 0;
  position: relative;
  z-index: 5;
}

.player-wrap {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 28px;
  background: #000;
  box-shadow: 0 30px 80px rgba(69, 26, 3, 0.32);
}

.movie-player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background: radial-gradient(circle at center, rgba(185, 28, 28, 0.2), rgba(0, 0, 0, 0.36));
  cursor: pointer;
}

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

.player-icon {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding-left: 6px;
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #b91c1c);
  box-shadow: 0 20px 52px rgba(185, 28, 28, 0.42);
  font-size: 34px;
}

.player-overlay strong {
  font-size: 22px;
}

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

.detail-article {
  display: grid;
  gap: 16px;
  padding: 30px;
  border: 1px solid rgba(217, 119, 6, 0.18);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 44px rgba(120, 53, 15, 0.08);
}

.detail-article h2 {
  margin-top: 12px;
  font-size: 30px;
}

.detail-article p {
  margin: 0;
  color: #7c2d12;
  font-size: 17px;
  line-height: 1.9;
}

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

.info-list div {
  padding: 14px 16px;
  border-radius: 16px;
  background: #fff7ed;
}

.info-list dt {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.info-list dd {
  margin: 5px 0 0;
  color: var(--text);
  font-weight: 800;
}

.site-footer {
  margin-top: 86px;
  color: #ffedd5;
  background:
    radial-gradient(circle at 18% 8%, rgba(245, 158, 11, 0.22), transparent 28%),
    linear-gradient(135deg, #451a03, #7f1d1d);
}

.footer-inner {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(260px, 0.7fr);
  gap: 34px;
  padding: 48px 0;
}

.footer-logo {
  color: #fff;
}

.footer-brand p {
  max-width: 720px;
  color: #fed7aa;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-content: start;
}

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
  color: #ffedd5;
  background: rgba(255, 255, 255, 0.1);
}

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  color: #fed7aa;
  text-align: center;
}

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

  .menu-toggle {
    display: block;
  }

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

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

@media (max-width: 820px) {
  .header-inner {
    height: 66px;
  }

  .brand-name {
    font-size: 23px;
  }

  .hero {
    min-height: 76vh;
  }

  .hero-content {
    left: 20px;
    bottom: 72px;
    width: calc(100% - 40px);
  }

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

  .hero-arrow {
    top: auto;
    bottom: 24px;
    width: 44px;
    height: 44px;
    font-size: 31px;
  }

  .hero-prev {
    left: 20px;
  }

  .hero-next {
    right: 20px;
  }

  .quick-search-inner,
  .footer-inner,
  .detail-top {
    grid-template-columns: 1fr;
  }

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

  .wide-search {
    display: grid;
  }

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

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

  .detail-poster {
    width: min(280px, 80vw);
  }

  .info-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 540px) {
  .content-section {
    padding-top: 52px;
  }

  .movie-grid,
  .channel-grid,
  .ranking-grid,
  .category-pills,
  .category-card-grid {
    grid-template-columns: 1fr;
  }

  .hero-actions,
  .page-actions {
    display: grid;
  }

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

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

  .detail-hero {
    min-height: auto;
  }

  .detail-top {
    min-height: auto;
    gap: 26px;
  }

  .detail-info h1 {
    font-size: 36px;
  }

  .player-section {
    margin-top: 24px;
  }
}
