* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #0e0f17;
  color: #ffffff;
  font-family: Arial, Helvetica, sans-serif;
}

.page {
  min-height: 100vh;
  padding: 120px 24px 70px;
  background: #0e0f17;
}

.content {
  width: min(1120px, 100%);
  margin: 0 auto;
}

h1 {
  margin: 0 0 38px;
  font-size: 64px;
  line-height: 1.1;
  font-weight: 800;
}

label {
  display: block;
  margin-bottom: 16px;
  font-size: 24px;
  color: #ffffff;
}

.combo-box {
  position: relative;
  width: min(1030px, 100%);
  margin-bottom: 26px;
}

#movieName {
  width: 100%;
  height: 96px;
  padding: 0 78px 0 28px;
  border: 1px solid #3c3d4b;
  border-radius: 6px;
  background: #383945;
  color: #ffffff;
  font-size: 34px;
  outline: none;
}

#movieName::placeholder {
  color: #9b9b9b;
}

#movieName:focus {
  border-color: #ff3b70;
  box-shadow: 0 0 0 3px rgba(255, 59, 112, 0.25);
}

.dropdown-button {
  position: absolute;
  top: 0;
  right: 0;
  width: 72px;
  height: 96px;
  border: 0;
  background: transparent;
  color: #ffffff;
  font-size: 28px;
  cursor: pointer;
}

.dropdown-list {
  position: absolute;
  top: 104px;
  left: 0;
  right: 0;
  z-index: 20;
  display: none;
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid #ff3b70;
  border-radius: 6px;
  background: #ffffff;
  color: #111111;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.dropdown-list.show {
  display: block;
}

.dropdown-item {
  padding: 14px 18px;
  font-size: 18px;
  cursor: pointer;
}

.dropdown-item:hover,
.dropdown-item.active {
  background: #ffedf3;
  color: #d91f55;
}

.recommend-button {
  margin-bottom: 70px;
  padding: 20px 34px;
  border: 2px solid #ff3b70;
  border-radius: 8px;
  background: transparent;
  color: #ff3b70;
  font-size: 30px;
  cursor: pointer;
  box-shadow: 0 0 0 3px rgba(255, 59, 112, 0.18);
}

.recommend-button:hover {
  background: #ff3b70;
  color: #ffffff;
}

.recommend-button:disabled {
  opacity: 0.6;
  cursor: wait;
}

#message {
  min-height: 28px;
  margin: -42px 0 34px;
  color: #ffb3c7;
  font-size: 20px;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 30px;
  align-items: start;
}

.movie-card {
  min-width: 0;
}

.movie-card h3 {
  margin: 0 0 20px;
  color: #ffffff;
  font-family: "Courier New", monospace;
  font-size: 22px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.movie-card img {
  width: 100%;
  height: 300px;
  display: block;
  object-fit: cover;
  background: #252631;
}

@media (max-width: 1000px) {
  h1 {
    font-size: 46px;
  }

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

  .movie-card img {
    height: 340px;
  }
}

@media (max-width: 640px) {
  .page {
    padding: 60px 16px;
  }

  h1 {
    font-size: 34px;
  }

  label {
    font-size: 18px;
  }

  #movieName {
    height: 68px;
    font-size: 22px;
  }

  .dropdown-button {
    height: 68px;
  }

  .dropdown-list {
    top: 76px;
  }

  .recommend-button {
    width: 100%;
    font-size: 22px;
  }

  .movie-grid {
    grid-template-columns: 1fr;
  }

  .movie-card img {
    height: auto;
  }
}
