@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');

/* Reset & Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: #000000;
  color: white;
  line-height: 1.6;
}

/* ================= HEADER ================= */
.header {
  background: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
  padding: 1rem 2rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 20px rgba(0,0,0,0.5);
  transition: background 0.3s ease;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
}

.logo {
  font-size: 2rem;
  font-weight: bold;
  background: linear-gradient(90deg, #e94e00, #e50914);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-links a {
  color: white;
  text-decoration: none;
  transition: color 0.3s ease;
  font-weight: 500;
}

.nav-links a:hover {
  color: #00d4ff;
}

.search-profile {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.search-box {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 25px;
  padding: 0.5rem 1rem;
  color: white;
  outline: none;
  transition: all 0.3s ease;
}

.search-box:focus {
  background: rgba(255,255,255,0.2);
  border-color: #00d4ff;
}

.search-box::placeholder {
  color: rgba(255,255,255,0.7);
}

.profile-btn {
  background: linear-gradient(45deg, #00d4ff, #ff006e);
  border: none;
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.3s ease;
}

.profile-btn:hover {
  transform: scale(1.05);
}

/* ================= HERO with 3D Background ================= */
.hero {
  position: relative;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: white;
  overflow: hidden;
  padding: 4rem 2rem;
}

.hero .background-carousel {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  perspective: 1200px;
  z-index: -1;
}

.background-carousel img {
  position: absolute;
  width: 180px;
  height: 270px;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.6);
  animation: spin 25s linear infinite;
  transform-origin: center center -600px;
}

.background-carousel img:nth-child(1) { animation-delay: 0s; }
.background-carousel img:nth-child(2) { animation-delay: -5s; }
.background-carousel img:nth-child(3) { animation-delay: -10s; }
.background-carousel img:nth-child(4) { animation-delay: -15s; }
.background-carousel img:nth-child(5) { animation-delay: -20s; }

@keyframes spin {
  from { transform: rotateY(0deg) translateZ(600px); }
  to   { transform: rotateY(360deg) translateZ(600px); }
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 700px;
}

.hero-content h1 {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  background: linear-gradient(45deg, #ffffff, #00d4ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-content p {
  font-size: 1.3rem;
  margin-bottom: 2rem;
  opacity: 0.9;
}

.hero-content .btn {
  padding: 1rem 2rem;
  border: none;
  border-radius: 30px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  background: linear-gradient(45deg, #00d4ff, #ff006e);
  color: white;
  transition: all 0.3s ease;
}

.hero-content .btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0,212,255,0.3);
}

/* ================= CONTENT ================= */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: 3rem 0;
}

.section h2 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
  color: #00d4ff;
}

/* Movie Grid */
.movie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
  justify-content: center;
  align-items: start;
}

.movie-card {
  background: rgba(255,255,255,0.05);
  border-radius: 15px;
  overflow: hidden;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.movie-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0,212,255,0.2);
}

.movie-poster {
  width: 100%;
  height: 300px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: white;
  position: relative;
}

.play-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.movie-card:hover .play-overlay {
  opacity: 1;
}

.play-btn {
  width: 60px;
  height: 60px;
  background: linear-gradient(45deg, #e1cb06, #ff006e);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
}

.movie-info {
  padding: 1rem;
  margin-top: auto;
}

.movie-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-meta {
  color: #aaa;
  font-size: 0.9rem;
}

/* Poster Images */
.poster-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: 10px;
  display: block;
  transition: transform 0.3s ease;
}

.poster-img-small {
  width: 100%;
  height: 225px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
  transition: transform 0.3s ease;
}

.poster-img:hover,
.poster-img-small:hover {
  transform: scale(1.05);
}

/* Categories */
.category-row { margin-bottom: 3rem; }

.category-title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: white;
}

.category-scroll {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding: 1rem 0;
  scrollbar-width: thin;
  scrollbar-color: #000000 #1a252f;
}

.category-scroll::-webkit-scrollbar { height: 8px; }
.category-scroll::-webkit-scrollbar-track { background: #ff0000; }
.category-scroll::-webkit-scrollbar-thumb {
  background: #1389a1;
  border-radius: 4px;
}

.category-card {
  min-width: 150px;
  height: 225px;
  background: rgba(255,255,255,0.05);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 1rem;
  text-align: center;
}

.category-card:hover {
  background: rgb(255, 0, 0);
  transform: scale(1.05);
}

/* Features */
.features {
  background: rgba(255,255,255,0.02);
  border-radius: 20px;
  padding: 3rem;
  margin: 3rem 0;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature-item {
  text-align: center;
  padding: 2rem;
  border-radius: 15px;
  background: rgba(255,255,255,0.05);
  transition: all 0.3s ease;
}

.feature-item:hover {
  background: rgba(0,212,255,0.1);
  transform: translateY(-5px);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  background: linear-gradient(45deg, #00d4ff, #ff006e);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Footer */
.footer {
  background: #1a252f;
  padding: 3rem 2rem 2rem;
  margin-top: 4rem;
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.footer-section h3 {
  color: #00d4ff;
  margin-bottom: 1rem;
}

.footer-section a {
  color: #aaa;
  text-decoration: none;
  display: block;
  margin-bottom: 0.5rem;
  transition: color 0.3s ease;
}

.footer-section a:hover { color: white; }

.footer-bottom {
  text-align: center;
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  color: #aaa;
}

/* ================= RESPONSIVE ================= */
@media (max-width: 768px) {
  .nav-links { display: none; }

  .hero-content h1 { font-size: 2.5rem; }

  .movie-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
  }

  .features { padding: 2rem 1rem; }

  .search-profile { gap: 0.5rem; }
  .search-box { width: 120px; }
}
