:root {
    --theme-light-blue-rgb: 59 179 187;
}

.table-scroll-container {
    overflow-x: auto;
}

.table-search {
    margin: 1em 0;
    font-size: 0.95em;
}

.table-search__form {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
}

.table-search__radio {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    border: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.table-search__tabs {
    display: flex;
    gap: 0;
    flex-basis: 100%;
}

.table-search__tab {
    padding: 0.5em 1.2em;
    cursor: pointer;
    background: #f3f3f3;
    border: 1px solid #ccc;
    border-bottom: none;
    border-radius: 4px 4px 0 0;
    user-select: none;
    color: #555;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.table-search__tab + .table-search__tab {
    margin-left: -1px;
}

.table-search__tab:hover {
    background: #eaeaea;
}

.table-search__radio[data-axis="aperture"]:focus-visible ~ .table-search__tabs .table-search__tab[data-axis="aperture"],
.table-search__radio[data-axis="mesh"]:focus-visible ~ .table-search__tabs .table-search__tab[data-axis="mesh"] {
    outline: 2px solid rgb(var(--theme-light-blue-rgb));
    outline-offset: -2px;
}

.table-search__radio[data-axis="aperture"]:checked ~ .table-search__tabs .table-search__tab[data-axis="aperture"],
.table-search__radio[data-axis="mesh"]:checked ~ .table-search__tabs .table-search__tab[data-axis="mesh"] {
    background: rgb(var(--theme-light-blue-rgb) / 0.2);
    border-color: rgb(var(--theme-light-blue-rgb));
    color: #222;
    font-weight: bold;
}

.table-search__body {
    display: flex;
    align-items: center;
    gap: 0.5em;
    flex-wrap: wrap;
    flex-basis: 100%;
    padding: 0.75em;
    border: 1px solid #ccc;
    border-radius: 0 4px 4px 4px;
    background: #fff;
}

.table-search__panels {
    flex: 1 1 auto;
    min-width: 0;
}

.table-search__panel {
    display: none;
    align-items: center;
    gap: 0.4em;
}

.table-search__radio[data-axis="aperture"]:checked ~ .table-search__body .table-search__panels .table-search__panel[data-axis="aperture"],
.table-search__radio[data-axis="mesh"]:checked ~ .table-search__body .table-search__panels .table-search__panel[data-axis="mesh"] {
    display: flex;
}

.table-search__input {
    flex: 1 1 auto;
    min-width: 0;
    padding: 0.4em 0.6em;
    font-size: 1em;
    border: 1px solid #bbb;
    border-radius: 3px;
    background: #fff;
}

.table-search__input:focus {
    outline: 2px solid rgb(var(--theme-light-blue-rgb));
    outline-offset: -1px;
    border-color: rgb(var(--theme-light-blue-rgb));
}

.table-search__unit {
    color: #666;
    flex: 0 0 auto;
    white-space: nowrap;
}

.table-search__submit {
    flex: 0 0 auto;
    padding: 0.45em 1.4em;
    font-size: 1em;
    cursor: pointer;
    border: 1px solid rgb(var(--theme-light-blue-rgb));
    background: rgb(var(--theme-light-blue-rgb));
    color: #fff;
    border-radius: 3px;
    transition: opacity 0.15s ease;
}

.table-search__submit:hover {
    opacity: 0.85;
}

.table-search__message {
    flex-basis: 100%;
    margin-top: 0.4em;
    min-height: 1.4em;
    color: #444;
    font-size: 0.9em;
}

.table-search__message:empty {
    display: none;
}

.table-search-hit > th,
.table-search-hit > td {
    background: rgb(var(--theme-light-blue-rgb) / 0.2) !important;
    transition: background-color 0.6s ease;
}
