/* Google fonts import */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100;0,9..40,200;0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;0,9..40,800;0,9..40,900;0,9..40,1000;1,9..40,100;1,9..40,200;1,9..40,300;1,9..40,400;1,9..40,500;1,9..40,600;1,9..40,700;1,9..40,800;1,9..40,900;1,9..40,1000&family=DM+Serif+Display:ital@0;1&display=swap');

/* Asterisk wildcard selector overriding default browser styles - written with help from Love Running project */
* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

/* General  styles */
body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    /* Generic project styles */
    color: #000000;
    font-family: 'DM Sans', sans-serif;
}

h1, h2, h3, h4 {
    font-family: 'DM Serif Display', serif;
}

/* Header */
header {
    background-color: #ffffff;
    padding: 0 1rem;
    position: fixed;
    z-index: 99;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header a {
    text-decoration: none;
    color: inherit;
}

#menu {
    font-size: 110%;
    list-style-type: none;
    margin-top: 15px;
}

#menu>li {
    margin-bottom: 1em;
}

.active {
    border-bottom: 1px solid #000000;
}

/* Navbar styles with dropdown toggle - styles created with help from Love Running */
nav {
    position: absolute;
    background-color: #ffffff;
    width: 100%;
    left: 0;
    padding: 0 1rem;
    display: none;
    top: 100%;
}

/* Nav toggle - styles created with help from Love Running */
#nav-toggle:checked~nav {
    display: block;
}

#nav-toggle {
    display: none;

}

.nav-toggle-label {
    font-size: 2rem;
}

/* Homepage */
/* Main Content */
main {
    /* Main element will take up surplus space to push the footer down */
    flex: 1 0 auto;
    margin-top: 100px;
    /* Enable flex properties for child elements */
    display: flex;
    flex-direction: column;
}

/* Hero image for homepage */
#hero {
    height: 75vh;
    width: 100%;
    background: url(../images/hero1.webp) no-repeat top/cover;
    position: relative;
}

#cover-text {
    /* Final RGB value used to set opacity */
    background-color: rgba(0, 0, 0, 0.31);
    font-size: 90%;
    color: #ffffff;
    position: absolute;
    bottom: 130px;
    min-width: 25%;
    min-height: 100px;
    padding-top: 30px;
    padding-right: 10px;
    padding-left: 10px;
}

/* About Page */
#about {
    padding: 20px;
}

#about-content {
    text-align: left;
}

.about-headings {
    text-align: left;
}

.about-images {
    width: 280px;
    padding-bottom: 10px;
    padding-right: 20px;
}

/* Portfolio Page */
#hidden-heading {
    display: none;
}

#photos img {
    width: 100%;
    line-height: 1em;
    padding: 5px;
}

#photos {
    padding: 5px;
    line-height: 0;
}

/* Contact Page and Contact Form */
#contact {
    height: 75vh;
    width: 100%;
    background: url(../images/hero2.webp) no-repeat top/cover;
    position: relative;
    padding: 10px 10% 0 10%;
}

#contact-form {
    color: #ffffff;
    background-color: rgba(0, 0, 0, 0.31);
    border-radius: 5px;
    padding: 30px;
}

#contact-form>h2 {
    background-color: rgba(0, 0, 0, 0.11);
    text-transform: uppercase;
    text-align: center;
    font-weight: 500;
    font-size: larger;
    margin-bottom: 10px;
    border-radius: 5px;
}

.text-input {
    width: 100%;
    height: 25px;
    margin: 5px 0 20px 0;
    border: 1px solid black;
    border-radius: 5px;
    padding: 0 5px;
}

#message {
    height: 60px;
}

.submit-button {
    border-radius: 5px;
    padding: 10px 30px;
    background-color: rgba(247, 243, 243, 0.301);
    color: #ffffff;
}

/* Thanks Page */
#thanks-image {
    height: 75vh;
    width: 100%;
    background: url(../images/thanks.webp) no-repeat center/cover;
    position: relative;
    padding: 10px 10% 0 10%;
}

#thanks-text {
    /* Final RGB value used to set opacity */
    background-color: rgba(0, 0, 0, 0.31);
    font-size: 110%;
    color: #ffffff;
    position: absolute;
    bottom: 160px;
    left: 0px;
    min-width: 25%;
    min-height: 100px;
    padding: 10px
}

/* Footer */
#social-networks {
    text-align: center;
    padding: 20px 0;
    display: flex;
    justify-content: space-evenly;
    list-style-type: none;
}

#social-networks i {
    font-size: 140%;
    padding: 5%;
}

/* Media query: small phones (320px) */
@media screen and (max-width: 320px) {
    #logo {
        font-size: 210%;
    }
}

/* Media query: medium and larger phones (320px and up) */
@media screen and (min-width: 320px) {
    /* About page */
    .about-images {
        width: 100%;
        padding-right: 5px;
    }
}

/* Media query: large or landscape phones (576px and up) */
@media screen and (min-width: 576px) {
    #photos {
        column-count: 2;
        column-gap: 0;
    }

}

/* Media query: tablets and larger (768px and up) */
@media screen and (min-width: 768px) {

    /* Header */
    nav {
        display: block;
        position: relative;
        width: fit-content;
        padding-right: 1rem;
    }

    #menu {
        display: flex;
    }

    #menu>li {
        padding-left: 1rem;
    }

    .nav-toggle-label {
        display: none;
    }

    #logo {
        font-size: 280%;
        line-height: 75px;
        margin: 0 0.5rem;
    }

    /* About Page */
    #about {
        padding-left: 28%;
        padding-right: 28%;
    }

    #about-content {
    text-align: justify;
    }
    
    .about-headings {
    text-align: center;
    }

    /* Portfolio */
    #photos {
        column-count: 3;
        width: 100%;
    }

    /* Contact Form */
    #contact {
        position: relative;
    }

    #contact-form {
        max-width: 400px;
        position: absolute;
        left: 10%;
        top: 100px;
    }

    .text-input:hover {
        border-color: #6593f7;
    }

    .submit-button:hover {
        border-color: #6593f7;
        background-color: #fafafa;
        color: rgba(0, 0, 0, 0.31);
    }
}

/* Large devices (laptops and desktops 992px and up) */
@media screen and (min-width: 992px) {
    #menu a:hover {
        border-bottom: 1px solid #000000;
    }

    /* About Page */
    #about-heading {
        font-size: xx-large;
        text-align: center;
    }

    /* Portfolio */
    #photos {
        column-count: 5;
        width: 100%;
    }

    /* Thanks Page */
    #thanks-text {
        bottom: 200px;
    }
}