@charset "UTF-8";
/* CSS Document */

/* --- Event Type Grid Styles --- */

.wg-event-type-grid {
    display: grid;
    /* Use the custom property from PHP, falling back to 3 columns if not set */
    grid-template-columns: repeat(var(--grid-columns, 3), 1fr);
    gap: 20px; /* Spacing between cells */
    margin-bottom: 30px;
}

.wg-type-grid-cell {
    /* Required base styling */
    display: flex;
    justify-content: center; /* Horizontal centering */
    align-items: center; /* Vertical centering */
    min-height: 120px; /* Ensure cells are not too thin */
    
    /* Requested visual styling */
    background-color: var(--wg-red);
    color: #fff; /* White text color */
    border-radius: 10px;
    text-decoration: none; /* Remove underline from link */
    text-align: center;
    font-size: 1.2em;
    font-weight: bold;
    
    /* Requested padding for desktop and tablet (default) */
    padding: 10px 30px; 
    
    /* Smooth transition for hover effect */
    transition: background-color 0.3s ease;
}

/* Hover effect */
.wg-type-grid-cell:hover,
.wg-type-grid-cell:focus {
    background-color: var(--wg-green);
    color: #fff; /* Keep text white on hover */
    text-decoration: none;
}

/* Ensure the text itself doesn't wrap oddly */
.wg-type-grid-cell .wg-type-name {
    display: block;
}

/* --- Responsive Padding & Layout --- */

@media (max-width: 768px) {
    .wg-event-type-grid {
        /* Collapse to 2 columns on tablets and smaller screens, ignoring items_per_row */
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .wg-event-type-grid {
        /* Collapse to 1 column on smartphones */
        grid-template-columns: 1fr;
    }
    
    .wg-type-grid-cell {
        /* Requested padding for smartphones */
        padding: 20px;
        min-height: 100px;
    }
}