/* general styles */
:root {
    --primary-color: #98cecd;
    --secondary-color: #445c82;
    --tertiary-color: #353a4a;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
.section-content {
    width: 80%;
    margin: 60px 15% 60px 5%;
}
.flex-2of2 {
    width: 80%;
    padding: 0 30px;
}
.title-wrapper {
    width: 20%;
    padding-right: 20px;
    border-right: 3px solid var(--secondary-color);
}
.title-wrapper h3 {
    font-size: 35px;
    text-align: right;
    color: var(--secondary-color);
}
/*.section-title {
    width: 33%;
    font-size: 35px;
    text-align: right;
    padding-right: 20px;
    align-self: center;
}*/

/* header and nav section*/
header {
    background-color: var(--tertiary-color);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 5px 20px 10px 0;

}
header h1 {
    line-height: 1.3;
    padding-right: 10px;
    padding-left: 40px;
    font-size: 38px;
    color: var(--tertiary-color);
}
header nav ul {
    display: flex;
    margin-top: 10px;
}
header nav ul li {

    list-style: none;
}
header nav ul li a {
    padding: 5px;
    margin: 0 5px;
    font-weight: bold;
    font-size: 20px;
    color: var(--primary-color);
    text-decoration: none;
    border-bottom: 3px solid var(--primary-color);
}
.name-container {
    background-color: var(--primary-color);
    border-bottom-right-radius: 5px;
    border-top-right-radius: 5px;
}

/* hero and tagline section */
.hero {
    background: url("../images/gh-portfolio-hero.jpg");
    background-size: cover;
    background-position: center;
    display: flex;
    justify-content: space-between;
    height: 350px;
    width: 100%;
}
.hero h2 {
    align-self: flex-end;
    margin: 18px 8px;
    padding: 5px;
    background-color: var(--primary-color);
    font-size: 32px;
    color: var(--tertiary-color);
}
.profile-picture {
    align-self: center;
    margin-left: 18px;
}
.profile-picture img {
    border: 4px solid var(--primary-color);
    border-radius: 150px;
}

/* about me section */
.about-container {
    display: flex;
    justify-content: space-between;
}
.text-wrapper p {
    color: var(--secondary-color);
}

/* work section */
.work-container {
    display: flex;
    justify-content: space-between;
}
.project-grid-container {
    display: flex;
    justify-content: center;
}
.project-grid-wrapper {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    grid-gap: 75px 10px;
}
.project-grid-item {
    position: relative;
    font-size: 0;
}
.project-grid-item::after {
    content: "";
    height: 100%;
    width: 100%;
    background: rgba(68, 92, 130, 0.4);
    position: absolute;
    top: 0;
    left: 0;
    opacity: 1;
    transition: 0.5s;
    pointer-events: none;
}
.project-grid-item:hover::after {
    opacity: 0;
}
.project-grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 3px solid var(--primary-color);
}
.item-title {
    position: absolute;
    padding: 5px;
    bottom: 0;
    font-size: 14px;
    background: var(--primary-color);
    z-index: 10;
}
.item-title h4 {
    font-size: 20px;
    font-weight: bold;
    color: var(--secondary-color);
}
.item-title p {
    color: var(--secondary-color);
}
.item-description {
    position: absolute;
    font-size: 14px;
    width: 100%;
    text-align: center;
    color: black;
    padding: 10px;
}
.item-github {
    position: absolute;
    padding: 5px;
    top: 0;
    right: 0;
    font-size: 14px;
    z-index: 10;
    text-decoration: none;
    color: var(--primary-color);
    background-color: #ff4545;
    border-bottom-left-radius: 5px;
}
.item-github:hover {
    background-color: black;
}
.item-github span {
    padding-left: 7px;
}
.project-grid-item.primary-item {
    grid-column: 1 / span 2;
    grid-row: 1 / span 2;
}

/* contact me section */
.contact-container {
    display: flex;
    justify-content: space-between;
}
.contact-info {
    align-self: center;
}
.contact-info ul {
    display: flex;
    justify-content: space-between;
    width: 85%;
    margin: auto;
}
.contact-info ul li {
    line-height: 1.5;
    border-bottom: 3px solid var(--secondary-color);
    list-style: none;
}
.contact-info ul li a {
    color: var(--tertiary-color);
    text-decoration: none;
    font-weight: bold;
    font-size: 30px;
    padding: 10px 0;
}

 /* media query for non wide-screen monitors*/
 @media screen and (max-width: 1024px) {
    .section-content {
        width: 100%;
        margin: 30px auto;
    }
    .profile-picture img {
        width: 250px;
        height: auto;
    }
    .hero h2 {
        font-size: 30px;
    }
    .item-title h4 {
        font-size: 15px;
    }
    .item-title p {
        font-size: 12px;
    }
}

 /* media query for tablets and smaller */
 @media screen and (max-width: 768px) {
    .section-content {
        margin: 15px auto;
    }
    .flex-2of2 {
        padding: 0;
        margin: 0 auto 30px auto;    
    }
    .title-wrapper {
        padding: 0;
        margin-bottom: 10px;
        width: 100%;
        border-right: none;
    }
    .title-wrapper h3 {
        text-align: center;
        font-size: 54px;
        line-height: 1;
    }
    header h1 {
        line-height: 1;
        font-size: 30px;
    }
    header nav ul {
        margin-top: 5px;
    }
    header nav ul li a {
        font-size: 16px;
        border-bottom: 2px solid var(--primary-color);
    }
    .hero {
        flex-direction: column;
    }
    .profile-picture {
        margin: 18px 0 0 0;
    }
    .hero h2 {
        align-self: center;
        border-radius: 10px;
    }
    .about-container {
        flex-direction: column;
    }
    .work-container {
        flex-direction: column;
        background: linear-gradient(var(--secondary-color), var(--tertiary-color));
        border-top: 6px solid var(--tertiary-color);
        border-bottom: 6px solid var(--secondary-color);
    }
    .work-container .title-wrapper h3 {
        color: #fff;
    }
    .project-grid-wrapper {
        grid-template-columns: 1fr;
        grid-template-rows: repeat(6, 1fr);
    }
    .project-grid-item.primary-item {
        grid-column: 1 / 2; 
    }
    .item-title h4 {
        font-size: 18px;
    }
    .item-title p {
        font-size: 14px;
    }
    .item-description {
        font-size: 18px;
        color: white;
    }
    .contact-container {
        flex-direction: column;
        margin-bottom: 30px;
    }
    .contact-info ul {
        flex-direction: column;
    }
    .contact-info ul li {
        border-bottom: 2px solid var(--secondary-color);
        text-align: center;
    }
  }
  
  /* media query for phones and smaller */
  @media screen and (max-width: 480px) {
    .flex-2of2 {
        width: 90%;
    }
    .title-wrapper h3 {
        font-size: 48px;
    }
    header {
        flex-direction: column;
        justify-content: space-between;
        padding: 0 0 10px 0;
    }
    .name-container {
        width: 100%;
        background-color: var(--primary-color);
        text-align: center;
        border-bottom-right-radius: 0;
        border-top-right-radius: 0;
    }
    .name-container h1 {
        font-size: 40px;
    }
    header nav {
            align-self: center;
    }
    header nav ul li a {
        font-size: 20px;
    }
    .hero h2 {
        margin: 0 0 10px 0;
        padding: 5px 10px;
        font-size: 24px;
        text-align: center;
        opacity: 0.8;
    }
  }