:root {
  --site-blue: #1d4ed8;
  --site-cyan: #06b6d4;
  --site-deep: #0f172a;
  --site-gold: #facc15;
  --site-soft: #f8fafc;
  --site-muted: #64748b;
  --site-card: #ffffff;
  --site-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

body {
  min-height: 100vh;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 42%, #f1f5f9 100%);
  color: #1f2937;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

img {
  background: linear-gradient(135deg, #dbeafe, #ecfeff);
}

.container {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #ffffff;
  background: linear-gradient(90deg, var(--site-blue), var(--site-cyan));
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.25);
}

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

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.logo-icon,
.footer-logo span {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  color: #1e3a8a;
  background: #facc15;
  box-shadow: 0 10px 24px rgba(250, 204, 21, 0.3);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 15px;
  font-weight: 600;
}

.desktop-nav a,
.mobile-nav a {
  border-radius: 12px;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active {
  color: #fde047;
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 22px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
}

.mobile-nav a {
  display: block;
  padding: 12px 14px;
  margin-top: 6px;
  color: #ffffff;
}

.mobile-nav a:hover,
.mobile-nav a.active {
  background: rgba(255, 255, 255, 0.16);
}

.mobile-nav.open {
  display: block;
}

.home-hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: radial-gradient(circle at 80% 20%, rgba(34, 211, 238, 0.55), transparent 24%), linear-gradient(100deg, #172554, #1d4ed8 46%, #0891b2);
}

.home-hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 72px;
  background: linear-gradient(0deg, #f8fafc, rgba(248, 250, 252, 0));
}

.hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.86fr);
  gap: 42px;
  align-items: center;
  padding: 72px 0 86px;
}

.hero-copy {
  display: grid;
  gap: 22px;
}

.hero-badge,
.kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 999px;
  color: #172554;
  background: #facc15;
  font-size: 14px;
  font-weight: 800;
}

.hero-copy h1 {
  max-width: 760px;
  font-size: clamp(40px, 6vw, 64px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.hero-copy p {
  max-width: 720px;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.75;
}

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

.hero-meta span,
.detail-meta span,
.tag-list span {
  padding: 6px 11px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.18);
  color: inherit;
  font-size: 14px;
  font-weight: 700;
}

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

.hero-button,
.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 24px;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.hero-button,
.primary-button {
  color: #172554;
  background: #facc15;
  box-shadow: 0 16px 30px rgba(250, 204, 21, 0.24);
}

.secondary-button {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.12);
}

.hero-button:hover,
.primary-button:hover,
.secondary-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 34px rgba(15, 23, 42, 0.18);
}

.hero-poster {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 30px;
  box-shadow: 0 32px 80px rgba(15, 23, 42, 0.38);
  transform: translateZ(0);
}

.hero-poster img {
  width: 100%;
  height: min(58vw, 520px);
  min-height: 390px;
  object-fit: cover;
  transition: transform 0.45s ease;
}

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

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.55), transparent 52%);
}

.hero-play {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.hero-poster:hover .hero-play {
  opacity: 1;
}

.hero-play span,
.poster-play,
.play-dot {
  display: inline-grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 999px;
  color: var(--site-blue);
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.section-block {
  padding: 56px 0;
}

.section-soft {
  background: linear-gradient(90deg, #ecfdf5, #f0fdfa);
}

.section-gold {
  background: linear-gradient(90deg, #fffbeb, #fefce8);
}

.section-heading {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 28px;
}

.section-heading span {
  width: 5px;
  height: 34px;
  border-radius: 999px;
  background: linear-gradient(180deg, #3b82f6, #06b6d4);
}

.section-heading.orange span {
  background: linear-gradient(180deg, #f97316, #ef4444);
}

.section-heading.green span {
  background: linear-gradient(180deg, #22c55e, #10b981);
}

.section-heading.gold span {
  background: linear-gradient(180deg, #f59e0b, #eab308);
}

.section-heading h2 {
  color: #1f2937;
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1.2;
  font-weight: 900;
}

.section-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
}

.view-more {
  color: #2563eb;
  font-weight: 800;
}

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

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: 18px;
  color: inherit;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
}

.poster-wrap img,
.horizontal-poster img,
.compact-poster img,
.detail-cover img,
.category-teaser img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.card-region,
.card-type {
  position: absolute;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 9px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.card-region {
  top: 12px;
  left: 12px;
  background: #2563eb;
}

.card-type {
  right: 12px;
  bottom: 12px;
  background: rgba(15, 23, 42, 0.82);
}

.poster-mask {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  opacity: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.08));
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster-mask {
  opacity: 1;
}

.card-body {
  padding: 18px;
}

.card-body h3,
.compact-info h3,
.horizontal-info h3 {
  color: #111827;
  font-weight: 850;
  transition: color 0.2s ease;
}

.card-body h3 {
  min-height: 52px;
  font-size: 18px;
  line-height: 1.45;
}

.movie-card:hover h3 {
  color: #2563eb;
}

.card-body p {
  min-height: 44px;
  margin-top: 8px;
  color: #5b6472;
  font-size: 14px;
  line-height: 1.55;
}

.card-foot,
.card-meta-row,
.compact-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
  color: #64748b;
  font-size: 13px;
}

.movie-card-compact {
  display: grid;
  grid-template-columns: 124px minmax(0, 1fr);
  gap: 14px;
  padding: 10px;
  box-shadow: none;
  border: 1px solid #e5e7eb;
}

.compact-poster {
  position: relative;
  overflow: hidden;
  height: 82px;
  border-radius: 14px;
}

.play-dot {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 36px;
  height: 36px;
  opacity: 0;
  transform: translate(-50%, -50%);
  transition: opacity 0.2s ease;
}

.play-dot.large {
  width: 54px;
  height: 54px;
}

.movie-card:hover .play-dot {
  opacity: 1;
}

.rank-badge {
  position: absolute;
  top: 6px;
  left: 6px;
  display: grid;
  place-items: center;
  min-width: 28px;
  height: 28px;
  padding: 0 7px;
  border-radius: 10px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #ef4444);
  font-size: 13px;
  font-weight: 900;
}

.compact-info {
  min-width: 0;
}

.compact-info h3 {
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  font-size: 15px;
}

.compact-info p {
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  margin-top: 5px;
  color: #64748b;
  font-size: 13px;
  line-height: 1.45;
}

.compact-meta {
  justify-content: flex-start;
  margin-top: 8px;
  font-size: 12px;
}

.movie-card-horizontal {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 18px;
  padding: 0;
}

.horizontal-poster {
  position: relative;
  overflow: hidden;
  min-height: 158px;
}

.horizontal-info {
  padding: 18px 18px 18px 0;
}

.horizontal-info h3 {
  margin: 10px 0 8px;
  font-size: 21px;
}

.horizontal-info p {
  color: #64748b;
  line-height: 1.65;
}

.genre-line {
  margin-top: 14px;
  color: #64748b;
  font-size: 13px;
}

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

.category-panel,
.category-card,
.content-card {
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.category-panel {
  padding: 24px;
}

.category-panel-head,
.category-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

.category-panel h3,
.category-card h2 {
  color: #2563eb;
  font-size: 22px;
  font-weight: 900;
}

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

.page-hero {
  color: #ffffff;
  background: radial-gradient(circle at 18% 10%, rgba(250, 204, 21, 0.32), transparent 24%), linear-gradient(100deg, #172554, #1d4ed8 55%, #0891b2);
}

.page-hero-inner {
  display: grid;
  gap: 18px;
  padding: 58px 0;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #dbeafe;
  font-size: 14px;
  font-weight: 700;
}

.breadcrumbs a:hover {
  color: #facc15;
}

.page-hero h1,
.detail-copy h1 {
  max-width: 900px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.12;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 780px;
  color: #dbeafe;
  font-size: 17px;
  line-height: 1.75;
}

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

.category-card {
  overflow: hidden;
  color: inherit;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-teaser {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  height: 120px;
  overflow: hidden;
}

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

.category-card-body p {
  margin-top: 8px;
  color: #64748b;
  line-height: 1.6;
}

.filter-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 26px;
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 48px;
  border: 1px solid #dbe3ef;
  border-radius: 16px;
  padding: 0 16px;
  color: #1f2937;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus {
  border-color: #38bdf8;
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.16);
}

.no-results {
  display: none;
  padding: 36px;
  border-radius: 20px;
  color: #64748b;
  background: #ffffff;
  text-align: center;
  box-shadow: var(--site-shadow);
}

.no-results.show {
  display: block;
}

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

.detail-hero {
  color: #ffffff;
  background: linear-gradient(110deg, #0f172a, #1e3a8a 58%, #0e7490);
}

.detail-hero-inner {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
  padding: 58px 0;
}

.detail-cover {
  overflow: hidden;
  height: 430px;
  border-radius: 28px;
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.35);
}

.detail-copy {
  display: grid;
  gap: 18px;
}

.detail-copy p {
  max-width: 820px;
  color: #dbeafe;
  font-size: 17px;
  line-height: 1.8;
}

.player-section {
  padding: 54px 0 26px;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #020617;
  box-shadow: 0 22px 56px rgba(15, 23, 42, 0.24);
}

.movie-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.2));
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.play-overlay span {
  display: inline-grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  color: #1d4ed8;
  background: #ffffff;
  font-size: 36px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
}

.play-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  padding: 34px 0 64px;
}

.content-card {
  padding: 26px;
}

.content-card h2 {
  margin-bottom: 14px;
  color: #111827;
  font-size: 24px;
  font-weight: 900;
}

.content-card p {
  color: #475569;
  font-size: 16px;
  line-height: 1.9;
}

.content-card p + p {
  margin-top: 16px;
}

.side-stack {
  display: grid;
  gap: 14px;
  align-content: start;
}

.meta-table {
  display: grid;
  gap: 10px;
}

.meta-table div {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eef2f7;
  color: #64748b;
}

.meta-table strong {
  color: #111827;
}

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

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

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

  .mobile-menu-button {
    display: inline-grid;
    place-items: center;
  }

  .hero-grid,
  .detail-hero-inner,
  .detail-content-grid {
    grid-template-columns: 1fr;
  }

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

  .category-panels,
  .ranking-list {
    grid-template-columns: 1fr;
  }

  .detail-cover {
    height: 460px;
    max-width: 360px;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .site-logo {
    font-size: 20px;
  }

  .hero-grid,
  .page-hero-inner,
  .detail-hero-inner {
    padding: 42px 0 58px;
  }

  .hero-poster img {
    min-height: 300px;
  }

  .card-grid,
  .card-grid.three,
  .card-grid.two,
  .category-card-grid,
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

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

  .movie-card-horizontal {
    grid-template-columns: 1fr;
  }

  .horizontal-info {
    padding: 18px;
  }

  .horizontal-poster {
    height: 210px;
  }

  .detail-cover {
    height: 360px;
  }

  .filter-bar {
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .card-grid,
  .card-grid.three,
  .card-grid.two,
  .category-card-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .movie-card-compact {
    grid-template-columns: 110px minmax(0, 1fr);
  }

  .compact-poster {
    height: 76px;
  }

  .section-block {
    padding: 42px 0;
  }
}
