@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&family=Oxanium:wght@200..800&display=swap');

:root {
    --nav-height: 100px;
    --hero-height: 500px;
    --color-light50: #E9ECF1;
    --color-light40: #BEC8D6;
    --color-light30: #94A5BC;
    --color-light20: #6A83A2;
    --color-light10: #3F6289;
    --color-primary: #004470;
    --color-dark10: #0B385B;
    --color-dark20: #102D47;
    --color-dark30: #102234;
    --color-dark30-transparent: #102234C9;
    --color-dark40: #0E1721;
    --color-dark50: #050A0F;
    --color-accent-light: #8D512D;
    --color-accent: #702D00;
    --color-accent-dark: #5C2602;
    --line-height: 1.618;
    font-size: clamp(16px, 15px + 0.390625vw, 50px);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    padding: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Oxanium', sans-serif;
}

.noselect {
    user-select: none;
}

.explore-button {
    background-color: var(--color-accent);
    color: var(--color-light50);
    text-decoration: none;
    width: fit-content;
    padding: 10px 20px;
    align-self: flex-end;
    cursor: pointer;

    &:hover {
        background-color: var(--color-accent-dark);
    }
}

nav {
    --list-gap: 20px;
    --nav-padding: 10px;
    --line-height: calc(var(--nav-height) - (2 * var(--nav-padding)));

    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    gap: var(--list-gap);
    height: var(--nav-height);
    padding: var(--nav-padding);
    background-color: var(--color-dark30-transparent);
    backdrop-filter: blur(10px);
    z-index: 100;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    font-family: 'Oxanium', sans-serif;

    @media (max-width: 768px) {
        height: fit-content;
        align-items: flex-start;
    }

    a {
        color: var(--color-light50);
        font-weight: bold;
        font-size: 0.8rem;
        text-decoration: none;
        position: relative;
        line-height: var(--line-height);
    }

    .logo {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: var(--list-gap);

        img {
            display: block;
            height: var(--line-height);
        }
    }

    ul {
        display: flex;
        flex-direction: row;
        gap: var(--list-gap);
        align-items: start;
        list-style: none;
        margin: 0;
        padding: 0;

        @media (max-width: 768px) {
            flex-direction: column;
            flex: 1;
            align-items: flex-end;

            li:first-child {
                height: var(--line-height);
                display: flex;
                align-items: center;
            }

            li:not(:first-child) {
                display: none;
            }
        }

        a {
            padding: var(--nav-padding) 0;

            &:before {
                position: absolute;
                content: '';
                bottom: 0;
                left: 0;
                width: 0;
                height: 3px;
                background-color: var(--color-accent-light);
                transition: all 0.3s ease-out 0s;
            }

            &:hover {
                color: var(--color-light40);

                &:before {
                    width: 100%;
                }
            }
        }
    }

    label[for="hamburger"] {
        display: none;
        font-weight: bold;
        font-size: 0.8rem;

        .hamburger-bar {
            width: 30px;
            height: 2px;
            background-color: var(--color-light50);
            display: block;
            margin: 5px 0;
            position: relative;
            transition: all 0.3s ease-out 0s;
        }

        @media (max-width: 768px) {
            display: list-item;
            text-align: end;
        }
    }


    #hamburger {
        display: none;

        &:checked ~ ul {

            li:first-child {

                .hamburger-bar:nth-of-type(1) {
                    transform: rotate(45deg);
                    top: 7px;
                }

                .hamburger-bar:nth-of-type(2) {
                    opacity: 0;
                }

                .hamburger-bar:nth-of-type(3) {
                    transform: rotate(135deg);
                    top: -7px;
                }
            }

            li:not(:first-child) {
                display: list-item;

                a {
                    line-height: 2rem;
                }
            }
        }
    }
}

footer {
    --footer-padding-lg: 48px;
    --footer-padding-sm: 24px;
    width: 100%;

    a {
        color: var(--color-light50);
    }

    a:visited {
        color: var(--color-light50);
    }

    ul {
        list-style: none;
        margin: 0;
        padding: 0;

        li {
            padding: 5px 0;
        }
    }

    .grid {
        padding: 20px var(--footer-padding-lg);
        display: flex;
        flex-direction: row;
        gap: 20px;
        justify-content: space-between;
        background-color: var(--color-dark40);
        color: var(--color-light50);

        @media (max-width: 768px) {
            padding: 20px var(--footer-padding-sm);
            flex-direction: column;
        }
    }

    .copyright {
        padding: 20px var(--footer-padding-lg);
        background-color: var(--color-dark50);
        color: var(--color-light50);
        text-align: center;

        @media (max-width: 768px) {
            padding: 20px var(--footer-padding-sm);
        }
    }
}

#index-page {
    margin: 0;
    padding: 0;
    color: var(--color-dark30);

    .hero {
        padding: 0 2rem;
        background: #FFF;
        background: linear-gradient(0deg, rgba(255, 255, 255, 1) 0%, var(--color-dark30) 75%);
        color: var(--color-light50);

        .overlay-text {
            max-width: 600px;
            margin: auto;
            padding: 8rem 0 2rem 0;
        }
    }

    .categories {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
        padding: 0 6rem 4rem;

        @media (max-width: 768px) {
            grid-template-columns: 1fr;
            padding: 0 0 4rem;
        }

        .category {
            display: flex;
            flex-direction: column;
            justify-content: space-between;
            padding: 20px 40px;
            background-color: var(--color-dark30);
            color: var(--color-light50);
        }
    }

    .featured {
        padding: 2rem 0 0;

        h1 {
            margin-left: 4rem;

            @media (max-width: 768px) {
                margin-left: 0;
                text-align: center;
            }
        }

        .products {
            .product {
                --section-height: 500px;

                display: flex;
                flex-direction: row;
                gap: 2rem;
                justify-content: space-between;
                min-height: var(--section-height);

                &:nth-child(even) {
                    flex-direction: row-reverse;

                    @media (max-width: 768px) {
                        flex-direction: column;
                    }
                }

                @media (max-width: 768px) {
                    flex-direction: column;
                }

                .image {
                    flex: 1.4;
                    height: var(--section-height);
                    overflow: hidden;

                    img {
                        width: 100%;
                        height: 100%;
                        object-fit: cover;
                        object-position: center;
                    }
                }

                .details {
                    flex: 1;
                    padding: 2rem;

                    .small-title {
                        display: flex;
                        align-items: center;
                        gap: 1rem;
                        font-size: small;
                        font-weight: 600;
                        color: var(--color-accent);

                        &::before,
                        &::after {
                            content: "";
                            flex: 1;
                            height: 1px;
                            background: var(--color-accent-light);
                        }
                    }
                }
            }
        }
    }
}