:root {
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.82);
  --panel-strong: #0f172a;
  --text: #f8fafc;
  --muted: #94a3b8;
  --line: rgba(148, 163, 184, 0.18);
  --cyan: #22d3ee;
  --teal: #14b8a6;
  --green: #10b981;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: radial-gradient(circle at top left, rgba(34, 211, 238, 0.16), transparent 32rem), var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

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

img {
  display: block;
  max-width: 100%;
  background: linear-gradient(135deg, #0f172a, #164e63);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(2, 6, 23, 0.78);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  color: #001018;
  box-shadow: 0 0 30px rgba(34, 211, 238, 0.35);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #cbd5e1;
  font-weight: 600;
}

.nav-links a:hover,
.text-link:hover {
  color: var(--cyan);
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.8);
  color: var(--text);
}

.hero {
  position: relative;
  height: 70vh;
  min-height: 560px;
  overflow: hidden;
}

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

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(15, 23, 42, 0.76), rgba(15, 23, 42, 0.1)),
    linear-gradient(0deg, #020617 0%, transparent 40%);
}

.hero-content {
  position: absolute;
  left: max(24px, calc((100vw - 1200px) / 2));
  top: 50%;
  transform: translateY(-50%);
  max-width: 680px;
  padding-right: 24px;
}

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

.hero-content h1 {
  margin: 16px 0;
  font-size: clamp(40px, 7vw, 76px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero-content p {
  max-width: 620px;
  margin: 0 0 24px;
  color: #cbd5e1;
  font-size: 18px;
}

.hero-tags,
.detail-meta,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.hero-tags span,
.detail-meta span,
.detail-meta a,
.tag-list span {
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.62);
  color: #cbd5e1;
  font-size: 13px;
}

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

.primary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 180ms ease, background 180ms ease, border 180ms ease;
}

.primary-button {
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  color: #001018;
}

.ghost-button {
  border: 1px solid rgba(34, 211, 238, 0.35);
  background: rgba(15, 23, 42, 0.58);
  color: #dff9ff;
}

.primary-button:hover,
.ghost-button:hover,
.movie-card:hover {
  transform: translateY(-3px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.64);
  color: #fff;
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
}

.hero-prev {
  left: 22px;
}

.hero-next {
  right: 22px;
}

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

.hero-dots button {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: #64748b;
  cursor: pointer;
  transition: width 180ms ease, background 180ms ease;
}

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

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

.hero + .search-panel {
  margin-top: 32px;
}

.search-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 440px);
  gap: 24px;
  align-items: center;
  margin: 48px auto 28px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(8, 47, 73, 0.48));
  box-shadow: var(--shadow);
}

.search-panel.slim {
  margin-top: 24px;
}

.search-panel h2,
.section-heading h2,
.page-hero h1,
.player-section h2,
.copy-section h2 {
  margin: 6px 0 0;
  line-height: 1.18;
}

.search-panel input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 16px;
  outline: none;
  background: rgba(2, 6, 23, 0.6);
  color: #fff;
}

.category-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  margin: 28px 0 44px;
}

.category-tile {
  position: relative;
  min-height: 170px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.4;
  transition: transform 300ms ease;
}

.category-tile:hover img {
  transform: scale(1.08);
}

.category-tile span,
.category-tile p {
  position: relative;
  z-index: 2;
  display: block;
  padding: 0 18px;
}

.category-tile span {
  margin-top: 82px;
  font-size: 20px;
  font-weight: 900;
}

.category-tile p {
  margin: 8px 0 0;
  color: #cbd5e1;
  font-size: 13px;
}

.section-block,
.category-overview-card,
.player-section,
.copy-section {
  margin: 42px 0;
}

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

.section-heading h2 {
  font-size: clamp(26px, 4vw, 38px);
}

.section-heading p,
.page-hero p,
.copy-section p,
.footer-grid p {
  color: #cbd5e1;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.7);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
  transition: transform 180ms ease, border 180ms ease, box-shadow 180ms ease;
}

.movie-card:hover {
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 24px 70px rgba(8, 145, 178, 0.14);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4.2;
  overflow: hidden;
}

.card-wide .poster-link {
  aspect-ratio: 16 / 9;
}

.poster-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms ease;
}

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

.play-chip,
.rank-badge {
  position: absolute;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.play-chip {
  right: 10px;
  bottom: 10px;
  padding: 6px 10px;
  background: rgba(34, 211, 238, 0.92);
  color: #001018;
}

.rank-badge {
  left: 10px;
  top: 10px;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--cyan), var(--green));
  color: #001018;
}

.card-body {
  padding: 14px;
}

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

.card-meta,
.card-desc {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.card-desc {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.page-hero {
  margin: 40px 0 26px;
  padding: 44px;
  border: 1px solid var(--line);
  border-radius: 32px;
  background:
    radial-gradient(circle at right top, rgba(34, 211, 238, 0.22), transparent 24rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(8, 47, 73, 0.44));
  box-shadow: var(--shadow);
}

.page-hero h1 {
  font-size: clamp(34px, 6vw, 64px);
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 760px;
  margin-bottom: 0;
}

.category-overview-card {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background: rgba(15, 23, 42, 0.52);
}

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

.library-grid {
  margin-bottom: 22px;
}

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

.detail-shell {
  padding-bottom: 28px;
}

.detail-hero {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 34px;
  align-items: end;
  margin: 44px 0;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 34px;
  background:
    radial-gradient(circle at 20% 10%, rgba(34, 211, 238, 0.18), transparent 24rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(8, 47, 73, 0.38));
  box-shadow: var(--shadow);
}

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

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

.detail-info h1 {
  margin: 10px 0 14px;
  font-size: clamp(38px, 6vw, 70px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.detail-line {
  max-width: 780px;
  color: #dbeafe;
  font-size: 18px;
}

.player-section,
.copy-section {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.64);
  box-shadow: var(--shadow);
}

.video-player {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
}

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

.video-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  border: 0;
  background: radial-gradient(circle, rgba(2, 6, 23, 0.32), rgba(2, 6, 23, 0.72));
  color: #fff;
  cursor: pointer;
}

.video-overlay.is-hidden {
  display: none;
}

.play-large {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  padding-left: 4px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  color: #001018;
  font-size: 32px;
}

.copy-section p {
  font-size: 17px;
}

.site-footer {
  margin-top: 70px;
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.72);
}

.footer-grid {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0;
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.footer-links {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  color: #cbd5e1;
}

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

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

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

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

@media (max-width: 760px) {
  .menu-button {
    display: inline-grid;
    place-items: center;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 76px;
    display: none;
    flex-direction: column;
    align-items: flex-start;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(2, 6, 23, 0.96);
  }

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

  .hero {
    height: 76vh;
    min-height: 560px;
  }

  .hero-content {
    left: 18px;
    right: 18px;
    padding: 0;
  }

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

  .hero-arrow {
    display: none;
  }

  .search-panel,
  .detail-hero {
    grid-template-columns: 1fr;
  }

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

  .page-hero,
  .detail-hero,
  .player-section,
  .copy-section {
    padding: 22px;
    border-radius: 24px;
  }

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

  .footer-grid {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .movie-grid,
  .small-grid,
  .rank-grid,
  .category-strip {
    grid-template-columns: 1fr;
  }

  .card-wide .poster-link,
  .poster-link {
    aspect-ratio: 16 / 10;
  }
}
