/*--- Global styles ---*/

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

@font-face {
    font-family:"Outfit";
    src: url("./assets/fonts/outfit/Outfit-VariableFont_wght.ttf") format("truetype");;
    font-weight: 400,600,700;
    font-display: swap;
}

@font-face {
    font-family:"Young Serif";
    src: url("./assets/fonts/young-serif/YoungSerif-Regular.ttf") format("truetype");
    font-weight: 400;
    font-display: swap;
}

:root{
    --white: hsl(0, 0%, 100%);
    --stone-100: hsl(30, 54%, 90%);
    --stone-150: hsl(30, 18%, 87%);
    --stone-600: hsl(30, 10%, 34%);
    --stone-900: hsl(24, 5%, 18%);
    --brown-800: hsl(14, 45%, 36%);
    --rose-800: hsl(332, 51%, 32%);
    --rose-50: hsl(330, 100%, 98%);
}

body{
    display: flex;
    flex-direction: column;
    font-family: "Outfit", Times, serif;
    font-size: 16px;
    color: var(--stone-600);
    background-color:var(--stone-100);
    min-height:100vh;
    line-height: 1.6;
}

ul,
ol{
    list-style-position: inside;
}

li::marker{
    color:var(--brown-800);
    font-weight:bold;
}

li{
    padding-left: 2.5em;  
    text-indent: -1.5em;    /* multiline alignment: l. 56-57 */
    margin-bottom:0.5em;
}

hr{
    border: none;
    border-top: 1.2px solid var(--stone-150);
    width:100%;
}

a{
    font-weight: bold;
}

/*--- Main Components ---*/

main{
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

footer{
    margin:0 auto;
    padding:40px;
}

footer a{
    color:var(--rose-800);
}

footer a:hover,
footer a:focus {
     color:var(--grey-800);
}

.ingredients,
.instruction,
.nutrition{
    margin: 25px 0;
}

/*--- Card components ---*/

.card{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    width: 55%;
    height: fit-content;
    max-width: 90%;
    padding:40px;
    margin: 120px 75px;
    background-color: var(--white);
    border-radius: 20px;
  }

.intro img{
    max-width: 100%;
    height:auto;
    margin-bottom:20px;
    border-radius: 10px;
}

.intro__time-list{
    display:flex;
    flex-direction:column;
    justify-content:center;
    margin-top:30px;
    margin-bottom:15px;
    width:100%;
    background-color:var(--rose-50);
    padding:15px 25px;
    line-height: 1.9rem;
}

.ingredients__list{
    padding-left:5px;
    margin-bottom:20px;
}

.instructions{
    margin-top:15px;
}

/* Nutrition table */

.nutrition__macro table {
    width: 100%;
    border-collapse: collapse; 
    border: none; 
    margin-top:20px;
}

.nutrition__macro td {
    padding: 10px 0;
    border-bottom: 1px solid var(--stone-150);
}

.nutrition__macro td:first-child {
    padding-left: 25px;
    width: 70%; 
}

.nutrition__macro td:last-child {
    padding-left: 20px;
    padding-right: 50px;
    width: 30%; 
    text-align: right;
}

.nutrition__macro tr:last-child td { 
    border-bottom: none;
}

.value {
    font-weight: bold;
    color: var(--brown-800);
}

/*--- Headings ---*/

h1{
    font-family: "Young Serif", Times,serif;
    color: var(--stone-900);
    font-size: 40px;
    font-weight: 500;
    margin-bottom: 11px;
}

h2 {
    font-family: "Young Serif", Times, serif;
    font-size: 28px;
    font-weight: 400;
    margin-bottom:15px;
    color: var(--brown-800);
}

.intro h2{
    font-family: "Outfit",Times, serif;
    color: var(--rose-800);
    font-size: 20px;
    font-weight: 700;
    margin-top: 20px;
    text-indent: 1.5em;
}