:root {
  --blackboard: #1a2e1a;
  --blackboard-dark: #0f1a0f;
  --blackboard-light: #2d4a2d;
  --chalk-white: #f5f5dc;
  --chalk-yellow: #fffacd;
  --chalk-blue: #add8e6;
  --chalk-green: #90ee90;
  --chalk-pink: #ffb6c1;
  --vintage-gold: #ffd700;
  --shadow-soft: 0 20px 60px rgba(0, 0, 0, 0.28);
  --border-chalk: rgba(245, 245, 220, 0.24);
}

body {
  background:
    radial-gradient(circle at 20% 10%, rgba(255, 250, 205, 0.08), transparent 28rem),
    radial-gradient(circle at 80% 0%, rgba(173, 216, 230, 0.08), transparent 24rem),
    var(--blackboard);
  color: var(--chalk-white);
}

.site-shell {
  min-height: 100vh;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 42px 42px;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 26, 15, 0.88);
  border-bottom: 1px solid rgba(245, 245, 220, 0.16);
  backdrop-filter: blur(18px);
}

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

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--chalk-yellow);
}

.logo-mark {
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 2px dashed rgba(255, 250, 205, 0.78);
  border-radius: 14px;
  background: rgba(255, 250, 205, 0.08);
  font-weight: 800;
  box-shadow: 0 0 18px rgba(255, 250, 205, 0.12) inset;
}

.logo-text {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link,
.mobile-nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: rgba(245, 245, 220, 0.76);
  transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover {
  color: var(--chalk-yellow);
  border-color: rgba(255, 250, 205, 0.32);
  background: rgba(255, 250, 205, 0.08);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 250, 205, 0.28);
  border-radius: 12px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: var(--chalk-yellow);
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
  border-top: 1px solid rgba(245, 245, 220, 0.10);
}

.hero {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  background: var(--blackboard-dark);
}

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

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

.hero-bg,
.hero-bg img,
.hero-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-bg img {
  object-fit: cover;
  filter: saturate(0.9) brightness(0.7);
  transform: scale(1.03);
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(15, 26, 15, 0.92) 0%, rgba(26, 46, 26, 0.74) 46%, rgba(26, 46, 26, 0.22) 100%),
    linear-gradient(0deg, var(--blackboard) 0%, rgba(26, 46, 26, 0.15) 42%, rgba(26, 46, 26, 0.28) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  min-height: 72vh;
  padding-top: 120px;
  padding-bottom: 76px;
}

.hero-copy {
  max-width: 760px;
}

.hero-kicker,
.eyebrow {
  margin-bottom: 12px;
  color: var(--chalk-yellow);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  color: var(--chalk-white);
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.95;
  letter-spacing: 0.02em;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.42);
}

.hero-desc {
  max-width: 680px;
  margin-top: 22px;
  color: rgba(245, 245, 220, 0.88);
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.8;
}

.hero-tags,
.detail-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

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

.hero-tags span,
.detail-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(255, 250, 205, 0.24);
  border-radius: 999px;
  background: rgba(255, 250, 205, 0.08);
  color: rgba(245, 245, 220, 0.88);
  font-size: 12px;
}

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

.primary-button,
.ghost-button,
.section-more,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 800;
  transition: all 0.2s ease;
}

.primary-button {
  background: var(--chalk-yellow);
  color: var(--blackboard-dark);
  box-shadow: 0 12px 36px rgba(255, 250, 205, 0.22);
}

.primary-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 44px rgba(255, 250, 205, 0.30);
}

.ghost-button,
.section-more,
.text-link {
  border: 1px dashed rgba(255, 250, 205, 0.36);
  color: var(--chalk-yellow);
  background: rgba(255, 250, 205, 0.06);
}

.ghost-button:hover,
.section-more:hover,
.text-link:hover {
  border-style: solid;
  background: rgba(255, 250, 205, 0.12);
}

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

.hero-dot {
  width: 36px;
  height: 5px;
  border-radius: 999px;
  background: rgba(245, 245, 220, 0.28);
  transition: all 0.2s ease;
}

.hero-dot.is-active {
  width: 62px;
  background: var(--chalk-yellow);
}

.quick-search-section {
  margin-top: -36px;
  position: relative;
  z-index: 5;
}

.quick-search,
.filter-panel,
.chalk-board-panel,
.category-overview-card,
.page-hero {
  border: 1px solid rgba(255, 250, 205, 0.20);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(255, 250, 205, 0.08), rgba(173, 216, 230, 0.04)),
    rgba(15, 26, 15, 0.72);
  box-shadow: var(--shadow-soft);
}

.quick-search {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 16px;
  align-items: center;
  padding: 18px;
}

.quick-search label {
  color: var(--chalk-yellow);
  font-weight: 900;
}

.quick-search div {
  display: flex;
  gap: 10px;
}

.quick-search input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid rgba(255, 250, 205, 0.24);
  border-radius: 14px;
  outline: none;
  background: rgba(26, 46, 26, 0.9);
  color: var(--chalk-white);
}

.quick-search button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 14px;
  background: var(--chalk-yellow);
  color: var(--blackboard-dark);
  font-weight: 900;
}

.page-main {
  padding-top: 36px;
  padding-bottom: 54px;
}

.page-section {
  margin-top: 54px;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.section-heading h2,
.chalk-board-panel h2,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  color: var(--chalk-yellow);
  font-weight: 900;
  letter-spacing: 0.02em;
}

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

.section-heading span,
.page-hero p,
.chalk-board-panel p,
.detail-content p {
  color: rgba(245, 245, 220, 0.76);
  line-height: 1.8;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 18px;
}

.featured-grid {
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
}

.library-grid {
  grid-template-columns: repeat(auto-fill, minmax(178px, 1fr));
}

.compact-grid {
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 250, 205, 0.18);
  border-radius: 20px;
  background: rgba(15, 26, 15, 0.72);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(255, 250, 205, 0.46);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.26);
}

.movie-poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 250, 205, 0.20), transparent 40%),
    linear-gradient(135deg, var(--blackboard-light), var(--blackboard-dark));
}

.movie-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 26, 15, 0.78), transparent 45%);
}

.play-badge,
.year-badge,
.rank-corner {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.play-badge {
  left: 10px;
  bottom: 10px;
  background: var(--chalk-yellow);
  color: var(--blackboard-dark);
}

.year-badge {
  top: 10px;
  right: 10px;
  background: rgba(15, 26, 15, 0.72);
  color: var(--chalk-yellow);
  border: 1px solid rgba(255, 250, 205, 0.30);
}

.rank-corner {
  left: 10px;
  top: 10px;
  background: rgba(255, 215, 0, 0.92);
  color: var(--blackboard-dark);
}

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

.card-meta-line {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: rgba(173, 216, 230, 0.82);
  font-size: 12px;
}

.movie-card h3 {
  margin: 8px 0 8px;
  color: var(--chalk-white);
  font-size: 17px;
  font-weight: 900;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: var(--chalk-yellow);
}

.movie-card p {
  display: -webkit-box;
  min-height: 44px;
  overflow: hidden;
  margin: 0 0 12px;
  color: rgba(245, 245, 220, 0.68);
  font-size: 13px;
  line-height: 1.7;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.category-tile {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border: 1px solid rgba(255, 250, 205, 0.18);
  border-radius: 24px;
  background: var(--blackboard-dark);
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.category-tile img,
.category-glow {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.category-tile img {
  object-fit: cover;
  opacity: 0.45;
  transition: transform 0.3s ease;
}

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

.category-glow {
  background: linear-gradient(0deg, rgba(15, 26, 15, 0.92), rgba(15, 26, 15, 0.18));
}

.category-tile strong,
.category-tile em,
.category-tile p {
  position: relative;
  z-index: 2;
}

.category-tile strong {
  color: var(--chalk-yellow);
  font-size: 24px;
}

.category-tile em {
  margin-top: 4px;
  color: var(--chalk-blue);
  font-style: normal;
}

.category-tile p {
  margin-top: 8px;
  color: rgba(245, 245, 220, 0.72);
  line-height: 1.65;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: start;
}

.chalk-board-panel {
  padding: 22px;
}

.rank-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.rank-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 10px;
  padding: 12px;
  border: 1px dashed rgba(255, 250, 205, 0.18);
  border-radius: 16px;
  background: rgba(255, 250, 205, 0.04);
}

.rank-row:hover {
  border-style: solid;
  border-color: rgba(255, 250, 205, 0.38);
}

.rank-num {
  color: var(--vintage-gold);
  font-weight: 900;
}

.rank-title {
  overflow: hidden;
  color: var(--chalk-white);
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-meta {
  grid-column: 2;
  color: rgba(245, 245, 220, 0.58);
  font-size: 12px;
}

.page-hero {
  padding: clamp(28px, 5vw, 56px);
}

.small-hero,
.category-page-hero {
  margin-bottom: 24px;
}

.page-hero h1 {
  font-size: clamp(34px, 5vw, 58px);
}

.filter-panel {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, minmax(140px, 1fr)) auto;
  gap: 12px;
  align-items: end;
  padding: 16px;
  margin-bottom: 30px;
}

.filter-panel label {
  display: grid;
  gap: 6px;
  color: var(--chalk-yellow);
  font-size: 13px;
  font-weight: 800;
}

.filter-count {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px dashed rgba(255, 250, 205, 0.24);
  border-radius: 14px;
  color: rgba(245, 245, 220, 0.8);
}

.filter-count strong {
  margin-right: 4px;
  color: var(--chalk-yellow);
}

.category-overview-grid {
  display: grid;
  gap: 18px;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 24px;
  padding: 18px;
  align-items: center;
}

.category-thumb-stack {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.category-thumb-stack img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 14px;
  background: var(--blackboard-light);
}

.category-overview-card h2 {
  margin: 0 0 8px;
  color: var(--chalk-yellow);
  font-size: 30px;
}

.category-overview-card p {
  color: rgba(245, 245, 220, 0.72);
  line-height: 1.8;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 22px;
  color: rgba(245, 245, 220, 0.72);
}

.breadcrumb a:hover {
  color: var(--chalk-yellow);
}

.detail-hero {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 28px;
  align-items: end;
  padding: 24px;
  border: 1px solid rgba(255, 250, 205, 0.20);
  border-radius: 28px;
  background:
    radial-gradient(circle at 90% 10%, rgba(255, 250, 205, 0.12), transparent 30rem),
    rgba(15, 26, 15, 0.74);
  box-shadow: var(--shadow-soft);
}

.detail-cover {
  overflow: hidden;
  border-radius: 22px;
  background: var(--blackboard-light);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.32);
}

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

.detail-info h1 {
  font-size: clamp(36px, 5vw, 64px);
}

.detail-one-line {
  margin-top: 16px;
  color: rgba(245, 245, 220, 0.82);
  font-size: 19px;
  line-height: 1.8;
}

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

.player-section {
  margin-top: 28px;
}

.video-frame {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 250, 205, 0.22);
  border-radius: 28px;
  background: #000;
  box-shadow: var(--shadow-soft);
  aspect-ratio: 16 / 9;
}

.video-player {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.player-overlay-button {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 8px;
  background: linear-gradient(0deg, rgba(15, 26, 15, 0.72), rgba(15, 26, 15, 0.32));
  color: var(--chalk-yellow);
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-triangle {
  width: 72px;
  height: 72px;
  border-radius: 999px;
  background: var(--chalk-yellow);
  box-shadow: 0 0 38px rgba(255, 250, 205, 0.34);
  position: relative;
}

.play-triangle::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  margin-left: -8px;
  margin-top: -14px;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  border-left: 22px solid var(--blackboard-dark);
}

.player-overlay-button strong {
  font-size: 22px;
}

.player-overlay-button em {
  color: rgba(245, 245, 220, 0.72);
  font-style: normal;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 24px;
  align-items: start;
  margin-top: 32px;
}

.detail-content h2 {
  margin: 0 0 12px;
  color: var(--chalk-yellow);
  font-size: 26px;
}

.detail-content h2:not(:first-child) {
  margin-top: 28px;
}

.detail-content p {
  font-size: 16px;
}

.meta-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.meta-list div {
  display: grid;
  grid-template-columns: 82px 1fr;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed rgba(255, 250, 205, 0.14);
}

.meta-list dt {
  color: var(--chalk-blue);
  font-weight: 900;
}

.meta-list dd {
  margin: 0;
  color: rgba(245, 245, 220, 0.84);
}

.large-tags {
  margin-top: 22px;
}

.sticky-panel {
  position: sticky;
  top: 96px;
}

.side-link {
  display: block;
  padding: 12px 0;
  border-bottom: 1px dashed rgba(255, 250, 205, 0.16);
  color: rgba(245, 245, 220, 0.78);
}

.side-link:hover {
  color: var(--chalk-yellow);
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(255, 250, 205, 0.18);
  border-radius: 20px;
  background: rgba(15, 26, 15, 0.72);
}

.rank-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.rank-table th,
.rank-table td {
  padding: 13px 14px;
  border-bottom: 1px solid rgba(255, 250, 205, 0.12);
  text-align: left;
}

.rank-table th {
  color: var(--chalk-yellow);
  background: rgba(255, 250, 205, 0.06);
}

.rank-table td {
  color: rgba(245, 245, 220, 0.78);
}

.rank-table a {
  color: var(--chalk-white);
  font-weight: 800;
}

.rank-table a:hover {
  color: var(--chalk-yellow);
}

.site-footer {
  margin-top: 70px;
  border-top: 1px solid rgba(245, 245, 220, 0.14);
  background: rgba(15, 26, 15, 0.72);
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 34px 0;
}

.footer-logo {
  margin-bottom: 8px;
  color: var(--chalk-yellow);
  font-size: 22px;
  font-weight: 900;
}

.site-footer p {
  color: rgba(245, 245, 220, 0.62);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-content: flex-start;
}

.footer-links a {
  color: rgba(245, 245, 220, 0.68);
}

.footer-links a:hover {
  color: var(--chalk-yellow);
}

[hidden] {
  display: none !important;
}

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

  .nav-toggle {
    display: inline-block;
  }

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

  .quick-search,
  .split-section,
  .filter-panel,
  .category-overview-card,
  .detail-hero,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .quick-search div {
    flex-direction: column;
  }

  .detail-cover {
    max-width: 260px;
  }

  .sticky-panel {
    position: static;
  }
}

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

  .hero,
  .hero-content {
    min-height: 78vh;
  }

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

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

  .movie-grid,
  .featured-grid,
  .library-grid,
  .compact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

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

  .movie-card p {
    display: none;
  }

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

  .detail-hero {
    padding: 16px;
  }

  .video-frame {
    border-radius: 18px;
  }

  .meta-list div {
    grid-template-columns: 1fr;
  }
}
