@import url('https://fonts.googleapis.com/css2?family=Barlow+Semi+Condensed:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&family=Figtree:ital,wght@0,300..900;1,300..900&family=Fraunces:ital,opsz,wght@0,9..144,100..900;1,9..144,100..900&family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=Karla:ital,wght@0,200..800;1,200..800&family=Manrope:wght@200..800&family=Montserrat:ital,wght@0,100..900;1,100..900&family=Outfit:wght@100..900&family=Overpass:ital,wght@0,100..900;1,100..900&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&family=Red+Hat+Display:ital,wght@0,300..900;1,300..900&family=Roboto:ital,wght@0,100..900;1,100..900&family=Rubik:ital,wght@0,300..900;1,300..900&family=Space+Mono:ital,wght@0,400;0,700;1,400;1,700&family=Work+Sans:ital,wght@0,100..900;1,100..900&family=Young+Serif&display=swap');

:root {
    --Soft-orange: hsl(35, 77%, 62%);
    --Soft-red: hsl(5, 85%, 63%);

    --Off-white: hsl(36, 100%, 99%);
    --Grayish-blue: hsl(233, 8%, 79%);
    --Dark-grayish-blue: hsl(236, 13%, 42%);
    --Very-dark-blue: hsl(240, 100%, 5%);

    --weight-400: 400;
    --weight-700: 700;
    --weight-800: 800;
    --font-para: 0.9375rem;
    --overlay: rgba(0, 0, 0, 0.7);
}

* {
    padding: 0;
    margin: 0;
}

body {
    font-family: 'Inter';
    box-sizing: border-box;
}

.container {
    min-height: 100vh;
    overflow: hidden;
    padding: 2rem 1rem;
    position: relative;
    background-color: var(--Off-white);
    display: grid;
    place-content: center;
}

.container::before {
    content: '';
    width: 100%;
    height: 100%;
    background-color: var(--overlay);
    position: absolute;
    top: 0;
    left: 0;
    visibility: hidden;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav button {
    cursor: pointer;
    outline: none;
    border: 0;
    background-color: var(--Off-white);
    -webkit-tap-highlight-color: transparent;
}

.menu {
    position: fixed;
    list-style-type: none;
    top: 0;
    right: 0;
    background-color: var(--Off-white);
    height: 100%;
    padding: 2rem 1.5rem;
    width: 55%;
    display: flex;
    flex-direction: column;
    gap: 2rem;

    transform: translateX(100%);
    transition: transform .3s ease-in-out;
}

.close-menu {
    text-align: right;
    margin-bottom: 3rem;
}

.menu li a {
    text-decoration: none;
    color: var(--Very-dark-blue);
    font-size: 1.3rem;
}

.menu-open .menu {
    transform: translateX(0);
}

.container.menu-open::before {
    visibility: visible;
}

header {
    margin-bottom: 2rem;
}

picture img {
    width: 100%;
}

.main-blog h1 {
    margin: 1.5rem 0;
    font-size: 3rem;
    line-height: 3rem;
    color: var(--Very-dark-blue);
}

.main-blog p {
    margin-bottom: 1.5rem;
    font-size: var(--font-para);
    line-height: 1.6rem;
    color: var(--Very-dark-blue);
    font-weight: var(--weight-700);
}

.main-blog button {
    cursor: pointer;
    padding: 1rem 1.7rem;
    margin-bottom: 4rem;
    background-color: var(--Soft-red);
    color: var(--Very-dark-blue);
    border: 0;
    outline: none;
    text-transform: uppercase;
    letter-spacing: .3rem;
    font-weight: var(--weight-800);
    -webkit-tap-highlight-color: transparent;
}

.main-blog button:hover {
    background-color: var(--Very-dark-blue);
    color: var(--Off-white);
}

.new {
    background-color: var(--Very-dark-blue);
    padding: 2rem 1.2rem;
    margin-bottom: 4rem;
}

.new h2 {
    color: var(--Soft-orange);
    margin-bottom: 2.5rem;
    font-size: 2rem;
}

.new-blog h3 {
    color: var(--Off-white);
    margin-bottom: .5rem;
}

.new-blog p {
    color: var(--Grayish-blue);
    font-size: var(--font-para);
}

.new-blog:not(:last-child)::after {
    content: '';
    display: block;
    height: .05rem;
    margin: 2rem 0;
    background-color: var(--Grayish-blue);
}

.top-blog {
    display: flex;
    gap: 1rem;
    margin-bottom: 2.2rem;
}

.top-blog img {
    width: 6rem;
}

.top-blog h1 {
    color: var(--Soft-red);
    font-size: 2.2rem;
    margin-bottom: .5rem;
}

.top-blog h2 {
    margin-bottom: .8rem;
    font-size: 1rem;
    font-weight: var(--weight-800);
}

.top-blog p {
    font-size: var(--font-para);
    color: var(--Dark-grayish-blue);
}

.menu li a:hover, .top-blog h2:hover {
    color: var(--Soft-red);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.new-blog h3:hover {
    color: var(--Soft-orange);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

@media (min-width: 48rem) {
    .container{
        padding: 5rem 1rem;
    }

    .content {
        max-width: 67rem;
    }

    #menu-btn {
        display: none;
    }

    .content {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: 2fr fit-content;
        gap: 1.5rem;
    }

    .main-blog {
        grid-column: 1 / 2 span;
    }

    .top-blogs {
        display: flex;
        grid-column: 1 / 3 span;
        gap: 2.8rem;
    }

    .blog {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .blog h1 {
        max-width: 14.5rem;
    }

    .blog-content p {
        margin-top: 1.5rem;
        color: var(--Dark-grayish-blue);
    }

    .top-content p {
        max-width: 13rem;
    }

    .menu {
        position: static;
        transform: translateX(0);
        flex-direction: row;
        padding: 0;
        justify-content: right;
    }

    .menu li a {
        color: var(--Dark-grayish-blue);
    }

    .close-menu {
        display: none;
    }
}