/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* Netflix-inspired styling */
:root {
  --netflix-red: #e50914;
  --netflix-black: #141414;
  --netflix-dark-gray: #181818;
  --netflix-gray: #2f2f2f;
  --netflix-light-gray: #808080;
  --netflix-white: #ffffff;
}

body {
  background-color: var(--netflix-black);
  color: var(--netflix-white);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.7) 10%, transparent);
  transition: background-color 0.3s ease;
  padding: 0 4rem;
}

.site-header.scrolled {
  background-color: var(--netflix-black);
}

.header-content {
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
}

.logo-link {
  display: block;
  line-height: 0;
  background-color: #000000;
  padding: 1rem 1.5rem 1rem 1.5rem;
  border-radius: 0 0 20px 20px;
  transition: all 0.3s ease;
}

.logo-link:hover {
  background-color: #1a1a1a;
  transform: translateY(5px);
}

.site-logo {
  height: 120px;
  width: auto;
  display: block;
}

.site-logo:hover {
  filter: brightness(1.1);
}

/* Hero Banner */
.hero-banner {
  position: relative;
  height: 80vh;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: flex-end;
  padding: 0 4rem 8rem;
}

.hero-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    to top,
    var(--netflix-black) 0%,
    transparent 50%,
    transparent 100%
  );
}

.hero-banner::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    to right,
    var(--netflix-black) 0%,
    transparent 50%
  );
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 40%;
}

.hero-title {
  font-size: 4rem;
  font-weight: 700;
  margin: 0 0 1rem 0;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.hero-description {
  font-size: 1.4rem;
  line-height: 1.5;
  margin: 0 0 2rem 0;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  margin-bottom: 3rem;
}

.btn-play,
.btn-info {
  padding: 0.8rem 2rem;
  font-size: 1.2rem;
  font-weight: 600;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  text-decoration: none;
}

.btn-play {
  background-color: var(--netflix-white);
  color: var(--netflix-black);
}

.btn-play:hover {
  background-color: rgba(255, 255, 255, 0.75);
}

.btn-info {
  background-color: rgba(109, 109, 110, 0.7);
  color: var(--netflix-white);
}

.btn-info:hover {
  background-color: rgba(109, 109, 110, 0.4);
}

/* Movie Rows */
.movie-rows {
  padding: 0 4rem 4rem;
  margin-top: -8rem;
  position: relative;
  z-index: 3;
}

.movie-row {
  margin-bottom: 3rem;
}

.row-title {
  font-size: 1.4rem;
  font-weight: 600;
  margin: 0 0 1rem 0;
  color: #e5e5e5;
}

.row-container {
  position: relative;
  overflow: hidden;
}

.row-content {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 0.5rem 0;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
}

.row-content::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

/* Movie Card */
.movie-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.movie-card {
  position: relative;
  min-width: 250px;
  width: 250px;
  height: 140px;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
  background-color: var(--netflix-gray);
}

.movie-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.3s ease;
}

.movie-card:hover {
  transform: scale(1.05);
  z-index: 10;
}

.movie-card:hover img {
  filter: brightness(0.7);
}

.movie-card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.movie-card:hover .movie-card-overlay {
  opacity: 1;
}

.movie-card-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 0.25rem 0;
  color: var(--netflix-white);
}

.movie-card-info {
  font-size: 0.85rem;
  color: var(--netflix-light-gray);
  margin: 0;
}

.movie-card-no-image {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--netflix-gray) 0%, var(--netflix-dark-gray) 100%);
  color: var(--netflix-light-gray);
  font-size: 0.9rem;
  text-align: center;
  padding: 1rem;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--netflix-light-gray);
}

.empty-state h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

/* Video Player Modal */
.video-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.9);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.video-modal.hidden {
  display: none;
}

.video-modal-content {
  position: relative;
  width: 100%;
  max-width: 1200px;
  background-color: var(--netflix-black);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 10px 50px rgba(0, 0, 0, 0.8);
}

.video-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 10;
  background-color: rgba(0, 0, 0, 0.7);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  color: var(--netflix-white);
}

.video-modal-close:hover {
  background-color: rgba(0, 0, 0, 0.9);
  transform: scale(1.1);
}

.video-wrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  height: 0;
  overflow: hidden;
}

.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .hero-banner {
    padding: 0 3rem 6rem;
  }
  
  .movie-rows {
    padding: 0 3rem 3rem;
  }
  
  .hero-content {
    max-width: 50%;
  }
  
  .hero-title {
    font-size: 3rem;
  }
}

@media (max-width: 768px) {
  .site-header {
    padding: 0 2rem;
  }

  .hero-banner {
    height: 60vh;
    padding: 0 2rem 4rem;
  }
  
  .movie-rows {
    padding: 0 2rem 2rem;
    margin-top: -4rem;
  }
  
  .hero-content {
    max-width: 70%;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-description {
    font-size: 1rem;
  }
  
  .btn-play,
  .btn-info {
    padding: 0.6rem 1.5rem;
    font-size: 1rem;
  }
  
  .movie-card {
    min-width: 180px;
    width: 180px;
    height: 100px;
  }
  
  .row-title {
    font-size: 1.2rem;
  }
}

@media (max-width: 480px) {
  .site-header {
    padding: 0 1rem;
  }

  .logo-link {
    padding: 0.75rem 1rem 0.75rem 1rem;
  }

  .site-logo {
    height: 80px;
  }

  .hero-banner {
    padding: 0 1rem 3rem;
  }
  
  .movie-rows {
    padding: 0 1rem 1rem;
  }
  
  .hero-content {
    max-width: 90%;
  }
  
  .hero-title {
    font-size: 1.5rem;
  }
  
  .hero-description {
    font-size: 0.9rem;
  }
  
  .hero-buttons {
    flex-direction: column;
  }
  
  .movie-card {
    min-width: 150px;
    width: 150px;
    height: 85px;
  }
}
