/* General Reset */

.ctm-categories-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
}

/* Row Styling */
.ctm-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap; /* Ensure items wrap properly */
    justify-content: center; /* Center-align items on smaller screens */
}

/* Individual Banners */
.ctm-category-banner {
    flex: 1; /* Equal distribution of space */
    min-width: 150px; /* Ensure a minimum size for small screens */
    height: 200px; /* Keep height consistent */
    position: relative;
    background-size: cover;
    background-position: center;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Overlay Effect */
.ctm-category-banner a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: white;
    font-size: 1.2em;
    font-weight: bold;
    background: rgba(0, 0, 0, 0.5); /* Dark overlay */
    transition: background 0.3s ease;
}

.ctm-category-banner a:hover {
    background: rgba(0, 0, 0, 0.7); /* Darker overlay on hover */
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .ctm-row {
        flex-direction: column; /* Stack banners vertically */
        gap: 15px; /* Reduce gap for smaller screens */
    }

    .ctm-category-banner {
    	flex: none !important;
        height: 150px; /* Adjust height for smaller screens */
        min-width: unset; /* Remove min-width to fit container */
    }

    .ctm-category-banner a {
        font-size: 1em; /* Reduce font size for smaller screens */
    }
}