:root {
  color-scheme: light;
  --brand: #dc2626;
  --brand-dark: #991b1b;
  --brand-soft: #fee2e2;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #e5e7eb;
  --card: #ffffff;
  --bg: #f9fafb;
  --shadow: 0 18px 55px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}

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

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #111827;
}

.logo-mark {
  width: 38px;
  height: 38px;
  border-radius: 16px;
  background: linear-gradient(135deg, #ef4444, #be123c);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 12px 28px rgba(220, 38, 38, 0.28);
}

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

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

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

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

.header-search {
  display: flex;
  align-items: center;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  overflow: hidden;
  min-width: 250px;
}

.header-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  padding: 10px 14px;
}

.header-search button {
  border: 0;
  background: var(--brand);
  color: #fff;
  padding: 10px 16px;
  cursor: pointer;
}

.mobile-toggle {
  display: none;
  border: 0;
  background: #f3f4f6;
  border-radius: 12px;
  width: 42px;
  height: 42px;
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #111827;
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  padding: 0 0 16px;
  border-top: 1px solid var(--line);
}

.mobile-nav a {
  display: block;
  padding: 11px 0;
  color: #4b5563;
  font-weight: 700;
}

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

.hero {
  position: relative;
  overflow: hidden;
  min-height: 660px;
  background: radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.25), transparent 26%), linear-gradient(135deg, #7f1d1d 0%, #dc2626 45%, #f97316 100%);
  color: #fff;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  filter: blur(4px);
}

.hero::before {
  width: 260px;
  height: 260px;
  right: 10%;
  top: 12%;
}

.hero::after {
  width: 420px;
  height: 420px;
  left: -140px;
  bottom: -180px;
}

.hero-track {
  position: relative;
  z-index: 2;
  min-height: 660px;
}

.hero-slide {
  display: none;
  min-height: 660px;
  align-items: center;
  padding: 72px 0;
}

.hero-slide.active {
  display: flex;
  animation: fadeIn 0.65s ease both;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  align-items: center;
  gap: 46px;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
  font-weight: 800;
}

.hero-title {
  margin: 22px 0 18px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.06em;
  font-weight: 950;
}

.hero-desc {
  margin: 0 0 22px;
  max-width: 690px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 19px;
  line-height: 1.8;
}

.hero-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag,
.meta-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: inherit;
  font-size: 13px;
  font-weight: 800;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  border-radius: 999px;
  padding: 12px 22px;
  border: 0;
  cursor: pointer;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: #fff;
  color: var(--brand);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.18);
}

.btn-red {
  background: linear-gradient(135deg, #ef4444, #be123c);
  color: #fff;
  box-shadow: 0 14px 30px rgba(220, 38, 38, 0.26);
}

.btn-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.1);
}

.hero-poster {
  position: relative;
  border-radius: 34px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow: 0 32px 90px rgba(60, 8, 8, 0.45);
  transform: rotate(1deg);
}

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

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

.hero-poster-caption {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 22px;
  z-index: 2;
}

.hero-poster-caption strong {
  display: block;
  font-size: 24px;
  margin-bottom: 8px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  border: 0;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
}

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

.section {
  padding: 66px 0;
}

.section-soft {
  background: linear-gradient(180deg, #fff, #fff1f2);
}

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

.section-kicker {
  color: var(--brand);
  font-size: 14px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section-title {
  margin: 5px 0 0;
  color: #111827;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.15;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 24px;
  background: var(--card);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.movie-cover {
  position: relative;
  background: linear-gradient(135deg, #fee2e2, #fff7ed);
  overflow: hidden;
}

.movie-cover img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

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

.cover-play {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.92);
  color: var(--brand);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.18);
}

.movie-body {
  padding: 16px;
}

.movie-title {
  margin: 0;
  color: #111827;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 950;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-line {
  margin: 8px 0 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #6b7280;
  font-size: 12px;
  font-weight: 800;
}

.movie-meta span {
  border-radius: 999px;
  background: #f3f4f6;
  padding: 5px 8px;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 166px;
  border-radius: 26px;
  padding: 24px;
  color: #fff;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.16);
  transition: transform 0.2s ease;
}

.category-card:hover {
  transform: translateY(-5px) scale(1.01);
}

.category-card::after {
  content: "";
  position: absolute;
  right: -36px;
  bottom: -46px;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.category-card strong {
  position: relative;
  z-index: 1;
  display: block;
  font-size: 24px;
  margin-bottom: 10px;
}

.category-card span {
  position: relative;
  z-index: 1;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.7;
}

.grad-1 { background: linear-gradient(135deg, #ef4444, #be123c); }
.grad-2 { background: linear-gradient(135deg, #f97316, #dc2626); }
.grad-3 { background: linear-gradient(135deg, #8b5cf6, #e11d48); }
.grad-4 { background: linear-gradient(135deg, #0ea5e9, #dc2626); }
.grad-5 { background: linear-gradient(135deg, #10b981, #f97316); }
.grad-6 { background: linear-gradient(135deg, #6366f1, #be123c); }
.grad-7 { background: linear-gradient(135deg, #14b8a6, #f43f5e); }
.grad-8 { background: linear-gradient(135deg, #64748b, #dc2626); }

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

.rank-row {
  display: grid;
  grid-template-columns: 58px 80px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  border-radius: 20px;
  padding: 12px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.rank-num {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: #fff1f2;
  color: var(--brand);
  font-weight: 950;
  font-size: 20px;
}

.rank-poster {
  width: 78px;
  height: 102px;
  border-radius: 14px;
  object-fit: cover;
  background: #fee2e2;
}

.rank-title {
  margin: 0 0 6px;
  color: #111827;
  font-size: 18px;
  font-weight: 950;
}

.rank-summary {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rank-score {
  color: var(--brand);
  font-weight: 950;
}

.page-hero {
  padding: 58px 0;
  background: linear-gradient(135deg, #7f1d1d, #ef4444 52%, #fb923c);
  color: #fff;
}

.page-hero h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 780px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.85;
  font-size: 18px;
}

.filter-panel {
  margin-top: -34px;
  position: relative;
  z-index: 3;
}

.filter-box {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(150px, 0.45fr));
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow);
}

.filter-box input,
.filter-box select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  outline: 0;
  padding: 12px 13px;
  background: #f9fafb;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  background: #111827;
  color: #fff;
}

.detail-hero-bg {
  position: absolute;
  inset: 0;
  opacity: 0.34;
  filter: blur(2px);
}

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

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.96), rgba(17, 24, 39, 0.78), rgba(17, 24, 39, 0.42));
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 38px;
  align-items: end;
  padding: 74px 0;
}

.detail-poster {
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 32px 70px rgba(0, 0, 0, 0.38);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
  font-weight: 800;
}

.breadcrumb a:hover {
  color: #fff;
}

.detail-title {
  margin: 0 0 16px;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1.05;
  font-weight: 950;
  letter-spacing: -0.06em;
}

.detail-line {
  max-width: 850px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.8;
  font-size: 18px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}

.player-section {
  padding: 48px 0 28px;
  background: #0f172a;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.36);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.46));
  cursor: pointer;
}

.play-overlay span {
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--brand);
  font-weight: 950;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.32);
}

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

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 26px;
  align-items: start;
}

.article-card,
.side-card {
  border-radius: 26px;
  padding: 26px;
  background: #fff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.article-card h2,
.side-card h2 {
  margin: 0 0 14px;
  color: #111827;
  font-size: 24px;
  font-weight: 950;
}

.article-card p {
  color: #4b5563;
  line-height: 1.95;
  margin: 0 0 18px;
}

.info-list {
  display: grid;
  gap: 10px;
}

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid #f3f4f6;
  padding-bottom: 10px;
  color: #4b5563;
}

.info-list strong {
  color: #111827;
}

.footer {
  padding: 38px 0;
  color: #9ca3af;
  background: #111827;
}

.footer-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.footer a:hover {
  color: #fff;
}

.empty-state {
  display: none;
  border-radius: 24px;
  padding: 36px;
  background: #fff;
  color: var(--muted);
  text-align: center;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.empty-state.show {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

  .mobile-toggle {
    display: block;
  }

  .hero,
  .hero-track,
  .hero-slide {
    min-height: auto;
  }

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

  .hero-slide {
    padding: 54px 0 84px;
  }

  .hero-poster {
    transform: none;
  }

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

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

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

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

  .section {
    padding: 44px 0;
  }

  .hero-title,
  .detail-title {
    letter-spacing: -0.04em;
  }

  .hero-actions,
  .section-head,
  .footer-grid {
    align-items: stretch;
    flex-direction: column;
  }

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

  .rank-row {
    grid-template-columns: 42px 68px minmax(0, 1fr);
  }

  .rank-score {
    grid-column: 3;
  }

  .rank-poster {
    width: 66px;
    height: 88px;
  }
}
