/* Structure */
:root {
    --primary-color: #3498db; /* Primary color for accents */
    --secondary-color: #f4f4f4; /* Light background color */
    --text-color: #333; /* Dark text color */
    --footer-color: #2c3e50; /* Footer background */
}

body {
    font-family: 'Open Sans', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    background-color: var(--secondary-color);
    color: var(--text-color);
    margin: 0;
    padding: 0;
}

a {
    text-decoration: none;
    color: var(--primary-color);
}

a:hover {
    color: darkblue;
}

header, footer {
    background-color: var(--footer-color);
    color: white;
    padding: 20px 0;
    text-align: center;
}

/* Logo */
#logo {
    float: left;
    height: 75px;
    width: 75px;
    position: absolute;
    top: 10px;
    left: 10px;
}

/* Navigation */
#main-nav {
    display: flex;
    justify-content: center;
    background-color: var(--footer-color);
    padding: 10px 0;
    position: relative;
}

#main-nav ul {
    display: flex;
    justify-content: center;
    padding: 0;
    list-style: none;
    margin: 0;
}

#main-nav li {
    margin-right: 20px;
}

#main-nav a {
    font-size: 1.2rem;
    color: white;
    padding: 10px 15px;
}

#main-nav a:hover {
    background-color: #2980b9;
    border-radius: 5px;
}

/* Typography */
main {
    padding: 20px;
    text-align: center;
}

header h1 {
    text-align: center;
}

footer p {
    text-align: center;
}

/* Left Layout */
.left-layout {
    display: flex;
    flex-wrap: wrap; /* Allow wrapping on small screens */
    align-items: center;
    justify-content: center;
    gap: 20px; /* Space between image and text */
    padding: 20px;
}

h2, p {
    text-align: center;
}

#toggle-nav div {
    width: 25px;
    height: 2px;
    background-color: black;
    margin: 6px 0;
}

.hide-small {
    display: none;
}

/* Image Styling */
.image-container {
    width: 50%; /* Takes up about 2/3 of the area */
}

img {
    width: 100%;
    max-width: 400px; /* Ensure image doesn't exceed a max width */
    height: auto;
}

.image-container img {
    border-radius: 5px;
}

/* Text Styling */
.text-container {
    width: 50%; /* Takes up about 1/3 of the area */
    text-align: left;
}

.text-container h2 {
    margin-bottom: 10px;
    font-size: 24px;
    color: #333;
}

.text-container p {
    font-size: 16px;
    color: #555;
    margin-bottom: 10px;
}

/* Responsive Design for Smaller Devices */
@media only screen and (max-width: 768px) {
    #main-nav ul {
        display: none; /* Hide the normal nav */
    }

    #toggle-nav {
        display: block; /* Show the hamburger menu */
        cursor: pointer;
    }

    #toggle-nav div {
        width: 30px;
        height: 3px;
        background-color: white;
        margin: 5px 0;
    }

    /* Show the mobile menu when toggled */
    .show-nav {
        display: flex !important; /* Ensure the menu appears */
        flex-direction: column;
        position: absolute;
        top: 70px;
        right: 0;
        background-color: var(--footer-color);
        width: 100%;
        padding: 10px 0;
    }

    .show-nav li {
        margin: 0;
        padding: 10px;
        text-align: center;
    }

    .show-nav a {
        padding: 10px;
        font-size: 1.2rem;
        color: white;
    }

    .show-nav a:hover {
        background-color: #2980b9;
        border-radius: 5px;
    }

    /* Stack the image and text vertically on smaller screens */
    .left-layout {
        flex-direction: column; /* Stack image and text */
        gap: 10px;
    }

    .image-container,
    .text-container {
        width: 100%; /* Full width for both on small screens */
    }
}

/* Larger screens (min-width: 768px) */
@media only screen and (min-width: 768px) {
    /* Hide hamburger menu on larger screens */
    #toggle-nav {
        display: none;
    }

    /* Ensure the regular navigation menu is displayed */
    #main-nav ul {
        display: flex;
    }

    /* Make sure the layout is still responsive for larger screens */
    .left-layout {
        flex-direction: row; /* Align items horizontally */
    }

    .image-container,
    .text-container {
        width: 45%; /* Adjust the width for each container */
    }
}
