*{
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: sans-serif;
    background-color: #e2eaff;
    color: #101632dd;
    overflow-x: hidden;
}

body, div, ul, nav, header, footer, a, li, label {
    margin: 0;
    padding: 0;
}

body {
    background: linear-gradient(-45deg, #aaa, #41045660, #eee, #41045651);
	background-size: 400% 400%;
	animation: gradient 10s ease infinite;
}

/*-------------HEADER SECTION---------------------------*/
.header {
    padding: 0;
    background-color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 10;
    text-align: center;
    font-size: 20px;
    color: #420456;
    height: auto;
}

.header__open-nav-button {
    color: #48e;
    font-size: 3rem;
    font-weight: 600;
    position: absolute;
    right: 10px;
}

.header__checkbox {
    display: none;
}

.header__nav {
    display: none;
    position: absolute;
    height: 50vh;
    min-height: 100px;
    width: 50vw;
    top: 0;
    
    background-color: #fff;
}

.header__nav-list {
    display: flex;
    flex-direction: column;
    height: 40vh;
    margin: auto;
    justify-content: space-evenly;
}

.header__checkbox:checked ~ .header__nav {
    display:flex;
}

.header__logo {
    max-width: 100%;
    width: 64px;
    margin: 10px 20px;
}

.header__nav-item {
    list-style: none;
}

.header__nav-item a {
    color: inherit;
    text-decoration: none;
}

.header__nav-item :is(:hover,:active) {
    text-decoration: underline;
}

/*------------HEADER QUERIES--------------------------*/

@media screen and (min-width: 600px) {
    
    .header{
        padding: 0px;
        height: 50px;
        animation: header-movement both;
        animation-timeline: scroll();
        position: sticky;
        top: 0;
        animation-range: 10px 100px;
    }

    .header__logo {
        animation: cambio-color;
        animation-timeline: scroll();
        animation-duration: .06s;
    }

    .header__nav {
        display: flex;
        position: static;
        height: auto;
        width: auto;
        justify-content: space-between;
        z-index: 1;
        background-color: initial;
    }

    .header__nav-list {
        flex-direction: row;
        height: auto;
        width: auto;
        gap: 20px;
        margin-right: 40px;
    }

    .header__open-nav-button {
        display: none;
    }
}

@media screen and (min-height: 580px){
    .profile-imglogo {
    z-index: 0;
}
}

@media screen and (min-height: 430px){
    .portfolio h2 {
        font-size: 2rem;
    }

    .form {
        height: 85dvh;
    }
}
/*-----------HEADER ENDS--------------------------------*/

/*--------------PROFILE SECTION------------------------*/

.profile {
    container-name: profile;
    container-type: inline-size;
    opacity: 0;
    animation: aparecer 3s both;
}

.profile__wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin: auto;
    background-color: #FFF;
    max-width: 1016px;
    min-height: 600px;
}

@property --angle{
    syntax: "<angle>";
    initial-value: 0deg;
    inherits: false;
}

.animate-bg::before, .animate-bg::after {
    content: "";
    position: absolute;
    border-radius:27px;
    left: calc(110px, 70%, 250px);
    top: 77px;
    background: conic-gradient(from var(--angle),#fff,#f396ff,#790089,#790089,#50005a,#fff,#f396ff,#790089,#790089,#50005a,#fff);
    width: 96.1%;
    height: 78%;
    z-index: -1;
    animation: 4s spin linear infinite;
}

@keyframes spin {
    from{
        --angle: 0deg;
    }
    to{
        --angle: 360deg;
    }
}

.animate-bg::before {
    filter: blur(1.2rem)
}

.profile__data-container {
    padding: 12px;
    z-index: 2;
    overflow: hidden;
    text-align: center;
}

.profile__img-container {
    max-height: 480px;
    min-width: 300px;
    overflow: hidden;
    display: flex;
    justify-content: center;
}

.profile-img {
    filter: blur(6px);
    max-height: 1092px;
}

.profile-imglogo {
    top: 120px;
    position:absolute;
    z-index: 1;
    height: 250px;
}

.profile__description h1 {
        font-size: 1.6rem;
        color: #420456;
        margin-bottom: 40px;
    }

    .profile__description p {
    text-align:justify;
    }

    .p1 {
        color: #420456;
    margin-top: 25px;
    text-align:center;
    }

/*--------------PROFILE QUERIES------------------------*/

@media screen and (min-width: 430px) {
    .profile__data-container {
        padding: 0px 20px;
    }
    .profile__description h1 {
        font-size: 2.2rem;
    }

    .profile__description h2 {
        margin: 0;
        margin-bottom: 8px;    
    }
}

@container profile (min-width: 720px) {
    .profile__wrapper {
        flex-direction: row;
        padding: 80px 20px;
        background-color: transparent;
        margin: auto;
        height: 700px;
    }

    .profile__data-container {
        background-color: #FFF;
        display: flex;
        align-items: center;
        border-radius: 0px 25px 25px 0px;
        min-width: 400px;
        max-width: 620px;
    }

    .profile__img-container {
        max-height: initial;
        border-radius: 25px 0 0 25px;
        min-width: 300px;
        max-width: 350px;
    }

    .profile-img {
        height: auto;
        object-fit: cover;
    }

    .profile-imglogo {
        top: 210px;
    }

    .profile__description h1 {
        margin-top: 0;
        font-size: 2.8rem;
        text-wrap: balance;
    }

    .profile__description h2 {
        margin: 0;
        margin-bottom: 4px; 
    }

    .profile__description p {
        margin: 20px; 
    }

    .p1 {
        font-weight: bold;
        font-size: 1rem;
        text-align: center;
    }

}

/*--------------PORTFOLIO SECTION------------------------*/

.portfolio {
    background-color: #4f0568;
    color: #FFF;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    text-align: center;
    container-name: portfolio;
    container-type: inline-size;
    justify-content: space-evenly;
    padding-top: 50px;
}

.portfolio__title {
    font-size: 3rem;
    margin: 20px;
}

.portfolio__project-container {
    display: grid;
    grid-template-columns: 1fr;
    max-width: 1300px;
    margin: auto;
    width: 100%;
    height: 100%;
    gap: 12px;
    padding: 12px;
    min-height: 80vh;
    margin-top: 0;
    position: relative;
}

.portfolio__project a {
    color: #fff;
    text-shadow: 5px 2px 5px #420456, -5px -2px 5px #420456;
}

.portfolio__project {
    background-image:linear-gradient(to bottom #000, #0009) ,url("imagenes/desa01.jpg");
    background-position: center;
    background-size: cover;
    display: grid;
    place-content: center;
    border-radius: 8px;
    opacity: 0.1;
    animation: aparecer both;
    animation-timeline: view();
    animation-range: contain -25% cover 40%;
    align-content: end;
}

.portfolio__project:first-child {
    background-image:linear-gradient(0deg, #000, #ffffff00, #ffffff00) , url("imagenes/over-cam.png");
    background-position: center;
    background-size: cover;
}

.portfolio__project:nth-child(2) {
    background-image:linear-gradient(0deg, #000, #ffffff00, #ffffff00) ,url("imagenes/rep-pc.png");
    background-position: center;
    background-size: cover;
}

.portfolio__project:nth-child(3) {
    background-image:linear-gradient(0deg, #000, #ffffff00, #ffffff00) ,url("imagenes/TARGIR.png");
    background-position: center;
    background-size: cover;
}

.portfolio__project:nth-child(4) {
    background-image:linear-gradient(0deg, #000, #ffffff00, #ffffff00) ,url("imagenes/Web-herre.png");
    background-position: center;
    background-size: cover;
}

.portfolio__project:nth-child(5) {
    background-image:linear-gradient(0deg, #000, #ffffff00, #ffffff00) ,url("imagenes/menulat.png");
    background-position: center;
    background-size: cover;
}

.portfolio__project:nth-child(6) {
    background-image:linear-gradient(0deg, #000, #ffffff00, #ffffff00) ,url("imagenes/PG1VISTA.png");
    background-position: center;
    background-size: cover;
}

.portfolio__project:hover {
    opacity: 0.75;
    outline: 2px solid #fff6;
}

/*--------------PORTFOLIO QUERIES------------------------*/

@media screen and (min-width: 430px) {
    .portfolio__project a h2 {
        font-size: 1.5rem;
    }
}

@container portfolio (min-width: 56.25rem) {
    .portfolio__project-container {
        grid-template-columns: repeat(auto-fill,minmaxminmax(420px,1fr));
    }

    .portfolio__project:first-child {
        grid-column: span 2;
    }

    .portfolio__project:nth-child(6) {
        grid-column: span 2;
    }

}

@container portfolio (min-width: 81.25rem) {
    .portfolio__project-container {
        grid-template-columns: repeat(auto-fill,minmax(300px,1fr));
    }

    .portfolio__project:first-child {
        grid-column: span 2;
        grid-row: span 2;
    }

    .portfolio__project:nth-child(6) {
        grid-column: span 4;
    }

}

/*--------------CONTACT SECTION------------------------*/

.form {
    opacity: 0;
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 30px 0;
    container-name: form;
    container-type: inline-size;
    animation: aparecer both;
    animation-timeline: view();
    animation-range: cover 10% contain 30%;
}

.form__form {
    padding: 12px;
    max-width: 600px;
    width: 100%;
    display: grid;
    background-image: radial-gradient(#18233f11,#18233f44);
    padding: 30px;
    border-radius: 12px;
}

.form__input-container :is(input, textarea) {
    width: 100%;
    padding: 9px;
    font-size: 16px;
    margin: 4px;
    border: none;
    box-shadow: 2px 2px 4px #1a002234;
    border-radius: 4px;
}

.form__input-container textarea {
    resize: none;
    min-height: 120px;
    font-family: inherit;
}

.form__input-container input[type="submit"] {
    padding: 12px;
    background-color: #420456;
    color: #fff;
}

.form__title {
    font-size: 2.4rem;
}

/*--------------CONTACT SECTION------------------------*/

@container form (min-width: 56.25rem){
    .form__form {
        grid-template-columns: 1fr 1fr;
        grid-template-areas: 
        "name lastname"
        "email email"
        "message message"
        "button button";
        gap: 12px;
        margin-bottom: 120px;
    }

    .form__input-container:first-child{
        grid-area: name;
    }
    .form__input-container:nth-child(2){
        grid-area: lastname;
    }
    .form__input-container:nth-child(3){
        grid-area: email;
    }
    .form__input-container:nth-child(4){
        grid-area: message;
    }
    .form__input-container:nth-child(5){
        grid-area: button;
    }
}

/*--------------CONTACT ENDS------------------------*/

/*--------------FOOTER SECTION------------------------*/

footer {
    padding: 3px;
    text-align: center;
    background-color: #18233f;
    font-size: 22px;
    color: #fff;
}

footer p {
    margin: 8px 0 8px 0;
}

.social-links img {
    height: 35px;
    margin: 5px;
}

.social-links a {
    text-decoration: none;
}

/*-----------ANIMATION-------------------------*/

@keyframes header-movement {
    form {
        background-color: #FFF;
        padding: 0;
    }
    TO {
        background-color: #2300346a;
        padding: 0;
        color: #fff;
    }
}

@keyframes aparecer {
    form {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes cambio-color {
    from{
        filter: hue-rotate(0deg);
    }
    to {
        filter: drop-shadow(-1.8rem 0 0.75rem #fff);
    }
}

@keyframes gradient {
	0% {
		background-position: 0% 50%;
	}
	50% {
		background-position: 100% 50%;
	}
	100% {
		background-position: 0% 50%;
	}
}