/* =========================
   BEFORE / AFTER SECTION
========================= */

.before-after {
    padding: 10px 0 !important;
}

/* =========================
   GRID (AMAZON STYLE FLOW)
========================= */

.ba-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-top: 40px;
}

/* =========================
   CARD
========================= */

.ba-card {
    position: relative;
    border-radius: 14px;
    overflow: hidden;

    background: #fff;

    box-shadow: 0 10px 25px rgba(0,0,0,0.06);

    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.ba-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 35px rgba(0,0,0,0.10);
}

/* =========================
   IMAGE (CONTROLLED SCALING)
========================= */

.ba-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;

    transition: transform 0.3s ease;
}

.ba-card:hover img {
    transform: scale(1.05);
}

/* =========================
   LABEL
========================= */

.ba-card span {
    position: absolute;
    bottom: 10px;
    left: 10px;

    background: rgba(0,0,0,0.65);
    color: #fff;

    padding: 5px 10px;
    border-radius: 10px;

    font-size: 0.8rem;
    font-weight: 600;
}

/* =========================
   TABLET LARGE (3 COLS)
========================= */

@media (max-width: 1100px) {
    .ba-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .ba-card img {
        height: 200px;
    }
}

/* =========================
   TABLET (2 COLS)
========================= */

@media (max-width: 800px) {
    .ba-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .ba-card img {
        height: 190px;
    }
}

/* =========================
   MOBILE (1 COL - CONTROLLED SIZE)
========================= */

@media (max-width: 600px) {
    .ba-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .ba-card img {
        height: 220px;
    }
}

/* =========================
   SMALL PHONES (LESS OVERWHELMING)
========================= */

@media (max-width: 400px) {
    .ba-card img {
        height: 200px;
    }
}