:root {
  --site-bg: #0f172a;
  --site-panel: rgba(30, 41, 59, 0.78);
  --site-panel-strong: rgba(15, 23, 42, 0.92);
  --site-border: rgba(148, 163, 184, 0.18);
  --site-text: #ffffff;
  --site-muted: #94a3b8;
  --site-soft: #cbd5e1;
  --site-amber: #f59e0b;
  --site-orange: #ea580c;
  --site-radius: 1.25rem;
  --site-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(245, 158, 11, 0.16), transparent 32rem),
    radial-gradient(circle at top right, rgba(234, 88, 12, 0.14), transparent 30rem),
    var(--site-bg);
  color: var(--site-text);
}

img {
  object-fit: cover;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.94), rgba(15, 23, 42, 0.95));
  border-bottom: 1px solid var(--site-border);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(16px);
}

.header-inner {
  height: 4.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-icon {
  width: 2.4rem;
  height: 2.4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.8rem;
  background: linear-gradient(135deg, var(--site-amber), var(--site-orange));
  box-shadow: 0 10px 30px rgba(245, 158, 11, 0.28);
  transform: translateZ(0);
}

.brand:hover .brand-icon {
  transform: scale(1.06);
}

.brand-text {
  font-size: 1.35rem;
  background: linear-gradient(90deg, #fbbf24, #fb923c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 1.35rem;
}

.nav-link,
.mobile-nav-link {
  color: #e2e8f0;
  font-weight: 600;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  color: #fbbf24;
}

.header-search,
.mobile-search,
.search-page-form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(51, 65, 85, 0.58);
  border: 1px solid var(--site-border);
  border-radius: 999px;
  padding: 0.42rem;
}

.header-search input,
.mobile-search input,
.search-page-form input,
.inline-filter input {
  min-width: 0;
  flex: 1;
  color: #fff;
  background: transparent;
  outline: none;
  padding: 0.45rem 0.85rem;
}

.header-search input::placeholder,
.mobile-search input::placeholder,
.search-page-form input::placeholder,
.inline-filter input::placeholder {
  color: #94a3b8;
}

.header-search button,
.mobile-search button,
.search-page-form button {
  border-radius: 999px;
  padding: 0.5rem 1rem;
  color: #fff;
  font-weight: 700;
  background: linear-gradient(135deg, var(--site-amber), var(--site-orange));
}

.header-search {
  width: min(24rem, 28vw);
}

.nav-toggle {
  display: none;
  color: #fff;
  font-size: 1.5rem;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.75rem;
  background: rgba(51, 65, 85, 0.58);
}

.mobile-panel {
  display: none;
  padding: 0 0 1rem;
}

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

.mobile-nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
  margin-top: 1rem;
}

.mobile-nav-link {
  padding: 0.75rem 1rem;
  border-radius: 0.85rem;
  background: rgba(51, 65, 85, 0.42);
}

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

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

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

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

.hero-bg,
.detail-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.55), rgba(15, 23, 42, 0.18)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.9), transparent 45%);
}

.hero-content {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 46rem;
  display: grid;
  gap: 1.2rem;
}

.hero-kicker,
.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  font-weight: 800;
}

.hero-kicker span,
.eyebrow {
  width: fit-content;
  border-radius: 999px;
  padding: 0.35rem 0.8rem;
  background: rgba(245, 158, 11, 0.96);
  box-shadow: 0 10px 24px rgba(245, 158, 11, 0.24);
}

.hero-kicker span + span {
  background: rgba(30, 41, 59, 0.82);
  box-shadow: none;
}

.hero-copy h1,
.page-hero h1,
.detail-info h1 {
  font-size: clamp(2.35rem, 5vw, 4.65rem);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-copy p {
  max-width: 42rem;
  color: #cbd5e1;
  font-size: 1.1rem;
  line-height: 1.8;
}

.hero-meta,
.hero-tags,
.detail-tags,
.tag-list,
.movie-meta-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.hero-meta {
  color: #cbd5e1;
}

.hero-tags span,
.detail-tags a,
.tag-list span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  color: #fed7aa;
  background: rgba(245, 158, 11, 0.14);
  border: 1px solid rgba(251, 191, 36, 0.2);
  padding: 0.25rem 0.65rem;
  font-size: 0.82rem;
}

.hero-actions,
.detail-info .btn-primary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn-primary,
.btn-secondary,
.btn-ghost,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  min-height: 2.75rem;
  padding: 0.75rem 1.25rem;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--site-amber), var(--site-orange));
  box-shadow: 0 16px 34px rgba(245, 158, 11, 0.28);
}

.btn-secondary {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.btn-ghost,
.section-more {
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.12);
}

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

.hero-controls {
  position: absolute;
  right: 2rem;
  bottom: 2rem;
  display: flex;
  gap: 0.75rem;
  z-index: 5;
}

.hero-controls button {
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  background: rgba(15, 23, 42, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

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

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

.hero-dot.is-active {
  width: 2.2rem;
  background: #f59e0b;
}

.content-section {
  padding: 3rem 0;
}

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

.section-heading h2,
.detail-text-block h2 {
  font-size: clamp(1.65rem, 3vw, 2.45rem);
  line-height: 1.15;
  font-weight: 900;
}

.section-heading p,
.detail-text-block p,
.site-footer p,
.page-hero p {
  color: var(--site-muted);
  line-height: 1.8;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--site-radius);
  background: var(--site-panel);
  border: 1px solid var(--site-border);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.16);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-0.45rem);
  border-color: rgba(245, 158, 11, 0.42);
  box-shadow: var(--site-shadow);
}

.movie-poster {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.8);
}

.movie-poster img {
  width: 100%;
  height: 100%;
  transition: transform 0.45s ease;
}

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

.play-hover,
.rank-badge {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
}

.play-hover {
  inset: 50% auto auto 50%;
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.92);
  transform: translate(-50%, -50%) scale(0.72);
  opacity: 0;
  transition: all 0.25s ease;
}

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

.rank-badge {
  top: 0.75rem;
  left: 0.75rem;
  min-width: 2rem;
  height: 2rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--site-amber), var(--site-orange));
  box-shadow: 0 10px 30px rgba(245, 158, 11, 0.3);
}

.movie-card-body {
  display: grid;
  gap: 0.65rem;
  padding: 1rem;
}

.movie-card-body h3 {
  color: #fff;
  font-weight: 900;
  line-height: 1.35;
}

.movie-card-body h3 a:hover,
.rank-title:hover,
.category-card-links a:hover,
.ranking-table a:hover {
  color: #fbbf24;
}

.movie-card-body p {
  color: var(--site-muted);
  font-size: 0.92rem;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta-line {
  color: #cbd5e1;
  font-size: 0.82rem;
}

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

.category-pill,
.category-card-large {
  display: grid;
  gap: 0.55rem;
  min-height: 8rem;
  padding: 1.15rem;
  border-radius: var(--site-radius);
  background:
    linear-gradient(135deg, rgba(245, 158, 11, 0.14), rgba(234, 88, 12, 0.06)),
    rgba(30, 41, 59, 0.74);
  border: 1px solid var(--site-border);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-pill:hover,
.category-card-large:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 158, 11, 0.44);
}

.category-pill span,
.category-card-main span {
  color: #fff;
  font-size: 1.2rem;
  font-weight: 900;
}

.category-pill small,
.category-card-main p {
  color: var(--site-muted);
  line-height: 1.65;
}

.category-card-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.4rem;
}

.category-card-links a {
  color: #fed7aa;
  font-size: 0.86rem;
}

.rank-section {
  border-top: 1px solid var(--site-border);
  border-bottom: 1px solid var(--site-border);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 2.5rem 4rem 1fr auto;
  align-items: center;
  gap: 0.9rem;
  padding: 0.8rem;
  border-radius: 1rem;
  background: rgba(30, 41, 59, 0.76);
  border: 1px solid var(--site-border);
}

.rank-number {
  color: #fbbf24;
  font-size: 1.2rem;
  font-weight: 900;
  text-align: center;
}

.rank-row img {
  width: 4rem;
  height: 5.2rem;
  border-radius: 0.65rem;
}

.rank-title {
  color: #fff;
  font-weight: 900;
}

.rank-info {
  color: var(--site-muted);
  font-size: 0.86rem;
}

.inner-page .page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
}

.page-hero {
  padding: 5rem 0 2.5rem;
  background:
    linear-gradient(135deg, rgba(245, 158, 11, 0.18), rgba(15, 23, 42, 0.75)),
    radial-gradient(circle at 80% 10%, rgba(234, 88, 12, 0.24), transparent 28rem);
}

.page-hero h1 {
  margin: 1rem 0;
}

.page-hero p {
  max-width: 46rem;
  font-size: 1.05rem;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1.3rem;
  color: #cbd5e1;
  font-size: 0.92rem;
}

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

.inline-filter,
.search-page-form {
  max-width: 42rem;
  margin-top: 1.5rem;
}

.inline-filter {
  display: flex;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--site-border);
}

.detail-hero {
  min-height: 560px;
  display: flex;
  align-items: end;
  background: #020617;
}

.detail-hero-mask {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.95), rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.42)),
    linear-gradient(0deg, rgba(15, 23, 42, 1), transparent 52%);
}

.detail-hero-content {
  position: relative;
  width: 100%;
  padding-top: 5rem;
  padding-bottom: 3rem;
}

.detail-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 2rem;
  align-items: end;
}

.detail-cover {
  border-radius: 1.4rem;
  overflow: hidden;
  border: 1px solid var(--site-border);
  box-shadow: var(--site-shadow);
}

.detail-cover img {
  width: 100%;
  aspect-ratio: 3 / 4;
}

.detail-info {
  display: grid;
  gap: 1rem;
  max-width: 62rem;
}

.detail-one-line {
  color: #e2e8f0;
  font-size: 1.1rem;
  line-height: 1.85;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  color: #cbd5e1;
}

.detail-meta-grid span {
  padding: 0.75rem 0.9rem;
  border-radius: 0.85rem;
  background: rgba(15, 23, 42, 0.58);
  border: 1px solid var(--site-border);
}

.player-section {
  padding: 2rem 0;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 1.4rem;
  background: #000;
  border: 1px solid var(--site-border);
  box-shadow: var(--site-shadow);
  aspect-ratio: 16 / 9;
}

.movie-player,
.player-cover,
.player-cover img,
.player-cover-mask {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.movie-player {
  background: #000;
}

.player-cover {
  z-index: 3;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #000;
}

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

.player-cover-mask {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.3)),
    rgba(0, 0, 0, 0.28);
}

.player-start-icon {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 5.2rem;
  height: 5.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  font-size: 2.35rem;
  background: linear-gradient(135deg, var(--site-amber), var(--site-orange));
  box-shadow: 0 22px 58px rgba(245, 158, 11, 0.38);
  transform: translate(-50%, -50%);
}

.detail-content-grid {
  display: grid;
  gap: 2rem;
  padding-bottom: 2rem;
}

.detail-text-block {
  padding: 1.5rem;
  border-radius: var(--site-radius);
  background: var(--site-panel);
  border: 1px solid var(--site-border);
}

.detail-text-block h2 {
  margin-bottom: 1rem;
}

.detail-text-block p {
  color: #cbd5e1;
  font-size: 1.02rem;
}

.related-section {
  padding-top: 1rem;
}

.ranking-table-wrap {
  overflow-x: auto;
  border-radius: 1rem;
  border: 1px solid var(--site-border);
  background: rgba(30, 41, 59, 0.62);
}

.ranking-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

.ranking-table th,
.ranking-table td {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--site-border);
  text-align: left;
}

.ranking-table th {
  color: #fbbf24;
  background: rgba(15, 23, 42, 0.48);
}

.ranking-table td {
  color: #e2e8f0;
}

.site-footer {
  margin-top: 2rem;
  padding: 3rem 0 2rem;
  background: rgba(2, 6, 23, 0.66);
  border-top: 1px solid var(--site-border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2rem;
}

.footer-brand {
  margin-bottom: 1rem;
}

.site-footer h2 {
  margin-bottom: 1rem;
  color: #fff;
  font-size: 1.25rem;
  font-weight: 900;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.footer-links a {
  color: #cbd5e1;
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  background: rgba(51, 65, 85, 0.56);
}

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

.footer-bottom {
  margin-top: 2rem;
  padding-top: 1.2rem;
  color: #64748b;
  border-top: 1px solid var(--site-border);
}

@media (min-width: 768px) {
  .hero-carousel {
    height: 600px;
  }
}

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

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

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

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

  .hero-controls {
    right: 1rem;
    bottom: 1.2rem;
  }

  .hero-dots {
    left: 1rem;
    bottom: 1.75rem;
    transform: none;
  }

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

  .category-pill-grid,
  .category-overview-grid,
  .rank-list,
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-layout {
    grid-template-columns: 190px minmax(0, 1fr);
  }
}

@media (max-width: 680px) {
  .header-inner {
    height: 4rem;
  }

  .brand-text {
    font-size: 1.15rem;
  }

  .hero-carousel {
    height: 620px;
  }

  .hero-copy {
    padding-top: 3rem;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-info h1 {
    font-size: 2.45rem;
  }

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

  .movie-grid,
  .movie-grid-small,
  .category-pill-grid,
  .category-overview-grid,
  .rank-list,
  .footer-grid,
  .detail-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rank-row {
    grid-template-columns: 2rem 3.5rem 1fr;
  }

  .rank-info {
    grid-column: 3;
  }

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

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

  .detail-cover {
    width: min(220px, 58vw);
  }

  .player-start-icon {
    width: 4.2rem;
    height: 4.2rem;
    font-size: 1.8rem;
  }
}

@media (max-width: 460px) {
  .movie-grid,
  .movie-grid-small,
  .category-pill-grid,
  .category-overview-grid,
  .rank-list,
  .footer-grid,
  .detail-meta-grid,
  .mobile-nav {
    grid-template-columns: 1fr;
  }

  .hero-actions,
  .detail-info .btn-primary {
    align-items: stretch;
    flex-direction: column;
  }

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