:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --brand: #d97706;
  --brand-dark: #b45309;
  --brand-soft: #fff7ed;
  --orange: #ea580c;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --soft-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.85);
  backdrop-filter: blur(18px);
  box-shadow: 0 6px 22px rgba(15, 23, 42, 0.06);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

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

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--brand), var(--orange));
  color: white;
  box-shadow: 0 12px 24px rgba(217, 119, 6, 0.25);
}

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

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

.nav-link {
  position: relative;
  padding: 8px 2px;
  color: #374151;
  font-size: 15px;
  font-weight: 700;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1px;
  height: 2px;
  border-radius: 999px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

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

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

.header-search {
  display: flex;
  align-items: center;
  width: 270px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: white;
  overflow: hidden;
}

.header-search input,
.mobile-search input,
.search-panel input,
.search-panel select {
  border: 0;
  outline: 0;
  background: transparent;
}

.header-search input {
  width: 100%;
  padding: 10px 13px;
}

.header-search button,
.mobile-search button,
.search-panel button,
.primary-btn,
.ghost-btn,
.play-overlay button {
  border: 0;
  cursor: pointer;
  font-weight: 800;
}

.header-search button {
  padding: 10px 16px;
  background: var(--brand);
  color: white;
}

.nav-toggle {
  display: none;
  border: 0;
  background: white;
  color: var(--ink);
  width: 42px;
  height: 42px;
  border-radius: 12px;
  box-shadow: var(--soft-shadow);
  cursor: pointer;
}

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

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

.mobile-link {
  padding: 12px 14px;
  border-radius: 14px;
  background: white;
  color: #374151;
  font-weight: 800;
}

.mobile-link.active {
  color: var(--brand-dark);
  background: var(--brand-soft);
}

.mobile-search {
  display: flex;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: white;
}

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

.mobile-search button {
  padding: 0 16px;
  background: var(--brand);
  color: white;
}

main {
  min-height: 65vh;
}

.hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(circle at 12% 18%, rgba(251, 191, 36, 0.34), transparent 26%), linear-gradient(135deg, #fff7ed 0%, #fffbeb 45%, #fff 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.8));
  pointer-events: none;
}

.hero-wrap {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  min-height: 610px;
  margin: 0 auto;
  padding: 72px 0 58px;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(360px, 0.98fr);
  align-items: center;
  gap: 46px;
}

.hero-copy {
  position: relative;
  z-index: 3;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(217, 119, 6, 0.12);
  color: var(--brand-dark);
  font-weight: 900;
  font-size: 14px;
}

.hero h1,
.page-hero h1,
.detail-title h1 {
  margin: 18px 0 18px;
  color: var(--ink);
  font-size: clamp(34px, 6vw, 68px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.hero h1 span,
.page-hero h1 span {
  color: var(--brand-dark);
}

.hero-copy p {
  max-width: 650px;
  margin: 0 0 26px;
  color: #4b5563;
  font-size: 19px;
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 13px 22px;
  border-radius: 15px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  background: linear-gradient(135deg, var(--brand), var(--orange));
  color: white;
  box-shadow: 0 14px 24px rgba(217, 119, 6, 0.22);
}

.ghost-btn {
  background: white;
  color: var(--brand-dark);
  box-shadow: var(--soft-shadow);
}

.primary-btn:hover,
.ghost-btn:hover {
  transform: translateY(-2px) scale(1.01);
}

.hero-slider {
  position: relative;
  z-index: 2;
  min-height: 510px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  border-radius: 34px;
  background: #111827;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateX(24px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.45s ease, transform 0.45s ease;
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  min-height: 510px;
  object-fit: cover;
  opacity: 0.94;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.77));
}

.slide-caption {
  position: absolute;
  left: 26px;
  right: 26px;
  bottom: 26px;
  z-index: 2;
  color: white;
}

.slide-caption h2 {
  margin: 8px 0;
  font-size: clamp(26px, 4vw, 42px);
  line-height: 1.08;
}

.slide-caption p {
  margin: 0 0 16px;
  max-width: 560px;
  color: rgba(255, 255, 255, 0.88);
}

.slide-meta,
.meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.slide-meta span,
.meta-line span,
.tag-row span,
.breadcrumbs a,
.breadcrumbs span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: inherit;
  font-size: 12px;
  font-weight: 800;
}

.hero-dots {
  position: absolute;
  left: 26px;
  top: 26px;
  z-index: 4;
  display: flex;
  gap: 8px;
}

.hero-dots button {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.active {
  width: 28px;
  background: white;
}

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

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

.section-title h2,
.page-section h2,
.content-panel h2 {
  margin: 0 0 8px;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-title p,
.page-section > p,
.content-panel p {
  margin: 0;
  color: var(--muted);
}

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: white;
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #fde68a, #f97316);
}

.movie-card.wide .poster-link {
  aspect-ratio: 16 / 10;
}

.poster-link img,
.rank-cover img,
.related-card img,
.category-sample img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.movie-card:hover img,
.rank-item:hover img,
.related-card:hover img,
.category-card:hover img {
  transform: scale(1.06);
}

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.58));
}

.play-chip {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 900;
}

.movie-info {
  padding: 16px;
}

.movie-info h2,
.rank-item h2,
.related-card h2 {
  margin: 9px 0 8px;
  font-size: 18px;
  line-height: 1.25;
}

.movie-info p,
.rank-item p,
.related-card p {
  color: var(--muted);
  margin: 0 0 12px;
  font-size: 14px;
}

.meta-line span {
  background: var(--brand-soft);
  color: var(--brand-dark);
}

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

.tag-row span {
  background: #f3f4f6;
  color: #4b5563;
}

.channel-band {
  background: linear-gradient(135deg, #111827 0%, #7c2d12 100%);
  color: white;
}

.channel-band .section-title p,
.channel-band .section-title h2 {
  color: white;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 214px;
  padding: 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease;
}

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

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

.category-card p {
  margin: 0 0 14px;
  color: rgba(255, 255, 255, 0.82);
}

.category-samples {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 16px;
}

.category-sample {
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.14);
}

.page-hero {
  background: radial-gradient(circle at 18% 0%, rgba(251, 191, 36, 0.35), transparent 30%), linear-gradient(135deg, #fff7ed 0%, #ffffff 100%);
  border-bottom: 1px solid var(--line);
}

.page-hero-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 58px 0;
}

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

.search-panel {
  display: grid;
  grid-template-columns: 1fr 180px 180px;
  gap: 12px;
  margin: 26px 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: white;
  box-shadow: var(--soft-shadow);
}

.search-panel input,
.search-panel select {
  width: 100%;
  padding: 13px 14px;
  border-radius: 14px;
  background: #f9fafb;
  color: var(--ink);
}

.search-panel button {
  padding: 13px 16px;
  border-radius: 14px;
  background: var(--brand);
  color: white;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 118px 1fr;
  gap: 16px;
  padding: 14px;
  border-radius: 22px;
  background: white;
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.rank-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.rank-cover {
  position: relative;
  height: 148px;
  overflow: hidden;
  border-radius: 16px;
  background: var(--brand-soft);
}

.rank-cover span {
  position: absolute;
  left: 10px;
  top: 10px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(217, 119, 6, 0.94);
  color: white;
  font-weight: 900;
}

.breadcrumbs {
  width: min(1180px, calc(100% - 32px));
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 24px auto 0;
  color: var(--brand-dark);
}

.breadcrumbs a,
.breadcrumbs span {
  background: white;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

.detail-layout {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 26px;
  align-items: start;
}

.player-card,
.content-panel,
.side-panel {
  border-radius: 26px;
  background: white;
  box-shadow: var(--soft-shadow);
  overflow: hidden;
}

.video-shell {
  position: relative;
  overflow: hidden;
  background: #020617;
  aspect-ratio: 16 / 9;
}

.video-shell video {
  width: 100%;
  height: 100%;
  background: #020617;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.06), rgba(2, 6, 23, 0.72));
  cursor: pointer;
  z-index: 2;
}

.play-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.play-overlay button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 24px;
  border-radius: 999px;
  background: white;
  color: var(--brand-dark);
  box-shadow: var(--shadow);
}

.play-overlay button span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--brand), var(--orange));
  color: white;
}

.detail-title {
  padding: 24px;
}

.detail-title h1 {
  font-size: clamp(30px, 5vw, 52px);
  margin-top: 12px;
}

.content-panel {
  margin-top: 24px;
  padding: 26px;
}

.content-panel h2 {
  margin-top: 0;
}

.content-panel p {
  color: #374151;
  font-size: 17px;
}

.side-panel {
  padding: 20px;
}

.side-panel h2 {
  margin: 0 0 16px;
  font-size: 22px;
}

.side-meta {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
}

.side-meta div {
  padding: 12px;
  border-radius: 14px;
  background: #f9fafb;
}

.side-meta strong {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

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

.related-card {
  overflow: hidden;
  border-radius: 20px;
  background: white;
  box-shadow: var(--soft-shadow);
}

.related-card a:first-child {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--brand-soft);
}

.related-card div {
  padding: 14px;
}

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

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

.site-footer {
  margin-top: 70px;
  background: #111827;
  color: #d1d5db;
}

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

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

.site-footer h2 {
  color: white;
  margin: 0 0 12px;
  font-size: 18px;
}

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

.compact-links {
  grid-template-columns: repeat(2, 1fr);
}

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

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

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

  .nav-toggle {
    display: grid;
    place-items: center;
    margin-left: auto;
  }

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

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

  .hero-slide img {
    min-height: 440px;
  }

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

  .rank-list,
  .related-grid {
    grid-template-columns: 1fr;
  }

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

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

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

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

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

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

  .hero-slide img {
    min-height: 390px;
  }

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

  .section,
  .page-section {
    padding: 42px 0;
  }

  .section-title {
    display: block;
  }

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

  .rank-item {
    grid-template-columns: 92px 1fr;
  }

  .rank-cover {
    height: 122px;
  }

  .content-panel,
  .side-panel,
  .detail-title {
    padding: 18px;
  }
}

@media (max-width: 460px) {
  .movie-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .hero-actions,
  .section-actions,
  .detail-actions {
    display: grid;
  }

  .primary-btn,
  .ghost-btn {
    width: 100%;
  }
}
