@font-face {
    font-family: bold1;
    src: url(fonts/Agdasima/Agdasima-Bold.ttf);
}

@font-face {
    font-family: minuscolo;
    src: url(fonts/static/Arima-SemiBold.ttf);
}
@font-face {
    font-family: nunito;
    src: url(fonts/Nunito/NunitoSans-VariableFont_YTLC\,opsz\,wdth\,wght.ttf);
}
@font-face {
    font-family: monster;
    src: url(fonts/Monsterrat/Montserrat-VariableFont_wght.ttf);
}

html ,
body {
    background-image: url(img/sfondo-w.png);
    object-fit: cover;
    background-repeat: no-repeat;
    margin: 0;
    padding: 0;
    height: 100%;
    position: relative;
    overflow-x: hidden;
}


nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: bold1;
    position: fixed;
    z-index: 21;
    overflow: hidden;
    width: 98%;
}

ul {
    list-style-type: none;
    display: flex;
    justify-content: center;
    flex-direction: row;
    align-items: center;
    padding: 0.5rem;
    display: block;
}

li {
    margin: 5px;
    padding: 8px 12px;
    font-size: 1.3rem;
    list-style-type: none;
    z-index: 20;
    display: block;
}

article {
    height: 60vh;
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    width: 100%;
    flex-direction: column;
    z-index: 3;
    gap: 0;
    margin-top: 3rem;
}
.presentation-container {
    width: 30%;
    margin-top: 5rem;
    margin-left: 20rem;
    padding: 2rem;
    z-index: 5;
}
.presentation-container h2 {
    letter-spacing: 8px;
    text-transform: uppercase;
    font-size: 0.9rem;
    font-weight: 500;
    line-height: 100%;
}
.presentation-container p {
    padding: 0;
    margin: 0;
}
.presentation-container li {
    color: red;
    margin: 0;
    padding: 0;
}
.presentation-container a{
    text-decoration: none;
    cursor: pointer;
    background-color: white;
    border: 3px black solid ;
    font-weight: 700;
    color: black;
    font-family: monster;
    padding: 15px 40px;
    text-align: center;
    position: relative;
    top: 1.5rem;
}
.presentation-container a:hover{
    background-color: #e53838;
    border: 3px #e53838 solid;
    color: white;
}

.style-font {
    position: relative;
    font-family: minuscolo;
    font-size: 2rem;
    z-index: 5;
    width: auto;
}


/* CONTENT  */
main {
    display: block;
    position: static;
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    flex-direction: column;
    margin: 2rem;
    margin-top: 0;
}

.container-cards{
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    flex-direction: column;
}
.title-container{
    font-family: nunito;
    text-transform: uppercase;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.title-container div{
    margin: 10px;
}
.projects-container{
    display: flex;
    align-items: center;
    width: 95%;
    justify-content: center;
    flex-direction: row;
    flex-wrap: wrap;
}
.project{
    width: 50rem;
    height: 25rem;
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-around;
    border-radius: 30px;
    margin: 20px;
    font-family: nunito;
    background-color: white;
}


.project img{
    width: 10rem;
    overflow: hidden;
}
.content-nasa {
    width: 50%;
    height: 80%;
    font-family: 'monster', sans-serif;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    left: -8rem;
    color: white;
    z-index: 100;
}
.content-nasa img {
    position: relative;
    top: 1rem;
    left: 8rem;
    width: 100px;
}
.content-nasa a {
    color: red;
    font-weight: 600;
    text-decoration: none;
}
.content-nasa a:hover {
    text-decoration: underline;
}
.nasa {
    background-image: url('img/cnasa.jpg');
    background-color: black;
    justify-content: center;
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    color: white;
    overflow: hidden;
    text-decoration: none;
    z-index: 10;
}
.nasa-img {
    width: 50%;
    height: 100%;
}
.nasa-img img {
    width: 100%;
}

.project.tesla {
    display: block;
    overflow: hidden;
    background-color: #666672;
    text-decoration: none;
    color: black;
}
.project.tesla:hover {
    cursor: pointer;
}
.tesla-content {
    position: relative;
    left: 6rem; 
    top: 4rem; 
    width: 300px; 
    color: black;
    font-family: monster;
}
.tesla-content a {
    color: red;
    text-decoration: none;
    font-weight: 600;
}
.tesla-content span {
    color: #ff2828;
}
.tesla-content a:hover {
    text-decoration: underline;
}
.tesla-img-container img {
    width: 70%;
    position: relative;
    top: -7rem;
    right: -25rem;
    transition: transform 0.3s ease;
}
.project.tesla:hover .tesla-img-container img {
    transform: scale(1.1);
}


.project.google {
    display: flex;
    overflow: hidden;
    background-color: #32545b;
    color: white;
    text-decoration: none;
}
.project.google:hover {
    cursor: pointer;
}
.google-content {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    width: 50%;
    height: 100%;
    padding: 20px;
    position: relative;
    top: -3rem;
}
.ita-img img {
    width: 394px;
    transition: transform 0.3s ease;
}
.google-content a,
.project.google a {
    color: inherit;
    text-decoration: none;
}
.google-content a:hover {
    text-decoration: underline;
}
.project.google:hover .ita-img img {
    transform: scale(1.1);
}

.project.ristorante {
    display: flex;
    overflow: hidden;
    background-color: #232323;
    color: #e3af60;
    text-decoration: none;
}

.project.ristorante:hover {
    cursor: pointer;
}

.ristorante-content {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    width: 50%; /* Larghezza su schermi grandi */
    height: 100%; /* Altezza fissa */
    padding: 20px;
    position: relative;
    top: -3rem;
}

.ristorante-img {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

.ristorante-img img {
    position: relative;
    top: -1rem;
    width: 394px; /* Larghezza su schermi grandi */
    transition: transform 0.3s ease;
}

.ristorante-content a,
.project.ristorante a {
    color: inherit;
    text-decoration: none;
}

.ristorante-content a:hover {
    text-decoration: underline;
}

.project.ristorante:hover .ristorante-img img {
    transform: scale(1.1);
}


/* FOOTER */
footer{
    margin-top: 5rem;
    height: 30vh;
    width: 100%;
    font-family: monster;
}
footer h1{
    color: red;
    font-size: 4rem;
    letter-spacing: 1rem;
    width: 100%;
}
.end-container{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.button-container{
    margin-top: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}
.button-container button{
    font-family: monster;
    font-weight: 700;
    font-size: auto;
    text-align: center;
    border:none; 
    width: 250px;
    height: 60px;
    margin: 20px; 
    border: 3px black solid;
}
.button-container a button{
    color: white;
    background-color: black;
}
.button-container a{
    text-decoration: none;
}
.button-container button{
    background-color: white;
    color: black;
}
.button-container button:hover{
    background-color: #e53838;
    color: white;
    border: none;
    border: 3px #e53838 solid;
}

.contacts{
    margin-top: 5rem;
}
.contacts ul{
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
}

.contacts li:last-child {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    font-weight: bold;
    width: 27px; 
    height: 35px; 
    border-radius: 50%;
    overflow: hidden;
    transition: background-color 0.3s ease; 
}

.contacts li:last-child:hover {
    color: white;
    background-color: #e53838;
}
.fa-linkedin-in{
    color: white;
}
.contact-list{
    border-bottom:1px rgba(0, 0, 0, 0.5) solid ;
}
.copyrigth{
    display: flex;
    justify-content: flex-end;
    align-items: center;
}
.copyrigth p{
    font-family: monster;
    padding: 10px 20px;
    position: relative;
    right: 0 ;
    font-size: 0.8rem;
}
.pho-container {
    display: flex;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    font-size: 15px;
    font-weight: bold;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    transition: width 0.4s ease, background-color 0.4s ease;
    cursor: pointer;
  }


  .pho-container:hover {
    width: 215px;
    background-color: #e53838;
    border-radius: 25px;
  }
  .pho {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    margin-left: 17px;
  }
  .pho1 {
    opacity: 0;
    transition: opacity 0.2s ease;
    white-space: nowrap;
  }
  .pho-container:hover .pho1 {
    opacity: 1;
    margin-left: -5px;
  }

/* IMMAAGINI SFONDO DA */
.loader {
    position: absolute;
    top: 10rem;
    right: 40rem;
    animation: loader 8s linear infinite;
}

.loader img {
    width: 230px;
}

@keyframes loader {
    100% {
        transform: rotate(360deg);
    }
}

.circle {
    position: absolute;
    z-index: 0;
}

.pos1 {
    top: 5rem;
    left: 44rem;
}

.pos1 img {
    width: 500px;
    opacity: 0.2;
}

.pos2 {
    top: 35rem;
    left: -10rem;
    z-index: 9;
}

.pos2 img {
    width: 400px;
    opacity: 0.2;
}

.pos3 {
    top: -11rem;
    right: -10rem;
}

.pos3 img {
    width: 400px;
    opacity: 0.9;
}

.pos4 {
    top: 18rem;
    right: 10rem;
}

.pos4 img {
    width: 400px;
    opacity: 0.2;
}



@media (max-width: 768px) {
    .title-container{
        display: flex;
        justify-content: center;
        align-items: center;
        margin-top: 60px;
        position: relative;
        left: 1rem;
    }
    article {
        height: auto;
        justify-content: center;
        align-items: center;
        margin-top: 1rem;
        padding: 1rem;
    }
    .circle {
        width: 60px;
        height: 60px;
        margin: 0.5rem auto;
    }
    .circle img {
        width: 100%;
        height: auto;
    }
    .presentation-container {
        width: 90%;
        margin: 5rem auto 0;
        padding: 1rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    .presentation-container h2 {
        font-size: 1rem;
        letter-spacing: 2px;
    }
    .style-font {
        font-size: 1.2rem;
        text-align: center;
    }
    .loader img {
        width: 80px;
        height: auto;
    }
    .presentation-container li {
        font-size: 0.8rem;
        padding: 0.2rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .content-nasa {
        width: 90%;
        height: auto;
        left: 0;
        align-items: center;
        padding: 1rem;
        text-align: center;
    }
    .content-nasa img {
        width: 80px;
        top: 0;
        left: 0;
        margin-bottom: 1rem;
    }
    .nasa {
        background-size: cover;
        background-position: 95%  110px;
    }
    .nasa-img {
        width: 100%;
    }


    .project.google {
        flex-direction: column; 
        align-items: center; 
    }
    .google-content {
        width: 90%; 
        height: auto; 
        top: 0; 
        padding: 10px; 
    }
    .ita-img img {
        display: none;
        width: 100%;
        max-width: 300px; 
    }

    .tesla-content {
        left: 0; 
        top: 0; 
        width: 80%; 
        padding: 10px; 
        text-align: center; 
        margin: 20px;
    }
    .tesla-img-container {
        margin: 0 auto; 
    }
    .tesla-img-container img {
        width: 100%; 
        max-width: 300px; 
        top: -1rem;
        right: -1rem; 
    }

    .ristorante{
        display: flex;
        flex-direction: column;
    }
    .ristorante-content {
        width: 80%;
        top: 0;
        padding: 10px;
        margin: 20px;
        z-index: 30;
    }
    .ristorante-img img {
        width: 100%;
        max-width: 100%; 
        height: auto;
        position: relative;
        top: -3rem;
    }

    footer {
        height: auto; 
        padding: 2rem 0; 
    }
    footer h1 {
        font-size: 1.8rem;
    }
    .button-container a{
        display: flex;
        width: 100%;
        align-items: center;
        justify-content: center;
    }
    .button-container a button {
        display: flex; 
        align-items: center; 
        justify-content: center; 
        padding: 20px; 
        max-width: 300px; 
        width: 80%;
    }
    
    .button-container button {
        width: 80%; 
        max-width: 300px; 
        height: 50px; 
        margin: 10px 0; 
    }
}