.jsgrid {
    margin: 0 auto;
    padding-left: 15px;
    padding-right: 15px;
}

.jsgrid-table {
    margin-bottom: 0;
    border: 0;
}

.jsgrid-grid-body {
    overflow-y: hidden !important;
}

.jsgrid-table tr,
.js-grid-table td,
.jsgrid-cell,
.jsgrid-header-cell,
.jsgrid-header,
.jsgrid-grid-header,
.jsgrid-grid-body {
    border: 0 !important;
}

.jsgrid-pager-container {
    margin-top: 30px;
}

.jsgrid-header-row {
    display: none !important;
}

.jsgrid-row .jsgrid-cell:nth-of-type(2),
.jsgrid-alt-row .jsgrid-cell:nth-of-type(2) {
    font-weight: bold;
}

.jsgrid-selected-row > .jsgrid-cell {
    background: rgba(229, 45, 135, 0.5) !important;
}

/* Style the filter input for the 'Name' column (first filter input) */
.jsgrid-filter-row input[type="text"]:first-of-type {
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 20px;
    width: 100%;
    font-size: 14px;
    transition: all 0.2s ease;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.jsgrid-filter-row input[type="text"]:first-of-type:focus {
    border-color: #e52d87;
    outline: none;
    box-shadow: 0 0 5px rgba(229, 45, 135, 0.4);
}

/* Container to hold the search bar */
.legend-search-bar {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

/* Style the search input itself */
.legend-search-bar input[type="text"] {
    padding: 10px 16px;
    border: 1px solid #ccc;
    border-radius: 25px;
    width: 300px;
    font-size: 16px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.legend-search-bar input[type="text"]:focus {
    border-color: #e52d87;
    outline: none;
    box-shadow: 0 0 6px rgba(229, 45, 135, 0.3);
}

/* Hide jsGrid's default filter row (but keep functionality) */
.jsgrid-filter-row {
    visibility: hidden;
    position: absolute;
    height: 0;
    overflow: hidden;
}

/* Style for the "not found" message */
.jsgrid-nodata-row td {
    text-align: center;
    color: #555;
    font-size: 16px;
    padding: 20px;
    line-height: 1.5;
}

/* Allow pager buttons to wrap instead of overflowing */
.jsgrid-pager {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

/* Ensure pager container expands with wrapped buttons */
.jsgrid-pager-container {
    overflow: visible !important;
    padding-bottom: 10px;
}
