/**
 * Global sortable table headers (SLS).
 * Loaded from includes/header.php — do not copy into page <style> blocks.
 */

:where(thead th[data-sortable="1"]),
:where(thead th.sls-sortable) {
    cursor: pointer;
    user-select: none;
}

:where(thead th .sort-link) {
    cursor: pointer;
    user-select: none;
    text-decoration: none;
    color: inherit;
}

:where(thead th .sort-link:hover),
:where(thead th .sort-link:hover span),
:where(thead th .sort-link:hover .sort-dir-icon) {
    color: #0f766e;
}

:where(thead th .sort-link:focus-visible) {
    outline: 2px solid #0d9488;
    outline-offset: 2px;
    border-radius: 0.25rem;
}

:where(thead th .sort-dir-icon) {
    opacity: 0.75;
    flex-shrink: 0;
}

:where(thead th .sort-link[aria-sort="ascending"] .sort-dir-icon),
:where(thead th .sort-link[aria-sort="descending"] .sort-dir-icon) {
    opacity: 1;
    color: #0f766e;
}

html[data-theme="dark"] :where(thead th .sort-link:hover),
html[data-theme="dark"] :where(thead th .sort-link:hover span),
html[data-theme="dark"] :where(thead th .sort-link:hover .sort-dir-icon),
html[data-theme="dark"] :where(thead th .sort-link[aria-sort="ascending"] .sort-dir-icon),
html[data-theme="dark"] :where(thead th .sort-link[aria-sort="descending"] .sort-dir-icon) {
    color: #2dd4bf;
}
