:root {
  --site-bg: #f8fafc;
  --site-card: #ffffff;
  --site-text: #0f172a;
  --site-muted: #64748b;
  --site-line: #e2e8f0;
  --site-dark: #0f172a;
  --site-green: #10b981;
  --site-green-dark: #047857;
  --site-teal: #14b8a6;
  --site-orange: #f97316;
  --site-shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
}

body {
  min-height: 100vh;
  background: var(--site-bg);
  color: var(--site-text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

a {
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.94);
  color: #ffffff;
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.22);
}

.nav-shell {
  width: min(1180px, calc(100% - 32px));
  min-height: 74px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #ffffff;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--site-green), var(--site-teal));
  color: #ffffff;
  font-size: 18px;
  box-shadow: 0 12px 28px rgba(16, 185, 129, 0.36);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-copy strong {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-copy em {
  margin-top: 5px;
  color: #cbd5e1;
  font-size: 12px;
  font-style: normal;
}

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

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  border-radius: 999px;
  color: #e2e8f0;
  font-size: 15px;
}

.nav-link:hover,
.nav-link.active {
  color: #ffffff;
  background: rgba(16, 185, 129, 0.18);
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.mobile-menu-button span {
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background: #ffffff;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.mobile-nav a {
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
}

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

.hero-carousel {
  position: relative;
  min-height: 660px;
  overflow: hidden;
  background: #020617;
  color: #ffffff;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease;
}

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

.hero-backdrop {
  position: absolute;
  inset: 0;
  opacity: 0.34;
  filter: saturate(1.1);
}

.hero-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(16, 185, 129, 0.34), transparent 35%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(15, 23, 42, 0.62), rgba(2, 6, 23, 0.96));
}

.hero-content {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 56px;
  align-items: center;
  padding: 96px 0 130px;
}

.hero-kicker,
.section-title span,
.eyebrow {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.14);
  color: #34d399;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.hero-copy h1 {
  margin-top: 22px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 0.98;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.hero-lead {
  max-width: 710px;
  margin-top: 24px;
  color: #dbeafe;
  font-size: clamp(18px, 2vw, 23px);
  line-height: 1.8;
}

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

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

.hero-tags span,
.tag-row span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.08);
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.hero-tags span {
  background: rgba(255, 255, 255, 0.1);
  color: #ecfeff;
}

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

.primary-button,
.ghost-button,
.section-more,
.hero-search button,
.search-panel button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
}

.primary-button,
.hero-search button,
.search-panel button {
  background: linear-gradient(135deg, var(--site-green), var(--site-teal));
  color: #ffffff;
  box-shadow: 0 16px 30px rgba(16, 185, 129, 0.28);
}

.primary-button:hover,
.hero-search button:hover,
.search-panel button:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 36px rgba(16, 185, 129, 0.35);
}

.ghost-button {
  border: 1px solid rgba(255, 255, 255, 0.26);
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.ghost-button:hover {
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-2px);
}

.hero-card {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 32px;
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.42);
  transform: rotate(2deg);
}

.hero-card:hover {
  transform: rotate(0deg) translateY(-6px);
}

.hero-card span {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.72);
  color: #ffffff;
  text-align: center;
  backdrop-filter: blur(10px);
  font-weight: 800;
}

.hero-bottom-bar {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 4;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: minmax(280px, 420px) minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(16px);
}

.hero-search,
.search-panel {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-search input,
.search-panel input,
.search-panel select {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  color: #0f172a;
  padding: 0 16px;
  outline: none;
}

.hero-category-links {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.hero-category-links a {
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  font-size: 13px;
  font-weight: 700;
}

.hero-category-links a:hover {
  background: rgba(16, 185, 129, 0.22);
  color: #ffffff;
}

.hero-dots {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
}

.hero-dot.active {
  width: 28px;
  background: #34d399;
}

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

.page-main {
  padding: 72px 0;
}

.home-section,
.page-section {
  margin-bottom: 80px;
}

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

.section-title h2 {
  margin-top: 14px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.12;
  font-weight: 900;
  letter-spacing: -0.04em;
  color: #0f172a;
}

.section-title p {
  max-width: 720px;
  margin-top: 10px;
  color: var(--site-muted);
  line-height: 1.8;
}

.section-more {
  color: var(--site-green-dark);
  background: #d1fae5;
  white-space: nowrap;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--site-line);
  border-radius: 24px;
  background: var(--site-card);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

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

.movie-poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #e2e8f0;
}

.movie-poster img {
  transition: transform 0.45s ease;
}

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

.year-badge,
.rank-badge,
.poster-play {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  font-weight: 800;
}

.year-badge {
  left: 10px;
  top: 10px;
  min-height: 28px;
  padding: 0 10px;
  background: rgba(15, 23, 42, 0.72);
  font-size: 12px;
  backdrop-filter: blur(10px);
}

.rank-badge {
  right: 10px;
  top: 10px;
  min-width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--site-orange), #f43f5e);
  font-size: 14px;
}

.poster-play {
  left: 50%;
  top: 50%;
  width: 62px;
  height: 62px;
  transform: translate(-50%, -50%) scale(0.85);
  background: rgba(16, 185, 129, 0.9);
  opacity: 0;
  box-shadow: 0 16px 34px rgba(16, 185, 129, 0.4);
}

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

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

.movie-meta {
  color: var(--site-green-dark);
  font-size: 12px;
  font-weight: 800;
}

.movie-card h3 {
  margin-top: 8px;
  color: #0f172a;
  font-size: 17px;
  font-weight: 850;
  line-height: 1.35;
}

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

.movie-card p {
  margin-top: 8px;
  min-height: 48px;
  color: var(--site-muted);
  font-size: 13px;
  line-height: 1.65;
}

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

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

.category-card a {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 18px;
  min-height: 210px;
  padding: 18px;
  overflow: hidden;
  border-radius: 28px;
  background: #ffffff;
  border: 1px solid var(--site-line);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

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

.category-image-stack {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.category-image-stack img {
  min-height: 82px;
  border-radius: 16px;
  background: #e2e8f0;
}

.category-card-copy span {
  color: var(--site-green-dark);
  font-size: 13px;
  font-weight: 800;
}

.category-card-copy h2 {
  margin-top: 8px;
  font-size: 24px;
  font-weight: 900;
  color: #0f172a;
}

.category-card-copy p {
  margin-top: 10px;
  color: var(--site-muted);
  line-height: 1.75;
}

.page-hero {
  margin-bottom: 40px;
  padding: 54px;
  overflow: hidden;
  border-radius: 34px;
  background:
    radial-gradient(circle at 85% 20%, rgba(16, 185, 129, 0.35), transparent 34%),
    linear-gradient(135deg, #0f172a, #334155 55%, #047857);
  color: #ffffff;
  box-shadow: var(--site-shadow);
}

.page-hero h1 {
  max-width: 820px;
  margin-top: 16px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 760px;
  margin-top: 16px;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.8;
}

.search-panel {
  margin-bottom: 30px;
  padding: 18px;
  border: 1px solid var(--site-line);
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
}

.search-empty {
  display: none;
  padding: 34px;
  border-radius: 24px;
  background: #ffffff;
  color: var(--site-muted);
  text-align: center;
}

.search-empty.is-visible {
  display: block;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 28px 0;
  color: var(--site-muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--site-green-dark);
  font-weight: 800;
}

.detail-main {
  padding-bottom: 76px;
}

.detail-hero {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
  padding: 34px;
  border-radius: 34px;
  background:
    radial-gradient(circle at 92% 12%, rgba(16, 185, 129, 0.24), transparent 28%),
    linear-gradient(135deg, #ffffff, #f1f5f9);
  border: 1px solid var(--site-line);
  box-shadow: var(--site-shadow);
}

.detail-poster {
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border-radius: 28px;
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.22);
  background: #e2e8f0;
}

.detail-info h1 {
  color: #0f172a;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
  font-weight: 900;
  letter-spacing: -0.04em;
}

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

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  background: #e2e8f0;
  color: #334155;
  font-weight: 800;
  font-size: 13px;
}

.detail-info p {
  color: var(--site-muted);
  font-size: 17px;
  line-height: 1.9;
}

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

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

.detail-actions .ghost-button {
  color: var(--site-green-dark);
  border-color: #a7f3d0;
  background: #ecfdf5;
}

.player-section,
.text-section,
.related-section {
  margin-top: 46px;
}

.player-section h2,
.text-section h2,
.related-section h2 {
  margin-bottom: 18px;
  font-size: 30px;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #0f172a;
}

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #020617;
  box-shadow: var(--site-shadow);
}

.player-card video {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.2), rgba(2, 6, 23, 0.68));
  color: #ffffff;
}

.player-overlay span {
  display: grid;
  width: 84px;
  height: 84px;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--site-green), var(--site-teal));
  box-shadow: 0 22px 45px rgba(16, 185, 129, 0.4);
  font-size: 30px;
  padding-left: 5px;
}

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

.text-card {
  padding: 30px;
  border: 1px solid var(--site-line);
  border-radius: 30px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.text-card p {
  color: #334155;
  font-size: 17px;
  line-height: 2;
}

.text-card p + h2 {
  margin-top: 28px;
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid var(--site-line);
}

.ranking-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.1);
}

.ranking-cover {
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 16px;
  background: #e2e8f0;
}

.ranking-copy h3 {
  font-weight: 900;
  color: #0f172a;
}

.ranking-copy p {
  margin-top: 6px;
  color: var(--site-muted);
  font-size: 13px;
}

.ranking-number {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #ecfdf5;
  color: var(--site-green-dark);
  font-weight: 900;
}

.site-footer {
  background: #0f172a;
  color: #cbd5e1;
}

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

.footer-brand {
  color: #ffffff;
  font-size: 26px;
  font-weight: 900;
}

.site-footer p {
  margin-top: 14px;
  max-width: 520px;
  line-height: 1.8;
}

.site-footer h2 {
  margin-bottom: 14px;
  color: #ffffff;
  font-size: 18px;
  font-weight: 900;
}

.site-footer a:not(.footer-brand) {
  display: block;
  margin-top: 10px;
  color: #cbd5e1;
}

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  color: #94a3b8;
  font-size: 14px;
}

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

  .mobile-menu-button {
    display: inline-flex;
  }

  .hero-content {
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 32px;
  }

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

  .hero-dots {
    justify-content: flex-start;
  }

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

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

@media (max-width: 820px) {
  .hero-carousel {
    min-height: 760px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    padding-top: 58px;
  }

  .hero-card {
    width: min(260px, 72vw);
    justify-self: center;
  }

  .hero-bottom-bar {
    bottom: 14px;
    border-radius: 22px;
  }

  .hero-search,
  .search-panel {
    flex-direction: column;
    align-items: stretch;
  }

  .section-title {
    display: block;
  }

  .section-more {
    margin-top: 16px;
  }

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

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

  .category-card a {
    grid-template-columns: 1fr;
  }

  .detail-hero {
    grid-template-columns: 1fr;
    padding: 22px;
  }

  .detail-poster {
    width: min(280px, 78vw);
    margin: 0 auto;
  }

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

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

@media (max-width: 520px) {
  .nav-shell,
  .page-main,
  .detail-main,
  .footer-grid,
  .footer-bottom {
    width: min(100% - 22px, 1180px);
  }

  .brand-copy strong {
    font-size: 18px;
  }

  .brand-copy em {
    display: none;
  }

  .hero-copy h1 {
    font-size: 40px;
  }

  .page-hero {
    padding: 34px 22px;
    border-radius: 26px;
  }

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

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