@import url('https://fonts.googleapis.com/css2?family=Barlow:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');


/* General */
html {
    box-sizing: border-box;
    scroll-behavior: smooth;
}


body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    min-height: 100vh;
    height: auto;
    background-color: rgb(22, 22, 22);
    font-family: 'Barlow', sans-serif;
}

section {
    min-height: 100vh;
}

.section-title h2 {

    font-size: 4rem;
    font-weight: 400;
    color: whitesmoke;
}

/* Navigation */

.menu-icon {
    position: fixed;
    top: 47px;
    left: 15px;
    width: 2rem;
    height: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    z-index: 10;
    cursor: pointer;
}

.menu-icon div {
    height: 0.25rem;
    background-color: white;
    transition: 0.4s;
}

/* Rotate first bar */
.active .bar1 {
    transform: translate(0, 11px) rotate(-45deg);
}

/* Fade out the second bar */
.active .bar2 {
    opacity: 0;

}

/* Rotate last bar  */
.active .bar3 {
    transform: translate(0, -11px) rotate(45deg);
}

.nav-wrapper {
    position: fixed;
    height: 40px;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 10;
    background-color: #023e8a
}

.nav-wrapper h2 {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 1rem;
    position: absolute;
    top: -10%;
    left: 0;
    transform: translate(-50%, -50%);
    color: aliceblue;
    white-space: nowrap;
    text-align: center;
    width: calc(100% - 40px);
    pointer-events: none;
    animation: scrollBanner 40s linear infinite;
}

nav {
    height: 100vh;
    color: whitesmoke;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 2;
    width: 200px;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    opacity: 0;

}

nav ul {
    display: flex;
    flex-direction: column;
    list-style: none;
    align-items: center;
    justify-content: center;
    height: 85%;
    font-size: 2rem;
    color: aliceblue;
}

nav ul li {
    margin: 1rem 0;
}

nav a {
    text-decoration: none;
    color: whitesmoke;

    &:hover {
        padding-bottom: 5px;
        border-bottom: 5px solid white;
        border-radius: 10px;
    }
}

.active {
    transform: translateX(0);
}

#nav.active {
    opacity: 1;
}

*/

/* Home Section SlideShow */
#home {
    display: grid;
    place-items: center;
}

.slideshow {
    width: 100vw;
    height: 100vh;
    position: relative;
    overflow: hidden;
}

.slideshow::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, .4);
    pointer-events: none;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 2s;
}

.slideshow img.active {
    opacity: 1;
}

/* Title */

.page-title {
    position: absolute;
    top: 45%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    text-align: center;
}

.page-title h1 {

    color: white;
    font-size: 5rem;
    margin: 0;
    font-weight: 200;
}

/* scroll down animation */

.mouse {
    width: 40px;
    height: 80px;
    border: 3px solid whitesmoke;
    position: absolute;
    border-radius: 60px;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.mouse::before {
    content: '';
    width: 12px;
    height: 12px;
    position: absolute;
    top: 10px;
    left: 40%;
    transform: translatex(-50);
    background-color: white;
    opacity: 1;
    border-radius: 50%;
    animation: wheelAnimation 2s infinite;


}

@keyframes wheelAnimation {
    to {
        opacity: 0;
        top: 60%;
    }
}

/* About session -------------------------------------------*/
.section-title h2 {
    font-weight: 500;
}

.about-container {
    display: grid;
    place-items: center;
}

.about-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: auto;
    grid-gap: 10px;
    width: 50vw;
    color: white;


    .box1 {
        grid-area: 1 / 1 / 3 / 3;
    }

    .box2 {
        grid-area: 3 / 1 / 5 / 2;
    }

    .box3 {
        grid-area: 3 / 2 / 5 / 3;
    }

    .box4 {
        grid-area: 5 / 1 / 7 / 2;
    }

    .box5 {
        grid-area: 5 / 2 / 7 / 3;
    }

    .box6 {
        grid-area: 7 / 1 / 9 / 3;
    }
}

.about-grid div {
    background: #023e8a;
    display: grid;
    place-items: center;
    line-height: 1.5;
}

.text-box {
    box-sizing: border-box;
    width: 70ch;
    padding: 70px;
}

.icon-box {
    padding: 20px;
    text-align: center;
    color: black;
}

.icon-box i {
    font-size: 50px;
}

.icon-box:nth-child(2) {

    background: #0077B6;
}

.icon-box:nth-child(3) {

    background: #CAF0F8;
}

.icon-box:nth-child(4) {

    background: #ADE8F4;
}

.icon-box:nth-child(5) {

    background: #48CAE4;
}

/* Projects ------------------*/
.projects-container {
    text-align: center;
    margin-bottom: 100px;
    padding-top: 25px;
}

.projects-grid {
    display: grid;
    grid: 20px;
    margin: 0 20%;
}

/* mobile view 1 column */
.projects-grid {
    grid-template-columns: 1fr;
}

/* Tablet view: 2 column of 3 */

@media only screen and (min-width: 768px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* desktop view view: 3 column of 2 */

@media only screen and (min-width: 1025px) {
    .projects-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.grid-items {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}


.grid-items img {
    height: 400px;
    max-width: 200px;
    cursor: pointer;
}

.mockup {
    transition: transform 0.2s;

    &:hover {
        transform: scale(1.05);
    }
}

.github-link,
.live-link {
    margin-top: 8px;
    padding: 6px 12px;
    border: 1px solid rgba(14, 67, 107, 0.639);
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    color: white;

    &:hover {
        background-color: rgba(14, 67, 107, 0.639);
    }
}

/* Contact Section */

#contact {
    background: url(layered-waves-haikei-2.svg);
    color: white;
    background-repeat: no-repeat;
    background-size: cover;
}

.contact-container {
    position: relative;
    display: grid;
    place-items: center;
    height: 100vh;
}

.banner-link {
    display: block;
    height: 50px;
    width: 100%;
    position: relative;
    text-decoration: none;
    color: white;
}

.banner {
    position: absolute;
    left: 50%;
    transform: translateX(-50%) rotate(-5deg);
    width: 100vw;
    max-width: 100vw;
    bottom: 10%;
    height: 50px;
    background-color: #023e8a;
    overflow: hidden;
    transform-origin: 0 100%;
    display: flex;
    align-items: center;

    &:hover {
        background-color: #0077B6;
    }
}

.contact-container h2 {
    position: absolute;
    top: 2%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    width: 100%;
}

.banner-content {
    white-space: nowrap;
    display: inline-block;
    position: absolute;
    left: 0;
    animation: scrollBanner 60s linear infinite;
    transition: font-size .3s ease-in-out;
    font-size: 1rem;

    &:hover {
        font-size: 1.5rem;

    }
}

@keyframes scrollBanner {
    0% {
        transform: translate(0);
    }

    100% {
        transform: translate(-50%);
    }
}

.contact-message {
    margin-right: 50px;
}

/* Footer */

footer {
    position: relative;
}

.social-media-icons {
    position: absolute;
    display: flex;
    justify-content: center;
    width: 100%;
    font-size: 30px;
    bottom: 60px;
    text-decoration: none;
}

.social-media-icons i {
    cursor: pointer;
    text-decoration: none;

    &:hover {
        transform: scale(1.1);
    }
}

.social-media-icons :not(:first-child) {
    margin-left: 10px;
}

footer small {
    position: absolute;
    bottom: 20px;
    text-align: center;
    width: 100%;
    color: white;
}

/* media queries ------------------------------------------------------- */
/* All Mobile Devices */
@media screen and (max-width: 1180px) {
    html {
        scroll-behavior: auto;
    }

    nav {
        width: 100%;
        background: black;
    }
}

/* Tablet Vertical (Large) */
@media screen and (orientation: portrait) and (max-width: 1180px) {
    .about-grid {
        width: 83 vw;
    }

    .text-box {
        width: 75ch;
        padding: 70px;
    }

    .projects-grid {
        margin: 0 10%;
    }

    .banner {
        transform: translateX(-50%) rotate(0deg);
    }
}

/* Tablet Horizontal (Large) */

@media screen and (min-width: 800px) and (max-width: 1180px) {
    .about-grid {
        width: 83vw;
    }

    .projects-grid {
        margin: 0 10%;
    }

    .text-box {
        width: 75ch;
        padding: 60px;
    }
}

/* Tablet Mini */

@media (min-width: 700px) and (max-width: 800px) {

    html {
        overflow-x: hidden;
    }

    .about-container {
        position: relative;
        left: 48px;
    }

    .projects-container {
        place-content: center;
    }

    .banner {
        width: 126vw;
        max-width: 130vw;
    }


    .about-grid {
        position: relative;
        width: 88vw;
        left: -48px;
    }

    .slideshow {
        width: 114vw;
    }

    #contact {
        place-content: center;
    }

    .mouse {
        left: 53%;
    }


    .about-container .section-title h2 {
        position: relative;
        left: -25px;
    }
}

/* Smartphone Horizontal */

@media only screen and (max-width: 844px) {
    .page-title h1 {
        font-size: 3rem;
    }
}

.about-grid h3 {
    border-bottom: double 5px #38312f;
    place-items: center;
}