:root {
  --fog-50: #f0f4f8;
  --fog-100: #d9e2ec;
  --fog-200: #bcccdc;
  --fog-300: #9fb3c8;
  --fog-400: #829ab1;
  --fog-600: #486581;
  --fog-700: #334e68;
  --fog-800: #243b53;
  --fog-900: #102a43;
  --mist-500: #6c757d;
  --mist-600: #495057;
  --cyan-400: #38bec9;
  --cyan-500: #18a8b7;
  --cyan-600: #14919b;
  --amber-500: #d4a431;
  --white: #ffffff;
  --shadow-soft: 0 4px 6px -1px rgba(0, 0, 0, 0.06), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --shadow-medium: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.03);
  --shadow-strong: 0 20px 25px -5px rgba(0, 0, 0, 0.10), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
  color: var(--fog-800);
  background: var(--fog-50);
  line-height: 1.6;
}

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

img,
video {
  display: block;
  width: 100%;
  max-width: 100%;
}

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-soft);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--fog-800);
  font-weight: 700;
}

.brand:hover {
  color: var(--cyan-600);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--cyan-500), var(--fog-700));
  box-shadow: var(--shadow-soft);
  font-size: 13px;
}

.brand-text {
  font-size: 20px;
  letter-spacing: 0.02em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link,
.mobile-link {
  display: inline-flex;
  align-items: center;
  border-radius: 12px;
  color: var(--mist-600);
  font-size: 14px;
  font-weight: 600;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link {
  padding: 9px 16px;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: var(--fog-800);
  background: var(--fog-100);
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: var(--fog-100);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}

.menu-button span {
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--fog-800);
}

.mobile-menu {
  display: none;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 8px 0 16px;
}

.mobile-menu.open {
  display: grid;
  gap: 8px;
}

.mobile-link {
  padding: 12px 14px;
}

.hero {
  position: relative;
  height: 72vh;
  min-height: 540px;
  overflow: hidden;
  background: var(--fog-900);
}

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

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

.hero-bg,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-bg {
  background-size: cover;
  background-position: center;
  transform: scale(1.02);
}

.hero-overlay {
  background: linear-gradient(to top, rgba(16, 42, 67, 0.98), rgba(16, 42, 67, 0.62), rgba(16, 42, 67, 0.15));
}

.hero-content {
  position: relative;
  width: min(1280px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
  padding-bottom: 94px;
  max-width: 1280px;
}

.hero-label,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  background: var(--cyan-500);
  color: var(--white);
  padding: 6px 12px;
  font-size: 12px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-title {
  max-width: 760px;
  margin: 18px 0 14px;
  color: var(--white);
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.05;
  font-weight: 800;
  text-shadow: 0 12px 30px rgba(0, 0, 0, 0.34);
}

.hero-text {
  max-width: 720px;
  margin: 0 0 20px;
  color: var(--fog-100);
  font-size: 18px;
}

.hero-meta,
.detail-meta,
.wide-meta,
.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--fog-300);
  font-size: 14px;
}

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

.primary-button,
.ghost-button,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.primary-button {
  min-height: 46px;
  border-radius: 12px;
  padding: 0 26px;
  color: var(--white);
  background: var(--cyan-500);
  box-shadow: var(--shadow-soft);
}

.primary-button:hover {
  background: var(--cyan-600);
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
}

.ghost-button {
  min-height: 46px;
  border-radius: 12px;
  padding: 0 24px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(4px);
}

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

.text-link {
  color: var(--cyan-600);
  gap: 6px;
}

.text-link:hover {
  color: var(--fog-800);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(4px);
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-control:hover {
  background: rgba(0, 0, 0, 0.55);
}

.hero-control.prev {
  left: 24px;
}

.hero-control.next {
  right: 24px;
}

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

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

.hero-dot.active {
  width: 32px;
  background: var(--white);
}

.section {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0;
}

.soft-section {
  width: 100%;
  padding-left: max(16px, calc((100% - 1280px) / 2));
  padding-right: max(16px, calc((100% - 1280px) / 2));
  background: linear-gradient(135deg, rgba(217, 226, 236, 0.65), rgba(240, 244, 248, 0.95));
}

.intro-section {
  padding-bottom: 28px;
}

.section-head {
  margin-bottom: 30px;
}

.section-head h2,
.page-hero h1,
.content-card h2,
.side-card h2 {
  margin: 10px 0 0;
  color: var(--fog-800);
  line-height: 1.2;
}

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

.section-head p:not(.section-kicker) {
  max-width: 680px;
  margin: 12px 0 0;
  color: var(--mist-600);
}

.split-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.search-panel {
  margin: 26px 0 32px;
  border-radius: 18px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  padding: 20px;
}

.search-grid {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 180px 180px 180px;
  gap: 16px;
  align-items: end;
}

.search-grid label {
  display: grid;
  gap: 8px;
  color: var(--fog-700);
  font-size: 13px;
  font-weight: 700;
}

.search-wide {
  grid-column: span 1;
}

.search-grid input,
.search-grid select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--fog-200);
  border-radius: 12px;
  color: var(--fog-800);
  background: var(--fog-50);
  padding: 0 14px;
  outline: none;
}

.search-grid input:focus,
.search-grid select:focus {
  border-color: var(--cyan-500);
  box-shadow: 0 0 0 3px rgba(24, 168, 183, 0.14);
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-link,
.poster-wrap {
  display: block;
}

.poster-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: var(--fog-200);
}

.poster-wrap img,
.wide-cover img,
.category-preview img,
.detail-poster img {
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.poster-hover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--white);
  background: rgba(0, 0, 0, 0);
  font-size: 42px;
  opacity: 0;
  transition: opacity 0.25s ease, background 0.25s ease;
}

.movie-card:hover .poster-hover {
  opacity: 1;
  background: rgba(0, 0, 0, 0.42);
}

.poster-meta,
.rank-badge,
.wide-rank {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(4px);
  font-size: 12px;
  font-weight: 700;
}

.poster-meta {
  right: 10px;
  bottom: 10px;
  padding: 5px 9px;
}

.rank-badge {
  left: 10px;
  top: 10px;
  min-width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
}

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

.card-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.card-tags span,
.tag-row span {
  border-radius: 999px;
  color: var(--cyan-600);
  background: rgba(24, 168, 183, 0.10);
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 700;
}

.movie-card h2 {
  margin: 10px 0 8px;
  color: var(--fog-800);
  font-size: 16px;
  line-height: 1.35;
}

.movie-card h2 a:hover,
.wide-card h2 a:hover {
  color: var(--cyan-600);
}

.movie-card p {
  min-height: 46px;
  margin: 0 0 12px;
  color: var(--mist-600);
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  justify-content: space-between;
  color: var(--fog-600);
  font-weight: 600;
}

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

.category-tile {
  min-height: 160px;
  border-radius: 18px;
  color: var(--white);
  background: linear-gradient(135deg, var(--fog-900), var(--fog-700));
  box-shadow: var(--shadow-soft);
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  position: relative;
}

.category-tile::after {
  content: "";
  position: absolute;
  right: -38px;
  bottom: -38px;
  width: 110px;
  height: 110px;
  border-radius: 999px;
  background: rgba(56, 190, 201, 0.22);
}

.category-tile:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-medium);
}

.category-tile span {
  position: relative;
  z-index: 1;
  font-size: 20px;
  font-weight: 800;
}

.category-tile p {
  position: relative;
  z-index: 1;
  margin: 16px 0 0;
  color: var(--fog-100);
  font-size: 14px;
}

.wide-list {
  display: grid;
  gap: 16px;
}

.wide-card {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 20px;
  overflow: hidden;
  border-radius: 18px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.wide-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-medium);
}

.wide-cover {
  position: relative;
  min-height: 118px;
  background: var(--fog-200);
  overflow: hidden;
}

.wide-rank {
  left: 12px;
  top: 12px;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: var(--cyan-500);
}

.wide-body {
  padding: 20px 20px 20px 0;
}

.wide-body h2 {
  margin: 0 0 10px;
  font-size: 22px;
  line-height: 1.3;
}

.wide-body p {
  margin: 0 0 14px;
  color: var(--mist-600);
}

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

.category-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  overflow: hidden;
  border-radius: 20px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.category-preview {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3px;
  min-height: 220px;
  background: var(--fog-200);
}

.category-preview img {
  min-height: 108px;
}

.category-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.category-card h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.category-card p {
  margin: 0 0 18px;
  color: var(--mist-600);
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background: var(--fog-900);
}

.compact-hero {
  min-height: 360px;
}

.page-hero-bg,
.detail-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.32;
}

.page-hero::after,
.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(16, 42, 67, 0.95), rgba(16, 42, 67, 0.76), rgba(16, 42, 67, 0.35));
}

.page-hero-content,
.detail-shell {
  position: relative;
  z-index: 1;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
}

.page-hero-content {
  padding: 82px 0;
}

.page-hero h1 {
  color: var(--white);
  font-size: clamp(38px, 5vw, 58px);
}

.page-hero p:not(.section-kicker) {
  max-width: 760px;
  color: var(--fog-100);
  font-size: 18px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--fog-200);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--cyan-400);
}

.detail-hero {
  min-height: 560px;
}

.detail-shell {
  padding: 54px 0 70px;
}

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

.detail-poster {
  overflow: hidden;
  aspect-ratio: 3 / 4;
  border-radius: 20px;
  background: var(--fog-200);
  box-shadow: var(--shadow-strong);
}

.detail-copy h1 {
  max-width: 850px;
  margin: 18px 0 14px;
  color: var(--white);
  font-size: clamp(36px, 5vw, 64px);
  line-height: 1.08;
}

.detail-copy p {
  max-width: 820px;
  color: var(--fog-100);
  font-size: 18px;
}

.detail-copy .primary-button {
  margin-top: 28px;
}

.detail-section {
  padding-top: 46px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 0.8fr);
  gap: 28px;
  align-items: start;
}

.detail-main,
.detail-side {
  display: grid;
  gap: 24px;
}

.player-card,
.content-card,
.side-card {
  border-radius: 20px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.player-card {
  overflow: hidden;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  background: #000000;
}

.player-video {
  aspect-ratio: 16 / 9;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: var(--white);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.18));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.video-shell.is-playing .player-overlay,
.video-shell.is-ready .player-overlay {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.play-circle {
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(4px);
  font-size: 30px;
  box-shadow: var(--shadow-medium);
}

.content-card,
.side-card {
  padding: 26px;
}

.content-card h2,
.side-card h2 {
  margin-top: 0;
  font-size: 24px;
}

.content-card p {
  margin: 14px 0 0;
  color: var(--mist-600);
  font-size: 17px;
  white-space: pre-line;
}

.side-card dl {
  margin: 0;
  display: grid;
  gap: 12px;
}

.side-card dt {
  color: var(--fog-600);
  font-size: 13px;
  font-weight: 700;
}

.side-card dd {
  margin: -8px 0 0;
  color: var(--fog-800);
  font-weight: 700;
}

.side-card .text-link {
  display: flex;
  justify-content: flex-start;
  margin-top: 12px;
}

.empty-state {
  margin: 28px 0 0;
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  padding: 28px;
  color: var(--mist-600);
  text-align: center;
}

[hidden] {
  display: none !important;
}

.site-footer {
  margin-top: 40px;
  color: var(--fog-200);
  background: var(--fog-900);
}

.footer-shell {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 48px 0;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) 1fr 1fr;
  gap: 36px;
}

.footer-logo {
  color: var(--white);
}

.footer-brand p {
  max-width: 420px;
  margin: 16px 0 0;
  color: var(--fog-300);
}

.footer-column h2 {
  margin: 0 0 16px;
  color: var(--white);
  font-size: 16px;
}

.footer-column ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.footer-column a {
  color: var(--fog-300);
}

.footer-column a:hover {
  color: var(--cyan-400);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 18px 16px;
  color: var(--fog-300);
  text-align: center;
  font-size: 14px;
}

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

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

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

  .search-grid {
    grid-template-columns: minmax(220px, 1fr) 1fr 1fr;
  }
}

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

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

  .hero {
    min-height: 580px;
    height: 78vh;
  }

  .hero-content {
    padding-bottom: 88px;
  }

  .hero-control {
    display: none;
  }

  .split-head,
  .detail-intro,
  .detail-layout,
  .footer-shell,
  .category-card,
  .wide-card {
    grid-template-columns: 1fr;
  }

  .split-head {
    display: grid;
  }

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

  .wide-body {
    padding: 0 18px 20px;
  }

  .wide-cover {
    min-height: 220px;
  }

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

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

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

@media (max-width: 580px) {
  .nav-shell,
  .mobile-menu,
  .section,
  .page-hero-content,
  .detail-shell,
  .footer-shell,
  .hero-content {
    width: min(100% - 24px, 1280px);
  }

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

  .hero-title {
    font-size: 38px;
  }

  .hero-text,
  .page-hero p:not(.section-kicker),
  .detail-copy p {
    font-size: 16px;
  }

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

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

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

  .section {
    padding: 48px 0;
  }

  .soft-section {
    padding-left: 12px;
    padding-right: 12px;
  }

  .content-card,
  .side-card {
    padding: 20px;
  }
}
