#proyectos{
    width: 100%;
    min-height: clamp(1050px, 50vw, 1350px);
    background-color: #0B1120;
    position: relative;
    
    display: flex;
    justify-content: center;
    align-items: center;
}
#proyectos::before{
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(to right, rgba(76, 201, 240, 0.08) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(76, 201, 240, 0.08) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: radial-gradient(circle at center, black 0%, transparent 75%);
    -webkit-mask-image: radial-gradient(circle at center, black 0%, transparent 75%);
    pointer-events: none;
}


#proyectos .title{
    color: #235edd;
    font-family: "Bricolage Grotesque";
    font-size: clamp(50px,10vw,80px);
    font-weight: bold;

    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: 120px;
}

.projects-wrap{
    position: relative;
    width: 100%;
    max-width: 950px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
}

.projects{
    display: flex;
    flex-direction: row;
    gap: 30px;
}

.carousel-btn{
    display: none;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #2A3A5C;
    background: #0B1120;
    color: #F0F3F8;
    font-size: 20px;
    cursor: pointer;
}
.carousel-btn:hover{
    background: #172338;
}

.project{
    flex-shrink: 0; /* clave: nunca se aprieta, pase lo que pase */
    display: flex;
    justify-content: flex-start;
    align-items: center;
    flex-direction: column;
    padding: 30px;
    height: 550px;
    width: 400px;
    z-index: 30;
}


.project .up.uno{
    width: 100%;
    height: 300px;
    background-image: url(imgs/Web\ FOUR.png);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    border-radius: 6px 6px 0 0;
}
.project .up.dos{
    width: 100%;
    height: 300px;
    background-image: url(imgs/Web\ Rockstar.png);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    border-radius: 6px 6px 0 0;
}
.project .up.tres{
    width: 100%;
    height: 300px;
    background-image: url(imgs/Web\ KeyTest.png);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    border-radius: 6px 6px 0 0;
}
.project .down{
    padding: 30px;
    width: 100%;
    height: 250px;
    background-color: #172338;
    border-radius: 0 0 6px 6px
}

.project .down span{
    font-family: "Bricolage Grotesque";
    font-weight: bold;
    color:  rgba(255, 255, 255, 0.9);
}

.project .down p{
    color: rgba(255, 255, 255, 0.6);
    margin-top: 10px;
    font-size: 15px;
    font-family: "Montserrat";
    font-weight: 400;
    line-height: 1.5;
}

.boton{
    display: inline-block;
    text-decoration: none;
    color: white;
    font-family: "IBM Plex Sans";
    font-size: clamp(14px,3vw,17px);
    padding: 14px 22px;
    font-weight: 500;
    background-color: #235edd;
    border-radius: 15px;
    margin-top: 20px;
    z-index: 10;
    text-align: center;
    box-shadow: 
        0 1px 2px rgba(0, 0, 0, 0.24),
        0 4px 12px rgba(0, 0, 0, 0.16);

    transition: .1s;
}

.boton:hover{
    background-color: #1948ad;
}


@media (max-width: 1280px){
    .projects-wrap{
        gap: 4px;
        padding: 0 8px;
        justify-content: center;
    }

    .projects{
        flex: 1;
        min-width: 0;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;
        scrollbar-width: none;
    }
    .projects::-webkit-scrollbar{
        display: none;
    }

    .project{
        scroll-snap-align: center;
        width: 400px; /* explícito, aunque flex-shrink:0 ya lo protege */
    }

    .project .up.uno,
    .project .up.dos,
    .project .up.tres{
        height: 220px;
    }

    .carousel-btn{
        display: block;
    }
}

@media (max-width: 1000px){
    .project{
        width: 320px;
        height: 600px;
    }
    .project .down{
        height: 300px;
    }
}