/* Marcas: title + static grid of logos */
.section-marcas {
    position: relative;
    z-index: 30;
    background: #e02a2a;
    min-height: 100vh;
    width: 100%;
    overflow: hidden;
    container-type: inline-size; /* sizes use cqw so it scales with the section width */
    display: flex;
    flex-direction: column;
}

.marcas-title-wrap {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5cqw 4cqw 3cqw;
    overflow: hidden; /* mask for the top-to-bottom reveal */
}
.marcas-title {
    font-family: 'Bebas Neue', sans-serif;
    font-weight: 400;
    font-size: 10cqw;
    line-height: 0.9;
    letter-spacing: 0.01em;
    color: #fff;
    text-transform: uppercase;
}

/* six per row on desktop; the last row stays centered */
.brand-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.4cqw;
    padding: 0 4cqw 6cqw;
}
.brand-card {
    flex: none;
    width: 14cqw;
    height: 6.8cqw;
    border-radius: 999px;
    background: #ebebeb;
    display: flex;
    align-items: center;
    justify-content: center;
}
.brand-card img { max-width: 64%; max-height: 72%; object-fit: contain; display: block; }
.brand-name { font-family: 'Bebas Neue', sans-serif; font-size: 2.6cqw; letter-spacing: 0.04em; color: #111; }
.brand-card.has-bg img { max-width: 72%; max-height: 38%; }

@media (max-width: 900px) {
    .brand-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 3cqw;
        padding: 0 5cqw 12cqw;
    }
    .brand-card { width: auto; height: 19cqw; }
    /* an odd last logo fills both columns */
    .brand-card:last-child:nth-child(odd) { grid-column: 1 / -1; }
}
