:root {
  --primary: #f97316;
  --primary-dark: #ea580c;
  --primary-soft: #fff7ed;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --card: #ffffff;
  --page: #f9fafb;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, .10), 0 2px 4px -1px rgba(0, 0, 0, .06);
  --shadow-xl: 0 24px 40px -16px rgba(15, 23, 42, .35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--page);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  line-height: 1.6;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .94);
  border-bottom: 1px solid rgba(229, 231, 235, .9);
  backdrop-filter: blur(16px);
}

.header-inner,
.footer-inner,
.content-section,
.home-search,
.detail-content,
.player-section {
  max-width: 1280px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: .02em;
  color: var(--ink);
  white-space: nowrap;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #fb923c);
  border-radius: 999px;
  box-shadow: 0 12px 24px rgba(249, 115, 22, .32);
}

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

.nav-link {
  padding: 8px 12px;
  border-radius: 999px;
  color: #374151;
  font-weight: 600;
  transition: color .2s ease, background .2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--primary-dark);
  background: var(--primary-soft);
}

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

.mobile-nav {
  display: none;
  flex-direction: column;
  padding: 8px 24px 18px;
  border-top: 1px solid var(--line);
}

.mobile-nav.is-open {
  display: flex;
}

.hero {
  position: relative;
  min-height: 640px;
  overflow: hidden;
  background: #0f172a;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) 360px;
  align-items: center;
  gap: 48px;
  padding: 96px max(24px, calc((100vw - 1280px) / 2 + 24px)) 88px;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity .7s ease, transform 1s ease;
  background-image:
    linear-gradient(90deg, rgba(15, 23, 42, .96), rgba(15, 23, 42, .62) 48%, rgba(15, 23, 42, .25)),
    linear-gradient(0deg, rgba(15, 23, 42, .82), rgba(15, 23, 42, .06)),
    var(--hero-image);
  background-size: cover;
  background-position: center;
}

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

.hero-content {
  max-width: 760px;
  color: #fff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: #fed7aa;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.08;
  letter-spacing: -.04em;
}

.hero p {
  max-width: 680px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, .84);
  font-size: 18px;
}

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

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

.hero-tags span,
.detail-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  color: #9a3412;
  background: #ffedd5;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags span {
  color: #fff7ed;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .18);
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.primary-btn {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #fb923c);
  box-shadow: 0 16px 30px rgba(249, 115, 22, .32);
}

.ghost-btn {
  color: #fff;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .22);
}

.detail-actions .ghost-btn,
.section-more {
  color: var(--primary-dark);
  background: var(--primary-soft);
  border: 1px solid #fed7aa;
}

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

.hero-poster {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: var(--shadow-xl);
  transform: rotate(2deg);
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: linear-gradient(135deg, #1f2937, #111827);
}

.hero-poster span {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 64px;
  height: 64px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: rgba(249, 115, 22, .95);
  border-radius: 999px;
  transform: translate(-50%, -50%);
}

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

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

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

.home-search {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(320px, 1fr);
  align-items: center;
  gap: 28px;
  margin-top: 36px;
}

.home-search h2,
.section-heading h2,
.detail-article h2,
.detail-side h2 {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.2;
  letter-spacing: -.02em;
}

.home-search p,
.section-heading p,
.page-hero p {
  margin: 10px 0 0;
  color: var(--muted);
}

.filter-panel {
  display: grid;
  gap: 14px;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.search-box {
  display: grid;
  gap: 8px;
  color: #374151;
  font-weight: 700;
}

.search-box input {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  outline: none;
}

.search-box input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, .14);
}

.quick-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.quick-filters button {
  min-height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-weight: 800;
  cursor: pointer;
}

.content-section {
  padding-top: 52px;
  padding-bottom: 24px;
}

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

.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  font-weight: 800;
  white-space: nowrap;
}

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

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

.movie-card {
  overflow: hidden;
  background: var(--card);
  border: 1px solid rgba(229, 231, 235, .82);
  border-radius: 18px;
  box-shadow: var(--shadow);
  transition: transform .24s ease, box-shadow .24s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, .10), 0 8px 10px -6px rgba(0, 0, 0, .10);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, #111827, #374151);
}

.poster-link img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  transition: transform .5s ease;
}

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

.type-badge,
.rank-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 4px 8px;
  color: #fff;
  background: rgba(0, 0, 0, .72);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.rank-badge {
  left: 10px;
  right: auto;
  background: var(--primary);
}

.poster-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 50px;
  height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: rgba(249, 115, 22, .92);
  border-radius: 999px;
  opacity: 0;
  transform: translate(-50%, -50%) scale(.9);
  transition: opacity .2s ease, transform .2s ease;
}

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

.movie-card-body {
  padding: 16px;
}

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

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

.movie-card p {
  display: -webkit-box;
  min-height: 45px;
  margin: 0 0 12px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: #4b5563;
  font-size: 13px;
  font-weight: 700;
}

.tag-row {
  margin-top: 10px;
}

.tag-row span {
  min-height: 24px;
  font-size: 12px;
}

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

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

.category-tile {
  position: relative;
  min-height: 180px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  padding: 22px;
  color: #fff;
  background-image:
    linear-gradient(0deg, rgba(15, 23, 42, .90), rgba(15, 23, 42, .20)),
    var(--tile-image);
  background-size: cover;
  background-position: center;
  border-radius: 20px;
  box-shadow: var(--shadow);
  transition: transform .24s ease, box-shadow .24s ease;
}

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

.category-tile span {
  font-size: 22px;
  font-weight: 900;
}

.category-tile strong {
  color: rgba(255, 255, 255, .82);
  font-size: 14px;
  font-weight: 600;
}

.page-hero,
.detail-hero {
  color: #fff;
  background: #111827;
}

.compact-hero {
  min-height: 320px;
  display: flex;
  align-items: center;
  padding: 86px max(24px, calc((100vw - 1280px) / 2 + 24px)) 56px;
  background-image:
    radial-gradient(circle at 20% 20%, rgba(249, 115, 22, .34), transparent 34%),
    linear-gradient(135deg, #111827, #1f2937 48%, #431407);
}

.rank-hero {
  background-image:
    radial-gradient(circle at 78% 25%, rgba(249, 115, 22, .35), transparent 34%),
    linear-gradient(135deg, #111827, #1f2937 52%, #7c2d12);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  background-image:
    linear-gradient(90deg, rgba(15, 23, 42, .96), rgba(15, 23, 42, .74), rgba(15, 23, 42, .32)),
    var(--detail-image);
  background-size: cover;
  background-position: center;
}

.detail-hero-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 88px 24px 60px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
  color: rgba(255, 255, 255, .72);
  font-size: 14px;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: var(--shadow-xl);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: #111827;
}

.detail-copy {
  max-width: 820px;
}

.detail-one-line {
  margin: 20px 0 0;
  color: rgba(255, 255, 255, .84);
  font-size: 18px;
}

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

.player-section {
  padding-top: 44px;
}

.player-wrap {
  position: relative;
  overflow: hidden;
  background: #000;
  border-radius: 22px;
  box-shadow: var(--shadow-xl);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, rgba(0, 0, 0, .12), rgba(0, 0, 0, .58));
  cursor: pointer;
  transition: opacity .2s ease, visibility .2s ease;
}

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

.play-button {
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #fb923c);
  box-shadow: 0 18px 36px rgba(249, 115, 22, .38);
  cursor: pointer;
  font-size: 30px;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  padding-top: 36px;
}

.detail-article,
.detail-side {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.detail-article {
  padding: 28px;
}

.detail-article h2 + p {
  margin-top: 12px;
}

.detail-article p {
  color: #374151;
  font-size: 17px;
  white-space: pre-line;
}

.detail-side {
  align-self: start;
  padding: 24px;
}

.detail-side dl {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px 14px;
  margin: 18px 0 0;
}

.detail-side dt {
  color: var(--muted);
  font-weight: 700;
}

.detail-side dd {
  margin: 0;
  color: var(--ink);
  font-weight: 700;
}

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

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding-top: 34px;
  padding-bottom: 34px;
}

.footer-inner p {
  max-width: 720px;
  margin: 8px 0 0;
  color: #9ca3af;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 14px;
  white-space: nowrap;
}

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

.is-card-hidden {
  display: none !important;
}

@media (max-width: 1100px) {
  .movie-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

  .hero-slide {
    grid-template-columns: minmax(0, 1fr) 280px;
  }
}

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

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .hero {
    min-height: 720px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    align-content: center;
    gap: 24px;
    padding-top: 88px;
  }

  .hero-poster {
    max-width: 220px;
    transform: none;
  }

  .home-search,
  .detail-layout,
  .detail-content,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    display: grid;
  }

  .detail-poster {
    max-width: 240px;
  }

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

@media (max-width: 560px) {
  .header-inner,
  .footer-inner,
  .content-section,
  .home-search,
  .detail-content,
  .player-section,
  .detail-hero-inner {
    padding-left: 16px;
    padding-right: 16px;
  }

  .brand {
    font-size: 15px;
  }

  .hero {
    min-height: 760px;
  }

  .hero-slide {
    padding-left: 16px;
    padding-right: 16px;
  }

  .movie-grid,
  .movie-strip,
  .category-grid,
  .category-grid.wide {
    grid-template-columns: 1fr;
  }

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

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