@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap");

:root {
  --primary-color: #22254b;
  --secondary-color: #373b69;
}

* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

body {
  font-family: "Poppins";
  background-color: var(--primary-color);
  overflow-x: hidden;
}

nav {
  background-color: var(--secondary-color);
  height: 4rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 1rem;
}

nav .title {
  font-size: 1.5rem;
  color: #eee;
  cursor: pointer;
}

nav .search {
  font-family: inherit;
  color: #fff;
  height: 2.8rem;
  padding: 0 0 0 15px;
  border-radius: 30px;
  transform: scale(1);
  background-color: var(--primary-color);
  border: 2px solid var(--secondary-color);
  transition: transform 0.2s ease;
}

nav .search:focus {
  outline: none;
  transform: scale(1.01);
}

nav .search::placeholder {
  color: #eee;
}

main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
}

.movie {
  background-color: var(--secondary-color);
  display: flex;
  flex-direction: column;
  width: 300px;
  margin-bottom: 2rem;
  overflow: hidden;
  position: relative;
  border-radius: 10px;
}

.movie img {
  width: 100%;
}

.movie-info {
  display: flex;
  color: #eee;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem;
  letter-spacing: 1px;
}

.movie-title {
  font-size: 1rem;
  padding-right: 5px;
}

.movie-rating {
  background-color: var(--primary-color);
  padding: 3px 12px;
  border-radius: 3px;
  font-weight: bold;
}

.movie-rating.green {
  background-color: green;
}

.movie-rating.orange {
  background-color: orangered;
}

.movie-rating.red {
  background-color: red;
}

.movie-overview {
  position: absolute;
  left: 0;
  bottom: 0;
  right: 0;
  background-color: #eee;
  max-height: 100%;
  padding: 2rem;
  transform: translateY(101%);
  transition: transform 0.3s ease;
  border-radius: 10px;
  overflow-y: scroll;

  scrollbar-width: none;
  -ms-overflow-style: none;
}

.movie:hover .movie-overview {
  transform: translateY(0);
}
