/* IMPORT FONT */
@import url("https://fonts.googleapis.com/css2?family=Kdam+Thmor+Pro&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&family=Teko&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scrollbar-width: thin;
  scrollbar-color: lightgrey;
}

:root {
  /* COLORS */
  --PRIMARYBACKGROUNDCOLOR: white;
  --PRIMARYCOLOR: black;
  --FONTFAMILY: "Poppins", sans-serif;
  --BODYBACKGROUNDCOLOR: rgb(243, 225, 255);
}

body {
  font-family: var(--FONTFAMILY);
  background-color: var(--BODYBACKGROUNDCOLOR);
  min-height: 100vh;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  position: relative;
}

.recipeGeneratorContainer {
  max-width: 400px;
  max-height: auto;
  box-shadow: 0px 5px 5px black;
  background-color: white;
  border-radius: 10px;
}

.searchFoodForm {
  padding: 1rem;
  text-align: center;
}

.searchFoodForm input {
  border: none;
  background-color: lightgrey;
  padding: 0.8rem 1rem;
  border-radius: 10px;
  color: black;
  font-size: 1.1rem;
}

.searchFoodForm button {
  border: none;
  outline: none;
  background-color: transparent;
  align-items: center;
}
.searchFoodForm i {
  transform: translateY(0.3rem);
  margin-inline: 0.6rem;
}

.fa-magnifying-glass {
  font-size: 25px;
  color: lightgrey;
}

.favoriteFoodContainer {
  background-color: var(--BODYBACKGROUNDCOLOR);
  padding: 1rem;
  margin-bottom: 0.3rem;
}
.favoriteFoodContainer h2 {
  text-align: center;
  margin-bottom: 0.6rem;
  font-weight: 500;
}

.favoriteFoodContainerFlex {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  justify-content: space-around;
}

.favoriteFoodDiv {
  width: 80px;
  height: 80px;
  display: grid;
  place-items: center;
  margin-bottom: 3rem;
  position: relative;
  cursor: pointer;
}

.favoriteFoodDescription {
  word-break: break-all;
  font-size: 0.9rem;
}

.favoriteFoodContainer img {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 3px solid white;
  padding: 0.1rem;
}
.randomMealContainer {
  width: 100%;
  height: auto;
  background-color: var(--PRIMARYBACKGROUNDCOLOR);
  display: grid;
  place-items: center;
  padding: 1rem;
  position: relative;
}
.randomMealContainer h3 {
  box-shadow: 0px 2px 2px black;
  width: 170px;
  height: 30px;
  font-weight: 400;
  position: absolute;
  top: 0;
  left: 20px;
  background-color: var(--PRIMARYBACKGROUNDCOLOR);
  transform: translateY(2rem);
}

.displayRandomMealContainer {
  width: 350px;
  height: 270px;
  box-shadow: 0px 4px 4px black;
  margin-bottom: 1rem;
  cursor: pointer;
}
.randomMealImageContainer {
  width: 100%;
  height: 200px;
}

.randomMealImageContainer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.randomMealDescriptionContainerFlex {
  display: flex;
  justify-content: space-between;
  padding: 1rem;
}

.randomMealDescription {
  font-weight: 800;
}

.randomMealDescriptionContainerFlex button {
  border: none;
  outline: none;
  background-color: transparent;
  cursor: pointer;
}

.randomMealDescriptionContainerFlex i {
  font-size: 1.2rem;
}

.viewRecipeBtn {
  font-size: 1rem;
  background-color: blue;
  border: none;
  outline: none;
  color: var(--PRIMARYBACKGROUNDCOLOR);
  padding: 0.25rem 1rem;
  margin-left: 0.25rem;
  border-radius: 3px;
  transition: 0.3s ease-in-out;
  cursor: pointer;
}

.is-active {
  color: red;
}

.deleteFavMeal {
  width: 18px;
  height: 18px;
  border: none;
  outline: none;
  color: white;
  background-color: var(--PRIMARYCOLOR);
  position: absolute;
  top: 0;
  right: 0;
  transform: translateX(10px);
  display: none;
  transition: 0.3s ease-in-out;
  font-size: 0.6rem;
  font-weight: 400;
  cursor: pointer;
}

.favoriteFoodDiv:hover .deleteFavMeal {
  display: block;
}

.viewRecipeBtn:hover {
  background-color: green;
}

.recipeInfoContainer {
  position: fixed;
  background-color: rgba(0, 0, 0, 0.89);
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  display: grid;
  place-items: center;
  padding: 2rem;
}

.recipeInfo {
  background-color: var(--PRIMARYBACKGROUNDCOLOR);
  max-width: 600px;
  width: 100%;
  min-height: 500px;
  max-height: 600px;
  padding: 2rem;
  overflow-y: scroll;
  position: relative;
  transform: translateY(2rem);
}
.recipeInfo h1 {
  text-align: center;
}
.recipeInfo img {
  max-width: 100%;
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.recipeInfo ul {
  list-style-position: inside;
}

.recipeInfo p {
  margin-bottom: 1rem;
}

.recipeInfo li {
  margin-bottom: 2rem;
}

.recipeInfo button {
  border: none;
  outline: none;
  width: 18px;
  height: 18px;
  position: absolute;
  right: 0.2rem;
  top: 0;
  background-color: black;
  color: white;
  margin-top: 0.3rem;
  cursor: pointer;
}

.hidden {
  display: none;
}
@media screen and (max-width: 400px) {
  .displayRandomMealContainer {
    width: 280px;
  }
  .randomMealContainer h3 {
    left: 30px;
  }
}
@media screen and (max-width: 330px) {
  .displayRandomMealContainer {
    width: 230px;
  }
}
