* {
    font-family: "Courier New"
}

body {
    margin: auto 10em;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-direction: row;
}

h1 {
    font-size: 3em;
}

h2 {
    font-size: 1.5em;
}

p {
    font-size: 1em;
}

#burger {
    display: none;
}

#burger:hover {
    cursor: pointer;
}

figcaption {
    font-size: 0.9em;
}

header+hr {
    margin-top: -0.5em;
    margin-bottom: 3em;
}

.nav a {
    font-size: 1em;
}

ul.navbar {
    list-style-type: none;
    display: flex;
    gap: 1em;
    padding-left: 0;
    align-items: center;
    font-size: 1.1em;
}



.navbar>li {
    text-align: center;
}

.navbar>li>a {
    color: black;
    text-decoration: none;
}

.navbar>li>a.active {
    text-decoration: underline;
    font-weight: bold;
}

.navbar .separator {
    width: 1px;
    height: 1em;
    background: black;
}

.portfolio-grid {
    /* width: 80%; */
    margin-top: 3em;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1em;
}

.portfolio-grid li {
    list-style-type: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(0, 0, 0, 0.449);
    box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.2);
}

.portfolio-grid>li>.no-img>* {
    margin: 0;
    font-size: 90%;
}

.portfolio-grid>li>.no-img>p {
    font-size: 80%;
    color: rgba(0, 0, 0, 0.7);
    margin-top: 0.5em;
}


.portfolio-grid img {
    width: 100%;
    border-bottom: 1px solid rgba(0, 0, 0, 0.328);
}

.portfolio-grid .no-img {
    background: rgba(0, 0, 0, 0.128);
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    padding: 1em;
    padding-top: 0.5em;
}

.portfolio-grid>li:hover {
    transform: scale(1.03);
    transition: transform 0.3s ease;
    box-shadow: 8px 8px 8px rgba(0, 0, 0, 0.5);
}

figure {
    margin: 2em 0;
    text-align: center;
}

figcaption {
    margin-top: 0.5em;
    font-style: italic;
    color: #666;
}

#contact-form {
    width: 50%;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 1em;
}

#contact-form>* {
    display: flex;
    justify-content: left;
}

#contact-form>#submit {
    display: flex;
    text-align: center;
    justify-content: center;
    gap: 0.5em;
    width: 100%;
    text-align: center;
    align-items: center;
    background: rgb(10, 173, 10);
    color: rgba(255, 255, 255, 0.888);
    border-radius: 3px;
    border: 1px solid rgb(5, 100, 5);
    font-weight: bold;
}

#contact-form>#submit:hover {
    cursor: pointer;
    transform: scale(1.05);
    box-shadow: 3px 3px 3px rgba(0, 0, 0, 0.3);
}

#contact-form>#submit svg {
    width: 16px;
}

#contact-form textarea {
    min-height: 100px;
    overflow-y: auto;
}

table,
th,
tr,
td {
    border: 1px solid black;
    border-collapse: collapse;
    padding: 0.3em;
    margin: auto;
}

#cv>section {
    background-color: rgba(0, 0, 0, 0.01)
}

#cv>section:nth-child(even) {
    background-color: rgba(0, 0, 0, 0.1);
}

#cv>section {
    padding: 1em;
    padding-top: 0.1em;
}

@media screen and (max-width: 1100px) {
    body {
        margin: auto 1em;
        padding: 0.5em 1em;
    }

    header {
        flex-direction: column;
    }

    .navbar .separator {
        display: none;
    }

    ul.navbar {
        font-size: 1.3em;
        /* Increase font size for better readability on mobile */
    }

    @media screen and (max-width: 600px) {

        header {
            display: grid;
            grid-template-areas: "h1 burger" "navbar navbar";
        }

        ul.navbar {
            grid: "navbar";
            display: flex;
            flex-direction: column;
            align-items: flex-start;
        }

        .navbar>li {
            font-size: 0.8em;
        }

        hr {
            width: 100%;
        }

        h1 {
            grid: "h1";
            font-size: 2em;
        }

        #burger {
            grid: "burger";
        }

        #burger {
            display: block;
            transition: transform 0.3s ease;
        }

        #burger.active {
            transform: rotate(90deg);
        }

        ul.navbar:not(.visible) {
            display: none;
        }

        .navbar.visible {
            animation: slideDown 0.3s ease-out forwards;
            transform-origin: top;
        }

        @keyframes slideDown {
            0% {
                transform: scaleY(0);
                opacity: 0.5;
            }

            100% {
                transform: scaleY(1);
                opacity: 1;
            }
        }

        ul.navbar {
            display: flex;
            flex-direction: column;
        }


        .portfolio-grid {
            display: flex;
            flex-direction: column;

        }

    }


}

@media print {

    /* header {
        flex-direction: column;
    } */
    h1 {
        font-size: 2em;
    }

    ul.navbar {
        gap: 0.5em;
    }

    body {
        margin: 1em;
    }

    a[href^="http"]::after {
        content: "(" attr(href) ")";
    }
}

@page {
    margin: .8in 0.5in;
}