/* GDES306 | MMDD253 - Coding Your Portfolio     */
/* Extra small devices (phones, less than 600px) */
/* No media query since this is the default CSS */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600&display=swap');
/* Basic page styling */
:root {
    /* These are global variables that you can use in your CSS */
    --black: black;
    --dark-grey: #333;
    --mid-grey: #666;
    --light-grey: #999;
    --white: white;
    --accent-colour: rgb(24, 181, 221);
    --headline-font: 'Merriweather', serif; /* Fonte para cabeçalhos */
    --body-font: 'Avenir', 'Avenir Next', 'Nunito', sans-serif; /* Fonte Open Sans para o corpo do texto */
    --horizontal-shift: 6px;
    --section-padding-top: 60px
}

* {
    margin: 0;
    padding: 0;
    transition: 0.5s;
}


a {
    font-size: calc(16px + (20 - 16) * (100vw - 400px) / (1800 - 400));
    text-decoration: none;
    color: var(--black);
}

a:visited {
    color: var(--black);
}

.btn {
    background-color: var(--accent-colour);
    /* Azul */
    color: var(--black);
    /* Texto preto */
    border: none;
    padding: 15px 32px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: calc(16px + (20 - 16) * (100vw - 400px) / (1800 - 400));
    width: fit-content;
}

.btn:hover {
    background-color: var(--black);
    /* Preto */
    color: var(--white);
    /* Texto branco */
    padding-left: calc(32px + var(--horizontal-shift));
}

.btn:visited {
    color: var(--black);
}

.btn:hover:visited {
    color: var(--white);
}


/* Styling the Navigation */
header {
    position: fixed;
    width: 100%;
    z-index: 10;
}

nav {
    overflow: hidden;
    background: var(--white);
    height: auto;
}


nav ul {
    display: flex;
    list-style-type: none;
    flex-wrap: wrap;
    text-align: center;
}

nav ul>li {
    margin-top: 14px;
    flex-basis: 100%;
}

nav ul li a {
    text-decoration: none;
    color: var(--black);
    margin: 20px;
}

nav ul li a:hover {
    text-decoration: none;
    color: var(--dark-grey);
    background: var(--accent-colour);
}

#logo {
    margin-right: auto;
    flex-basis: auto; /* melhor que 50% para mobile */
    text-align: left;
}

#logo img {
    height: 3rem;       /* altura padrão */
    width: auto;
    max-width: 100%;    /* não ultrapassa o contêiner */
    object-fit: contain; /* garante que a logo não corte */
}

/* Mobile e pequenas telas */
@media (max-width: 600px) {
    #logo img {
        height: 2rem;        /* reduz ainda mais a altura para caber na barra */
        width: auto;         /* mantém a proporção */
        max-width: 100%;     /* garante que não ultrapasse o contêiner */
    }
}



#menu-icon {
    margin-left: auto;
    flex-basis: 50%;
    text-align: right;
    font-size: 40px;
    margin-top: 0px;
}

#close-icon {
    display: none;
}

.navexpanded #close-icon {
    display: inline-block;
}

.navexpanded #menu-icon {
    display: none;
}


#logo a:hover,
#menu-icon a:hover #close-icon a:hover {
    background: none;
}


/* Styling the Navigation  Substituiu ??? */
nav {
    background: var(--white);
    height: 60px;
    overflow: hidden;
}

.navexpanded {
    height: auto;
}


/* Styling for the Sections */
section {
    display: grid;
    min-height: calc(100vh - var(--section-padding-top));
    padding-top: var(--section-padding-top);
    grid-template-columns: 5% 1fr 5%;
    align-content: start;
}

section>* {
    grid-column: 2;
}

#introduction {
    align-content: center;
    height: 100vh;
    padding-top: 0;
    color: black; /* Cor inicial para todo o texto */
}

@import url('https://fonts.googleapis.com/css2?family=Merriweather:wght@700&italic=true&display=swap');

/* Aplica a fonte Merriweather no h1 da introdução */
#introduction h1 {
    font-family: 'Merriweather', serif;
    font-weight: 800; /* Peso Bold */
    opacity: 0;
    transition: opacity 1s
}

#introduction .btn {
    opacity: 0; /* Inicialmente invisível */
    transition: opacity 2s ease-in-out 1s; /* Transição suave com atraso para o botão */
}

#introduction .highlight {
    color: black;
    animation: colorChange 4s ease-in-out 2s forwards; /* Atraso de 1 segundo */
}



@keyframes colorChange {
    0% {
        color: black; /* Cor inicial (preto) */
    }
    50% {
        color: var(--accent-colour); /* Cor no meio da animação */
    }
    100% {
        color: var(--accent-colour); /* Cor final */
    }
}

/* Small devices (i.e. tablets in portrait) */
@media (min-width: 600px) {
    .navexpanded #close-icon {
        display: none;
    }

    nav {
        height: auto;
    }

    nav ul {
        flex-direction: row;
        align-items: baseline;
    }

    nav ul>li {
        flex-basis: auto;
    }

    #logo {
        flex-basis: auto;
    }

    #menu-icon {
        display: none;
    }
}

section {
    grid-template-columns: 15% 1fr 15%;
}



/* Medium devices (i.e. tablets in landscape */
@media (min-width: 900px) {


    body, p, ul, ol, li {
        font-family: var(--body-font);
    }

    h1, h2, h3, h4, h5, h6 {
        font-family: var(--headline-font);
    }

    h1 {
        font-size: calc(26.67px + (48 - 26.67) * (100vw - 400px) / (1800 - 400));
        margin-bottom: 3rem;
    }

    h2 {
        font-size: calc(32px + (48 - 32) * (100vw - 400px) / (1800 - 400));
        margin-bottom: 1.5rem;
    }

    h3 {
        font-size: calc(20px + (28 - 20) * (100vw - 400px) / (1800 - 400));
    }

    li, p {
        font-size: 18px; /* ou outro valor desejado */
        line-height: 1.6;
    }

}

/* Large devices (i.e. desktop) */

@media (min-width: 1200px) {}

/* X-Large devices (i.e. big desktop) */

@media (min-width: 1800px) {}


/* Styling the Sections */

img {
    width:100%;
    }


.two-columns {
    display: grid;
    grid-template-columns: 1fr;
    grid-gap: 2rem;
    margin-bottom: 2rem;
}

/* Small devices (i.e. tablets in portrait) */
@media (min-width: 600px) {
    .two-columns {
        grid-template-columns: 1fr 1fr;
    }
}

.featured {
    grid-column: 1/-1;
    /*This Class can be used to stretch an item the entire width of the parent grid */
}

/* Styling for the Portfolio Section */
#portfolio a:hover h3,
#portfolio a:hover p {
    padding-left: var(--horizontal-shift);
}

.two-columns-fixed {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-gap: 2rem;
    margin-bottom: 2rem;
}

#about ul {
    list-style: none;
}

/* Styling the Contact section */
#contact {
    min-height: auto;
}

#contact ul {
    display: flex;
    list-style-type: none;
    margin-bottom: 1rem;
}

#contact ul li a {
    text-decoration: none;
    color: var(--accent-colour);
    margin: 0 20px 0 0;
    font-size: 32px;
}

#contact ul li a:hover {
    text-decoration: none;
    color: var(--mid-grey);
}

/* Styling to make a dark the colour scheme. Add this class to a section */
.dark-colours {
    background: var(--black);
    color: var(--white);
}

.dark-colours a {
    color: var(--white);
}

.dark-colours a:visited {
    color: var(--white);
}

.dark-colours .btn {
    color: var(--black);
    background: var(--white);
}

.dark-colours .btn:hover {
    color: var(--black);
    background: var(--accent-colour);
}

#about .intro-paragraph {
    font-size: calc(20px + (28 - 20) * (100vw - 400px) / (1800 - 400));
    grid-column: 1/-1;
}

.three-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-gap: 2rem;
    margin-bottom: 2rem;
}

@media (min-width: 600px) {
    .three-columns {
        grid-template-columns: 1fr 1fr 1fr;
    }
}

.auto-height {
    min-height: auto;
}

html {
    scroll-behavior: smooth;
}

