:root {
  color-scheme: light;
  --brand-orange: #f97316;
  --brand-red: #dc2626;
  --ink: #1f2937;
  --soft-ink: #4b5563;
  --panel: #ffffff;
  --muted-panel: #f8fafc;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1 0 auto;
}

img {
  background: linear-gradient(135deg, #111827, #f97316);
}

.brand-icon {
  display: inline-flex;
  width: 2.5rem;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 900;
}

.brand-icon.small {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.5rem;
  background: linear-gradient(135deg, #f97316, #dc2626);
}

.brand-title,
.brand-subtitle {
  display: block;
  line-height: 1.1;
}

.nav-link {
  color: #d1d5db;
  font-weight: 600;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #fb923c;
}

.mobile-menu-button {
  padding: 0.5rem 0.75rem;
  color: #d1d5db;
  border-radius: 0.75rem;
}

.mobile-menu-button:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.mobile-link {
  display: block;
  padding: 0.625rem 0;
  color: #d1d5db;
  font-weight: 600;
}

.mobile-link:hover,
.mobile-link.is-active {
  color: #fb923c;
}

.mobile-link-muted {
  padding: 0.45rem 0.65rem;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 0.75rem;
  text-align: center;
  font-size: 0.875rem;
}

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

.search-box {
  display: block;
}

.search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: #9ca3af;
  font-size: 1.15rem;
  line-height: 1;
}

.search-input {
  width: 15rem;
  padding: 0.625rem 1rem 0.625rem 2.5rem;
  color: #ffffff;
  background: #334155;
  border-radius: 0.75rem;
  outline: none;
  transition: box-shadow 0.2s ease, background 0.2s ease;
}

.search-input:focus {
  background: #1f2937;
  box-shadow: 0 0 0 2px #f97316;
}

.mobile-search .search-input,
.search-page-form input {
  width: 100%;
}

.hero-carousel {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
  border-radius: 1rem;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
}

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

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

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.08));
}

.hero-content {
  position: absolute;
  left: 1.5rem;
  right: 1.5rem;
  bottom: 1.5rem;
  max-width: 46rem;
  color: #ffffff;
}

.hero-category,
.category-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.9rem;
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #ef4444);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
}

.hero-content h1 {
  margin-top: 1rem;
  margin-bottom: 0.9rem;
  font-size: clamp(2rem, 4.6vw, 4.5rem);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-content p {
  max-width: 46rem;
  color: #e5e7eb;
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.8;
}

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

.hero-tags span {
  padding: 0.35rem 0.7rem;
  color: #fed7aa;
  background: rgba(249, 115, 22, 0.14);
  border: 1px solid rgba(251, 146, 60, 0.28);
  border-radius: 999px;
  font-size: 0.82rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.5rem;
}

.primary-button,
.secondary-button,
.section-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.75rem 1.4rem;
  border-radius: 0.75rem;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #dc2626);
  box-shadow: 0 16px 30px rgba(220, 38, 38, 0.25);
}

.primary-button:hover,
.section-action:hover {
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 18px 36px rgba(220, 38, 38, 0.28);
}

.primary-button.small {
  min-height: 2.35rem;
  padding: 0.55rem 1rem;
  font-size: 0.9rem;
}

.primary-button.full {
  width: 100%;
  margin-top: 1rem;
}

.secondary-button {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(12px);
}

.secondary-button:hover {
  background: rgba(255, 255, 255, 0.22);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 2.75rem;
  height: 2.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 2.5rem;
  line-height: 1;
  background: rgba(0, 0, 0, 0.42);
  border-radius: 999px;
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(0, 0, 0, 0.7);
}

.hero-prev {
  left: 1rem;
}

.hero-next {
  right: 1rem;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 1rem;
  z-index: 3;
  display: flex;
  gap: 0.5rem;
  transform: translateX(-50%);
}

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

.hero-dot.is-active {
  width: 2rem;
  background: #f97316;
}

.white-panel,
.color-panel,
.category-overview-card,
.filter-panel,
.side-card {
  border-radius: 1rem;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.white-panel,
.category-overview-card,
.filter-panel,
.side-card {
  background: #ffffff;
}

.white-panel,
.color-panel,
.category-overview-card,
.filter-panel {
  padding: 2rem;
}

.blue-panel {
  color: #ffffff;
  background: linear-gradient(90deg, #3b82f6, #14b8a6);
}

.purple-panel {
  color: #ffffff;
  background: linear-gradient(90deg, #a855f7, #ec4899);
}

.green-panel {
  color: #ffffff;
  background: linear-gradient(135deg, #4ade80, #3b82f6);
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.section-heading.compact {
  margin-bottom: 1rem;
}

.section-heading h2 {
  color: inherit;
  font-size: clamp(1.7rem, 3vw, 2.25rem);
  line-height: 1.15;
  font-weight: 900;
}

.white-panel .section-heading h2,
.category-overview-card h2,
.filter-panel h2 {
  color: #1f2937;
}

.section-heading p {
  margin-top: 0.35rem;
  color: inherit;
  opacity: 0.82;
}

.white-panel .section-heading p {
  color: #6b7280;
}

.section-action {
  min-height: 2.4rem;
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #dc2626);
  white-space: nowrap;
}

.movie-card img,
.horizontal-cover img,
.side-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.aspect-wide {
  aspect-ratio: 16 / 9;
}

.year-pill,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 800;
}

.year-pill {
  right: 0.65rem;
  bottom: 0.65rem;
  padding: 0.3rem 0.55rem;
  background: rgba(0, 0, 0, 0.72);
}

.rank-badge {
  left: 0.65rem;
  top: 0.65rem;
  min-width: 2rem;
  height: 2rem;
  background: linear-gradient(135deg, #f97316, #dc2626);
  box-shadow: 0 10px 20px rgba(220, 38, 38, 0.25);
}

.category-pill {
  position: absolute;
  left: 1rem;
  top: 1rem;
  z-index: 2;
}

.play-hover {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  width: 4rem;
  height: 4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: #f97316;
  border-radius: 999px;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.9);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.play-hover.compact {
  width: 3rem;
  height: 3rem;
}

.movie-card-link figure::after,
.movie-card-large figure::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.22);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.movie-card-link:hover figure::after,
.movie-card-large a:hover figure::after,
.movie-card-link:hover .play-hover,
.movie-card-large a:hover .play-hover {
  opacity: 1;
}

.movie-card-link:hover .play-hover,
.movie-card-large a:hover .play-hover {
  transform: translate(-50%, -50%) scale(1);
}

.card-meta,
.horizontal-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  color: #6b7280;
  font-size: 0.8rem;
}

.card-meta span:first-child,
.horizontal-meta span:first-child {
  padding: 0.25rem 0.5rem;
  color: #ea580c;
  background: #ffedd5;
  border-radius: 0.375rem;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.tag-chip {
  padding: 0.3rem 0.55rem;
  color: #4b5563;
  background: #f3f4f6;
  border-radius: 0.45rem;
  font-size: 0.75rem;
}

.horizontal-link {
  display: flex;
  gap: 1rem;
  color: inherit;
  background: #ffffff;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.horizontal-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.16);
}

.horizontal-cover {
  position: relative;
  width: 12rem;
  min-height: 8rem;
  flex-shrink: 0;
  overflow: hidden;
}

.horizontal-body {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1rem 1rem 1rem 0;
}

.horizontal-body h3 {
  color: #1f2937;
  font-size: 1.1rem;
  font-weight: 800;
  line-height: 1.35;
}

.horizontal-body p {
  display: -webkit-box;
  margin-top: 0.5rem;
  color: #4b5563;
  font-size: 0.92rem;
  line-height: 1.6;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

.category-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.95rem 1rem;
  color: inherit;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease;
}

.white-panel .category-chip {
  color: #334155;
  background: #f8fafc;
  border-color: #e5e7eb;
}

.category-chip:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.28);
}

.category-chip span {
  padding: 0.2rem 0.55rem;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.24);
  border-radius: 999px;
  font-size: 0.75rem;
}

.white-panel .category-chip span {
  background: #f97316;
}

.page-hero {
  padding: 2.25rem;
  color: #ffffff;
  border-radius: 1rem;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.16);
}

.orange-hero {
  background: linear-gradient(90deg, #f97316, #dc2626);
}

.blue-hero {
  background: linear-gradient(90deg, #3b82f6, #14b8a6);
}

.page-hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.15;
  font-weight: 900;
}

.page-hero p {
  max-width: 58rem;
  margin-top: 0.8rem;
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.05rem;
  line-height: 1.8;
}

.category-overview-card {
  padding: 1.5rem;
}

.category-overview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.category-overview-head h2 {
  font-size: 1.45rem;
  font-weight: 900;
}

.category-overview-head p,
.category-count {
  color: #6b7280;
}

.category-count {
  margin-bottom: 1.25rem;
  font-weight: 700;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  color: #6b7280;
  font-size: 0.92rem;
}

.breadcrumb a {
  color: #ea580c;
  font-weight: 700;
}

.filter-panel {
  margin: 1.5rem 0;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
  margin-top: 0.85rem;
}

.filter-row:first-child {
  margin-top: 0;
}

.filter-label,
.filter-search span {
  color: #374151;
  font-weight: 800;
}

.filter-search {
  display: grid;
  grid-template-columns: auto minmax(12rem, 1fr);
  align-items: center;
  gap: 0.85rem;
  width: 100%;
}

.filter-search input {
  width: 100%;
  padding: 0.75rem 0.95rem;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  outline: none;
}

.filter-search input:focus {
  border-color: #f97316;
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12);
}

.filter-row button {
  padding: 0.55rem 0.9rem;
  color: #374151;
  background: #f3f4f6;
  border-radius: 999px;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease;
}

.filter-row button:hover,
.filter-row button.is-active {
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #dc2626);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(17rem, 0.85fr);
  gap: 2rem;
}

.detail-main {
  display: grid;
  gap: 1.5rem;
}

.player-shell {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
  overflow: hidden;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.32);
}

.player-overlay span {
  width: 5rem;
  height: 5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #dc2626);
  border-radius: 999px;
  font-size: 2rem;
  box-shadow: 0 24px 48px rgba(220, 38, 38, 0.32);
  transition: transform 0.2s ease;
}

.player-overlay:hover span {
  transform: scale(1.08);
}

.player-overlay.is-hidden {
  display: none;
}

.detail-info {
  display: grid;
  gap: 1.4rem;
}

.detail-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.detail-title-row h1 {
  color: #111827;
  font-size: clamp(1.85rem, 4vw, 3rem);
  line-height: 1.15;
  font-weight: 900;
}

.detail-title-row span {
  flex-shrink: 0;
  padding: 0.45rem 0.9rem;
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #dc2626);
  border-radius: 999px;
  font-weight: 800;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.detail-meta span {
  padding: 0.45rem 0.75rem;
  color: #4b5563;
  background: #f3f4f6;
  border-radius: 0.65rem;
  font-weight: 700;
}

.one-line {
  padding-left: 1rem;
  color: #374151;
  border-left: 4px solid #f97316;
  font-size: 1.05rem;
  line-height: 1.8;
}

.detail-section h2 {
  margin-bottom: 0.6rem;
  color: #111827;
  font-size: 1.25rem;
  font-weight: 900;
}

.detail-section p {
  color: #4b5563;
  line-height: 1.9;
}

.detail-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.detail-chips span {
  padding: 0.5rem 0.8rem;
  color: #ea580c;
  background: #ffedd5;
  border-radius: 999px;
  font-weight: 700;
}

.detail-chips.soft span {
  color: #2563eb;
  background: #dbeafe;
}

.detail-side {
  display: grid;
  align-content: start;
  gap: 1.5rem;
}

.side-card {
  padding: 1rem;
}

.side-card img {
  aspect-ratio: 16 / 9;
  border-radius: 0.85rem;
}

.side-card h2 {
  margin-top: 1rem;
  color: #111827;
  font-size: 1.25rem;
  font-weight: 900;
}

.side-card p {
  margin-top: 0.55rem;
  color: #6b7280;
  line-height: 1.7;
}

.compact-side dl {
  display: grid;
  gap: 0.8rem;
  margin-top: 1rem;
}

.compact-side dl div {
  display: grid;
  grid-template-columns: 4rem 1fr;
  gap: 0.75rem;
}

.compact-side dt {
  color: #6b7280;
}

.compact-side dd {
  color: #111827;
  font-weight: 800;
}

.search-page-form {
  display: flex;
  gap: 0.75rem;
  max-width: 42rem;
  margin-top: 1.5rem;
}

.search-page-form input {
  flex: 1;
  min-height: 3rem;
  padding: 0 1rem;
  color: #111827;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 0.8rem;
  outline: none;
}

.search-page-form button {
  min-height: 3rem;
  padding: 0 1.35rem;
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #dc2626);
  border-radius: 0.8rem;
  font-weight: 900;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 0.8fr);
  gap: 2rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.footer-brand strong,
.site-footer h2 {
  display: block;
  color: #ffffff;
  font-weight: 900;
}

.footer-brand span span {
  display: block;
  color: #9ca3af;
  font-size: 0.8rem;
}

.site-footer p {
  color: #9ca3af;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1rem;
}

.footer-links.vertical {
  display: grid;
}

.footer-links a {
  color: #cbd5e1;
  font-size: 0.92rem;
}

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

[data-category-card].is-hidden {
  display: none;
}

@media (min-width: 768px) {
  .hero-carousel {
    height: 500px;
  }

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

@media (min-width: 1024px) {
  .hero-carousel {
    height: 600px;
  }

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

@media (max-width: 900px) {
  .detail-layout,
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .white-panel,
  .color-panel,
  .filter-panel,
  .page-hero,
  .category-overview-card {
    padding: 1.15rem;
  }

  .section-heading,
  .category-overview-head,
  .detail-title-row,
  .search-page-form {
    align-items: stretch;
    flex-direction: column;
  }

  .horizontal-link {
    gap: 0.75rem;
  }

  .horizontal-cover {
    width: 8.5rem;
  }

  .hero-arrow {
    display: none;
  }

  .hero-content {
    left: 1rem;
    right: 1rem;
    bottom: 2rem;
  }

  .hero-content p {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
  }
}
