*{
    margin: 0;
    padding: 0;
    font-family: "Open Sans", sans-serif;
}
html{
    scroll-behavior: smooth;
}
header{
    height: 220px;
    width: 100%;
    background-image: linear-gradient(rgba(0, 0, 0, 0.4),rgba(0, 0, 0, 0.2)),url(../images/IAYC.jpg);
    background-size: cover;
    background-position: center;
    position: relative;

    display: flex;
    flex-direction: column;
    align-items: center;  /*centrados horizontalmente*/
    justify-content: space-between;
}
.header-top{
    margin-top: 10px;
    width: 62%;
    display: flex;
    justify-content: space-between;
}
.header-bottom{
    margin-bottom: 10px;
    width: 64%;
    display: flex;
    justify-content: space-between;
}
.title-text{
    color: #fff;
    text-align: left;
}
.title-text h1{
    font-size: 64px;
}
.title-text p{
    padding: none;
    font-size: 28px;
    color: #fff;
}
.logo{
    border-radius: 50%;
    width: 100px;
}
.social-icons{
    display:  flex;
    flex-wrap: wrap;
    justify-content:  space-between;
    align-items: center;
}
.social-item{
    fill:rgb(255, 255, 255);
    width: 30px;
    margin: 10px;
    cursor: pointer;
}
.page-links{
    display:  flex;
    flex-wrap: wrap;
    justify-content:  space-between;
    align-items: center;
}
.page-links{
    text-align: right;
}
.page-links ul li{
    list-style: none;
    display: inline-block;
    padding: 8px 12px;
    position: relative;
}
.page-links ul li a{
    color:  #fff;
    text-decoration: none;
    font-size: 17px;
}
.page-links ul li::after{
    content: '';
    width: 0%;
    height: 2px;
    background: #ffffff;
    display: block;
    margin: auto;
    transition: 0.5s;
}
.page-links ul li:hover::after{
    width: 100%;
}
.page-links .icon{
    display: none;
    width: 30px;
}

main{
    display: flex;
    justify-content: space-between;
}
.sidebar {
    width: 350px;
    position: sticky;
    top: 20px;

    height: fit-content;
    display: flex;
    flex-direction: column;
    align-items: left;
}
nav{  
    margin-top: 25px;
    margin-left: 45px;
}
nav h2{
    margin-bottom: 15px;
    font-size: 20px;
}
nav li{
    margin-bottom: 6px;
}
nav a{
    text-decoration: underline;
    color: #1b1b1b;
    font-size: 16px;

}
.content-container{
    width: 100%;
}


@media(max-width: 600px){
    header{
        min-height: 40vh;
    }
    nav .icon {
        display: none;
        width: 30px;
        margin: 10px;
        cursor: pointer;
        color: #fff;
    }
    nav img{
        width: 60px;
    }
    .text-box{
        top: 70%;
    }
    .text-box h1{
        font-size: 30px;
    }
    .nav-links ul{
        margin-top: 10px;
    }
    .nav-links ul li{
        padding: 10px 8px;
    }
    .nav-links ul li a{
        font-size: 16px;
    }
    .ani{
        bottom: 2%;
        padding: 0 0 0 0;
    }
    .ani p{
        font-size: 12px;
        padding: 0 0 0 0;
        margin-left: 2%;
        color: #727272;
    }
}

/*------ Secciones ------*/

section{
    max-width: 90%;
    margin: 30px auto;
    scroll-snap-align: start;
    scroll-margin-top: 30px;
}
section h1{
    font-size: 26px;
    text-align: center;
    margin: 15px 0;
}

#sobre-mi{
    margin-top: 20px;
    margin-bottom: 10px;
    max-width: 76%;
}
#sobre-mi .container{
    display: flex;
    justify-content: space-between;
    align-items: center;             /* vertical center */
    margin: 10px;
}
#sobre-mi .p-container{
    max-width: 50%;
    display: flex;
    flex-direction: column;
    align-items: left;             /* vertical center */
}
#sobre-mi .img-container{
    align-items: center;
}
#sobre-mi a{
    color: #5b5b5b;
}
#sobre-mi p{
    text-align: justify;
    vertical-align: middle;
    font-size: 16px;
    margin-bottom: 6px;
}
#sobre-mi img{
    max-width: 200px;
    height: auto;
    border-radius: 15px;
}

@media(max-width: 850px){
    .sobre-mi{
        max-width: 85%;
        padding-top: 80px;
    }
    .counter{
        top: 105%;
    }
    .sobre-mi div{
        flex-direction: column;
        text-align: center;
    }
    .sobre-mi p{
        max-width: 100%;
        font-size: 14px;
    }
    .perfil{
        justify-content: center;
        margin-top: 20px;
    }
}
 

.card-container{
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin: 20px 0;
}
.card{
    max-width: 22%;
    flex-grow: 1;
}
.card a{
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
}
.card img{
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border: 3px solid black;
    border-radius: 30px;

    transition: filter 0.2s ease;
}
.card p{
    text-align: center;
    margin-top: 5px;
}
.card img:hover{
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.25);
    filter: brightness(1.10);
}

/*------ Proyectos ------*/

.projects{
    width: 88%;
    margin: auto;
    margin-bottom: 50px;
}

.proj-grid {
    display: grid;
    grid-template-columns: auto auto;
    gap: 30px;
}

.proj-card {
    position: relative;
    text-decoration: none;
    height: 290px; /* puedes ajustar */
    background-size: cover;      /* ocupa todo */
    background-position: center; /* centrada */
    background-repeat: no-repeat;
    display: flex;
    overflow: hidden;
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.proj-card:hover{
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.proj-card::before {
  content: "";
  position: absolute;
  inset: 0;

  background-image: var(--bg-image);
  background-size: cover;
  background-position: center;

  filter: blur(var(--bg-blur)) brightness(var(--bg-bright));
  transform: scale(1.1);

  z-index: -1;
}

.proj-card ul{
    padding: 10px;
    margin-left: 13px;
}
.proj-card li{
    text-align: justify;
    font-size: 16px;
    font-weight: 500;
}
.proj-card h3{
    font-size: larger;
}

.layer, .layer-dark{
    display: flex;
    flex-direction: column;
    text-align: center;
    padding: 25px;
    vertical-align: middle;
    width: 100%;
    height: 100%;
    max-width: 400px;
}

.layer p, .layer h3, .layer li{
    color: rgb(0, 0, 0);
    text-shadow: 0 0 7px white;
    text-shadow:
        0 0 6px rgba(255, 255, 255, 0.897),
        0 1px 2px rgba(0,0,0,0.4);
}

.layer-dark p, .layer-dark h3, .layer-dark li{
    color: white;
    text-shadow: 0 0 7px black;
}

.layer p, .layer-dark p{
    margin-top: 8px;
    text-align: justify;
    font-size: 16px;
    font-weight: 500;
}

/* Responsive para móvil */
@media (max-width: 800px) {
    .proj-grid {
        grid-template-columns: 100%;
    }
}
/*
.row{
    justify-content: space-between;
    padding: 10px;
    margin-top: 5%;
    display: flex;
    justify-content: space-between;

}
.proj-col{
    flex-basis: 31%;
    background: #fff3f3;
    border-radius: 10px;
    margin-bottom: 5%;
    box-sizing: border-box;
    transition: 0.5s;
    overflow: hidden;
    position: relative;
}
.proj-col img{
    width: 100%;
    
}

.layer{
    height: 100%;
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
}
h3{
    text-align: center;
    font-weight: 600;
    margin: 10px 0;
}
.proj-col:hover{
    box-shadow: 0 0 20px 0px rgba(0,0,0,0.2);
}
*/

@media(max-width: 600px){
    .row{
        flex-direction: column;
    }
}

/*------ ko-fi ------*/

.ko-fi{
    width: 80%;
    margin: auto;
    text-align: center;
    padding-top: 100px;
    padding-bottom: 300px;
}
/*p{
    color: #5b5b5b;
    font-size: 14px;
    font-weight: 370;
    line-height: 22px;
    padding: 10px;
    letter-spacing: 1%;
}*/



#footer{
    background-color: #d6d6d6;
    width: 100%;
    text-align: center;
    padding: 30px 0;
}
#footer h4{
    margin-bottom: 25px;
    font-weight: 600;
}
.icons{
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: auto;
}
.icons svg{
    fill:rgb(0, 0, 0);
    width: 25px;
    margin: 10px;
    cursor: pointer;
}
.contact-item{
    display: flex;
}
.contact-item a{
    text-decoration: none;   /* remove underline */
    color: #1b1b1b;             /* change color */
    font-weight: 500;
}


.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    margin-top: 20px;
}

.footer-left,
.footer-right {
    display: none;
    opacity: 0.2;
    gap: 10px;
    margin: auto;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-left img,
.footer-right img {
    height: 140px;
    margin: 12px;
}