:root {
  --site-red: #dc2626;
  --site-red-dark: #991b1b;
  --site-orange: #f97316;
  --site-slate: #0f172a;
  --site-muted: #64748b;
  --site-bg: #f8fafc;
  --site-card: #ffffff;
  --site-ring: rgba(220, 38, 38, 0.18);
}

body {
  min-height: 100vh;
  background: var(--site-bg);
  color: var(--site-slate);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.site-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.main-content {
  flex: 1;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(14px);
}

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

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 76px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.logo-mark {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-weight: 900;
  font-size: 22px;
  background: linear-gradient(135deg, var(--site-red), var(--site-orange));
  box-shadow: 0 16px 30px rgba(220, 38, 38, 0.28);
  transition: transform 0.25s ease;
}

.logo:hover .logo-mark {
  transform: scale(1.08) rotate(-3deg);
}

.logo-title {
  display: block;
  font-size: 20px;
  line-height: 1.15;
  font-weight: 900;
  color: #1e293b;
}

.logo-subtitle {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  color: #64748b;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  font-weight: 700;
  color: #475569;
}

.nav-links a,
.mobile-panel a,
.footer-links a,
.breadcrumb a,
.category-card,
.rank-row,
.movie-card,
.inline-link {
  text-decoration: none;
}

.nav-links a {
  position: relative;
  transition: color 0.2s ease;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -8px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--site-red), var(--site-orange));
  transform: scaleX(0);
  transition: transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--site-red);
}

.nav-links a:hover::after,
.nav-links a.is-active::after {
  transform: scaleX(1);
}

.header-search {
  position: relative;
  width: min(280px, 24vw);
}

.header-search input,
.filter-input,
.filter-select {
  width: 100%;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  border-radius: 999px;
  outline: none;
  color: #0f172a;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input {
  height: 42px;
  padding: 0 48px 0 16px;
}

.header-search button {
  position: absolute;
  right: 5px;
  top: 5px;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--site-red), var(--site-orange));
}

.header-search input:focus,
.filter-input:focus,
.filter-select:focus {
  border-color: var(--site-red);
  box-shadow: 0 0 0 4px var(--site-ring);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  background: #fee2e2;
  color: var(--site-red);
  font-size: 24px;
  line-height: 1;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 16px;
  border: 1px solid #fee2e2;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.12);
}

.mobile-panel.is-open {
  display: block;
  animation: fade-up 0.22s ease both;
}

.mobile-panel nav {
  display: grid;
  gap: 8px;
}

.mobile-panel a {
  padding: 12px 14px;
  border-radius: 14px;
  color: #475569;
  font-weight: 800;
}

.mobile-panel a:hover {
  background: #fef2f2;
  color: var(--site-red);
}

.mobile-panel .header-search {
  width: 100%;
  margin-top: 12px;
}

.hero {
  position: relative;
  min-height: 660px;
  overflow: hidden;
  background: radial-gradient(circle at 18% 10%, rgba(248, 113, 113, 0.4), transparent 28%), linear-gradient(135deg, #0f172a 0%, #111827 45%, #7f1d1d 100%);
  color: #ffffff;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -10% -24% -10%;
  height: 42%;
  background: linear-gradient(180deg, transparent, var(--site-bg) 75%);
  pointer-events: none;
}

.hero-carousel {
  position: relative;
  min-height: 660px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.015);
  transition: opacity 0.75s ease, transform 0.75s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  opacity: 0.35;
}

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

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.74) 42%, rgba(15, 23, 42, 0.25));
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 660px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 42px;
  align-items: center;
  padding: 70px 0 95px;
}

.hero-kicker,
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 8px 13px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #fecaca;
  font-weight: 900;
  letter-spacing: 0.02em;
  backdrop-filter: blur(8px);
}

.hero h1 {
  margin-top: 24px;
  max-width: 760px;
  font-size: clamp(40px, 6vw, 74px);
  line-height: 0.98;
  font-weight: 950;
  letter-spacing: -0.06em;
}

.hero h1 span {
  display: block;
  color: #fed7aa;
}

.hero-desc {
  max-width: 720px;
  margin-top: 24px;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.85;
}

.hero-meta,
.detail-meta,
.card-meta,
.rank-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
}

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

.meta-pill,
.tag-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.meta-pill {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.tag-pill {
  color: #b91c1c;
  background: #fee2e2;
}

.hero-actions,
.section-actions,
.detail-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 13px;
  margin-top: 30px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--site-red), var(--site-orange));
  box-shadow: 0 18px 34px rgba(220, 38, 38, 0.28);
}

.btn-secondary {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
}

.btn-light {
  color: var(--site-red);
  background: #ffffff;
  border-color: #fee2e2;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 36px rgba(15, 23, 42, 0.18);
}

.hero-poster {
  position: relative;
  border-radius: 34px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 34px 70px rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(18px);
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 26px;
  background: linear-gradient(135deg, #334155, #991b1b);
}

.hero-poster-info {
  position: absolute;
  left: 26px;
  right: 26px;
  bottom: 26px;
  padding: 18px;
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(10px);
}

.hero-poster-info strong {
  display: block;
  font-size: 20px;
  margin-bottom: 6px;
}

.hero-controls {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 34px;
  display: flex;
  align-items: center;
  gap: 10px;
  transform: translateX(-50%);
}

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

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

.section {
  padding: 74px 0;
}

.section.compact {
  padding: 42px 0;
}

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

.section-title {
  font-size: clamp(28px, 3.4vw, 42px);
  line-height: 1.12;
  font-weight: 950;
  letter-spacing: -0.04em;
  color: #0f172a;
}

.section-desc {
  max-width: 740px;
  margin-top: 10px;
  color: #64748b;
  line-height: 1.8;
}

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

.category-card {
  display: block;
  min-height: 160px;
  padding: 22px;
  border-radius: 26px;
  color: #ffffff;
  background: linear-gradient(135deg, #1e293b, #991b1b);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:nth-child(2n) {
  background: linear-gradient(135deg, #7f1d1d, #f97316);
}

.category-card:nth-child(3n) {
  background: linear-gradient(135deg, #0f172a, #475569);
}

.category-card strong {
  display: block;
  font-size: 21px;
  margin-bottom: 12px;
}

.category-card span {
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.65;
}

.category-card:hover,
.movie-card:hover,
.rank-row:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 50px rgba(15, 23, 42, 0.18);
}

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

.movie-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 26px;
  background: var(--site-card);
  color: #0f172a;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-cover {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #cbd5e1, #fee2e2);
}

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

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

.card-badge {
  position: absolute;
  left: 13px;
  top: 13px;
  z-index: 2;
  padding: 6px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(220, 38, 38, 0.92);
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 18px;
}

.card-title {
  font-size: 18px;
  line-height: 1.36;
  font-weight: 950;
  color: #0f172a;
}

.card-summary {
  display: -webkit-box;
  overflow: hidden;
  min-height: 48px;
  margin: 10px 0 14px;
  color: #64748b;
  line-height: 1.65;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  margin-top: auto;
  color: #64748b;
  font-size: 13px;
  font-weight: 800;
}

.page-hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: radial-gradient(circle at 80% 0%, rgba(249, 115, 22, 0.34), transparent 28%), linear-gradient(135deg, #0f172a, #7f1d1d);
}

.page-hero .section-wrap {
  padding: 76px 0 72px;
}

.page-hero h1 {
  max-width: 900px;
  margin-top: 18px;
  font-size: clamp(36px, 5vw, 62px);
  line-height: 1.04;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 780px;
  margin-top: 18px;
  color: #cbd5e1;
  line-height: 1.85;
  font-size: 18px;
}

.filters {
  display: grid;
  grid-template-columns: 1fr 180px 180px 180px;
  gap: 14px;
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid #e2e8f0;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.filter-input,
.filter-select {
  height: 46px;
  padding: 0 15px;
  border-radius: 16px;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 72px 120px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 13px;
  border-radius: 24px;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.07);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-number {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--site-red), var(--site-orange));
  font-weight: 950;
  font-size: 20px;
}

.rank-cover {
  width: 120px;
  height: 76px;
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(135deg, #cbd5e1, #fee2e2);
}

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

.rank-title {
  display: block;
  margin-bottom: 8px;
  font-weight: 950;
  font-size: 18px;
}

.rank-summary {
  color: #64748b;
  line-height: 1.6;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  color: #fee2e2;
  font-weight: 800;
}

.breadcrumb a {
  color: #ffffff;
}

.detail-hero-grid {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 40px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 34px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 72px rgba(0, 0, 0, 0.32);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 25px;
  background: linear-gradient(135deg, #334155, #991b1b);
}

.detail-meta {
  margin-top: 20px;
}

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

.content-card {
  padding: 28px;
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
}

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

.content-card h2,
.content-card h3 {
  margin-bottom: 14px;
  color: #0f172a;
  font-weight: 950;
  letter-spacing: -0.03em;
}

.content-card h2 {
  font-size: 28px;
}

.content-card h3 {
  font-size: 22px;
}

.content-card p {
  color: #475569;
  line-height: 1.9;
  margin-top: 10px;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #020617;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.72));
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.play-core {
  display: grid;
  place-items: center;
  gap: 14px;
  text-align: center;
}

.play-icon {
  width: 82px;
  height: 82px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--site-red), var(--site-orange));
  box-shadow: 0 18px 44px rgba(220, 38, 38, 0.36);
  font-size: 32px;
}

.play-title {
  font-size: 22px;
  font-weight: 950;
}

.play-subtitle {
  color: #cbd5e1;
  font-weight: 800;
}

.side-stack {
  display: grid;
  gap: 18px;
}

.side-card {
  display: block;
  overflow: hidden;
  border-radius: 24px;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
  text-decoration: none;
}

.side-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: linear-gradient(135deg, #cbd5e1, #fee2e2);
}

.side-card span {
  display: block;
  padding: 14px 16px 16px;
  font-weight: 950;
  line-height: 1.35;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.site-footer {
  margin-top: auto;
  color: #ffffff;
  background: linear-gradient(135deg, #0f172a, #172554 48%, #450a0a);
}

.footer-wrap {
  padding: 54px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 34px;
}

.footer-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.footer-title .logo-mark {
  width: 42px;
  height: 42px;
  font-size: 20px;
}

.footer-title strong {
  display: block;
  font-size: 20px;
}

.footer-title span,
.footer-copy,
.footer-wrap p {
  color: #cbd5e1;
}

.footer-wrap p {
  max-width: 520px;
  line-height: 1.8;
}

.footer-links {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.footer-links a {
  color: #cbd5e1;
  transition: color 0.2s ease, transform 0.2s ease;
}

.footer-links a:hover {
  color: #ffffff;
  transform: translateX(3px);
}

.footer-heading {
  font-size: 18px;
  font-weight: 950;
  color: #fecaca;
}

.footer-copy {
  margin-top: 34px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 14px;
}

.empty-note {
  display: none;
  padding: 34px;
  border-radius: 24px;
  text-align: center;
  color: #64748b;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

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

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1100px) {
  .header-search {
    width: 220px;
  }

  .hero-inner {
    grid-template-columns: 1fr 310px;
  }

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

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

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

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

  .mobile-toggle {
    display: grid;
    place-items: center;
  }

  .hero,
  .hero-carousel,
  .hero-inner {
    min-height: auto;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    padding: 58px 0 108px;
  }

  .hero-poster {
    max-width: 360px;
  }

  .section-head {
    display: block;
  }

  .section-actions {
    margin-top: 18px;
  }

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

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

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

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

  .rank-row {
    grid-template-columns: 54px 1fr;
  }

  .rank-cover,
  .rank-row .btn {
    display: none;
  }

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

@media (max-width: 560px) {
  .nav-wrap,
  .section-wrap,
  .footer-wrap,
  .hero-inner,
  .page-hero .section-wrap {
    width: min(100% - 24px, 1180px);
  }

  .logo-title {
    font-size: 17px;
  }

  .logo-subtitle {
    display: none;
  }

  .hero h1,
  .page-hero h1 {
    letter-spacing: -0.04em;
  }

  .hero-desc,
  .page-hero p {
    font-size: 16px;
  }

  .hero-actions,
  .detail-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

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

  .section {
    padding: 52px 0;
  }

  .content-card {
    padding: 22px;
  }
}
