@import url("https://fonts.googleapis.com/css2?family=Patrick+Hand&display=swap");

: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;
  --vintage-beige: #d4c5aa;
  --shadow: 0 22px 55px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 10% 10%, rgba(255, 250, 205, 0.05), transparent 28rem),
    radial-gradient(circle at 90% 0%, rgba(173, 216, 230, 0.08), transparent 26rem),
    linear-gradient(135deg, rgba(255, 250, 205, 0.025), rgba(255, 255, 255, 0));
  z-index: -1;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(26, 46, 26, 0.94);
  border-bottom: 2px solid rgba(255, 250, 205, 0.3);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(16px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--chalk-white);
  white-space: nowrap;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 2px solid rgba(255, 250, 205, 0.65);
  border-radius: 999px;
  color: var(--blackboard);
  background: var(--chalk-yellow);
  box-shadow: 0 0 0 6px rgba(255, 250, 205, 0.08);
}

.brand-text,
.footer-logo,
.hero-content h1,
.hero-content h2,
.section-heading h2,
.page-title h1,
.detail-title {
  font-family: "Patrick Hand", "Noto Sans SC", cursive;
  letter-spacing: 0.02em;
}

.brand-text {
  font-size: clamp(1.55rem, 2vw, 2rem);
  font-weight: 800;
}

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

.nav-link {
  color: rgba(245, 245, 220, 0.86);
  font-weight: 700;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--chalk-yellow);
  transform: translateY(-1px);
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-search input,
.local-filter input {
  min-width: 220px;
  border: 1px solid rgba(255, 250, 205, 0.3);
  border-radius: 12px;
  padding: 10px 14px;
  color: var(--chalk-white);
  background: rgba(45, 74, 45, 0.95);
  outline: none;
}

.header-search input:focus,
.mobile-search input:focus,
.local-filter input:focus {
  border-color: var(--chalk-yellow);
  box-shadow: 0 0 0 4px rgba(255, 250, 205, 0.08);
}

.header-search input::placeholder,
.mobile-search input::placeholder,
.local-filter input::placeholder {
  color: rgba(245, 245, 220, 0.55);
}

.header-search button,
.mobile-search button,
.primary-button,
.ghost-button,
.filter-chip,
.play-overlay {
  border: 0;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

.header-search button,
.mobile-search button,
.primary-button {
  color: var(--blackboard);
  background: var(--chalk-yellow);
  font-weight: 800;
}

.header-search button {
  padding: 10px 14px;
}

.header-search button:hover,
.mobile-search button:hover,
.primary-button:hover {
  background: var(--chalk-white);
  transform: translateY(-1px);
}

.menu-button {
  display: none;
  color: var(--chalk-white);
  background: transparent;
  border: 1px solid rgba(255, 250, 205, 0.25);
  border-radius: 10px;
  padding: 8px 11px;
}

.mobile-panel {
  border-top: 1px solid rgba(255, 250, 205, 0.22);
  padding: 14px 16px 18px;
  background: rgba(15, 26, 15, 0.98);
}

.mobile-nav {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
}

.hero-slider {
  position: relative;
  min-height: min(760px, 76vh);
  overflow: hidden;
  background: var(--blackboard-dark);
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.8s ease, transform 1.2s ease;
}

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 26, 15, 0.96) 0%, rgba(26, 46, 26, 0.75) 45%, rgba(26, 46, 26, 0.2) 100%),
    linear-gradient(0deg, rgba(26, 46, 26, 0.98), rgba(26, 46, 26, 0.1));
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 90px 0 78px;
  max-width: 1200px;
}

.hero-label {
  display: inline-flex;
  color: var(--chalk-yellow);
  border: 1px solid rgba(255, 250, 205, 0.36);
  background: rgba(26, 46, 26, 0.65);
  border-radius: 999px;
  padding: 7px 14px;
  margin-bottom: 16px;
  font-weight: 800;
}

.hero-content h1 {
  max-width: 760px;
  margin: 0 0 12px;
  font-size: clamp(2.4rem, 5.6vw, 5.6rem);
  line-height: 1.02;
  color: var(--chalk-white);
  text-shadow: 0 8px 26px rgba(0, 0, 0, 0.4);
}

.hero-content h2 {
  max-width: 680px;
  margin: 0 0 16px;
  font-size: clamp(2rem, 4vw, 4.4rem);
  line-height: 1.05;
  color: var(--chalk-yellow);
  text-shadow: 0 8px 26px rgba(0, 0, 0, 0.4);
}

.hero-content p {
  max-width: 690px;
  margin: 0 0 20px;
  color: rgba(245, 245, 220, 0.9);
  font-size: clamp(1rem, 1.8vw, 1.22rem);
}

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

.hero-tags span,
.tag-row span,
.detail-tags span,
.category-pills a,
.meta-pill {
  border-radius: 999px;
  border: 1px solid rgba(255, 250, 205, 0.25);
  background: rgba(255, 250, 205, 0.1);
  color: rgba(245, 245, 220, 0.88);
  padding: 5px 10px;
  font-size: 0.86rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.primary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 22px;
  font-weight: 900;
}

.ghost-button {
  border: 1px solid rgba(255, 250, 205, 0.36);
  color: var(--chalk-white);
  background: rgba(26, 46, 26, 0.58);
}

.ghost-button:hover {
  border-color: var(--chalk-yellow);
  color: var(--chalk-yellow);
  transform: translateY(-1px);
}

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

.hero-dot {
  width: 38px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(245, 245, 220, 0.35);
  cursor: pointer;
}

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

main {
  min-height: 70vh;
}

.home-content,
.page-content,
.detail-content {
  padding: 54px 0 72px;
}

.content-section {
  margin-bottom: 64px;
}

.content-section.panel,
.detail-panel,
.category-hero,
.search-panel {
  border: 2px solid rgba(255, 250, 205, 0.24);
  border-radius: 22px;
  padding: clamp(22px, 3vw, 34px);
  background: rgba(45, 74, 45, 0.68);
  box-shadow: var(--shadow);
}

.section-heading,
.page-title {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
}

.section-heading p,
.page-kicker,
.breadcrumbs,
.detail-kicker {
  color: var(--chalk-yellow);
  font-weight: 800;
  margin: 0 0 7px;
}

.section-heading h2,
.page-title h1,
.detail-title {
  margin: 0;
  color: var(--chalk-white);
  font-size: clamp(2rem, 3.8vw, 3.6rem);
  line-height: 1.1;
}

.section-more {
  color: var(--chalk-yellow);
  font-weight: 800;
}

.section-more:hover {
  color: var(--chalk-white);
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(255, 250, 205, 0.16);
  border-radius: 18px;
  background: rgba(15, 26, 15, 0.74);
  box-shadow: 0 16px 35px rgba(0, 0, 0, 0.2);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 250, 205, 0.65);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.34), 0 0 20px rgba(255, 250, 205, 0.08);
}

.poster-wrap {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.18);
}

.poster-wrap img,
.category-tile img,
.detail-cover img,
.rank-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.poster-wrap img {
  transition: transform 0.35s ease;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--blackboard);
  font-weight: 900;
  background: linear-gradient(0deg, rgba(15, 26, 15, 0.84), rgba(15, 26, 15, 0.05));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.poster-shade span {
  border-radius: 999px;
  padding: 9px 16px;
  background: var(--chalk-yellow);
}

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

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 34px;
  border-radius: 999px;
  color: var(--blackboard);
  background: var(--vintage-gold);
  font-weight: 900;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28);
}

.card-body {
  padding: 15px;
}

.card-body h3 {
  margin: 0 0 8px;
  color: var(--chalk-white);
  font-size: 1.08rem;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-body p {
  min-height: 3.1em;
  margin: 0 0 12px;
  color: rgba(245, 245, 220, 0.68);
  font-size: 0.92rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
  color: rgba(255, 250, 205, 0.85);
  font-size: 0.82rem;
}

.tag-row span {
  font-size: 0.76rem;
  padding: 3px 8px;
}

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

.category-tile {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: 20px;
  border: 2px solid rgba(255, 250, 205, 0.2);
  background: var(--blackboard-dark);
  box-shadow: var(--shadow);
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 26, 15, 0.96), rgba(15, 26, 15, 0.2));
}

.category-tile div {
  position: absolute;
  inset: auto 18px 18px;
  z-index: 1;
}

.category-tile h2 {
  margin: 0 0 8px;
  color: var(--chalk-yellow);
  font-size: 1.45rem;
}

.category-tile p {
  margin: 0;
  color: rgba(245, 245, 220, 0.82);
}

.category-tile:hover {
  border-color: var(--chalk-yellow);
}

.category-hero {
  margin-bottom: 34px;
}

.category-hero p {
  max-width: 820px;
  margin: 12px 0 0;
  color: rgba(245, 245, 220, 0.82);
}

.category-pills {
  margin-top: 20px;
}

.category-pills a:hover {
  border-color: var(--chalk-yellow);
  color: var(--chalk-yellow);
}

.local-filter {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 24px;
  border: 1px solid rgba(255, 250, 205, 0.16);
  border-radius: 18px;
  padding: 14px;
  background: rgba(15, 26, 15, 0.45);
}

.local-filter input {
  width: min(420px, 100%);
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 14px;
  color: var(--chalk-white);
  border: 1px solid rgba(255, 250, 205, 0.22);
  background: rgba(45, 74, 45, 0.7);
}

.filter-chip:hover {
  color: var(--chalk-yellow);
  border-color: var(--chalk-yellow);
}

.no-results {
  display: none;
  margin: 28px 0 0;
  color: rgba(245, 245, 220, 0.7);
  text-align: center;
}

.no-results.is-visible {
  display: block;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 70px 100px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(255, 250, 205, 0.16);
  border-radius: 18px;
  background: rgba(15, 26, 15, 0.58);
}

.rank-num {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  color: var(--blackboard);
  background: var(--chalk-yellow);
  font-size: 1.2rem;
  font-weight: 900;
}

.rank-cover {
  width: 100px;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 12px;
}

.rank-main h2 {
  margin: 0 0 8px;
  font-size: 1.25rem;
  color: var(--chalk-white);
}

.rank-main p {
  margin: 0;
  color: rgba(245, 245, 220, 0.72);
}

.rank-action {
  color: var(--chalk-yellow);
  font-weight: 900;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}

.breadcrumbs a:hover {
  color: var(--chalk-white);
}

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

.detail-player {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  border: 2px solid rgba(255, 250, 205, 0.24);
  background: #000;
  box-shadow: var(--shadow);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--blackboard);
  background: linear-gradient(0deg, rgba(15, 26, 15, 0.58), rgba(15, 26, 15, 0.08));
  z-index: 2;
}

.play-overlay span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 90px;
  height: 90px;
  border-radius: 999px;
  background: var(--chalk-yellow);
  font-size: 2rem;
  box-shadow: 0 0 0 12px rgba(255, 250, 205, 0.12), 0 20px 45px rgba(0, 0, 0, 0.34);
}

.play-overlay:hover {
  background: linear-gradient(0deg, rgba(15, 26, 15, 0.36), rgba(15, 26, 15, 0.02));
}

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

.detail-panel {
  margin-top: 22px;
}

.detail-title {
  margin-bottom: 14px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 18px;
}

.detail-summary h2,
.related-section h2,
.side-box h2 {
  margin: 0 0 14px;
  color: var(--chalk-yellow);
  font-size: 1.4rem;
}

.detail-summary p {
  margin: 0 0 16px;
  color: rgba(245, 245, 220, 0.84);
}

.detail-side {
  position: sticky;
  top: 96px;
}

.detail-cover {
  overflow: hidden;
  border-radius: 22px;
  border: 2px solid rgba(255, 250, 205, 0.22);
  aspect-ratio: 2 / 3;
  background: var(--blackboard-dark);
  box-shadow: var(--shadow);
}

.side-box {
  margin-top: 18px;
  border: 1px solid rgba(255, 250, 205, 0.18);
  border-radius: 18px;
  padding: 18px;
  background: rgba(15, 26, 15, 0.55);
}

.side-box p {
  margin: 0 0 8px;
  color: rgba(245, 245, 220, 0.78);
}

.related-section {
  margin-top: 36px;
}

.site-footer {
  border-top: 2px solid rgba(255, 250, 205, 0.25);
  background: var(--blackboard-dark);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 34px;
  padding: 44px 0;
}

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

.site-footer h2 {
  margin: 0 0 12px;
  color: var(--chalk-yellow);
  font-size: 1.1rem;
}

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

.footer-links {
  display: grid;
  gap: 8px;
}

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

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

.footer-bottom {
  border-top: 1px solid rgba(255, 250, 205, 0.16);
  padding: 18px 16px;
  color: rgba(245, 245, 220, 0.62);
  text-align: center;
}

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

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

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

  .detail-side {
    position: static;
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 18px;
  }
}

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

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

  .hero-slider {
    min-height: 680px;
  }

  .hero-overlay {
    background: linear-gradient(0deg, rgba(15, 26, 15, 0.98), rgba(15, 26, 15, 0.55));
  }

  .section-heading,
  .page-title,
  .local-filter {
    align-items: flex-start;
    flex-direction: column;
  }

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

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

  .rank-item {
    grid-template-columns: 50px 80px 1fr;
  }

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

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

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

  .brand-text {
    font-size: 1.34rem;
  }

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

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

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

  .card-body {
    padding: 12px;
  }

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

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

  .rank-item {
    grid-template-columns: 42px 72px 1fr;
    gap: 12px;
  }

  .rank-num {
    width: 42px;
    height: 42px;
    border-radius: 12px;
  }

  .rank-cover {
    width: 72px;
  }
}
