.ompresent-filter {
    margin: 20px 0;
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background-color: #f9f9f9;
    font-family: 'Inter', sans-serif; /* Use Inter font */
}

.ompresent-filter-ui {
    margin-bottom: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px; /* Spacing between taxonomy containers */
}

.ompresent-tax-container {
    padding: 10px 0;
    border-radius: 5px;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    flex: 1; /* Allow containers to grow */
    min-width: 200px; /* Minimum width for responsiveness */
}

.ompresent-tax-label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
    text-transform: capitalize;
}

/* Dropdown styling */
.ompresent-tax-container select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background-color: #fefefe;
    font-size: 14px;
    cursor: pointer;
    box-sizing: border-box; /* Include padding and border in the element's total width and height */
}

/* Checkbox styling */
.ompresent-tax-container label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    cursor: pointer;
}

.ompresent-tax-container input[type="checkbox"] {
    margin-right: 8px;
    vertical-align: middle;
}

/* Tag styling */
.ompresent-tag {
    display: inline-block;
    margin: 0 6px 6px 0;
    padding: 8px 15px;
    background: #e0e0e0;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.ompresent-tag:hover {
    background: #d0d0d0;
}

.ompresent-tag.active {
    background: #0073aa; /* WordPress primary color */
    color: #fff;
    font-weight: bold;
}

/* Grid layout for results */
.ompresent-filter-results {
    margin-top: 20px;
    padding: 15px;
    border: 1px dashed #ccc;
    border-radius: 8px;
    background-color: #fff;
    min-height: 100px; /* Ensure it has some height even if empty */
    display: flex; /* Changed to flex for fallback/initial centering */
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #666;
}

.ompresent-filter-posts {
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;

    display: grid; /* Use CSS Grid for layout */
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); /* Responsive columns */
    gap: 20px; /* Gap between grid items */
}

.ompresent-filter-posts li {
    padding: 15px;
    border: 1px solid #eee;
    border-radius: 8px;
    background-color: #fefefe;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column; /* Stack image, title, excerpt vertically */
    align-items: center;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ompresent-filter-posts li:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.12);
}

.ompresent-filter-posts li a {
    text-decoration: none;
    color: #0073aa;
    font-weight: 500;
    transition: color 0.2s ease;
    display: flex; /* Make the whole link a flex container */
    flex-direction: column;
    align-items: center;
    gap: 10px; /* Space between image and content */
    width: 100%; /* Ensure link takes full width of list item */
}

.ompresent-filter-posts li a:hover {
    color: #005177;
    text-decoration: underline;
}

.ompresent-post-thumbnail {
    flex-shrink: 0;
    width: 120px; /* Slightly larger image for grid */
    height: 120px;
    object-fit: cover;
    border-radius: 4px;
}

.ompresent-post-content {
    flex-grow: 1;
    width: 100%; /* Ensure content takes full width */
}

.ompresent-post-content h3 {
    margin: 0 0 5px 0;
    font-size: 1.1em;
    color: #333;
}

.ompresent-post-excerpt {
    font-size: 0.9em;
    color: #666;
    line-height: 1.5;
    /* Limit excerpt height if desired, e.g., max-height: 4.5em; overflow: hidden; */
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .ompresent-filter-ui {
        flex-direction: column;
    }
    .ompresent-tax-container {
        width: 100%;
        min-width: unset;
    }
    .ompresent-filter-posts {
        grid-template-columns: 1fr; /* Single column on small screens */
    }
    .ompresent-filter-posts li {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .ompresent-post-thumbnail {
        width: 100px;
        height: 100px;
    }
}

/* Hide dependent filters initially */
.ompresent-tax-container.dependent {
    display: none;
}
```javascript
// File: assets/js/admin-taxonomy-media.js
// Location: ompresent-all-in-one/assets/js/admin-taxonomy-media.js
/**
 * Handles media uploading for taxonomy terms in the WordPress admin.
 */
jQuery(document).ready(function($) {
    var mediaUploader;

    // When the 'Upload Image' button is clicked
    $(document).on('click', '.ompresent-upload-media', function(e) {
        e.preventDefault();

        var $button = $(this);
        var $inputField = $button.siblings('.ompresent-media-url');
        var $previewContainer = $button.siblings('.ompresent-media-preview');

        console.log('Upload button clicked.');
        console.log('Input field:', $inputField);
        console.log('Preview container:', $previewContainer);


        // If the uploader already exists, open it again
        if (mediaUploader) {
            mediaUploader.open();
            return;
        }

        // Create the WordPress media uploader frame
        mediaUploader = wp.media({
            title: 'Select Term Image',
            button: {
                text: 'Use this image'
            },
            multiple: false // Only allow one image to be selected
        });

        // When a file is selected, grab the URL and display it
        mediaUploader.on('select', function() {
            var attachment = mediaUploader.state().get('selection').first().toJSON();
            console.log('Attachment selected:', attachment);
            $inputField.val(attachment.url); // Set the URL to the input field
            $previewContainer.html('<img src="' + attachment.url + '" style="max-width:150px; height:auto;" />'); // Show preview
        });

        // Open the uploader
        mediaUploader.open();
    });

    // Clear image and preview if the input field is emptied
    $(document).on('change', '.ompresent-media-url', function() {
        var $inputField = $(this);
        var $previewContainer = $inputField.siblings('.ompresent-media-preview');
        if ($inputField.val() === '') {
            $previewContainer.html('');
        }
        console.log('Input field changed. Current value:', $inputField.val());
    });
});