/* ============ page colors ===============
/* color: #f7f1e8; /* cream */
/* color: #2e261c; /* cast iron */
/* color: #a8570c; /* cacao */
/* color: #fff9f1; /* paper */
/* color: #888; /* ash */
/* color: #8b5e34; /* oak */
/*color: #fff; /* white */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

p {
  margin: 0px;
}

/* page layout, padding, flexbox, margins */
html {
  font-family: "Nunito", sans-serif;
  font-size: 18px;
  color: #2e261c;
  /* cast iron */
  background-color: #f7f1e8;
  /* cream */
  display: flex;
  flex-direction: row;
  justify-content: center;
  padding: 0 0.5rem;
}

body {
  display: flex;
  flex-direction: column;
  /*min-width: 400px;*/
  max-width: 700px;
  gap: 3rem;
}

main {
  background-color: #fff9f1;
  /* paper */
  border: 1px solid #888;
  /* ash */
  border-radius: 40px 40px 0 0;
  border-bottom: none;
  padding: 1rem;
}

main header {
  padding-bottom: 2rem;
}

header {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

header .header_title_box {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  border-bottom: 2px solid #8b5e34;
  /* oak */
  align-items: end;
}

header nav {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  gap: 0.5rem;
}

header nav ul {
  display: flex;
  flex-direction: row;
  gap: 1rem;
}

header nav form input,
header nav form button {
  padding: 0.25rem;
}


.visually-hidden {
  display: none;
}

/* fonts, text, colors, borders, lists */
a {
  color: #8b5e34;
  /* oak */
  text-decoration: none;
}

a:hover {
  color: #a8570c;
  /* cacao */
  text-decoration: underline;
}

h1,
h2,
h3 {
  font-family: "Playwrite US Trad", cursive;
  font-size: 125%;
  color: #a8570c;
  /* cacao */
}

h1 {
  font-size: 180%;
}

.login_form label,
.login_form input,
.login_form button {
  font-size: 125%;
}

dl dt {
  font-weight: 600;
}

main.recipe_full p.recipe_description,
main.recipe_full ul.recipe_ingredients,
main.recipe_full ol.recipe_steps {
  line-height: 1.25;
}

ul.taglist li a::before {
  content: "#";
  color: #888;
  /* ash */
}

ul.taglist li {
  text-wrap: nowrap;
}

.main_header h1 {
  color: #8b5e34;
  /* oak */
  font-size: 100%;
}

ul li {
  list-style: none;
}

/* ====== page components, buttons, page specifics ======= */
/* home page */
header.home_maincontent_header {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.fakebutton {
  color: #f7f1e8;
  /* cream */
  background-color: #8b5e34;
  /* oak */
  padding: 0.5em 1em;
  border-radius: 18px;
}

.fakebutton:hover {
  background-color: #a8570c;
  /* cacao */
  color: #fff9f1;
  /* paper */
}

.fakebutton_container {
  display: flex;
  flex-direction: row;
  gap: 1rem;
  justify-content: center;
}

/* recipe page */
.recipe_full h1{
  display: flex;
  justify-content: space-between;
  align-items: start;
}

main.recipe_full section.recipe_imgNprep img {
  transform: rotate(2deg);
  border: 5px solid white;
  border-radius: 3px;
  width: 100%;
  margin-bottom: 0.5rem;
}

section.recipe_imgNprep dl {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

section.recipe_imgNprep dl div.recipe_prep_labelval {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
}

section.recipe_imgNprep dl div.recipe_prep_labelval dt {
  width: calc(100% - 75%);
}

section.recipe_imgNprep dl div.recipe_prep_labelval dd {
  width: calc(100% - 25%);
}

section.recipe_ingredients ul.recipe_ingredients {
  padding-left: 1rem;
  text-indent: -1rem;
}

section.recipe_steps ol.recipe_steps {
  padding-left: 1rem;
}

main.recipe_full div.recipe_metadata {
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
  flex-wrap: wrap;
  row-gap: 0px;
}

main.recipe_full div.recipe_metadata ul.taglist {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
}

div.recipe_sections_row {
  display: flex;
  flex-direction: row;
  gap: 1rem;
}

section.recipe_sections_row_left {
  width: 0;
  flex-grow: 1;
}

section.recipe_sections_row_right {
  width: 0;
  flex-grow: 2;
}

div.recipe_sections_row:has(section.recipe_ingredients) {
  padding-top: 2rem;
}

/* recipe cards */
ul.recipe_list_cardGrid {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  padding: 1rem 0;
  gap: 1rem;
  align-items: start;
}

li.recipe_list_cardDisplay {
  border-radius: 5px;
  box-shadow: 0px 2px 2px 0px #888;
  /* ash */
  width: calc((100% - 2rem) / 3);
  padding: 0.5rem;
}

li.recipe_list_cardDisplay h3 {
  font-size: 100%;
}

li.recipe_list_cardDisplay img {
  width: 100%;
}

ul.taglist {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0px 0.5rem;
}

/* search page */
#search_recipes_input {
  width: 100%;
  padding: .25rem;
}

/* profile page */
div.profile_topper_wrapper {
  display: flex;
  flex-direction: row;
  gap: 1rem;
  justify-content: space-between;
  margin-bottom: 1rem;
}

div.profile_topper_wrapper img {
  width: 5rem;
  height: 5rem;
}

div.profile_metadata {
  display: flex;
  flex-direction: row;
  gap: 1rem;
}

/* login page */
form.login_form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

div.login_form_row{
  display: flex;
  flex-direction: row;
  gap: 1rem;
  align-items: baseline;
}

form.login_form div.login_form_row input[type="text"], form.login_form div.login_form_row input[type="password"] {
  width: 80%;
  padding: 0.25rem;
}

form.login_form > button {
  width: 50%;
  min-width: 200px;
}

.login_form_show_pw{
  display: flex;
  flex-direction: row;
  width: 100%;
  gap: 1em;
  padding-left: 1em;;
}


/* responsive layout */

@media (max-width: 700px) {
  /*login page*/
  div.login_form_row{
    display: flex;
    flex-direction: column;
    gap: 0;
  }
}

@media (max-width: 600px) {
  /*search page*/
  li.recipe_list_cardDisplay {
    width: calc((100% - 2rem) / 2);
  }
}

@media (max-width: 500px) {
  html {
    padding: 0;
  }

  body>header div.header_title_box {
    padding: 0.5rem;
    padding-bottom: 0;
  }

  body>header nav {
    padding: 0.5rem;
    padding-top: 0;
  }

  main {
    border-left: 0;
    border-right: 0;
  }

  /* recipe page */
  div.recipe_sections_row {
    display: flex;
    flex-direction: column;
    gap: 2rem;
  }

  section.recipe_sections_row_left {
    width: 100%;
    flex-grow: 0;
  }

  section.recipe_sections_row_right {
    width: 100%;
    flex-grow: 0;
  }
}

@media (max-width: 400px) {
  /*search page*/
  li.recipe_list_cardDisplay {
    width: calc((100% - 2rem) / 1);
  }
}

/* recipe edit page*/
.recipe_edit h1 {
  display: flex;
  justify-content: space-between;
  align-items: start;
}

.recipe_edit h1 input{
  font-family: "Playwrite US Trad", cursive;
  font-size: 125%;
  color: #a8570c;
  /* cacao */
}

.recipe_edit textarea{
  width: 100%;
  resize: vertical;
}

.recipe_edit .recipe_steps textarea{
  vertical-align: top;
}

input[type=number][size] { 
  width: calc(attr(size type(<number>)) * 1ch + 2rem); 
}

.recipe_edit .recipe_steps ul{
  padding-bottom: 1rem;    
}

.recipe_edit .recipe_steps ul li{
  padding-top: .25rem;
  list-style: circle;
  list-style-position: inside;
}

.recipe_edit textarea, .recipe_edit input{
  padding: .1rem;
  font-family: "Nunito", sans-serif;
  font-size: 18px;
  color: #2e261c;
}

output {
  color: red;
}