:root {
  --green-950: #052e16;
  --green-900: #064e3b;
  --green-800: #166534;
  --green-700: #15803d;
  --green-600: #16a34a;
  --green-100: #dcfce7;
  --green-50: #f0fdf4;
  --yellow: #facc15;
  --ink: #111827;
  --muted: #64748b;
  --line: #e5e7eb;
  --card: #ffffff;
  --bg: #f8fafc;
  --shadow: 0 20px 45px 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(--ink);
  background: linear-gradient(180deg, var(--green-50), #ffffff 520px);
  line-height: 1.6;
}

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

img {
  display: block;
  width: 100%;
  background: linear-gradient(135deg, var(--green-900), var(--green-600));
}

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  color: #ffffff;
  background: linear-gradient(90deg, var(--green-800), var(--green-950));
  box-shadow: 0 10px 28px rgba(5, 46, 22, 0.22);
}

.nav-shell {
  max-width: 1280px;
  height: 64px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  white-space: nowrap;
}

.brand-icon {
  font-size: 26px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
}

.desktop-nav a,
.mobile-nav a {
  color: rgba(255, 255, 255, 0.88);
  transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.mobile-nav a:hover {
  color: #bbf7d0;
}

.top-search {
  position: relative;
  display: flex;
  align-items: center;
  margin-left: 4px;
}

.top-search input {
  width: min(260px, 22vw);
  border: 0;
  border-radius: 999px;
  padding: 10px 76px 10px 18px;
  color: #ffffff;
  background: rgba(5, 46, 22, 0.68);
  outline: none;
}

.top-search input::placeholder {
  color: rgba(220, 252, 231, 0.76);
}

.top-search input:focus {
  box-shadow: 0 0 0 3px rgba(187, 247, 208, 0.32);
}

.top-search button {
  position: absolute;
  right: 4px;
  border: 0;
  border-radius: 999px;
  padding: 6px 14px;
  color: var(--green-950);
  background: #ffffff;
  cursor: pointer;
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  margin-left: auto;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  cursor: pointer;
}

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

.mobile-nav {
  display: none;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px 18px;
  gap: 14px;
  flex-direction: column;
}

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

.hero-carousel {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(120deg, var(--green-950), var(--green-700) 54%, var(--green-900));
}

.hero-track {
  position: relative;
  z-index: 2;
  max-width: 1280px;
  min-height: 560px;
  margin: 0 auto;
  padding: 64px 24px 92px;
}

.hero-slide {
  display: none;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
  gap: 56px;
  align-items: center;
  min-height: 400px;
}

.hero-slide.is-active {
  display: grid;
  animation: fadeUp 0.55s ease both;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 16px;
  padding: 7px 14px;
  border-radius: 999px;
  color: #bbf7d0;
  background: rgba(255, 255, 255, 0.12);
  font-weight: 700;
  letter-spacing: 0.03em;
}

.hero-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-lead {
  max-width: 720px;
  margin: 0 0 24px;
  color: rgba(240, 253, 244, 0.92);
  font-size: clamp(18px, 2.4vw, 25px);
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: var(--green-800);
  background: var(--green-100);
  font-size: 13px;
  font-weight: 700;
}

.hero-tags span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: var(--green-950);
  background: #ffffff;
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.18);
}

.primary-btn:hover,
.ghost-btn:hover {
  transform: translateY(-2px) scale(1.02);
}

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

.primary-btn.light {
  color: var(--green-900);
}

.hero-poster {
  position: relative;
  display: block;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.32);
  transform: rotate(2deg);
}

.hero-poster img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(5, 46, 22, 0.36));
}

.hero-glow {
  position: absolute;
  border-radius: 999px;
  filter: blur(52px);
  opacity: 0.26;
  animation: pulse 3.8s ease-in-out infinite;
}

.hero-glow-a {
  top: 58px;
  left: 7%;
  width: 220px;
  height: 220px;
  background: #ffffff;
}

.hero-glow-b {
  right: 8%;
  bottom: 84px;
  width: 320px;
  height: 320px;
  background: var(--yellow);
  animation-delay: 1s;
}

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

.hero-controls button {
  border: 0;
  color: #ffffff;
  cursor: pointer;
}

.hero-prev,
.hero-next {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  font-size: 28px;
  line-height: 1;
}

.hero-dots {
  display: inline-flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
}

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

.hero-wave {
  position: absolute;
  z-index: 1;
  left: 0;
  right: 0;
  bottom: -1px;
  width: 100%;
  height: 90px;
}

.hero-wave path {
  fill: var(--green-50);
}

.content-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 64px 24px;
}

.soft-section {
  max-width: none;
  background: linear-gradient(90deg, var(--green-100), var(--green-50));
}

.soft-section > .section-title,
.soft-section > .movie-grid,
.soft-section > .ranking-list {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
}

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

.section-title h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.15;
}

.section-title a {
  color: var(--green-700);
  font-weight: 800;
}

.section-intro {
  max-width: 860px;
  margin: -12px 0 28px;
  color: var(--muted);
}

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

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

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: var(--card);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.poster {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--green-900);
}

.poster img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.32s ease;
}

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

.score-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  border-radius: 999px;
  padding: 5px 10px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 900;
  backdrop-filter: blur(8px);
}

.score-badge {
  right: 12px;
  background: rgba(21, 128, 61, 0.88);
}

.rank-badge {
  left: 12px;
  background: rgba(250, 204, 21, 0.96);
  color: #1f2937;
}

.card-body {
  padding: 18px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 13px;
}

.card-body h3 {
  margin: 0 0 8px;
  font-size: 20px;
  line-height: 1.25;
}

.card-body h3 a:hover {
  color: var(--green-700);
}

.card-body p {
  min-height: 52px;
  margin: 0 0 14px;
  color: #475569;
  font-size: 14px;
}

.split-section {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 36px;
  align-items: start;
}

.rank-panel,
.ranking-list,
.side-card,
.detail-card,
.player-card,
.search-panel,
.filter-bar {
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.rank-panel {
  padding: 14px;
}

.rank-item {
  display: grid;
  grid-template-columns: 34px 64px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  transition: background 0.2s ease;
}

.rank-item:hover {
  background: var(--green-50);
}

.rank-item img {
  height: 58px;
  border-radius: 12px;
  object-fit: cover;
}

.rank-item strong,
.ranking-row strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-item small,
.ranking-row small {
  display: block;
  color: var(--muted);
}

.mini-rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  color: var(--green-950);
  background: var(--yellow);
  font-weight: 900;
}

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

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

.category-tile,
.category-card {
  position: relative;
  overflow: hidden;
  min-height: 138px;
  border-radius: 22px;
  color: #ffffff;
  background: var(--green-900);
  box-shadow: 0 12px 32px rgba(5, 46, 22, 0.16);
}

.category-tile img,
.category-card img {
  position: absolute;
  inset: 0;
  height: 100%;
  object-fit: cover;
  opacity: 0.36;
  transition: transform 0.28s ease;
}

.category-tile:hover img,
.category-card:hover img {
  transform: scale(1.06);
}

.category-tile span,
.category-card span,
.category-card p {
  position: relative;
  z-index: 2;
}

.category-tile span,
.category-card {
  display: flex;
  flex-direction: column;
  justify-content: end;
  padding: 22px;
}

.category-tile strong,
.category-card span {
  display: block;
  font-size: 22px;
  font-weight: 900;
}

.category-tile small,
.category-card p {
  margin-top: 6px;
  color: rgba(240, 253, 244, 0.88);
}

.green-cta {
  margin-top: 28px;
  padding: 72px 24px;
  color: #ffffff;
  text-align: center;
  background: linear-gradient(90deg, var(--green-800), var(--green-950));
}

.green-cta h2 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
}

.green-cta p {
  max-width: 760px;
  margin: 0 auto 28px;
  color: rgba(240, 253, 244, 0.9);
}

.page-hero {
  padding: 76px 24px 84px;
  color: #ffffff;
  text-align: center;
  background: radial-gradient(circle at 18% 10%, rgba(250, 204, 21, 0.22), transparent 26%), linear-gradient(120deg, var(--green-950), var(--green-700));
}

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

.page-hero p {
  max-width: 840px;
  margin: 0 auto;
  color: rgba(240, 253, 244, 0.9);
  font-size: 18px;
}

.filter-bar,
.search-panel {
  display: flex;
  gap: 14px;
  margin-bottom: 28px;
  padding: 16px;
}

.filter-bar input,
.filter-bar select,
.search-panel input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 12px 18px;
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus,
.search-panel input:focus {
  border-color: var(--green-600);
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.15);
}

.filter-bar select {
  max-width: 190px;
}

.search-panel button {
  border: 0;
  border-radius: 999px;
  padding: 0 28px;
  color: #ffffff;
  background: var(--green-700);
  font-weight: 900;
  cursor: pointer;
}

.ranking-list {
  overflow: hidden;
  padding: 8px;
}

.ranking-row {
  display: grid;
  grid-template-columns: 54px 86px minmax(0, 1fr) 70px;
  gap: 16px;
  align-items: center;
  padding: 13px;
  border-radius: 18px;
  transition: background 0.2s ease;
}

.ranking-row:hover {
  background: var(--green-50);
}

.ranking-number {
  font-size: 22px;
  font-weight: 900;
  color: var(--green-700);
  text-align: center;
}

.ranking-row img {
  height: 70px;
  border-radius: 14px;
  object-fit: cover;
}

.ranking-score {
  color: var(--green-700);
  font-size: 20px;
  font-weight: 900;
  text-align: right;
}

.breadcrumb {
  max-width: 1280px;
  margin: 0 auto;
  padding: 22px 24px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

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

.detail-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px 24px 64px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  align-items: start;
}

.detail-main {
  display: grid;
  gap: 24px;
}

.player-card {
  position: relative;
  overflow: hidden;
  background: #000000;
  aspect-ratio: 16 / 9;
}

.player-card video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000000;
  object-fit: contain;
}

.play-cover {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.62));
  cursor: pointer;
}

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

.play-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 76px;
  border-radius: 999px;
  color: var(--green-900);
  background: #ffffff;
  font-size: 30px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
}

.detail-card {
  padding: 28px;
}

.detail-card h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.1;
}

.detail-card h2,
.side-card h2 {
  margin: 28px 0 12px;
  font-size: 24px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  color: var(--muted);
}

.detail-meta span {
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--green-50);
}

.detail-lead {
  color: #334155;
  font-size: 18px;
  font-weight: 600;
}

.detail-card p {
  color: #334155;
}

.detail-tags {
  margin: 18px 0 6px;
}

.detail-side {
  position: sticky;
  top: 86px;
  display: grid;
  gap: 18px;
}

.side-poster {
  overflow: hidden;
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.side-poster img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.side-card {
  padding: 22px;
}

.side-card h2 {
  margin-top: 0;
}

.side-card dl {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 10px 16px;
  margin: 0;
}

.side-card dt {
  color: var(--muted);
}

.side-card dd {
  margin: 0;
  font-weight: 700;
}

.side-card a {
  color: var(--green-700);
}

.related-section {
  padding-top: 0;
}

.site-footer {
  color: rgba(255, 255, 255, 0.82);
  background: linear-gradient(90deg, #111827, #1f2937);
}

.footer-grid {
  max-width: 1280px;
  margin: 0 auto;
  padding: 46px 24px;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 36px;
}

.footer-grid h2,
.footer-grid h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.footer-grid p {
  margin: 0;
  max-width: 480px;
  color: rgba(255, 255, 255, 0.72);
}

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

.footer-links a:hover {
  color: #86efac;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 24px;
  text-align: center;
  color: rgba(255, 255, 255, 0.66);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.24;
  }

  50% {
    transform: scale(1.08);
    opacity: 0.38;
  }
}

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

  .mobile-toggle {
    display: block;
  }

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

  .hero-poster {
    display: none;
  }

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

  .split-section,
  .detail-shell,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .detail-side {
    position: static;
  }

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

@media (max-width: 720px) {
  .nav-shell {
    padding: 0 16px;
  }

  .brand {
    font-size: 19px;
  }

  .hero-carousel,
  .hero-track {
    min-height: 560px;
  }

  .hero-track {
    padding: 54px 18px 96px;
  }

  .hero-copy h1 {
    font-size: 42px;
  }

  .content-section {
    padding: 46px 16px;
  }

  .movie-grid,
  .compact-grid,
  .catalog-grid,
  .category-grid,
  .category-overview {
    grid-template-columns: 1fr;
  }

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

  .filter-bar,
  .search-panel {
    flex-direction: column;
  }

  .filter-bar select {
    max-width: none;
  }

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

  .ranking-score {
    display: none;
  }

  .detail-shell,
  .breadcrumb {
    padding-left: 16px;
    padding-right: 16px;
  }

  .detail-card,
  .side-card {
    padding: 20px;
  }
}
