:root {
  --site-bg: #f8fafc;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --cyan: #06b6d4;
  --blue: #2563eb;
  --teal: #14b8a6;
  --panel: rgba(255, 255, 255, 0.88);
  --shadow: 0 24px 60px rgba(15, 23, 42, 0.12);
}

body {
  background:
    radial-gradient(
      circle at top left,
      rgba(6, 182, 212, 0.12),
      transparent 34rem
    ),
    var(--site-bg);
  color: var(--ink);
}

body.nav-open {
  overflow: hidden;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

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

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

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--cyan), var(--blue), var(--teal));
  box-shadow: 0 14px 32px rgba(37, 99, 235, 0.28);
}

.brand-name {
  font-size: 22px;
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--teal));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.nav-link {
  position: relative;
  padding: 10px 16px;
  border-radius: 999px;
  color: #334155;
  font-weight: 650;
  transition: 0.25s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #0891b2;
  background: rgba(6, 182, 212, 0.1);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #f1f5f9;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  background: #0f172a;
  border-radius: 99px;
}

.hero-carousel {
  position: relative;
  overflow: hidden;
  padding: 42px 0 70px;
  background: linear-gradient(180deg, #ffffff 0%, #ecfeff 100%);
}

.hero-glow {
  position: absolute;
  inset: -20% -10% auto;
  height: 520px;
  background:
    radial-gradient(
      circle at 30% 25%,
      rgba(6, 182, 212, 0.24),
      transparent 34%
    ),
    radial-gradient(circle at 68% 10%, rgba(37, 99, 235, 0.18), transparent 30%);
  pointer-events: none;
}

.hero-shell {
  position: relative;
  z-index: 2;
}

.hero-search-panel {
  display: grid;
  grid-template-columns: auto minmax(240px, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px;
  margin-bottom: 26px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: 24px;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(18px);
}

.hero-search-panel > span {
  font-weight: 800;
  color: #0891b2;
}

.hero-search {
  display: flex;
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
}

.hero-search input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
}

.hero-search input {
  padding: 12px 16px;
}

.hero-search button,
.filter-bar button {
  border-radius: 999px;
  padding: 10px 18px;
  color: #fff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  font-weight: 700;
  margin-right: 4px;
}

.hero-cats,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-cats a,
.footer-links a,
.tag-row span,
.info-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(6, 182, 212, 0.1);
  color: #0e7490;
  font-size: 13px;
  font-weight: 650;
}

.hero-stage {
  position: relative;
  min-height: 610px;
  border-radius: 34px;
  overflow: hidden;
  background: #020617;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) 430px;
  align-items: center;
  gap: 48px;
  padding: 64px;
  opacity: 0;
  transform: scale(1.02);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
  pointer-events: none;
  background-image:
    linear-gradient(
      90deg,
      rgba(2, 6, 23, 0.92),
      rgba(2, 6, 23, 0.56),
      rgba(2, 6, 23, 0.86)
    ),
    var(--hero-bg);
  background-size: cover;
  background-position: center;
}

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

.hero-copy {
  max-width: 780px;
  color: #fff;
}

.eyebrow {
  color: #06b6d4;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.hero-copy h1 {
  font-size: clamp(40px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.07em;
  font-weight: 900;
  text-shadow: 0 12px 42px rgba(0, 0, 0, 0.4);
}

.hero-line {
  margin-top: 24px;
  color: #dbeafe;
  font-size: clamp(18px, 2.3vw, 24px);
  line-height: 1.7;
}

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

.hero-tags span {
  background: rgba(255, 255, 255, 0.16);
  color: #e0f2fe;
  border: 1px solid rgba(255, 255, 255, 0.22);
}

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

.btn-primary,
.btn-secondary,
.section-more,
.detail-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  padding: 12px 22px;
  font-weight: 800;
  transition: 0.25s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 18px 34px rgba(37, 99, 235, 0.28);
}

.btn-primary:hover,
.section-more:hover,
.detail-back:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 42px rgba(37, 99, 235, 0.25);
}

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

.hero-poster {
  position: relative;
  border-radius: 26px;
  overflow: hidden;
  min-height: 480px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.38);
}

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

.hero-controls {
  margin-top: 18px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
}

.hero-prev,
.hero-next {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  color: #0f172a;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
  font-size: 32px;
  line-height: 1;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #cbd5e1;
  transition: 0.25s ease;
}

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

.content-section,
.page-hero,
.detail-wrap {
  padding: 70px 0;
}

.page-hero {
  background: linear-gradient(135deg, #fff, #ecfeff);
  border-bottom: 1px solid rgba(226, 232, 240, 0.82);
}

.page-hero h1,
.section-head h2,
.detail-title {
  font-size: clamp(32px, 4vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.055em;
  font-weight: 900;
  color: var(--ink);
}

.page-hero p,
.section-head p,
.detail-summary,
.detail-review,
.site-footer p {
  color: var(--muted);
  line-height: 1.8;
}

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

.section-head p {
  margin-top: 8px;
  max-width: 760px;
}

.section-more,
.detail-back {
  background: #fff;
  color: #0891b2;
  border: 1px solid rgba(6, 182, 212, 0.25);
}

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

.movie-card {
  background: var(--panel);
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
  transition: 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: rgba(6, 182, 212, 0.36);
}

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

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

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

.play-dot,
.rank-num {
  position: absolute;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
}

.play-dot {
  right: 12px;
  bottom: 12px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(6, 182, 212, 0.9);
  box-shadow: 0 12px 26px rgba(6, 182, 212, 0.32);
}

.rank-num {
  left: 12px;
  top: 12px;
  min-width: 42px;
  height: 34px;
  padding: 0 10px;
  border-radius: 12px;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  box-shadow: 0 12px 26px rgba(239, 68, 68, 0.28);
}

.card-body {
  padding: 18px;
}

.card-meta,
.detail-meta,
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #64748b;
  font-size: 13px;
}

.card-meta span,
.detail-meta span,
.breadcrumbs a,
.breadcrumbs span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #f1f5f9;
}

.card-body h2 {
  margin-top: 12px;
  font-size: 20px;
  line-height: 1.3;
  font-weight: 850;
  color: #0f172a;
}

.card-body p {
  margin-top: 10px;
  color: #64748b;
  line-height: 1.68;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.card-body .tag-row {
  margin-top: 14px;
}

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

.category-tile {
  min-height: 178px;
  padding: 22px;
  border-radius: 26px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.92),
    rgba(236, 254, 255, 0.9)
  );
  border: 1px solid rgba(226, 232, 240, 0.88);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-4px);
  border-color: rgba(6, 182, 212, 0.36);
}

.category-tile h2 {
  font-size: 22px;
  font-weight: 900;
  color: #0f172a;
}

.category-tile p {
  margin-top: 10px;
  color: #64748b;
  line-height: 1.7;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 170px 170px auto;
  gap: 12px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: 0 16px 38px rgba(15, 23, 42, 0.08);
  margin-bottom: 28px;
}

.filter-bar input,
.filter-bar select {
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  background: #f8fafc;
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 14px;
  padding: 12px;
  border-radius: 22px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.ranking-item img {
  width: 86px;
  height: 118px;
  object-fit: cover;
  border-radius: 16px;
}

.ranking-item h2 {
  font-size: 18px;
  font-weight: 850;
  line-height: 1.35;
}

.ranking-item p {
  color: #64748b;
  margin-top: 8px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 36px;
  align-items: start;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #020617;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.22);
  aspect-ratio: 16 / 9;
}

.player-shell video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #020617;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background-size: cover;
  background-position: center;
  cursor: pointer;
  z-index: 3;
}

.player-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.28),
    rgba(2, 6, 23, 0.72)
  );
}

.player-cover span {
  position: relative;
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  font-size: 34px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 22px 48px rgba(37, 99, 235, 0.38);
}

.player-cover.is-hidden {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.detail-card {
  padding: 24px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

.detail-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 22px;
}

.detail-title {
  margin-top: 18px;
}

.detail-summary,
.detail-review {
  margin-top: 18px;
  font-size: 17px;
}

.detail-section-title {
  margin-top: 34px;
  margin-bottom: 14px;
  font-size: 28px;
  line-height: 1.2;
  font-weight: 900;
}

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

.empty-result {
  display: none;
  padding: 30px;
  text-align: center;
  color: #64748b;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
}

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

.site-footer {
  margin-top: 60px;
  background: linear-gradient(180deg, #f8fafc, #e0f2fe);
  border-top: 1px solid rgba(226, 232, 240, 0.86);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 1fr;
  gap: 36px;
  padding: 54px 0;
}

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

.site-footer a:not(.footer-brand) {
  display: block;
  color: #475569;
  line-height: 2;
}

.site-footer a:hover {
  color: #0891b2;
}

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.28);
  text-align: center;
  color: #64748b;
  padding: 18px;
}

@media (max-width: 1180px) {
  .movie-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hero-slide {
    grid-template-columns: 1fr 330px;
    padding: 44px;
  }
}

@media (max-width: 900px) {
  .menu-toggle {
    display: flex;
  }
  .site-nav {
    position: fixed;
    left: 16px;
    right: 16px;
    top: 82px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 22px;
    background: #fff;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  body.nav-open .site-nav {
    display: flex;
  }
  .hero-search-panel,
  .filter-bar,
  .detail-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .hero-slide {
    grid-template-columns: 1fr;
    padding: 30px;
    min-height: 690px;
  }
  .hero-poster {
    min-height: 300px;
  }
  .ranking-list,
  .related-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .brand-name {
    font-size: 18px;
  }
  .hero-carousel {
    padding-top: 22px;
  }
  .hero-stage {
    min-height: 760px;
    border-radius: 24px;
  }
  .hero-slide {
    padding: 24px;
  }
  .movie-grid,
  .category-grid,
  .ranking-list,
  .related-grid {
    grid-template-columns: 1fr;
  }
  .section-head {
    display: block;
  }
  .section-more {
    margin-top: 18px;
  }
  .content-section,
  .page-hero,
  .detail-wrap {
    padding: 46px 0;
  }
}
