@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap');

html, body {
    height: 100%;
    display: flex;
    flex-direction: column;
}

body {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    background: #000;
    color: #fff;
    flex: 1;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-sizing: border-box;
}

.logo img {
    height: 30px;
}

.menu-toggle {
    display: none;
    font-size: 24px;
    color: #fff;
    cursor: pointer;
}

.menu {
    display: flex;
    align-items: center;
}

.menu ul {
    list-style: none;
    display: flex;
    gap: 20px;
    margin: 0;
    padding: 0;
}

.menu a {
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s;
}

.menu a:hover, .menu a.active {
    color: #e50914;
}

.search {
    position: relative;
    flex-shrink: 0;
    max-width: 200px;
    margin-left: 20px;
}

.search input {
    width: 100%;
    padding: 8px 30px 8px 10px;
    border: none;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    outline: none;
    font-size: 14px;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
    padding-left: 14px;
}

.search input::placeholder {
    font-family: 'Montserrat', sans-serif;
    color: #bbb;
    opacity: 1;
}

.search i {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 14px;
}

.featured-content {
    position: fixed;
    top: 0;
    width: 100%;
    height: 240px;
    z-index: 0;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.6), black 90%);
}


.backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  align-items: center;
  pointer-events: none;
  overflow: hidden;
  background: radial-gradient(
    ellipse at center,
    rgba(0, 0, 0, 0) 40%,
    rgba(0, 0, 0, 0.3) 75%,
    rgba(0, 0, 0, 0.6) 100%
  );
}

.backdrop img {
  width: 166px;
  height: 233px;
  object-fit: cover;
  flex-shrink: 0;
  opacity: 0.35;
  filter: grayscale(20%) brightness(0.85);
  margin-left: -14px;

  /* Combined masking: left-right fade and bottom fade */
  mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%),
              linear-gradient(to bottom, black 0%, black 85%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%),
                      linear-gradient(to bottom, black 0%, black 85%, transparent 100%);
  mask-composite: intersect;
  -webkit-mask-composite: destination-in;
}



.content-tray {
    padding: 80px 40px 40px; /* leave space for fixed featured section */
    position: relative;
    z-index: 2;
    flex: 1;
}


.content-tray h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: #fff;
}

.owl-carousel .item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5), 0 0 10px rgba(229, 9, 20, 0.3);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.05), rgba(229, 9, 20, 0.1));
    pointer-events: auto;
    touch-action: manipulation;
}

.owl-carousel .item img {
    width: 166px;
    height: 222px;
    object-fit: cover;
    border-radius: 14px;
    transition: transform 0.3s;
    pointer-events: auto;
    user-select: none;
}

.owl-carousel .item img:hover {
    transform: scale(1.05);
}

.owl-carousel {
    margin: 0 10px;
    position: relative;
}

.owl-carousel .owl-stage {
    display: flex;
    align-items: center;
}

.owl-carousel .owl-item {
   
}

.owl-carousel .owl-dots {
    display: none;
}

.owl-carousel .owl-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
}

.owl-carousel .owl-nav button.owl-prev,
.owl-carousel .owl-nav button.owl-next {
    background: rgba(0, 0, 0, 0.5) !important;
    color: #fff !important;
    font-size: 24px !important;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
    position: absolute;
}

.owl-carousel .owl-nav button.owl-prev {
    left: -60px;
}

.owl-carousel .owl-nav button.owl-next {
    right: -60px;
}

.owl-carousel .owl-nav button.owl-prev:hover,
.owl-carousel .owl-nav button.owl-next:hover {
    background: #e50914 !important;
}

.footer {
    display: none;
    background: #1a1a1a;
    padding: 40px;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-logo img {
    height: 30px;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    margin: 0 10px;
    font-size: 14px;
}

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

.social-icons a {
    color: #fff;
    margin: 0 10px;
    font-size: 18px;
}

.social-icons a:hover {
    color: #e50914;
}

.footer-animation .particle {
    position: absolute;
    background: #e50914;
    border-radius: 10px;
    opacity: 0.5;
    animation: float 10s infinite;
}

.footer-animation .particle:nth-child(1) { width: 20px; height: 20px; bottom: 10%; left: 10%; animation-delay: 0s; }
.footer-animation .particle:nth-child(2) { width: 15px; height: 15px; bottom: 20%; left: 30%; animation-delay: 2s; }
.footer-animation .particle:nth-child(3) { width: 25px; height: 25px; bottom: 15%; left: 60%; animation-delay: 4s; }
.footer-animation .particle:nth-child(4) { width: 10px; height: 10px; bottom: 25%; left: 80%; animation-delay: 6s; }

@keyframes float {
    0% { transform: translateY(0); opacity: 0.5; }
    50% { transform: translateY(-100px); opacity: 0.2; }
    100% { transform: translateY(0); opacity: 0.5; }
}

@media (max-width: 768px) {
    .header {
        padding: 20px;
        justify-content: space-between;
        align-items: center;
    }

    .menu-toggle {
        display: block;
    }

    .menu {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        width: 100%;
        background: rgba(0, 0, 0, 0.95);
        padding: 20px;
        flex-direction: column;
        align-items: center;
        z-index: 999;
    }

    .menu.active {
        display: flex;
    }

    .menu ul {
        flex-direction: column;
        gap: 15px;
        width: 100%;
        text-align: center;
    }

    .menu .search {
        max-width: 100%;
        margin-top: 20px;
        margin-left: 0;
    }

    .search input {
        width: 100%;
    }

    .featured-content {
        height: 150px;
    }

    .backdrop img {
        width: 120px;
        height: 168px;
    }

    .owl-carousel .item img {
        width: 120px;
        height: 162px;
    }

    .owl-carousel .owl-nav button.owl-prev {
        left: -30px;
    }

    .owl-carousel .owl-nav button.owl-next {
        right: -30px;
    }

    .content-tray {
        padding: 60px 15px;
    }

    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
}

@media (min-width: 769px) {
    .header {
        flex-wrap: nowrap;
    }

    .menu {
        display: flex !important;
    }

    .menu-toggle {
        display: none;
    }

    .featured-content {
        height: 240px;
        justify-content: flex-end;
    }
}

#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    color: #fff;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 20px;
    font-family: 'Montserrat', sans-serif;
}

#preloader .spinner {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(255, 255, 255, 0.2);
    border-top: 5px solid #e50914;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

#preloader .icon {
    font-size: 48px;
    margin-bottom: 20px;
}

#preloader .message {
    font-size: 18px;
    margin-bottom: 10px;
}

#preloader .fact {
    font-size: 14px;
    color: #bbb;
    margin-top: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

#search-bar-full {
    width: 100%;
    padding-left: 30px;
    padding-top: 14px;
    padding-bottom: 14px;
    border: none;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.3);
    color: #ffffff;
    outline: none;
    font-size: 14px;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
    padding-left: 14px;
}

.search-screen-result
{
    margin-top: 16px;
}

.netflix-spinner {
    width: 48px;
    height: 48px;
    border: 5px solid rgba(229, 9, 20, 0.2);
    border-top: 5px solid #e50914;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 40px auto;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.search-error-msg
{
    text-align: center;
    padding-left: 12px;
    margin-top: 35px;
    color: #e50914;
    font-weight: bold;
}

/* Grid container for search results */
.srhr_search-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); /* Flexible grid */
    gap: 15px; /* Space between items */
    padding: 15px; /* Optional padding for spacing */
}

/* Each individual item */
.srhr_item {
    text-align: center; /* Center the content of each item */
}

/* Poster images */
.srhr_item img {
    width: 156px;
    height: 222px;
    border-radius: 12px;
    object-fit: cover;
}

/* Title of the movie/series */
.srhr_item-title {
    font-weight: bold;
    margin-top: 10px;
}

/* Mobile - 2 items per row */
.srhr_search-results {
    grid-template-columns: repeat(3, 1fr); /* 2 items per row */
}

/* Tablet - 4 items per row */
@media (min-width: 768px) {
    .srhr_search-results {
        grid-template-columns: repeat(5, 1fr); /* 4 items per row */
    }
}

/* Desktop - 6 items per row */
@media (min-width: 1024px) {
    .srhr_search-results {
        grid-template-columns: repeat(8, 1fr); /* 6 items per row */
    }
}

.srhr__list-error {
  margin-top: 50px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.srhr__error-icon {
  font-size: 30px;
  color: #f77;
  animation: srhr__wifi-pulse 1.5s infinite ease-in-out;
  margin-bottom: 20px;
}

@keyframes srhr__wifi-pulse {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.2); opacity: 1; }
}

.srhr__error-text-title {
  font-weight: bold;
  font-size: 16px;
  color: #f55;
  margin-bottom: 10px;
}

.srhr__error-text-sub {
  font-size: 14px;
  color: #bbb;
  margin-top: 5px;
}
