/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

/* Body */
body {
  background: #0f172a;
  color: #fff;
  min-height: 100vh;
}

/* Container */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 40px auto;
}

/* Header Section */
.mycontainer {
  text-align: center;
  margin-bottom: 30px;
}

.mycontainer h1 {
  font-size: 2.5rem;
  margin-bottom: 15px;
  color: #38bdf8;
}

/* Search Box */
#search-input {
  padding: 12px;
  width: 60%;
  max-width: 400px;
  border: none;
  border-radius: 8px;
  outline: none;
  font-size: 16px;
  margin-right: 10px;
}

#search-button {
  padding: 12px 20px;
  background: #38bdf8;
  border: none;
  border-radius: 8px;
  color: #000;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
}

#search-button:hover {
  background: #0ea5e9;
  transform: scale(1.05);
}

/* Movie Section */
.detailMovie {
  display: flex;
  gap: 30px;
  margin-top: 20px;
  flex-wrap: wrap;
}

/* Movie Grid */
#image-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
  width: 100%;
}

/* Movie Card */
.movie {
  background: #1e293b;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: 0.3s;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.movie:hover {
  transform: translateY(-5px);
}

/* Poster */
.movie img {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

/* Movie Info */
.movie h3 {
  font-size: 1rem;
  padding: 10px;
}

.movie p {
  padding: 0 10px 10px;
  color: #94a3b8;
}

/* Movie Details Panel */
#movie-details {
  background: #1e293b;
  padding: 20px;
  border-radius: 12px;
  flex: 1;
  min-width: 280px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.movie-details h2 {
  margin-bottom: 10px;
  color: #38bdf8;
}

.movie-details p {
  margin: 8px 0;
  line-height: 1.5;
}

/* Scroll Fix */
#movie-list {
  width: 100%;
}

/* Responsive */
@media (max-width: 768px) {
  #search-input {
    width: 100%;
    margin-bottom: 10px;
  }

  #search-button {
    width: 100%;
  }

  .detailMovie {
    flex-direction: column;
  }
}