*,
*::before,
*::after {
    box-sizing: border-box;
}

:root {
    --ff-comforta: 'Comfortaa';
    --ff-sans: 'Source Code Pro', sans-serif;

    --fw-reg: 300;
    --fw-bold: 900;

    --color-bg: #fff;
    --color-txt: #303030;
    --color-accent: #16e0bd;

    --fs-h1: 3rem;
    --fs-h2: 2.25rem;
    --fs-h3: 1.25rem;
    --fs-body: 1rem;

    --boxshadow: 0.25em 0.25em 0.75em rgba(0,0,0,.25),
                 0.125em 0.125em 0.25em rgba(0,0,0,.15);
}

@media (min-width: 800px) {
    :root {
        --fs-h1: 4.5rem;
        --fs-h2: 3.75rem;
        --fs-h2: 1.5rem;
        --fs-body: 1.125rem;
    }
}

/*general*/

html {
    scroll-behavior: smooth;
}

body {
    background: var(--color-bg);
    color: var(--color-txt);
    margin: 0;
    font-family: var(--ff-comforta);
    font-size: var(--fs-body);
    line-height: 1.6;
}

section {
    padding: 5em 2em;
}

img {
    display: block;
    max-width: 100%;
}

strong {
    font-weight: var(--fw-bold);
}

:focus {
    outline: 3px solid var(--color-accent);
    outline-offset: 3px;
}

.btn {
    display: inline-block;
    padding: 0.5em 2.5em;
    background: var(--color-accent);
    color: var(--color-txt);
    text-decoration: none;
    cursor: pointer;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight:  var(--fw-bold);
    transition: transform 200ms ease-in-out;
}

.btn:hover {
    transform: scale(1.1);
}

/* typography */


h1,
h2,
h3 {
    line-height: 1;
    margin: 0;
}

h1 { font-size: var(--fs-h1)}
h2 { font-size: var(--fs-h2)}
h3 { font-size: var(--fs-h3)}

.section_title {
    margin-bottom: 0.25em;
}

.section_title--intro {
    font-weight: var(--fw-reg);
}

.section_title--intro strong {
    display: block;
}

.section_title--work {
    margin-bottom: 1em;
}

.section_subtitle {
    margin: 0;
    font-size: var(--fs-h3);
}

.section_subtitle--intro,
.section_subtitle--about {
    background: var(--color-accent);
    padding: .25em 1em;
    font-family: var(--ff-sans);
    margin-bottom: 0.1em;
}

.section_subtitle--work {
    color: var(--color-accent);
    font-weight: var(--fw-bold);
    margin-bottom: 2em;
}

/* header */

header {
    display: flex;
    justify-content: space-between;
    padding: 1em;
}

.logo {
    max-width: 100px;
}

.nav {
    position: fixed;
    background: var(--color-txt);
    opacity: .95;
    color: var(--color-bg);
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
    transform: translateX(100%);
    transition: transform 250ms cubic-bezier(0.5, 0, 0.5, 1);
}

.nav_list{
    list-style: none;
    display: flex;
    height: 100%;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav_link {
    color:inherit;
    font-weight: var(--fw-bold);
    font-size: var(--fs-h2);
    text-decoration: none;
}

.nav_link:hover {
    color: var(--color-accent);
}

.nav-toggle {
    padding: .5em;
    background: transparent;
    border: 0;
    cursor: pointer;
    position: absolute;
    right: 1em;
    top: 1em;
    z-index: 1000;
}

.nav-open .nav{
    transform: translateX(0);
}

.nav-open .nav-toggle {
    position: fixed;
}

.nav-open .hamburger{
    transform: rotate(.625turn);
}

.nav-open .hamburger::before {
    transform: rotate(90deg) translateX(-6px);
}

.nav-open .hamburger::after {
    opacity: 0;
}



.hamburger {
    display: block;
    position: relative;
}

.hamburger,
.hamburger::before,
.hamburger::after {
    background: var(--color-accent);
    width: 2em;
    height: 3px;
    border-radius: 1em;
    transition: transform 250ms ease-in-out;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
}

.hamburger::before {
    top: 6px;
}

.hamburger::after {
    bottom: 6px;
}

/* Intro */

.intro {
    position: relative;
}

.intro_img {
    box-shadow: var(--boxshadow);
}

.section_subtitle--intro {
    display: inline-block;
}

@media (min-width: 600px) {
    .intro {
        display: grid;
        width: min-content;
        margin: 0 auto;
        grid-column-gap: 1em;
        grid-template-areas:
            "img title"
            "img subtitle";
        grid-template-columns: min-content max-content;
    }

    .intro_img {
        grid-area: img;
        min-width: 250px;
        position: relative;
        z-index: 2;
    }

    .section_subtitle--intro {
        align-self: start;
        grid-column: -1 / 1;
        grid-row: 2;
        text-align: right;
        position: relative;
        left: -4em;
        width: calc(100% + 10em);
    }
}

/* skills section */

.my-skills {
    background-color: var(--color-txt);
    background-image: url(../assets/skills_bg.png);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    background-blend-mode: multiply;
    color: var(--color-bg);
    text-align: center;
}

.section_title--skills {
    color: var(--color-accent);
    position: relative;
}

.section_title--skills::after {
    content: '';
    display: block;
    width: 2em;
    height: 1px;
    margin: 0.5em auto 1em;
    background: var(--color-bg);
    opacity: 0.25;
}

.skills {
    margin-bottom: 4em;
}

.skill {
    max-width: 500px;
    margin: 0 auto;
}

@media (min-width: 800px) {
    .skills {
        display: flex;
        max-width: 1000px;
        margin-left: auto;
        margin-right: auto;
    }

    .skill {
        max-width: 33%;
    }

    .skill + .skill {
        margin-left: 2em;
    }
}

/* about me */ 

.about-me {
    max-width: 1000px;
    margin: 0 auto;
}

.about-me_img {
    box-sizing: var(--boxshadow);
}

@media (min-width: 825px) {
    .about-me{
        display: grid;
        grid-template-columns: 1fr 300px;
        grid-template-areas: 
            "title img"
            "subtitle img"
            "text img";
        grid-column-gap: 2em;
    }

    .section_title--about {
        grid-area: title;
    }

    .section_subtitle--about{
        grid-column: 1 / -1;
        grid-row: 2;
        position: relative;
        left: -1em;
        width: calc(100% + 2em);
        padding-left: 1em;
        padding-right: calc(200px + 2em);
    }

    .about-me_img {
        grid-area: img;
        position: relative;
        z-index: 2;
    }
}

/* my work */

.my-work {
    background-color: var(--color-txt);
    color: var(--color-bg);
    text-align: center;
}

.mySlides {
    display: none;
}

.slide {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    max-width: 0 auto;
    grid-column-gap: 2em;

}

.project-description {
    margin-top: 1em;
}


.prev, .next {
    cursor: pointer;
    position: absolute;
    top: auto;
    width: auto;
    padding: 16px;
    color: white;
    font-weight: bold;
    font-size: 18px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
}

.prev {
    left: 0;
    border-radius: 3px 0 0 3px;
}

.next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.prev:hover, .next:hover {
    background-color: rgba(0,0,0,0.8);
}

.dot {
    cursor: pointer;
    height: 15px;
    width: 15px;
    margin: 0 2px;
    background-color: #bbb;
    border-radius: 50%;
    display: inline-block;
    transition: background-color 0.6s ease;
  }

.dots {
    margin-top: 2em;
}

.active, .dot:hover {
    background-color: #717171;
}

.fade {
    animation-name: fade;
    animation-duration: 1.5s;
}
  
@keyframes fade {
    from {opacity: .4}
    to {opacity: 1}
}

  
/* 
.portfolio {
    display: grid;
    grid-template-columns: repeat(3, 1fr); makes 3 columns 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    max-width: 0 auto;
} 
*/


/* footer */

.footer {
    background: var(--color-bg);
    color: var(--color-accent);
    text-align: center;
    padding: 2.5em 0;
    font-size: var(--fs-h3);
}

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

.footer_link {
    font-weight: var(--fw-bold);
}

.footer_link:hover,
.social-list_link:hover {
    opacity: .7;
}

.footer_link:hover{
    text-decoration: underline;
}

.social-list {
    list-style: none;
    display: flex;
    justify-content: center;
    padding: 0;
}

.social-list_item {
    margin: 0 1.5em;
}

.social-list_link:hover {
    transform: scale(1.2);
    opacity: 0.5;
}

.social-list_link {
    padding: .5em;
}