/*
 * Site styles on top of Bootstrap 5.3. Rules carried over from the old css/styles2.css are marked "legacy".
 * Dark mode uses Bootstrap's built-in colour modes (data-bs-theme="dark"), replacing css/dark-mode.css.
 */

/* legacy: whole-cell clickable links in tables */
.table td,
.table th {
    position: relative;
}

.fingerlink {
    position: absolute;
    inset: 0;
    z-index: 10;
}

.nomargin {
    margin: 0;
}

/* legacy: activity cards past their deadline */
.passeddeadline {
    border-left: 4px solid #ff0000 !important;
}

.activityMessageRight {
    border-left: 1px solid #ccc;
}

/* legacy dark mode colours (css/dark-mode.css) */
[data-bs-theme="dark"] body {
    background-color: #111;
    color: #eee;
}

/* Sign-in and account forms */
.auth-form {
    max-width: 28rem;
}

/* Activity page option forms: field errors wrap onto their own line */
.option-form .invalid-feedback {
    flex-basis: 100%;
    margin-top: 0;
}

/* Links look as they did under Bootstrap 4: underlined only on hover */
a {
    text-decoration: none;
}

a:hover,
a:focus-visible {
    text-decoration: underline;
}

.btn:hover,
.nav-link:hover,
.dropdown-item:hover {
    text-decoration: none;
}

/* Sortable tables (legacy tablesorter look): arrows in the header */
table.sortable thead th {
    cursor: pointer;
    user-select: none;
}

table.sortable thead th::after {
    content: "\2195";
    padding-left: 0.35em;
    opacity: 0.35;
    font-weight: normal;
}

table.sortable thead th[aria-sort="ascending"]::after {
    content: "\2191";
    opacity: 0.8;
}

table.sortable thead th[aria-sort="descending"]::after {
    content: "\2193";
    opacity: 0.8;
}

/* Amount inputs with a pound sign */
.money-input {
    max-width: 16rem;
}

table.sortable thead th[data-nosort] {
    cursor: default;
}

table.sortable thead th[data-nosort]::after {
    content: none;
}
