:root {
  --stone-950: #1c1917;
  --stone-900: #292524;
  --stone-800: #44403c;
  --stone-700: #57534e;
  --stone-600: #78716c;
  --stone-500: #a8a29e;
  --stone-300: #d6d3d1;
  --stone-200: #e7e5e4;
  --stone-100: #f5f5f4;
  --stone-50: #fafaf9;
  --amber-800: #92400e;
  --amber-700: #b45309;
  --amber-600: #d97706;
  --amber-500: #f59e0b;
  --amber-200: #fde68a;
  --amber-100: #fef3c7;
  --orange-700: #c2410c;
  --orange-600: #ea580c;
  --teal-700: #0f766e;
  --teal-600: #0d9488;
  --cyan-700: #0e7490;
  --white: #ffffff;
  --black: #000000;
  --radius-lg: 18px;
  --radius-md: 14px;
  --shadow-md: 0 10px 25px rgba(41, 37, 36, 0.12);
  --shadow-lg: 0 25px 60px rgba(41, 37, 36, 0.22);
}

* {
  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(--stone-900);
  background: var(--stone-50);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--amber-700), var(--amber-600), var(--orange-700));
  box-shadow: var(--shadow-md);
}

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

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

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.3);
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

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

.logo-subtitle {
  font-size: 12px;
  color: var(--amber-100);
  font-weight: 600;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 15px;
  font-weight: 700;
}

.primary-nav a {
  color: rgba(255, 255, 255, 0.92);
  transition: color 0.2s ease, transform 0.2s ease;
}

.primary-nav a:hover {
  color: var(--amber-200);
  transform: translateY(-1px);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.14);
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
}

.mobile-nav a {
  display: block;
  padding: 10px 14px;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.94);
  font-weight: 700;
}

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

.hero {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  color: var(--white);
  background: var(--stone-950);
}

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

.hero-slide {
  opacity: 0;
  transition: opacity 1s ease;
}

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

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

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.48) 48%, rgba(0, 0, 0, 0.08));
}

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

.hero-panel {
  width: min(760px, 100%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 7px 12px;
  border-radius: 999px;
  color: var(--amber-100);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
  font-size: 14px;
  font-weight: 800;
}

.hero h1,
.page-hero h1 {
  margin: 0 0 16px;
  font-size: clamp(34px, 6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-title {
  margin: 0 0 14px;
  font-size: clamp(26px, 3.5vw, 44px);
  line-height: 1.12;
}

.hero-desc {
  width: min(650px, 100%);
  margin: 0 0 26px;
  color: var(--stone-200);
  font-size: clamp(16px, 2vw, 20px);
}

.hero-actions,
.section-actions,
.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 11px 18px;
  border: 0;
  border-radius: 13px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

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

.btn-primary {
  color: var(--white);
  background: var(--amber-600);
  box-shadow: 0 14px 30px rgba(217, 119, 6, 0.32);
}

.btn-primary:hover {
  background: var(--amber-700);
}

.btn-light {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
}

.btn-light:hover {
  background: rgba(255, 255, 255, 0.26);
}

.btn-soft {
  color: var(--amber-800);
  background: var(--amber-100);
}

.btn-soft:hover {
  color: var(--white);
  background: var(--amber-600);
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: var(--white);
}

.hero-arrow {
  position: absolute;
  z-index: 4;
  top: 50%;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  color: var(--white);
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  transform: translateY(-50%);
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.3);
}

.hero-arrow.prev {
  left: 22px;
}

.hero-arrow.next {
  right: 22px;
}

.quick-search {
  margin-top: 24px;
  display: flex;
  gap: 10px;
  width: min(620px, 100%);
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(12px);
}

.quick-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  border-radius: 13px;
  padding: 12px 14px;
  color: var(--stone-900);
  outline: none;
}

.quick-search button {
  border: 0;
  border-radius: 13px;
  padding: 0 18px;
  color: var(--white);
  background: var(--amber-600);
  font-weight: 800;
}

.section {
  padding: 72px 0;
}

.section-warm {
  background: linear-gradient(180deg, var(--amber-100), var(--white));
}

.section-white {
  background: var(--white);
}

.section-dark {
  color: var(--white);
  background: linear-gradient(135deg, var(--stone-900), var(--stone-800));
}

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

.section-kicker {
  margin: 0 0 8px;
  color: var(--amber-700);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-title {
  margin: 0;
  color: var(--stone-900);
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.12;
}

.section-dark .section-title {
  color: var(--white);
}

.section-summary {
  max-width: 780px;
  margin: 12px 0 0;
  color: var(--stone-600);
}

.section-dark .section-summary {
  color: var(--stone-300);
}

.grid {
  display: grid;
  gap: 22px;
}

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

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

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

.movie-card,
.category-card,
.rank-card,
.info-card {
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: var(--shadow-md);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover,
.category-card:hover,
.rank-card:hover,
.info-card:hover {
  transform: translateY(-7px);
  box-shadow: var(--shadow-lg);
}

.poster {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--stone-200), var(--stone-100));
}

.poster-video {
  aspect-ratio: 16 / 9;
}

.poster-vertical {
  aspect-ratio: 2 / 3;
}

.poster-square {
  aspect-ratio: 1 / 1;
}

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

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

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

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 800;
}

.badge-amber {
  color: var(--white);
  background: var(--amber-600);
}

.badge-light {
  color: var(--amber-800);
  background: var(--amber-100);
}

.poster-badge {
  position: absolute;
  z-index: 2;
  top: 10px;
  right: 10px;
}

.card-body {
  padding: 16px;
}

.card-title {
  display: -webkit-box;
  margin: 0 0 8px;
  overflow: hidden;
  color: var(--stone-900);
  font-size: 16px;
  font-weight: 900;
  line-height: 1.3;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-desc {
  display: -webkit-box;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--stone-600);
  font-size: 14px;
  line-height: 1.5;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: var(--stone-600);
  font-size: 12px;
  font-weight: 700;
}

.category-card {
  position: relative;
  min-height: 190px;
  padding: 24px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-700), var(--orange-700));
}

.category-card:nth-child(3n + 2) {
  background: linear-gradient(135deg, var(--teal-700), var(--cyan-700));
}

.category-card:nth-child(3n) {
  background: linear-gradient(135deg, var(--stone-800), var(--amber-800));
}

.category-card h2,
.category-card h3,
.category-card p {
  position: relative;
  z-index: 1;
}

.category-card h2,
.category-card h3 {
  margin: 0 0 10px;
  font-size: 24px;
}

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 56px 88px 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: var(--shadow-md);
}

.rank-number {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--white);
  background: var(--amber-600);
  font-weight: 900;
}

.rank-thumb {
  width: 88px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 12px;
  background: var(--stone-200);
}

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

.rank-title {
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 900;
}

.rank-desc {
  margin: 0;
  color: var(--stone-600);
  font-size: 14px;
}

.page-hero {
  color: var(--white);
  background: linear-gradient(100deg, var(--amber-700), var(--amber-600), var(--orange-700));
}

.page-hero.teal {
  background: linear-gradient(100deg, var(--teal-700), var(--teal-600), var(--cyan-700));
}

.page-hero-inner {
  padding: 70px 0;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--amber-100);
  font-size: 20px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: var(--stone-600);
  font-size: 14px;
  font-weight: 700;
}

.breadcrumb a {
  color: var(--amber-700);
}

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

.player-card {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--black);
  box-shadow: var(--shadow-lg);
}

.player-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--black);
}

.player-frame video {
  width: 100%;
  height: 100%;
  background: var(--black);
}

.play-panel {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  background: radial-gradient(circle at center, rgba(217, 119, 6, 0.18), rgba(0, 0, 0, 0.72));
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-button {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  color: var(--white);
  background: var(--amber-600);
  box-shadow: 0 18px 45px rgba(217, 119, 6, 0.38);
  font-size: 32px;
}

.player-notice {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 20px;
  color: var(--white);
  text-align: center;
  font-weight: 700;
}

.detail-card,
.sidebar-card,
.search-panel {
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: var(--shadow-md);
}

.detail-card {
  padding: 26px;
  margin-top: 22px;
}

.detail-card h1 {
  margin: 0 0 14px;
  color: var(--stone-900);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.1;
}

.detail-card h2,
.sidebar-card h2,
.search-panel h2 {
  margin: 0 0 16px;
  color: var(--stone-900);
  font-size: 24px;
}

.detail-intro {
  margin: 0 0 20px;
  color: var(--stone-600);
  font-size: 18px;
}

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

.meta-pill,
.tag-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 11px;
  color: var(--stone-700);
  background: var(--stone-100);
  font-size: 13px;
  font-weight: 800;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-pill {
  color: var(--amber-800);
  background: var(--amber-100);
}

.prose {
  color: var(--stone-700);
  font-size: 16px;
}

.prose p {
  margin: 0;
  white-space: pre-wrap;
}

.sidebar-card {
  padding: 18px;
  margin-bottom: 18px;
}

.related-list {
  display: grid;
  gap: 12px;
}

.related-item {
  display: grid;
  grid-template-columns: 84px 1fr;
  gap: 12px;
  align-items: center;
}

.related-poster {
  width: 84px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 11px;
  background: var(--stone-200);
}

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

.related-title {
  margin: 0 0 4px;
  color: var(--stone-900);
  font-weight: 900;
  line-height: 1.25;
}

.related-meta {
  color: var(--stone-600);
  font-size: 12px;
  font-weight: 700;
}

.search-panel {
  padding: 22px;
  margin-bottom: 28px;
}

.search-line {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.search-line input {
  flex: 1;
  min-width: 0;
  border: 1px solid var(--stone-200);
  border-radius: 14px;
  padding: 13px 14px;
  outline: none;
}

.search-line input:focus {
  border-color: var(--amber-500);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-button {
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  color: var(--stone-700);
  background: var(--stone-100);
  font-weight: 800;
}

.filter-button.is-active,
.filter-button:hover {
  color: var(--white);
  background: var(--amber-600);
}

.no-results {
  display: none;
  padding: 28px;
  border-radius: var(--radius-md);
  background: var(--white);
  color: var(--stone-600);
  text-align: center;
  box-shadow: var(--shadow-md);
}

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

.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 38px;
}

.pagination a,
.pagination span {
  min-width: 42px;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  padding: 8px 12px;
  background: var(--white);
  color: var(--stone-700);
  box-shadow: var(--shadow-md);
  font-weight: 900;
}

.pagination .is-current {
  color: var(--white);
  background: var(--amber-600);
}

.site-footer {
  color: var(--stone-200);
  background: linear-gradient(90deg, var(--stone-900), var(--stone-800), var(--stone-900));
}

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

.footer-title {
  margin: 0 0 12px;
  color: var(--white);
  font-size: 18px;
  font-weight: 900;
}

.footer-text,
.footer-links a {
  color: var(--stone-300);
  font-size: 14px;
}

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

.footer-links a:hover {
  color: var(--amber-200);
}

.footer-bottom {
  padding: 18px 0 28px;
  border-top: 1px solid rgba(214, 211, 209, 0.2);
  color: var(--stone-500);
  font-size: 13px;
  text-align: center;
}

@media (max-width: 1100px) {
  .grid-featured {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

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

  .mobile-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

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

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

  .hero-content {
    padding: 110px 0 68px;
  }

  .hero-arrow {
    display: none;
  }

  .section {
    padding: 52px 0;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }

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

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

  .rank-row .btn {
    grid-column: 2 / -1;
  }

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

@media (max-width: 560px) {
  .header-inner,
  .container {
    width: min(100% - 24px, 1280px);
  }

  .logo-subtitle {
    display: none;
  }

  .quick-search,
  .search-line {
    flex-direction: column;
  }

  .quick-search button,
  .search-line button {
    min-height: 44px;
  }

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

  .card-body {
    padding: 12px;
  }

  .card-title {
    font-size: 14px;
  }

  .card-desc {
    font-size: 13px;
  }

  .page-hero-inner {
    padding: 52px 0;
  }

  .detail-card {
    padding: 20px;
  }

  .related-item {
    grid-template-columns: 76px 1fr;
  }
}
