/* Fredoka Font */
@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@300..700&display=swap');

body{
    font-size: 25px;
    color: white;
    background-color: rgb(21,28,72);
    font-family: Fredoka, sans-serif;
    margin: 0;
    padding: 0;
}
a{
    text-decoration: none;
    color: white;
}
strong{
    font-weight: 500;
}

h1, h2, h3, 
h4 ,h5 ,h6{
    font-weight: 400;  
}

.header-container{
    display: flex;
    justify-content: space-around;
    align-items: center;
    width: 100%;  
    top: 0;
    z-index: 100;
    padding: 0.5rem;
    color: white;
    height: 5vh;
    box-sizing: border-box;
    margin-top: 2rem;
}

.nav-container, .logo-container {
    display: flex;
    align-items: center;
    gap: 20px;
}

nav ul{
    list-style-type: none;
    display: flex;
    gap: 20px;
    margin: 0;
    padding: 0;
}

nav ul li a{
    text-decoration: none;
    color: white;
    font-size: 1.2rem;
}

.button {
    background-color: #FFC300;
    border: none;
    color: #000000;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    font-family: 'Fredoka', sans-serif;
}

.button:hover {
    background-color: #FFD60A;
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15);
}

.search-image{  
    height: 40rem;
    margin: 8rem auto 3rem auto;
    overflow: hidden;
}

.search-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('/images/search-img.jpg') no-repeat center / cover;
    height: 52rem;
    opacity: 0.5; /* Adjust opacity as desired */
    z-index: -1; /* Place behind content */
}
.quote{
    text-align: center;
}

.search-bar {
    text-align: center;
    margin-top: 50px;
}

#recipe-search {
    padding: 10px;
    width: 400px;
    border: none;
    border-radius: 30px;
    font-size: 1rem;
    outline: none;
    transition: border 0.3s ease;
    background-color: #f9f8f6;
    color: #333;
    padding-left: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

#recipe-search::placeholder {
    color: #aaa;
}

#recipe-search:focus {
    border-color: #FFD60A;
}

.search-button {
    padding: 10px 20px;
    margin-left: 10px;
    background-color: #FFC300;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.search-button:hover {
    background-color: #FFD60A;
    transform: translateY(-2px);
}

.category-section {
    text-align: center;
    margin-top: 20px;
}

.category-button {
    border: none;
    padding: 10px 20px;
    margin: 10px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.category-button:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}

.popular-recipes {
    padding: 0 20px 40px 20px;
    text-align: center;
    margin: 0 auto;
}

.popular-recipes h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    color: #FFC300;
}

/* recipe cards div */
.recipes-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}

/* recipe cards */
.recipe-card {
    background-color: #fff;
    color: #000;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 300px;
    text-align: left;
    font-family: 'Fredoka', sans-serif;
    transition: transform 0.3s ease;
}

.recipe-card:hover {
    transform: scale(1.05);
    cursor: pointer;
}

/* Recipe card image */
.recipe-card img {
    width: 100%;
    height: auto;
    border-bottom: 4px solid #FFC300;
}

/* title */
.recipe-card h3 {
    font-size: 1.5rem;
    padding: 10px;
    color: #000000; 
}

.recipe-card p {
    padding: 0 10px 10px;
    font-size: 1rem;
    line-height: 1.5;
    color: #4A4A4A; 
}

.recipe-card strong {
    color: #0073E6;
}

/* Login and Sign-Up CSS */
.login-reg {
    text-align: center;
    margin-top: 100px;
  }
  
  .login-reg h1 {
    color: #FFC300;
    font-size: 2rem;
    margin-bottom: 20px;
  }
  
  .login-reg input {
    display: block;
    margin: 10px auto;
    padding: 10px;
    width: 300px;
    border: none;
    border-radius: 30px;
    font-size: 1rem;
    outline: none;
    background-color: #ffffffeb;
    color: #333;
    padding-left: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  }
  
  .login-reg input::placeholder {
    color: #aaa;
  }
  
  .login-reg input:focus {
    border: solid 1px;
    border-color: #FFD60A;
    background-color: #f9f8f6;
    transition: all 0.25s ease-in-out;
  }
  
  .submit-button {
    padding: 10px 20px;
    margin-top: 10px;
    background-color: #FFC300;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
  }
  
  .submit-button:hover {
    background-color: #FFD60A;
    transform: translateY(-2px);
  }

.login-reg p{
    font-size: 16px;
}
.login-reg a{
    text-decoration: underline;
    color: #FFC300;
}
.login-reg a:hover{
    cursor: pointer;
    color: #ffc400b8;
}

/* Additional styles for fade effect */
.login-reg div {
    min-width: 40vw;
    max-width: 40vw;
    margin-left: auto;
    margin-right: auto;
    opacity: 0; /* Start hidden */
    transition: opacity 0.25s ease; /* Transition for fade effect */
    display: none; /* Start as not displayed */
}

.login-reg div.active {
    display: block; /* Show the active form */
    opacity: 1; /* Fade in */
}

/* Login-Signup and Sign-out buttons */
#auth-buttons{
    display: flex;
    width: 190px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.auth-button {
    padding: 10px 20px;
    background-color: transparent;
    color: white;
    border: 2px solid #FFC300;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
    width: auto;
}

.auth-button:hover {
    background-color: #FFC300;
    color: #000000;
    cursor: pointer;
}

.username-label{
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    font-size: 12px;
    max-width: 100px;
    border: 2px solid #f1e5c0;
    border-radius: 30px;
    flex-direction: row;
    gap: 8px;
    margin-right: 20px;
}

#profile{
    height: 1.2rem;
    margin: 0 auto;
}

@media screen and (max-width: 700px){
    .quote{
        font-size: 1rem;
    }

    .logo-container h3{
        display: none;
    }

    nav{
        display: none;
    }

    .nav-container .button{
        display: none;
    }

    #recipe-search {
        width: 10rem;
    }

    .login-reg input {
        width: 100%;
      }

}