:root {
  --night-900: #0d1117;
  --night-800: #161b22;
  --night-700: #21262d;
  --night-600: #30363d;
  --night-300: #8b949e;
  --night-200: #b1bac4;
  --moss-500: #6fa866;
  --moss-600: #4d7348;
  --moss-800: #2a4227;
  --swamp-700: #243329;
  --swamp-900: #121a16;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--night-900);
}

a {
  text-decoration: none;
}

img {
  display: block;
}

.logo-mark {
  width: 2.5rem;
  height: 2.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.75rem;
  background: linear-gradient(135deg, var(--moss-600), var(--moss-800));
  color: #ffffff;
  font-size: 1.25rem;
  font-weight: 800;
  box-shadow: 0 16px 30px rgba(18, 26, 22, 0.35);
}

.logo-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.logo-name {
  color: #96c48f;
  font-weight: 800;
  font-size: 1.25rem;
}

.logo-subtitle {
  color: #6e7681;
  font-size: 0.75rem;
  margin-top: 0.2rem;
}

.nav-link,
.mobile-link {
  color: #8b949e;
  font-weight: 600;
  transition: color 0.2s ease;
}

.nav-link:hover,
.mobile-link:hover {
  color: #96c48f;
}

.mobile-link {
  display: block;
  padding: 0.5rem 0;
}

.hero-slider {
  background: #000000;
}

.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.03);
  transition: opacity 0.65s ease, transform 1.2s ease;
  pointer-events: none;
}

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

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.hero-tags a,
.hero-tags span {
  color: #c9d1d9;
  background: rgba(22, 27, 34, 0.74);
  border: 1px solid rgba(122, 170, 115, 0.24);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.8rem;
  backdrop-filter: blur(10px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero-ghost {
  color: #d0d7de;
  border: 1px solid rgba(150, 196, 143, 0.35);
  background: rgba(13, 17, 23, 0.45);
  backdrop-filter: blur(10px);
}

.hero-ghost:hover {
  color: #ffffff;
  border-color: rgba(150, 196, 143, 0.7);
  background: rgba(42, 66, 39, 0.74);
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 1.5rem;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 1rem;
  z-index: 5;
}

.hero-arrow,
.hero-dot {
  border: 0;
  color: #ffffff;
  cursor: pointer;
}

.hero-arrow {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  background: rgba(13, 17, 23, 0.55);
  font-size: 1.8rem;
  line-height: 1;
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(77, 115, 72, 0.85);
  transform: translateY(-1px);
}

.hero-dots {
  display: flex;
  gap: 0.45rem;
}

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

.hero-dot.is-active {
  width: 1.6rem;
  background: #96c48f;
}

.home-search-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.5rem;
  border-radius: 1rem;
  background: linear-gradient(135deg, rgba(26, 38, 32, 0.95), rgba(13, 17, 23, 0.95));
  border: 1px solid rgba(58, 89, 55, 0.65);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.25);
}

.home-search-button {
  white-space: nowrap;
  color: #ffffff;
  background: var(--moss-600);
  border-radius: 999px;
  padding: 0.85rem 1.35rem;
  font-weight: 700;
  transition: background 0.2s ease, transform 0.2s ease;
}

.home-search-button:hover {
  background: var(--moss-500);
  transform: translateY(-1px);
}

.play-dot {
  color: #ffffff;
  font-weight: 900;
  padding-left: 0.15rem;
}

.horizontal-row .movie-card {
  height: 100%;
}

.category-entry-grid,
.category-card-grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 1rem;
}

.category-entry,
.category-card {
  position: relative;
  min-height: 13rem;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid rgba(58, 89, 55, 0.65);
  background: var(--night-800);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.2);
}

.category-entry-bg,
.category-card-cover {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.42;
  transform: scale(1.04);
  transition: transform 0.45s ease, opacity 0.45s ease;
}

.category-entry:hover .category-entry-bg,
.category-card:hover .category-card-cover {
  opacity: 0.58;
  transform: scale(1.11);
}

.category-card-shade,
.category-entry::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13, 17, 23, 0.2), rgba(13, 17, 23, 0.92));
}

.category-entry-body,
.category-card-body {
  position: absolute;
  left: 1.25rem;
  right: 1.25rem;
  bottom: 1.25rem;
  display: block;
  z-index: 2;
}

.category-entry-name,
.category-card-title {
  color: #ffffff;
  display: block;
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 0.55rem;
}

.category-entry-desc,
.category-card-desc {
  color: #b1bac4;
  display: block;
  font-size: 0.92rem;
  line-height: 1.5;
}

.ranking-strip,
.ranking-list {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 0.85rem;
}

.rank-item {
  display: grid;
  grid-template-columns: auto 7rem 1fr;
  align-items: center;
  gap: 1rem;
  padding: 0.8rem;
  border-radius: 0.9rem;
  background: rgba(22, 27, 34, 0.96);
  border: 1px solid rgba(36, 51, 41, 0.9);
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.rank-item:hover {
  background: #21262d;
  border-color: rgba(122, 170, 115, 0.5);
  transform: translateY(-1px);
}

.rank-number {
  color: #96c48f;
  font-size: 1.5rem;
  font-weight: 900;
  min-width: 2.6rem;
  text-align: center;
}

.rank-cover {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 0.55rem;
  background: #21262d;
}

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

.rank-item:hover img {
  transform: scale(1.08);
}

.rank-copy {
  min-width: 0;
}

.rank-title {
  display: block;
  color: #d0d7de;
  font-weight: 800;
  line-height: 1.35;
  margin-bottom: 0.25rem;
}

.rank-desc {
  color: #8b949e;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 0.88rem;
  line-height: 1.45;
}

.page-hero {
  background-image: radial-gradient(circle at top left, rgba(77, 115, 72, 0.24), transparent 36%), linear-gradient(135deg, #161b22, #0d1117);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  color: #6e7681;
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
}

.breadcrumb a {
  color: #96c48f;
}

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

.breadcrumb span::before,
.breadcrumb a + a::before {
  content: "/";
  color: #6e7681;
  margin-right: 0.55rem;
}

.search-panel {
  display: grid;
  gap: 0.7rem;
}

.search-label {
  color: #96c48f;
  font-weight: 700;
}

.site-search {
  width: 100%;
  border: 1px solid rgba(58, 89, 55, 0.75);
  background: #0d1117;
  color: #d0d7de;
  border-radius: 0.75rem;
  padding: 0.9rem 1rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.site-search:focus {
  border-color: #96c48f;
  box-shadow: 0 0 0 3px rgba(150, 196, 143, 0.16);
}

.site-search::placeholder {
  color: #6e7681;
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
}

.filter-button {
  border: 1px solid rgba(58, 89, 55, 0.8);
  background: #161b22;
  color: #8b949e;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.filter-button:hover,
.filter-button.is-active {
  color: #ffffff;
  background: #4d7348;
  border-color: #6fa866;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.watch-player {
  position: relative;
  isolation: isolate;
}

.watch-video {
  background: #000000;
  display: block;
  cursor: pointer;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  border: 0;
  cursor: pointer;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.66));
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.player-overlay-icon {
  width: 5rem;
  height: 5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(77, 115, 72, 0.92);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
  font-size: 2rem;
  padding-left: 0.25rem;
}

.player-overlay-title {
  max-width: min(80%, 42rem);
  font-size: 1.1rem;
  font-weight: 800;
  text-shadow: 0 2px 15px rgba(0, 0, 0, 0.7);
}

.player-message {
  position: absolute;
  left: 50%;
  bottom: 1rem;
  z-index: 8;
  transform: translateX(-50%);
  color: #ffffff;
  background: rgba(13, 17, 23, 0.88);
  border-radius: 999px;
  padding: 0.5rem 0.85rem;
  display: none;
  font-size: 0.85rem;
}

.player-message.is-visible {
  display: block;
}

.is-hidden-by-filter {
  display: none !important;
}

@media (min-width: 640px) {
  .category-entry-grid,
  .category-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (min-width: 1024px) {
  .category-entry-grid,
  .category-card-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

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

@media (max-width: 767px) {
  .home-search-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero-content {
    padding-bottom: 5.5rem;
  }

  .hero-controls {
    bottom: 1rem;
  }

  .rank-item {
    grid-template-columns: auto 5.5rem 1fr;
    gap: 0.75rem;
  }

  .player-overlay-icon {
    width: 4rem;
    height: 4rem;
    font-size: 1.5rem;
  }
}
