@import url("https://fonts.googleapis.com/css2?family=Domine:wght@400..700&family=Euphoria+Script&display=swap");

:root {
  --bgColor: beige;
  --darkColor: rgb(212, 212, 192);
  --edgeRadius: 1em;
  --centerWidth: 70vw;
}

/* Base style------------------------------------------------- */

.sideNav {
  position: fixed;
  top: 35%;
  right: 0;
  width: 1vw;
  height: fit-content;
  padding: 10px;
  background-color: white;
  border-top-left-radius: 10px;
  border-bottom-left-radius: 10px;
  transition: all 0.5s ease-in-out;
  border: solid 1px black;
}
.sideNav:hover {
  width: 10vw;
}
.sideNav ul {
  margin: 0;
  padding: 0;
}

.sideNav li {
  list-style: none;
  margin-left: 5em;
  transition: margin-left 0.3s ease-in-out;
}
.sideNav:hover li {
  margin-left: 0em;
}

.sideNav li a {
  text-decoration: none;
  color: black;
  font-size: 1em;
  display: block;
  padding: 0.5em;
  border-top-left-radius: 10px;
  border-bottom-left-radius: 10px;
  transition: background-color 0.3s ease-in-out;
}
.sideNav li a:hover {
  background-color: var(--bgColor);
}

button {
  font-family: "Domine", serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

body {
  margin: 0;
  padding: 0;
  background-color: rgb(181, 181, 158);
  font-family: "Domine", serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  overflow-x: hidden;
}

header {
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 2vh;
  
}

.homeTitle {
  background-color: var(--bgColor);
  width: fit-content;
  padding: 1.2em 4em;
  border-top-left-radius: 2em;
  border-top-right-radius: 2em;
  border-bottom: solid 3px black;
}

.headerTitle {
  font-family: "Euphoria Script", cursive;
  font-weight: 700;
  font-style: normal;
  text-decoration: none;
  letter-spacing: 0.2em;
  font-size: 2.5em;
}

header a {
  text-decoration: none;
  color: black;
  margin-top: 3vh;
}

.bodyCont {
  background-color: var(--bgColor);
  height: fit-content;
  width: 100%;
  padding-bottom: 20vh;
  /* height: 100vh; */
  border-top-left-radius: var(--edgeRadius);
  border-top-right-radius: var(--edgeRadius);
  /* overflow-y: scroll; */
  scroll-snap-type: y proximity;
  scroll-behavior: smooth;
}

/* index style------------------------------------------------ */
.recCont {
  margin: auto;
  padding: 20px;
  width: var(--centerWidth);
  margin-bottom: 8vh;

  /* background-color: violet; */
}
.recCont h1 {
  text-align: center;
  margin-top: 10vh;
}
#picks {
  display: grid;
  gap: 16px;
  margin: 12px 0;
  grid-template-columns: repeat(3, 1fr);
}
section {
  border-radius: 12px;
  padding: 12px;
  background-color: white;
}
.card a {
  font-weight: 700;
  text-decoration: none;
  color: black;
}
.card .cardImgBox {
  overflow: hidden;
  border: solid 1px black;
  border-radius: 12px;
  margin-bottom: 8px;
  width: 100%;
  height: 25vh;
  display: flex;
  justify-content: center;
  align-items: center;
}
.card img {
  width: 100%;
  transition: all 0.3s ease-in-out;
}
.card a:hover img {
  width: 110%;
}

.muted {
  color: #64748b;
  font-size: 0.9rem;
  font-weight: 400;
}

#reroll {
  display: block;
  margin: auto;
  padding: 8px 16px;
  border: none;
  border-radius: 8px;
  font-size: 1em;
  cursor: pointer;
  color: rgb(96, 96, 96);
  background-color: white;
  transition: all 0.3s ease-in-out;
  letter-spacing: normal;
}
#reroll:hover {
  color: black;
  letter-spacing: 0.1em;
}

/* Recipe select part ------------------------------------------------  */
#recipeCont {
  width: var(--centerWidth);
  margin: auto;
  height: fit-content;
  scroll-snap-align: start;
  padding-top: 5vh;
}
.controlBox {
  display: flex; /* 가로로 정렬 */
  justify-content: space-between; /* 양 끝으로 밀기 */
  align-items: end;
}
#sortIndex,
#sortTitle {
  font-family: "Domine", serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  padding: 8px 16px;
  border: none;
  font-size: 1.2em;
  border-top-left-radius: var(--edgeRadius);
  border-top-right-radius: var(--edgeRadius);
  cursor: pointer;
  color: rgb(87, 87, 87);
  background-color: rgb(124, 124, 118);
  transition: all 0.3s ease-in-out;
}
#num1,
#num2,
#num3,
#num4 {
  font-family: "Domine", serif;
  font-optical-sizing: auto;
  font-weight: 300;
  font-style: normal;
  padding: 8px 16px;
  margin: 0;
  border: none;
  font-size: 0.8em;
  border-top-left-radius: var(--edgeRadius);
  border-top-right-radius: var(--edgeRadius);
  cursor: pointer;
  color: rgb(87, 87, 87);
  background-color: rgb(124, 124, 118);
  transition: all 0.3s ease-in-out;
}
#num1.active,
#num2.active,
#num3.active,
#num4.active {
  background-color: var(--darkColor);
  color: black;
  font-size: 0.8em;
}

#sortIndex.active,
#sortTitle.active {
  background-color: var(--darkColor);
  color: black;
  font-size: 1.5em;
}

#recipeContGrid {
  background-color: var(--darkColor);
  height: 70vh;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2%;
  padding: 2%;
  border-bottom-left-radius: var(--edgeRadius);
  border-bottom-right-radius: var(--edgeRadius);
  /* border-top-right-radius: var(--edgeRadius); */
}

#recipeContGrid a {
  display: block;
}
/* .recipe{
    display: block;
} */
.previewImgBox {
  width: 100%;
  height: 25vh;
  overflow: hidden;
  border: solid 1px black;
  border-radius: var(--edgeRadius);
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 10px;
}
.previewImgBox img {
  width: 100%;
  transition: width 0.3s ease-in-out;
}
/* .previewImgBox img:hover{
    width: 110%;
} */

.recipe a {
  text-decoration: none;
  color: black;
  display: block;
}
.previewTextBox h4 {
  font-size: 12pt;
  margin: 0;
  transition: all 0.3s ease-in-out;
}
/* .previewTextBox h4:hover{
    font-size: 20pt;
} */
.previewTextBox p {
  font-size: 10pt;
  margin-top: 5px;
}
.recipe:hover .previewImgBox img {
  width: 110%;
}

/* Recipe Page style-------------------------------------------------  */
.recipeTopDiv {
  width: var(--centerWidth);
  margin: auto;
  padding-top: 5vh;
}
.recipeTitleBox {
  font-family: "Domine", serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  padding: 8px 25px;
  border: none;
  font-size: 2em;
  border-top-left-radius: var(--edgeRadius);
  border-top-right-radius: var(--edgeRadius);
  color: rgb(0, 0, 0);
  background-color: var(--darkColor);
  transition: all 0.3s ease-in-out;
  width: fit-content;
}
.recipreTotalBox {
  padding: 25px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  background-color: var(--darkColor);
  border-bottom-left-radius: var(--edgeRadius);
  border-bottom-right-radius: var(--edgeRadius);
  border-top-right-radius: var(--edgeRadius);

}

.recipeInfoBox {
  height: 100%;
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
}
.recipeInfoHorBox{
  height: 100%;
  width: 100%;
  display: grid;
  grid-template-rows: repeat(4,1fr);
  gap: 15px;
}
.recipeDetails {
  padding: 15px;
  background-color: white;
  border-radius: var(--edgeRadius);
  border: solid 1px black;
}
/* #ingredientsDiv{
  grid-column: 3/4;
  grid-row: 1/3;
} */
.recipeDetails h1 {
  margin-top: 0;
  padding-bottom: 10px;
  margin-bottom: 10px;
  text-align: left;
  font-size: 1.2em;
  border-bottom: solid 2px black  ;
}
.recipeDetails p {
  margin-top: 0px;
  margin-left: 0px;
  text-align: left;
  font-size: 1em;
}

.recipeImage {
  border-radius: var(--edgeRadius);
  height: 100%;
  overflow: hidden;
  border: solid 1px black;
  display: flex;
  justify-content: center;
  align-items: center;
  grid-column: 2/4;
}
.recipeImage img {
  width: 100%;
}


.recipeBody  {
  width: var(--centerWidth);
  margin: auto;
  padding-top: 10vh;
  padding-bottom: 30vh;
}

.recipeBody h1 {
  font-size: 2em;
  margin-top: 10vh;
  margin-bottom: 0;
  border-bottom: solid 2px black;
  padding-bottom: 5px;
}
.recipeBody h2 {
  font-size: 1.2em;
  margin-bottom: 0;
  padding-bottom: 5px;
}
.recipeBody p{
  line-height: 1.6em;
  font-size: 1em;
  margin-top: 0;
}