:root {
  --cyan: #0891b2;
  --cyan-light: #22d3ee;
  --blue: #2563eb;
  --teal: #0d9488;
  --slate: #0f172a;
  --text: #1f2937;
  --muted: #6b7280;
  --card: #ffffff;
  --soft: #f3f4f6;
  --ring: rgba(34, 211, 238, 0.35);
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: linear-gradient(180deg, #f9fafb 0%, #f3f4f6 100%);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

img {
  max-width: 100%;
}

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

button,
input,
select {
  font: inherit;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, var(--cyan) 0%, var(--blue) 48%, var(--teal) 100%);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.2);
}

.nav-shell {
  max-width: 1280px;
  height: 64px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
  transition: transform 0.3s ease;
}

.brand:hover .brand-mark,
.footer-brand:hover .brand-mark {
  transform: rotate(12deg) scale(1.05);
}

.brand-text {
  font-size: 24px;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  color: #ffffff;
  font-weight: 700;
}

.primary-nav a,
.mobile-panel a {
  transition: color 0.2s ease, transform 0.2s ease;
}

.primary-nav a:hover,
.mobile-panel a:hover {
  color: #cffafe;
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-search input {
  width: 260px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  padding: 9px 16px;
  outline: none;
  backdrop-filter: blur(8px);
}

.header-search input::placeholder,
.mobile-search input::placeholder {
  color: #cffafe;
}

.header-search button,
.mobile-search button,
.primary-button {
  border: 0;
  border-radius: 999px;
  padding: 10px 20px;
  color: #ffffff;
  background: linear-gradient(90deg, #06b6d4 0%, #2563eb 100%);
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.25);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.header-search button {
  background: rgba(255, 255, 255, 0.2);
  box-shadow: none;
}

.primary-button:hover,
.header-search button:hover,
.mobile-search button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 18px 30px rgba(37, 99, 235, 0.28);
}

.primary-button.full {
  width: 100%;
  display: inline-flex;
  justify-content: center;
}

.menu-toggle {
  display: none;
  border: 0;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  width: 42px;
  height: 42px;
}

.mobile-panel {
  display: none;
  padding: 16px 24px 22px;
  background: linear-gradient(180deg, #2563eb 0%, #0d9488 100%);
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

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

.mobile-panel nav {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
  color: #ffffff;
  font-weight: 700;
}

.hero {
  position: relative;
  height: 70vh;
  min-height: 520px;
  overflow: hidden;
  color: #ffffff;
  background: #0f172a;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease;
}

.hero-slide.is-active {
  opacity: 1;
  z-index: 1;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.56) 48%, rgba(0, 0, 0, 0.16) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(720px, calc(100% - 48px));
  margin: 0 auto;
  transform: translateX(calc((min(1280px, 100vw) - min(720px, calc(100vw - 48px))) / -2));
}

.hero-copy h1,
.hero-copy h2 {
  margin: 0 0 18px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.96;
  font-weight: 900;
  letter-spacing: -0.04em;
  text-shadow: 0 12px 34px rgba(0, 0, 0, 0.48);
}

.hero-copy p {
  max-width: 680px;
  margin: 0 0 24px;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.7;
  color: #e5e7eb;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.hero-tags,
.detail-meta,
.genre-list,
.tag-list,
.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.genre-chip,
.tag,
.card-meta span {
  border-radius: 999px;
  padding: 7px 14px;
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.genre-chip {
  background: #cffafe;
  color: #0e7490;
}

.tag {
  background: #f3f4f6;
  color: #374151;
}

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

.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 10px 20px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
  font-weight: 800;
  backdrop-filter: blur(8px);
  transition: background 0.2s ease, transform 0.2s ease;
}

.ghost-button:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: translateY(-2px);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.28);
  font-size: 34px;
  line-height: 1;
  backdrop-filter: blur(8px);
  transform: translateY(-50%);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 32px;
  background: #ffffff;
}

.page-shell {
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
}

.quick-categories {
  padding: 44px 0 16px;
}

.home-sections {
  padding: 32px 0 72px;
}

.content-section {
  margin-bottom: 72px;
}

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

.section-head.compact {
  margin-bottom: 18px;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--cyan);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.section-head h2,
.page-hero h1,
.detail-card h1,
.article-block h2,
.side-panel h2 {
  margin: 0;
  color: #1f2937;
  font-weight: 900;
}

.section-head h2 {
  font-size: clamp(28px, 3vw, 38px);
}

.section-head a {
  color: var(--cyan);
  font-weight: 800;
}

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

.movie-card {
  min-width: 0;
}

.movie-card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border-radius: 18px;
  background: var(--card);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-wrap {
  position: relative;
  height: 0;
  padding-bottom: 130%;
  overflow: hidden;
  background: #0f172a;
}

.poster-wrap img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.type-pill,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 900;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(8px);
}

.type-pill {
  top: 12px;
  right: 12px;
}

.rank-badge {
  left: 12px;
  top: 12px;
  min-width: 32px;
  text-align: center;
  background: linear-gradient(90deg, #06b6d4 0%, #2563eb 100%);
}

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

.movie-card-body h3 {
  margin: 0 0 10px;
  color: #1f2937;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 900;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.movie-card-link:hover h3 {
  color: var(--cyan);
}

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

.card-meta {
  justify-content: space-between;
  color: var(--muted);
  font-size: 13px;
}

.card-meta span {
  padding: 5px 9px;
  background: #ecfeff;
  color: #0e7490;
}

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

.category-tile {
  position: relative;
  height: 150px;
  overflow: hidden;
  border-radius: 20px;
  color: #ffffff;
  background: #0f172a;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.12);
}

.category-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.category-tile span {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 16px;
  z-index: 2;
  font-size: 20px;
  font-weight: 900;
}

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

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

.page-hero {
  background: linear-gradient(135deg, #ecfeff 0%, #eff6ff 50%, #f0fdfa 100%);
}

.small-hero {
  padding: 54px 0;
  margin-bottom: 44px;
}

.page-hero h1 {
  max-width: 850px;
  font-size: clamp(36px, 5vw, 58px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 820px;
  margin: 18px 0 0;
  color: #4b5563;
  font-size: 18px;
  line-height: 1.8;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: #64748b;
  font-size: 14px;
}

.breadcrumb a {
  color: var(--cyan);
  font-weight: 800;
}

.category-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  padding-bottom: 72px;
}

.category-card a {
  display: grid;
  grid-template-columns: 220px 1fr;
  overflow: hidden;
  min-height: 220px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-covers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  background: #0f172a;
}

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

.category-card-body {
  padding: 28px;
}

.category-card-body h2 {
  margin: 0 0 10px;
  font-size: 28px;
  font-weight: 900;
}

.category-card-body p {
  margin: 0 0 22px;
  color: var(--muted);
  line-height: 1.75;
}

.category-card-body span {
  color: var(--cyan);
  font-weight: 900;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 220px 220px;
  gap: 16px;
  margin-bottom: 24px;
  padding: 18px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: #374151;
  font-weight: 800;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 11px 14px;
  color: #1f2937;
  background: #f9fafb;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--cyan-light);
  box-shadow: 0 0 0 4px var(--ring);
}

.empty-state {
  display: none;
  margin: 28px 0 0;
  padding: 28px;
  border-radius: 18px;
  color: #64748b;
  text-align: center;
  background: #ffffff;
}

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

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

.detail-content,
.detail-sidebar {
  min-width: 0;
}

.player-card,
.detail-card,
.side-panel,
.poster-panel {
  overflow: hidden;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.1);
}

.player-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000000;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  padding: 0;
  overflow: hidden;
  color: #ffffff;
  background: #000000;
  cursor: pointer;
}

.player-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
}

.play-circle {
  position: relative;
  z-index: 2;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 6px;
  color: #ffffff;
  background: linear-gradient(90deg, #06b6d4 0%, #2563eb 100%);
  font-size: 34px;
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.38);
  transition: transform 0.2s ease;
}

.player-cover:hover .play-circle {
  transform: scale(1.08);
}

.player-shell.is-playing .player-cover {
  display: none;
}

.detail-card {
  margin-top: 22px;
  padding: 32px;
}

.detail-card h1 {
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.detail-meta {
  margin: 18px 0 18px;
}

.detail-meta span {
  border-radius: 999px;
  padding: 7px 12px;
  background: #ecfeff;
  color: #0e7490;
  font-size: 14px;
  font-weight: 900;
}

.article-block {
  margin-top: 30px;
}

.article-block h2 {
  margin-bottom: 12px;
  font-size: 24px;
}

.article-block p {
  margin: 0 0 14px;
  color: #4b5563;
  line-height: 1.9;
  font-size: 16px;
}

.poster-panel {
  padding: 18px;
  margin-bottom: 22px;
}

.poster-panel img {
  width: 100%;
  border-radius: 18px;
  margin-bottom: 18px;
}

.detail-sidebar {
  position: sticky;
  top: 88px;
  align-self: start;
}

.side-panel {
  padding: 22px;
}

.side-panel h2 {
  font-size: 24px;
  margin-bottom: 18px;
}

.side-list {
  display: grid;
  gap: 14px;
}

.side-card {
  display: grid;
  grid-template-columns: 82px 1fr;
  gap: 12px;
  align-items: center;
}

.side-card img {
  width: 82px;
  height: 108px;
  object-fit: cover;
  border-radius: 12px;
  background: #0f172a;
}

.side-card strong {
  display: block;
  color: #1f2937;
  line-height: 1.35;
  font-size: 15px;
}

.side-card em {
  display: block;
  margin-top: 6px;
  color: #64748b;
  font-style: normal;
  font-size: 13px;
}

.related-wide {
  margin-top: 34px;
  margin-bottom: 0;
}

.site-footer {
  color: #d1d5db;
  background: linear-gradient(180deg, #1f2937 0%, #0f172a 100%);
}

.footer-shell {
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
  padding: 44px 0;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
}

.footer-brand {
  margin-bottom: 14px;
  font-size: 24px;
}

.footer-shell p {
  max-width: 760px;
  margin: 0;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 14px;
}

.footer-links a {
  color: #a5f3fc;
  font-weight: 800;
}

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

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

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

  .detail-sidebar {
    position: static;
  }
}

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

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

  .brand-text {
    font-size: 21px;
  }

  .hero {
    min-height: 560px;
  }

  .hero-copy {
    width: min(100% - 48px, 680px);
    transform: none;
  }

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

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

  .category-covers {
    height: 220px;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .footer-shell {
    grid-template-columns: 1fr;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 560px) {
  .nav-shell,
  .page-shell,
  .footer-shell {
    width: auto;
    padding-left: 16px;
    padding-right: 16px;
  }

  .nav-shell {
    padding-left: 16px;
    padding-right: 16px;
  }

  .mobile-panel {
    padding-left: 16px;
    padding-right: 16px;
  }

  .mobile-search {
    display: grid;
    grid-template-columns: 1fr auto;
  }

  .mobile-search input {
    width: 100%;
  }

  .hero {
    min-height: 540px;
    height: 68vh;
  }

  .hero-copy {
    width: calc(100% - 32px);
  }

  .hero-control {
    display: none;
  }

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

  .detail-card {
    padding: 22px;
  }

  .play-circle {
    width: 72px;
    height: 72px;
    font-size: 28px;
  }
}
