:root {
    --primary-color: #1E1E1E;
    --secondary-color: #E4E4E4;
    --tertiary-color: #7e7e7e;
    --accent-color: #D5FD02;
    --font-family-primary: 'Tektur';
    --font-family-secondary: 'Fira Mono', monospace;
    --font-size-xxl: 7.5rem;
    --font-size-xl: 5rem;
    --font-size-l: 4.5rem;
    --font-size-m: 3rem;
    --font-size-s: 1.8rem;
    --font-size-xs: 1rem;
    --font-size-xxs: 0.8rem;
}

* {
    margin: 0;
    padding: 0;
    /* border: 1px solid pink; */
}

body {
    background-color: var(--primary-color);
    display: flex;
    justify-content: center;

    @media screen and (max-width:1080px) {
        margin: 16px 32px;
    }
}

main {
    width: 900px;
    margin-top: 24px;

    @media screen and (max-width:1080px) {
        width: 100%;
    }
}

section {
    padding: 40px 40px;

    @media screen and (max-width:1080px) {
        padding: 20px 20px;
    }
}

h2 {
    line-height: 0.8;
    color: var(--secondary-color);
    font-family: var(--font-family-primary);
    font-size: var(--font-size-xxl);
    font-weight: 900;
}

h3 {
    color: var(--primary-color);
    font-family: var(--font-family-primary);
    font-size: var(--font-size-m);
    font-weight: 900;
}

header {
    list-style: none;
    font-family: var(--font-family-primary);
    font-size: var(--font-size-s);
    color: var(--secondary-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 2px solid var(--tertiary-color);
    padding: 8px 40px;

    @media screen and (max-width:1080px) {
        padding: 8px 20px;
    }

    #modal-menu {
        position: absolute;
        transition: opacity 0.3s ease-in-out;
        opacity: 0;
        height: 100%;
        width: 100%;
        z-index: 9;
        display: none;
    }

    #modal-menu.opened {
        position: fixed;
        overflow-y: hidden;
        display: block;
        height: 100%;
        width: 100%;
        background-color: var(--primary-color);
        z-index: 9;
        top: 0;
        left: 0;
        display: flex;
        justify-items: center;
        align-items: center;
        justify-content: center;
        opacity: 1;
    }

    .menu {
        background-color: transparent;
        border: none;
        cursor: pointer;
        display: flex;
        padding: 0;
        z-index: 10;
        position: relative;
        display: none;

        @media screen and (max-width:1080px) {
            display: block;
        }

    }

    .menu.opened{
        position: fixed;
        right: 55px;
        top: 50px;
    }

    .menu-modal-list{
        list-style: none;
        font-size: var(--font-size-m);
       
    }

    .line {
        fill: none;
        stroke: var(--secondary-color);
        stroke-width: 6;
        transition: stroke-dasharray 600ms cubic-bezier(0.4, 0, 0.2, 1),
            stroke-dashoffset 600ms cubic-bezier(0.4, 0, 0.2, 1);
    }

    .line1 {
        stroke-dasharray: 60 207;
        stroke-width: 6;
    }

    .line2 {
        stroke-dasharray: 60 60;
        stroke-width: 6;
    }

    .line3 {
        stroke-dasharray: 60 207;
        stroke-width: 6;
    }


    .opened .line1 {
        stroke-dasharray: 90 207;
        stroke-dashoffset: -134;
        stroke-width: 6;
    }

    .opened .line2 {
        stroke-dasharray: 1 60;
        stroke-dashoffset: -30;
        stroke-width: 6;
    }

    .opened .line3 {
        stroke-dasharray: 90 207;
        stroke-dashoffset: -134;
        stroke-width: 6;
    }

}

a {
    text-decoration: none;
    color: var(--secondary-color);
    text-decoration: none;
}

a:hover {
    color: var(--accent-color);
}

nav {

    ul {
        list-style: none;
        display: flex;
        justify-content: flex-end;
        gap: 40px;
        width: 500px;
    }

    @media screen and (max-width:1080px) {
        display: none;
    }
}

/*HERE BEGINS HERO SECTION*/

.hero {
    border: 2px solid var(--tertiary-color);
    position: relative;
    margin-top: 16px;


    span {
        font-size: var(--font-size-xs);
        font-family: var(--font-family-secondary);
        color: var(--secondary-color);
        text-align: center;
        margin-top: 24px;
    }

    a {
        color: var(--accent-color);
        cursor: pointer;
    }


    h1 {
        position: absolute;
        z-index: 7;
        font-family: var(--font-family-primary);
        color: var(--secondary-color);
        font-size: var(--font-size-xl);
        max-width: calc(100% - 150px);
        left: 72px;
        top: 48px;

        @media screen and (max-width:1080px) {
            font-size: var(--font-size-m);
        }

        @media screen and (max-width:600px) {
            font-size: var(--font-size-s);
            left: 32px;
            top: 32px;
        }
    }

    video {
        width: 100%;
        filter: grayscale();
        margin-bottom: 8px;
    }

    span {
        font-size: var(--font-size-xs);
        font-family: var(--font-family-secondary);
        color: var(--secondary-color);
        text-align: center;
        margin-top: 24px;
    }

    a {
        color: var(--accent-color);
        cursor: pointer;
    }
}


/*HERE BEGINS BIO SECTION*/

.bio {

    border: 2px solid var(--tertiary-color);
    color: var(--secondary-color);
    font-family: var(--font-family-secondary);
    gap: 48px;
    margin-top: 16px;

    .title {
        text-align: left;
        width: 100%;

        h2 {
            @media screen and (max-width:1080px) {
                font-size: var(--font-size-l)
            }

            @media screen and (max-width:600px) {
                font-size: var(--font-size-m)
            }
        }

    }

    .bio-caption {
        display: flex;
        flex-direction: column;
        text-align: justify;
        word-spacing: -5px;
    }

    .cv-container {
        display: flex;
        gap: 24px;
    }

    .bio-container {
        display: flex;
        flex-direction: row;
        margin-top: 40px;
        gap: 48px;

        @media screen and (max-width:1080px) {
            flex-direction: column;
        }
    }

    .portrait-pic {
        width: 100%;
        height: 100%;
        max-width: 450px;
        align-self: center;
    }
}

.btn-download-cv {
    all: unset;
    padding: 4px;
    width: 150px;
    border-radius: 8px;
    border: 2px solid var(--secondary-color);
    color: var(--secondary-color);
    font-family: var(--font-family-secondary);
    font-size: var(--font-size-xs);
    text-align: center;
    cursor: pointer;
    margin-top: 24px;
    transition: all .3s ease-in-out;

    &:hover {
        color: var(--primary-color);
        border: 2px solid var(--accent-color);
        background-color: var(--accent-color);
        transform: scale(1.1);
    }
}

h2 {
    display: flex;
    justify-content: flex-start;
    color: var(--secondary-color);
    margin: 0;
}


/*AQUI EMPIEZA LA SECCION PROYECTOS*/

.projects {
    border: 2px solid var(--tertiary-color);
    margin-top: 16px;

    .title {
        text-align: left;
        width: 100%;

        h2 {
            @media screen and (max-width:1080px) {
                font-size: var(--font-size-l)
            }

            @media screen and (max-width:600px) {
                font-size: var(--font-size-m)
            }
        }
    }
}

.projects-container {
    display: flex;
    flex-direction: row;
    color: var(--secondary-color);
    font-family: var(--font-family-secondary);
    gap: 48px;
    margin-top: 40px;

    @media screen and (max-width:1080px) {
        flex-direction: column;
    }
}

.project-caption {
    width: 400px;
    display: flex;
    flex-direction: column;
    text-align: justify;
    word-spacing: -5px;

    @media screen and (max-width:1080px) {
        width: 100%;
    }
}


.social-media-links li {
    display: inline-block;
    max-width: 40px;
    margin-top: 24px;
    margin-right: 8px;
}

.social-media-links {
    
    img {
        max-width: 24px;
    }

    svg {

        &:hover {
            path {
                fill: var(--accent-color);
            }

            transform: scale(1.1);
        }
    }

}

.projects-portfolio-links {
    display: flex;
    flex-direction: column;
    gap: 20px;

    li {
        list-style: none;
        display: flex;
        color: var(--secondary-color);
        font-family: var(--font-family-secondary);
        font-size: var(--font-size-m);
        cursor: pointer;
        gap: 8px;
        line-height: 1;

        @media screen and (max-width:1080px) {
            gap: 12px;
            align-items: center;
        }
    }

    span {
        font-family: var(--font-family-primary);
        font-size: var(--font-size-m);
        color: var(--tertiary-color);
        min-width: 88px;
    }

    a {
        width: 260px;
        text-align: left;

        &:hover {
            color: var(--accent-color);
        }

        @media screen and (max-width:1080px) {
            width: 180px;
            text-align: start;
            font-size: var(--font-size-s);
            
        }
    }
}

/*HERE PEDAGOGIC SECTION*/

.pedagogic {
    border: 2px solid var(--tertiary-color);
    margin-top: 16px;

    h2 {
        @media screen and (max-width:1080px) {
            font-size: var(--font-size-l)
        }

        @media screen and (max-width:600px) {
            font-size: var(--font-size-m)
        }
    }

    .pedagogic-caption {
        margin-top: 8px;
    }

    p {
        color: var(--secondary-color);
        font-family: var(--font-family-secondary);
        font-size: var(--font-size-xs)
    }
}


.title-codepen {
    font-weight: 500;
    font-size: var(--font-size-s);
    margin-top: 32px;
}


/*AQUI EMPIEZA LA SECCION CONTACTOS*/

.contact {
    display: flex;
    flex-direction: column;
    border: 2px solid var(--tertiary-color);
    margin-top: 16px;


    .title {
        text-align: left;
        width: 100%;

        h2 {
            @media screen and (max-width:1080px) {
                font-size: var(--font-size-l)
            }

            @media screen and (max-width:600px) {
                font-size: var(--font-size-m)
            }
        }
    }

    p {
        font-size: var(--font-size-xs);
        font-family: var(--font-family-secondary);
        color: var(--secondary-color);
        margin-top: 24px;
    }
}

.heart-container {
    display: flex;
    flex-direction: column;

    span {
        font-size: var(--font-size-xs);
        font-family: var(--font-family-secondary);
        color: var(--secondary-color);
        text-align: center;
        margin-top: 24px;
    }

    @media screen and (max-width:1080px) {
        align-items: center;
    }

    a {
        color: var(--accent-color);
        cursor: pointer;
    }

}

.contact-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    margin-top: 24px;
    gap: 48px;

    img {
        width: 346px;
        animation: heart-pulse 3s infinite;

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

    @media screen and (max-width:1080px) {
        flex-direction: column;
    }

}

@keyframes heart-pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }

}

form {
    border: 2px solid var(--secondary-color);
    border-radius: 8px;
    min-width: 380px;
    display: flex;
    flex-direction: column;
    font-size: var(--font-size-xs);
    font-family: var(--font-family-secondary);
    color: var(--secondary-color);
    padding: 16px;
    gap: 8px;

    @media screen and (max-width:1080px) {
        width: calc(100% - 32px);
        min-width: unset;
    }

    input,
    textarea {
        border-radius: 8px;
        background-color: var(--background-color);
        border: 2px solid var(--tertiary-color);
        height: 26px;
        padding: 4px;
        color: var(--secondary-color);
    }

    #message-box {
        height: 150px;
        text-align: initial;
    }

    #btn-submit {
        all: unset;
        padding: 4px;
        width: 180px;
        border-radius: 8px;
        border: 2px solid var(--secondary-color);
        color: var(--secondary-color);
        font-family: var(--font-family-secondary);
        font-size: var(--font-size-xs);
        text-align: center;
        cursor: pointer;
        margin-top: 8px;
        transition: all .3s ease-in-out;
        align-self: center;

        &:hover {
            color: var(--primary-color);
            border: 2px solid var(--accent-color);
            background-color: var(--accent-color);
            transform: scale(1.1);
        }
    }

}


footer {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    padding: 40px 40px 24px 40px;
    margin-top: 16px;
    margin-bottom: 16px;
    border: 2px solid var(--tertiary-color);

    @media screen and (max-width:600px) {
       flex-direction: column;
    }

    .contact-info {
        font-family: var(--font-family-secondary);
        font-size: var(--font-size-xs);
        color: var(--secondary-color);

        li {
            list-style: none;
            display: flex;
            gap: 16px;
            margin-bottom: 16px;

            img {
                max-width: 24px;
            }

        }
    }

    .networking-container {
        font-family: var(--font-family-secondary);
        font-size: var(--font-size-xs);
        color: var(--secondary-color);
        text-align: right;

        @media screen and (max-width:600px) {
            text-align: left;
        }

        ul {
            list-style: none;
            display: flex;
            flex-direction: row;
            gap: 16px;
            margin-bottom: 16px;
            margin-top: 16px;

            @media screen and (max-width:600px) {
                justify-content: left;
                }


            img {
                max-width: 24px;
            }

            svg {

                &:hover {
                    path {
                        fill: var(--accent-color);
                    }

                    transform: scale(1.1);
                }
            }
        }
    }
}