@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600&family=PT+Serif:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Lora:wght@400;700&family=Roboto:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Merriweather:wght@400;700&family=Montserrat:wght@400;700&display=swap');

* {
    margin: 0;
    padding: 0;
    font-family: 'Montserrat', sans-serif;
    box-sizing: border-box;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Roboto', serif;
}

.text-content, .about-content {
    color: #000 !important;
}

:root {
    --background-color: #fff;
    --text-color: #000;
    --accent-color: #4CAF50;
    --header-bg: #dff0db;
    --header-text-color: #000;
    --main-text-color: #000;
    --main-h1-color: #000;
}

.dark-theme {
    --background-color: #000;
    --main-h1-color: #fff;
    --text-color: #fff;
    --accent-color: #4CAF50;
    --title-color: #4CAF50; 
}

body {
    background-color: var(--background-color);
    color: var(--text-color);
    transition: background 0.8s, color 0.8s;
}

h1, h2 {
    color: var(--accent-color);
}

/* HEADER */
.header {
    width: 100%;
    min-height: auto;
    padding: 0; 
    position: fixed;
    overflow: hidden;
    border-bottom: #000 solid 1px;
    z-index: 1;

    & nav {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 10px 20px;
        background-color: var(--header-bg);
        flex-wrap: wrap;

        & .logo img {
            width: 120px;
        }

        & ul {
            display: none; 
            flex-direction: column;
            width: 100%;
            list-style: none;
            padding: 0;
            margin: 0;
        
            & li {
                margin: 10px 0;
        
                & a {
                    text-decoration: none;
                    color: var(--header-text-color);
                    font-weight: 500;
                    font-size: 18px;
                }
            }
        }

        & .menu-toggle {
            display: block; 
            background: none;
            border: none;
            font-size: 24px;
            color: var(--header-text-color);
            cursor: pointer;
        }
    }

    & .toggle-btn {
        background: var(--accent-color);
        color: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 80px;
        height: 40px;
        border-radius: 20px;
        cursor: pointer;

        & img {
            width: 30px;
        }
    }
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.container-content {
    width: 100%;
    text-align: center;
    margin-bottom: 2rem;

    & h1 {
        font-size: 40px;
        font-family: serif;
        color: var(--main-h1-color);
        font-weight: 600;
        margin: 0;

        & span {
            font-family: serif;
            font-weight: 600;
            color: var(--accent-color);
        }
    }

    & p {
        font-size: 16px;
        margin: 20px 0;
    }

    & a {
        background: var(--accent-color);
        color: #fff;
        padding: 10px 30px;
        border-radius: 30px;
        cursor: pointer;
        display: inline-block;
        margin-top: 20px;
        text-decoration: none;
    }
}

.image-box {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    position: relative;

    & img#logo-box {
        width: 100%;
        height: auto;
        z-index: -2;
    }

    & .pattern {
        position: absolute;
        top: 20%;
        left: 50%;
        display: flex;
        transform: rotate(40deg);
        z-index: -2;
        scale: 1.2;

        & img {
            filter: sepia(1000%) hue-rotate(100deg) saturate(450%);
            width: 150px;
            position: absolute;
            top: 0;
            left: 0;
            animation: move 1s infinite alternate-reverse;
            animation-delay: 1.5s;

            &:nth-child(1) {
                transform: rotate(-45deg) translate(-35px, -75px);
            }

            &:nth-child(2) {
                transform: rotate(65deg) translate(-35px, -20px) scale(0.8);
            }
        }
    }
}

/* MAIN */
main {
    width: 100%;         
    max-width: 100%;   
    margin: 0 auto;    
    align-items: center;
}

.home, .about {
    background-color: var(--header-bg);
    color: var(--hearder-text-color);
    margin-bottom: 1rem;
    padding: 3rem 4rem;

    & h2 {
        text-align: center;
        margin-bottom: 2rem;
        font-size: 30px;
        color: var(--accent-color);
    }

    & .home-content, & .about-content {
        display: flex;
        flex-direction: column;
        align-items: center;

        & img {
            width: 100%;
            max-width: 500px;
            height: auto;
            border-radius: 8px;
            box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
            margin-bottom: 1rem;
        }
    
        & .text-content {
            width: 100%;
            max-width: 600px;
            text-align: justify;
            font-size: 16px;

            & ul {
                list-style-type: disc;
                padding-left: 20px;
                margin: 1rem 0;
            }
        
            & li {
                margin-bottom: 1rem;
            }
        
            & p {
                margin-bottom: 1.5rem;
                line-height: 1.6;
            }
        }
    }
}

/* PRODUCTS */
.products {
    padding: 2rem 1rem;
    scale: 1;

    & h2 {
        text-align: center;
        margin-bottom: 2rem;
        font-size: 30px;
        color: var(--accent-color);
    }

    & .products-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 2rem;
        justify-content: center;
        max-width: 1200px;
        margin: 0 auto;
    }

    & .product-item {
        background-color: var(--bg-color);
        border: 1px solid var(--accent-color);
        border-radius: 8px;
        padding: 1.5rem;
        text-align: center;
        transition: transform 0.3s ease;

        &:hover {
            transform: translateY(-5px);
        }
        
        & h3 {
            color: var(--accent-color);
            margin-bottom: 0.5rem;
            font-size: 20px;
        }
        
        & p {
            font-size: 14px;
        }

        & img {
            width: 100%;
            max-height: 100%;
            height: auto;
            margin-bottom: 1rem;
            border-radius: 8px;
            object-fit: cover;
            box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
        }
    }
}

/* TEAM */
.team {
    padding: 2rem 1rem;

    & h2 {
        text-align: center;
        margin-bottom: 2rem;
        font-size: 30px;
        color: var(--accent-color);
    }

    & .team-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 2rem;
        justify-content: center;
        max-width: 1200px;
        margin: 0 auto;
    }

    & .team-member {
        background-color: var(--bg-color);
        border: 1px solid var(--accent-color);
        border-radius: 8px;
        padding: 1.5rem;
        text-align: center;
        transition: transform 0.3s ease;

        &:hover {
            transform: translateY(-5px);
        }

        & img {
            width: 100%;
            max-width: 70%;
            height: auto;
            border-radius: 8px;
            margin-bottom: 1rem;
        }

        & h3 {
            color: var(--accent-color);
            margin-bottom: 0.5rem;
            font-size: 18px;
        }

        & p {
            font-size: 14px;
        }
    }
}

/* FOOTER */
.footer {
    background-color: var(--header-bg);
    color: var(--hearder-text-color);
    padding: 1rem;  
    text-align: center;

    & h1 {
        margin-bottom: 0.5rem;
        font-size: 24px;
    }

    & p {
        font-size: 14px;
        color: var(--main-text-color);
    }
}

/* ANIMATIONS */
@keyframes move {
    100% {
        margin-left: 20px;
        margin-top: 10px;
        opacity: 0.3;
    }
}

/* Media Queries for Responsiveness */
@media (min-width: 768px) {
    .container {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding-top: 150px;
    }

    .container-content {
        width: 50%;
        text-align: left;
        margin-right: 2rem;
    }

    .image-box {
        width: 50%;
    }

    .home, .about {
        & .home-content, & .about-content {
            flex-direction: row;
            justify-content: space-between;
            align-items: flex-start;

            & img {
                margin-right: 2rem;
                margin-bottom: 0;
            }

            & .text-content {
                max-width: 60%;
            }
        }
    }

    .products, .team {
        & .products-grid, & .team-grid {
            grid-template-columns: repeat(3, 1fr);
        }
    }
}

/* FOOTER */
.footer {
    background-color: var(--header-bg);
    color: var(--header-text-color);
    padding: 1rem;  
    text-align: center;

    & h1 {
        margin-bottom: 0.5rem;
        font-size: 24px;
    }

    & p {
        font-size: 14px;
        color: var(--main-text-color);
    }
}

/* ANIMATIONS */
@keyframes move {
    100% {
        margin-left: 40px;
        margin-top: 20px;
        opacity: 0.3;
    }
}

/* Media Queries for Responsiveness */
@media (min-width: 768px) {
    .header {
        & nav {
            & ul {
                display: flex !important; 
                flex-direction: row;
                width: auto;
                justify-content: flex-end;
            
                & li {
                    margin: 0 15px;
                }
            }

            & .menu-toggle {
                display: none; 
            }
        }
    }

    .container {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding-top: 150px;
    }

    .container-content {
        width: 50%;
        text-align: left;
        margin-right: 2rem;
    }

    .image-box {
        width: 50%;
    }

    .home, .about {
        & .home-content, & .about-content {
            flex-direction: row;
            justify-content: space-between;
            align-items: flex-start;

            & img {
                margin-right: 2rem;
                margin-bottom: 0;
            }

            & .text-content {
                max-width: 60%;
            }
        }
    }

    .products, .team {
        & .products-grid, & .team-grid {
            grid-template-columns: repeat(3, 1fr);
        }
    }
}

@media (min-width: 1024px) {
    .container-content {
        & h1 {
            font-size: 60px;
        }

        & p {
            font-size: 18px;
        }
    }

    .home, .about, .products, .team {
        & h2 {
            font-size: 40px;
        }
    }

    .home, .about {
        & .text-content {
            font-size: 18px;
        }
    }

    .products {
        & .product-item {
            & h3 {
                font-size: 22px;
            }

            & p {
                font-size: 16px;
            }
        }
    }

    .team {
        & .team-member {
            & h3 {
                font-size: 20px;
            }

            & p {
                font-size: 16px;
            }
        }
    }

    .footer {
        & h1 {
            font-size: 28px;
        }

        & p {
            font-size: 16px;
        }
    }
}