.products {
    padding-block: 40px;
    color: #fff;

}

.products h2 {
    text-align: center;
    margin-bottom: 80px;
    opacity: 0.3;
    position: relative;
    justify-content: center;
}

.products h2::before,
.products h2::after {
    min-width: 100%;
}

.products-container {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr)); 
    gap: 24px;
}

.products-container > a.product-item {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    position: relative;
    overflow: hidden;              
    border-radius: 6px;
    text-align: center;
    font-size: 4.8rem;    
    line-height: 4.8rem;  
    font-weight: 300;
    font-family: var(--font2);
    color: #fff;
    background: none;
    grid-column: span 4;
    aspect-ratio: 5 / 3;
}

.products-container > a.product-item > h4 {
    position: absolute;
    z-index: 2;    
    font-size: 4.8rem;    
    line-height: 4.8rem;  
    font-weight: 350;
    font-family: var(--font2);
    transition: transform 0.4s ease, letter-spacing 0.4s ease;    
    padding: 10px;       
}

.products-container > a.product-item > p {
    position: relative;
    z-index: 2;
    opacity: 0;
    color: #fff;
    transform: translateY(200px);
    transition: opacity 1s ease, transform 0.2s ease;
    font-size: 2.4rem;    
}

.products-container > a.product-item:hover > p {
    opacity: 1;
    transform: translateY(20px);
}

.products-container > a.product-item:hover > h4 {
    transform: translateY(-50px);
    font-size: 2.88rem;  
    letter-spacing: 1px;       
    margin-bottom: 20px;
}

.products-container > a.product-item {
    position: relative;
    overflow: hidden; 
}

.products-container > a.product-item::before {
    content: "";
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    transform-origin: center;
    transform: scale(1.25);
    transition: transform 0.4s ease-in-out; 
}

.products-container > a.product-item:nth-child(1)::before {
    background-image: url(../../images/linhas/casual.webp);
}

.products-container > a.product-item:nth-child(2)::before {
    background-image: url(../../images/linhas/ProdutoPoliamida.webp);
}

.products-container > a.product-item:nth-child(3)::before {
    background-image: url(../../images/linhas/lingerie.webp);
}

.products-container > a.product-item:nth-child(4)::before {
    background-image: url(../../images/linhas/estamparia.webp);
}

.products-container > a.product-item:nth-child(5)::before {
    background-image: url(../../images/linhas/fitness.webp);
}

.products-container > a.product-item:nth-child(6)::before {
    background-image: url(../../images/linhas/tech.webp);
}

.products-container > a.product-item::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    z-index: 1;
}

.products-container > a.product-item:hover::before {
    transform: scale(1); 
}

@media (max-width: 1400px) {
    .products-container > a.product-item > h4 {
        font-size: 3.52rem; /* era 2.2rem */
    }
}

@media (max-width: 1200px) {
    .products-container {
        grid-template-columns: repeat(12, minmax(0, 1fr));
    }
    .products-container > a.product-item {
        grid-column: span 6;
    }
}

@media (max-width: 860px) {
    .products h2 {
        line-height: 7.2rem;
        font-size: 4.8rem;
    }
    .products-container > a.product-item > h4 {
        font-size: 3.2rem; 
    }
    .products-container > a.product-item {
        grid-column: span 12;
    }
    .products{
        padding-block: 10px;
    }
}
