:root {
  --page-bg: #fff7ed;
  --page-bg-2: #fffbeb;
  --ink: #1f2937;
  --muted: #6b7280;
  --line: #fed7aa;
  --brand: #f97316;
  --brand-dark: #ea580c;
  --brand-soft: #ffedd5;
  --card: #ffffff;
  --shadow: 0 18px 40px rgba(124, 45, 18, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(180deg, var(--page-bg), var(--page-bg-2));
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

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, #fffbeb, #fff7ed);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 4px 18px rgba(124, 45, 18, 0.08);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 22px;
  font-weight: 800;
  border-radius: 12px;
  background: linear-gradient(135deg, #fb923c, #f59e0b);
  box-shadow: 0 10px 20px rgba(249, 115, 22, 0.25);
  transition: transform 0.2s ease;
}

.brand:hover .brand-mark {
  transform: scale(1.08);
}

.brand-text {
  font-size: 20px;
  font-weight: 800;
  color: var(--ink);
  white-space: nowrap;
}

.top-search {
  display: flex;
  align-items: center;
  flex: 1 1 320px;
  max-width: 420px;
  position: relative;
}

.top-search input {
  width: 100%;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 46px 0 16px;
  background: #ffffff;
  outline: none;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.top-search input:focus {
  border-color: #fb923c;
  box-shadow: 0 0 0 3px rgba(251, 146, 60, 0.22);
}

.top-search button {
  position: absolute;
  right: 6px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 10px;
  background: var(--brand);
  color: #ffffff;
  cursor: pointer;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 15px;
  font-weight: 600;
  color: #374151;
  white-space: nowrap;
}

.desktop-nav a,
.mobile-nav a {
  transition: color 0.2s ease;
}

.desktop-nav a:hover,
.mobile-nav a:hover {
  color: var(--brand-dark);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  cursor: pointer;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 14px 0 18px;
  border-top: 1px solid var(--line);
}

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

.hero-slider {
  position: relative;
  height: 500px;
  overflow: hidden;
  background: #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.9s ease;
  pointer-events: none;
}

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

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.12));
}

.hero-content {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  color: #ffffff;
  max-width: 1180px;
}

.hero-eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  margin-bottom: 12px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-content h1 {
  margin: 0 0 8px;
  font-size: clamp(28px, 6vw, 54px);
  line-height: 1.05;
  font-weight: 900;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.hero-content h2 {
  margin: 0 0 16px;
  font-size: clamp(26px, 5vw, 48px);
  line-height: 1.08;
  font-weight: 900;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.hero-content p {
  width: min(620px, 100%);
  margin: 0 0 22px;
  color: #e5e7eb;
  font-size: 18px;
  line-height: 1.75;
}

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

.hero-tag,
.tag-pill,
.mini-tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
}

.hero-tag {
  padding: 5px 12px;
  color: #ffffff;
  background: rgba(249, 115, 22, 0.82);
  backdrop-filter: blur(8px);
  font-size: 14px;
}

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

.primary-button,
.secondary-button,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.primary-button {
  padding: 0 28px;
  color: #ffffff;
  background: var(--brand);
  box-shadow: 0 14px 26px rgba(249, 115, 22, 0.26);
}

.primary-button:hover {
  background: var(--brand-dark);
  transform: translateY(-2px);
}

.secondary-button {
  padding: 0 24px;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.52);
  background: rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(8px);
}

.secondary-button:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-2px);
}

.hero-nav {
  position: absolute;
  top: 50%;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.48);
  font-size: 34px;
  line-height: 1;
  transform: translateY(-50%);
  cursor: pointer;
  transition: background 0.2s ease;
}

.hero-nav:hover {
  background: rgba(0, 0, 0, 0.72);
}

.hero-prev {
  left: 20px;
}

.hero-next {
  right: 20px;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.56);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

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

.section-block {
  padding: 44px 0;
}

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

.section-title h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.2;
}

.section-title a,
.text-link {
  color: var(--brand-dark);
  font-weight: 800;
}

.movie-grid {
  display: grid;
  gap: 22px;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 16px;
  background: var(--card);
  box-shadow: 0 8px 22px rgba(124, 45, 18, 0.09);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.card-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #e5e7eb;
}

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

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

.card-shade {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  transition: background 0.25s ease;
}

.movie-card:hover .card-shade {
  background: rgba(0, 0, 0, 0.28);
}

.play-dot,
.rail-play,
.large-play {
  display: grid;
  place-items: center;
  color: #ffffff;
  background: var(--brand);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.32);
}

.play-dot {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.76);
  transition: opacity 0.24s ease, transform 0.24s ease;
}

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

.year-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.year-badge {
  right: 10px;
  top: 10px;
  padding: 4px 9px;
  background: rgba(0, 0, 0, 0.68);
}

.rank-badge {
  left: 10px;
  top: 10px;
  min-width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #f97316, #f59e0b);
}

.card-body {
  padding: 14px;
}

.card-body h3 {
  margin: 0;
  font-size: 17px;
  line-height: 1.35;
}

.card-body h3 a {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

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

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

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #6b7280;
  font-size: 12px;
  margin-bottom: 10px;
}

.mini-tag {
  padding: 3px 8px;
  color: #c2410c;
  background: #ffedd5;
  font-size: 12px;
}

.movie-rail {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 4px 2px 14px;
  scroll-snap-type: x mandatory;
}

.movie-rail::-webkit-scrollbar {
  height: 8px;
}

.movie-rail::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: #fdba74;
}

.rail-card {
  position: relative;
  flex: 0 0 260px;
  display: block;
  overflow: hidden;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(124, 45, 18, 0.09);
  scroll-snap-align: start;
}

.rail-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.rail-play {
  position: absolute;
  top: 58px;
  left: 50%;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.8);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.rail-card strong,
.rail-card small {
  display: block;
  padding: 0 14px;
}

.rail-card strong {
  margin-top: 12px;
  font-size: 16px;
}

.rail-card small {
  margin: 6px 0 14px;
  color: var(--muted);
}

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

.category-card {
  display: flex;
  min-height: 260px;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 18px;
  padding: 22px;
  background: linear-gradient(145deg, #ffffff, #fff7ed);
  box-shadow: 0 8px 22px rgba(124, 45, 18, 0.09);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, #fb923c, #f59e0b);
  font-weight: 900;
}

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

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

.category-samples {
  display: grid;
  gap: 7px;
  margin: 16px 0;
  font-size: 14px;
}

.category-samples a {
  color: #9a3412;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.ranking-section {
  padding-top: 22px;
}

.ranking-list {
  display: grid;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.ranking-list li {
  display: grid;
  grid-template-columns: 46px 1fr auto;
  align-items: center;
  gap: 14px;
  border-radius: 14px;
  padding: 14px 16px;
  background: #ffffff;
  box-shadow: 0 6px 16px rgba(124, 45, 18, 0.08);
}

.ranking-list span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: #ffffff;
  background: var(--brand);
  font-weight: 900;
}

.ranking-list a {
  font-weight: 800;
}

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

.page-main {
  min-height: 70vh;
}

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

.compact-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(32px, 5vw, 48px);
  line-height: 1.12;
}

.compact-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

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

.breadcrumb a:hover {
  color: var(--brand-dark);
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 160px 160px auto;
  gap: 12px;
  margin-bottom: 14px;
  border-radius: 18px;
  padding: 14px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(124, 45, 18, 0.08);
}

.filter-panel input,
.filter-panel select,
.filter-panel button {
  width: 100%;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  color: var(--ink);
  padding: 0 12px;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #fb923c;
  box-shadow: 0 0 0 3px rgba(251, 146, 60, 0.18);
}

.filter-panel button {
  color: #ffffff;
  background: var(--brand);
  border-color: var(--brand);
  cursor: pointer;
  font-weight: 800;
}

.filter-result {
  min-height: 22px;
  margin: 0 0 22px;
  color: var(--muted);
}

[data-card].is-hidden {
  display: none;
}

.player-section {
  padding: 28px 0 0;
  background: linear-gradient(180deg, #111827, #1f2937 72%, transparent 72%);
}

.detail-breadcrumb {
  color: #e5e7eb;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  aspect-ratio: 16 / 9;
  background: #000000;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

.watch-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000000;
  cursor: pointer;
}

.watch-poster-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 0;
  padding: 0;
  background: #000000;
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.watch-poster-layer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.watch-poster-layer.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.video-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0.66));
}

.large-play {
  position: absolute;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  font-size: 34px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.watch-poster-layer:hover .large-play {
  transform: scale(1.08);
  background: var(--brand-dark);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) 330px;
  gap: 28px;
  padding: 38px 0 8px;
}

.detail-card,
.side-card {
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(124, 45, 18, 0.09);
}

.detail-card {
  padding: 30px;
}

.detail-card h1 {
  margin: 0 0 16px;
  font-size: clamp(30px, 5vw, 44px);
  line-height: 1.12;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  color: var(--muted);
}

.detail-meta span {
  border-radius: 999px;
  padding: 6px 10px;
  background: #fff7ed;
}

.tag-pill {
  padding: 6px 12px;
  color: #c2410c;
  background: #ffedd5;
  font-size: 14px;
}

.detail-card section {
  margin-top: 28px;
}

.detail-card h2 {
  margin: 0 0 12px;
  font-size: 22px;
}

.detail-card p {
  margin: 0;
  color: #374151;
  font-size: 16px;
  line-height: 1.9;
}

.side-card {
  position: sticky;
  top: 90px;
  align-self: start;
  padding: 18px;
}

.side-card img {
  width: 100%;
  border-radius: 14px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  margin-bottom: 18px;
}

.side-card h2 {
  margin: 0 0 12px;
  font-size: 20px;
}

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

.side-links a {
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff7ed;
  color: #9a3412;
  font-weight: 700;
}

.site-footer {
  margin-top: 42px;
  background: linear-gradient(90deg, #1f2937, #111827);
  color: #d1d5db;
}

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

.footer-inner h3,
.footer-inner h4 {
  margin: 0 0 14px;
  color: #ffffff;
}

.footer-inner p,
.footer-inner ul {
  margin: 0;
  padding: 0;
  color: #9ca3af;
  list-style: none;
  line-height: 1.8;
}

.footer-inner a:hover {
  color: #fdba74;
}

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

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

  .menu-toggle {
    display: grid;
    place-items: center;
  }

  .top-search {
    max-width: none;
  }

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

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

  .side-card {
    position: static;
  }

  .footer-inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .header-inner {
    height: auto;
    min-height: 64px;
    flex-wrap: wrap;
    padding: 10px 0;
  }

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

  .top-search {
    order: 3;
    flex-basis: 100%;
  }

  .hero-slider {
    height: 560px;
  }

  .hero-overlay {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.68));
  }

  .hero-content {
    justify-content: flex-end;
    padding-bottom: 78px;
  }

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

  .hero-nav {
    display: none;
  }

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

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

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

  .ranking-list li {
    grid-template-columns: 40px 1fr;
  }

  .ranking-list em {
    grid-column: 2;
  }

  .detail-card {
    padding: 22px;
  }

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

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

  .rail-card {
    flex-basis: 230px;
  }

  .large-play {
    width: 68px;
    height: 68px;
  }
}
