/* =========================================================
   RECIPEHUB - COMPLETE STYLE.CSS
========================================================= */

/* =========================
   RESET
========================= */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:Arial, sans-serif;
}

html{
    scroll-behavior:smooth;
}

body{
    background:#f5f5f5;
    color:#222;
    line-height:1.5;
}


/* =========================================================
   HEADER
========================================================= */

header{
    background:#ff5722;
    width:100%;
    min-height:70px;

    display:flex;
    align-items:center;
    justify-content:space-between;

    padding:15px 40px;

    position:relative;
    z-index:9999;

    box-shadow:0 2px 8px rgba(0,0,0,.15);
}


/* Logo */

.logo h2{
    color:white;
    font-size:26px;
    margin:0;
    white-space:nowrap;
}


/* Navigation */

header nav{
    display:flex;
    align-items:center;
    justify-content:flex-end;
}

header nav a{
    color:white;
    text-decoration:none;

    margin-left:20px;

    font-size:15px;
    font-weight:bold;

    transition:.3s;
}

header nav a:hover{
    color:#ffe600;
}


/* Hamburger */

.menu-toggle{
    display:none;

    color:white;
    font-size:32px;
    line-height:1;

    cursor:pointer;
    user-select:none;
}


/* Dark Mode Button */

#darkModeBtn{
    margin-left:20px;

    padding:9px 15px;

    background:white;
    color:#ff5722;

    border:none;
    border-radius:6px;

    cursor:pointer;

    font-weight:bold;

    transition:.3s;
}

#darkModeBtn:hover{
    background:#ffe600;
    color:#222;
}


/* =========================================================
   HERO
========================================================= */

.hero{
    min-height:400px;

    background:
        linear-gradient(
            rgba(0,0,0,.55),
            rgba(0,0,0,.55)
        ),
        url('https://images.unsplash.com/photo-1490645935967-10de6ba17061');

    background-size:cover;
    background-position:center;

    display:flex;
    justify-content:center;
    align-items:center;

    flex-direction:column;

    color:white;
    text-align:center;

    padding:40px 20px;
}

.hero h1{
    font-size:50px;
    margin-bottom:10px;
}

.hero h2{
    font-size:36px;
    margin-bottom:10px;
}

.hero p{
    margin-top:10px;
    font-size:20px;
    max-width:700px;
}


/* =========================================================
   BUTTON
========================================================= */

.btn{
    display:inline-block;

    margin-top:20px;

    padding:12px 25px;

    background:#ff5722;
    color:white;

    text-decoration:none;

    border:none;
    border-radius:6px;

    cursor:pointer;

    font-weight:bold;

    transition:.3s;
}

.btn:hover{
    background:#e64a19;
    transform:translateY(-1px);
}


/* =========================================================
   SEARCH
========================================================= */

.search{
    padding:40px 30px;
    text-align:center;

    background:#fff;
}

.search h2{
    margin-bottom:25px;
    font-size:28px;
}

.search form{
    max-width:1000px;
    margin:auto;

    display:flex;
    flex-wrap:wrap;

    gap:10px;

    align-items:center;
    justify-content:center;
}


/* Search Input */

.search input{
    flex:1;

    min-width:250px;

    padding:14px 15px;

    border:1px solid #ccc;
    border-radius:6px;

    outline:none;

    font-size:15px;
}

.search input:focus{
    border-color:#ff5722;
}


/* Category */

.search select{
    padding:14px 15px;

    border:1px solid #ccc;
    border-radius:6px;

    outline:none;

    font-size:15px;

    background:white;
}


/* Search Button */

.search button{
    padding:14px 25px;

    background:#ff5722;
    color:white;

    border:none;
    border-radius:6px;

    cursor:pointer;

    font-weight:bold;

    font-size:15px;
}

.search button:hover{
    background:#e64a19;
}


/* =========================================================
   SECTIONS
========================================================= */

.section{
    padding:50px 30px;

    text-align:center;
}

.section > h2{
    font-size:30px;
    margin-bottom:10px;
}


/* =========================================================
   CARDS CONTAINER
========================================================= */

.cards{
    display:flex;

    justify-content:center;
    align-items:stretch;

    gap:25px;

    flex-wrap:wrap;

    margin-top:30px;
}


/* =========================================================
   CARD
========================================================= */

.card{
    background:white;

    width:280px;

    border-radius:12px;

    overflow:hidden;

    box-shadow:
        0 3px 12px rgba(0,0,0,.12);

    padding-bottom:20px;

    transition:.3s;
}

.card:hover{
    transform:translateY(-5px);

    box-shadow:
        0 8px 20px rgba(0,0,0,.18);
}


/* Card Image */

.card img{
    display:block;

    width:100%;
    height:180px;

    object-fit:cover;
}


/* Card Heading */

.card h3{
    margin:15px;

    font-size:20px;
}


/* Card Paragraph */

.card p{
    margin:10px 15px;

    color:#555;
}


/* Recipe Card */

.recipe-card .btn{
    margin-left:15px;
    margin-right:15px;

    width:calc(100% - 30px);

    text-align:center;
}


/* =========================================================
   CATEGORY BUTTONS
========================================================= */

.category{
    text-align:center;
}

.category button{
    padding:10px 20px;

    margin:5px;

    background:#ff5722;
    color:white;

    border:none;
    border-radius:6px;

    cursor:pointer;
}

.category button:hover{
    background:#e64a19;
}


/* =========================================================
   LIKE BUTTON
========================================================= */

.like-btn{
    background:#e91e63;

    color:white;

    border:none;

    padding:10px 20px;

    border-radius:6px;

    cursor:pointer;

    margin-top:10px;
}

.like-btn:hover{
    background:#c2185b;
}


/* =========================================================
   RATING
========================================================= */

.rating{
    margin-top:15px;

    font-size:25px;

    cursor:pointer;
}

.star{
    padding:2px;

    display:inline-block;

    transition:.2s;
}

.star:hover{
    transform:scale(1.3);
}


/* =========================================================
   FOOTER
========================================================= */

footer{
    background:#222;

    color:white;

    text-align:center;

    padding:25px 15px;

    margin-top:40px;
}

footer p{
    margin:5px 0;
}


/* =========================================================
   DARK MODE
========================================================= */

.dark-mode{
    background:#222;
    color:white;
}

.dark-mode header{
    background:#111;
}

.dark-mode .search{
    background:#222;
    color:white;
}

.dark-mode .search input,
.dark-mode .search select{
    background:#333;
    color:white;

    border-color:#555;
}

.dark-mode .card{
    background:#333;
    color:white;
}

.dark-mode .card p{
    color:#ddd;
}

.dark-mode footer{
    background:#000;
}


/* =========================================================
   GENERAL RESPONSIVE ELEMENTS
========================================================= */

img{
    max-width:100%;
}

video{
    max-width:100%;
}

table{
    max-width:100%;
}


/* =========================================================
   TABLET
========================================================= */

@media screen and (max-width:900px){

    header{
        padding:15px 20px;
    }

    header nav a{
        margin-left:12px;
        font-size:14px;
    }

    #darkModeBtn{
        margin-left:12px;
    }

    .hero h1{
        font-size:42px;
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media screen and (max-width:768px){

    /* -------------------------
       HEADER
    ------------------------- */

    header{
        width:100%;

        height:70px;
        min-height:70px;

        padding:12px 18px;

        display:flex;
        flex-direction:row;

        justify-content:space-between;
        align-items:center;
    }


    /* Logo */

    .logo{
        display:flex;
        align-items:center;
    }

    .logo h2{
        font-size:21px;
    }


    /* Hamburger */

    .menu-toggle{
        display:block;

        font-size:32px;

        width:45px;
        height:45px;

        display:flex;
        align-items:center;
        justify-content:center;

        cursor:pointer;

        z-index:10001;
    }


    /* -------------------------
       MOBILE NAVIGATION
    ------------------------- */

    header nav#menu{

        display:none;

        position:absolute;

        top:70px;
        left:0;

        width:100%;

        background:#ff5722;

        padding:8px 15px 15px;

        flex-direction:column;

        align-items:stretch;

        justify-content:flex-start;

        box-shadow:
            0 5px 15px rgba(0,0,0,.25);

        z-index:10000;
    }


    /* Open Menu */

    header nav#menu.active{
        display:flex;
    }


    /* Menu Links */

    header nav#menu a{

        display:block;

        width:100%;

        margin:0;

        padding:14px 10px;

        color:white;

        font-size:16px;

        font-weight:bold;

        text-align:left;

        text-decoration:none;

        border-bottom:
            1px solid rgba(255,255,255,.25);
    }


    header nav#menu a:hover{
        background:rgba(0,0,0,.12);
        color:white;
    }


    /* Dark Mode */

    header nav#menu #darkModeBtn{

        display:block;

        width:100%;

        margin:12px 0 0;

        padding:12px;

        font-size:15px;
    }


    /* -------------------------
       HERO
    ------------------------- */

    .hero{
        min-height:420px;

        padding:35px 18px;
    }

    .hero h1{
        font-size:36px;

        line-height:1.2;
    }

    .hero h2{
        font-size:28px;
    }

    .hero p{
        font-size:18px;

        line-height:1.5;

        margin-top:15px;
    }

    .hero .btn{
        width:100%;

        max-width:350px;

        text-align:center;
    }


    /* -------------------------
       SEARCH
    ------------------------- */

    .search{
        padding:30px 15px;
    }

    .search h2{
        font-size:26px;

        margin-bottom:20px;
    }

    .search form{

        width:100%;

        display:flex;

        flex-direction:column;

        gap:10px;
    }

    .search input,
    .search select,
    .search button{

        width:100%;

        min-width:100%;
    }

    .search input{
        padding:14px;
    }

    .search select{
        padding:14px;
    }

    .search button{
        padding:14px;
    }

    .search .btn{

        width:100%;

        margin-top:0;

        text-align:center;
    }


    /* -------------------------
       SECTIONS
    ------------------------- */

    .section{
        padding:35px 15px;
    }

    .section > h2{
        font-size:26px;
    }


    /* -------------------------
       CARDS
    ------------------------- */

    .cards{

        width:100%;

        display:flex;

        flex-direction:column;

        align-items:center;

        gap:20px;

        margin-top:25px;
    }

    .card{

        width:100%;

        max-width:430px;

        margin:0 auto;
    }

    .card img{

        width:100%;

        height:220px;

        object-fit:cover;
    }

    .card h3{
        font-size:20px;
    }

    .card p{
        font-size:15px;
    }


    /* Recipe button */

    .recipe-card .btn{

        width:calc(100% - 30px);

        margin-left:15px;
        margin-right:15px;
    }


    /* -------------------------
       FOOTER
    ------------------------- */

    footer{
        padding:25px 15px;
    }

}


/* =========================================================
   SMALL PHONES
========================================================= */

@media screen and (max-width:480px){

    .logo h2{
        font-size:19px;
    }

    .menu-toggle{
        font-size:30px;
    }

    .hero{
        min-height:400px;

        padding:30px 15px;
    }

    .hero h1{
        font-size:32px;
    }

    .hero h2{
        font-size:25px;
    }

    .hero p{
        font-size:16px;
    }

    .section{
        padding:30px 12px;
    }

    .section > h2{
        font-size:23px;
    }

    .card{
        max-width:100%;
    }

    .card img{
        height:200px;
    }

    .card h3{
        font-size:19px;
    }

}


/* =========================================================
   VERY SMALL PHONES
========================================================= */

@media screen and (max-width:360px){

    .logo h2{
        font-size:17px;
    }

    .menu-toggle{
        font-size:28px;
    }

    .hero h1{
        font-size:28px;
    }

    .hero p{
        font-size:15px;
    }

}