html {
    font-size: 0.875rem;
    position: relative;
    min-height: 100%;
}

@media (min-width: 48rem) {
    html {
        font-size: 1rem;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem var(--secondary-color), 0 0 0 0.25rem var(--primary-color);
}

body {
    font-size: 100%;
    margin-bottom: 3.75rem;
    color: var(--text-color);
}

.body-container div {
    padding-bottom: 1rem;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

:root {
    --primary-color: #2C68A3;
    --secondary-color: whitesmoke;
    --text-color: black;
    --dot-color: #dee7ec;
}

table.header {
    background-color: var(--primary-color);
    color: white;
    font-size: 220%;
    width: 100%;
    height: 100%;
}

td.header {
    text-align: center;
    border: 0;
}

p {
    display: block;
}

h1::before, h2::before, h3::before {
    display: block;
    content: " ";
    margin-top: -6rem;
    height: 6rem;
    visibility: hidden;
    pointer-events: none;
}

h1, h2 {
    color: var(--primary-color);
    border-bottom: 0.2rem dotted var(--dot-color);
}

h3, h4 {
    color: var(--primary-color);
}

header {
    position: sticky;
    top: 0;
    z-index: 10;
}

.nav-item {
    padding: 0.5rem;
    text-align: center;
}

.nav-link:hover, .nav-item .active, button.show, .navbar-toggler:focus, .navbar-toggler:hover {
    background-color: var(--secondary-color);
    box-shadow: 0 0 0.313rem 0 rgba(0, 0, 0, 0.2);
}

.nav-link.disabled {
    color: lightgray !important;
}

.dropdown-menu {
    box-shadow: 0 0 0.313rem 0 rgba(0, 0, 0, 0.2);
    border: 0;
}

#navbar-collapse {
    background-color: white;
}

.dropdown-toggle {
    background-color: white;
    border-width: 0;
    text-align: center;
    vertical-align: middle;
    height: 100%;
    width: 100%;
}

.div-scroll {
    max-height: 80vh;
    overflow-y: auto;
    padding-bottom: 0;
    position: relative;
}

.table-scroll {
    margin-bottom: 0;
}

.highlight, .table-highlight-row > tbody > tr:hover {
    --bs-table-bg: var(--secondary-color);
}

.table-scroll thead {
    position: sticky;
    top: 0;
    box-shadow: 0 0.25rem 0 var(--bs-border-color) inset, 0 0.25rem 0 var(--bs-border-color) !important;
    z-index: 5 !important;
    border-width: thick;
    border-bottom: hidden;
    border-left: hidden;
}

.table-scroll tbody {
    border-width: thick;
    border-left: hidden;
}

.table-scroll th, .table-scroll td {
    vertical-align: middle;
    text-align: center;
}

.table-scroll-row-header {
    border-right-style: none;
    text-align: left !important;
    position: sticky;
    left: 0;
    box-shadow: 0.25rem 0 0 var(--bs-border-color) inset, -0.25rem 0 0 var(--bs-border-color) inset !important;
    z-index: 1;
}

.table-scroll-bottom-border {
    position: sticky;
    top: 0;
    box-shadow: 0.25rem 0 0 var(--bs-border-color) inset, -0.25rem 0 0 var(--bs-border-color) inset !important;
    z-index: 3;
    background-color: var(--bs-table-bg, white);
}

.table-scroll-row-header.table-scroll-bottom-border {
    left: 0;
    z-index: 4;
}

.table-scroll-bottom-border::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 0.0625rem;
    background-color: var(--bs-border-color);
    pointer-events: none;
    z-index: 10;
}

.body-container {
    margin-left: 5%;
    margin-right: 5%;
}

.bg-danger {
    color: white;
    font-size: 200%;
}

.div-scroll > .spinner-wrapper {
    position: sticky;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    margin: 0;
    padding: 0;
    display: block;
    overflow: visible;
    z-index: 10;
}

.spinner-wrapper {
    background-color: white;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 50;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.4s;
}

.spinner-border {
    color: var(--primary-color);
    height: 4rem;
    width: 4rem;
    font-size: 200%;
}

.switch {
    position: relative;
    z-index: 1;
    display: inline-block;
    width: 2.625rem;
    height: 1.5rem;
}

.switch-label {
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    padding-left: 0.375rem;
}

.switch-input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: grey;
    transition: .2s;
    border-radius: 1.5rem;
}

.slider:before {
    position: absolute;
    content: "";
    height: 75%;
    width: 40%;
    left: 10%;
    bottom: 14%;
    background-color: white;
    transition: .2s;
    border-radius: 50%;
}

.switch-input:checked + .switch > .slider {
    background-color: var(--primary-color);
}

.switch-input:checked + .switch > .slider:before {
    transform: translateX(90%);
}

.image-viewer-thumbnail {
    max-width: 100%;
    cursor: zoom-in;
    border: 0.0625rem solid var(--bs-border-color);
    border-radius: 0.375rem;
    transition: box-shadow 0.2s;
}

.image-viewer-thumbnail:hover {
    box-shadow: 0 0 0.5rem rgba(0, 0, 0, 0.25);
}

.image-viewer-overlay {
    position: fixed;
    inset: 0;
    z-index: 1050;
    background-color: rgba(0, 0, 0, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-viewer-overlay[hidden] {
    display: none !important;
}

.image-viewer-overlay-content {
    position: relative;
    max-width: 92vw;
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.5rem;
}

.image-viewer-close {
    align-self: flex-end;
    font-size: 0.875rem;
    background-color: transparent;
    border: none;
    color: white;
    cursor: pointer;
    padding: 0.375rem 0.75rem;
    border-radius: 0.375rem;
}

.image-viewer-close:hover {
    background-color: rgba(255, 255, 255, 0.15);
    color: white;
    outline: none;
}

.image-viewer-close:active,
.image-viewer-close:focus {
    background-color: rgba(255, 255, 255, 0.30);
    color: white;
    outline: none;
}

.image-viewer-full {
    height: 75vh;
    width: auto;
    max-width: 92vw;
    border-radius: 0.375rem;
    background-color: white;
}

.image-card-list {
    display: flex;
    align-items: stretch;
    gap: 0.75rem;
    height: 50vh;
}

.image-card-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
    overflow: hidden;
}

.image-card-track {
    width: 100%;
    display: flex;
    gap: 1rem;
    flex: 1;
    min-height: 0;
    align-items: stretch;
}

.image-card {
    display: none;
    flex: 1;
    min-width: 0;
    min-height: 0;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    overflow: hidden;
}

.image-card.active {
    display: flex;
}

.image-card .image-viewer {
    flex: 1;
    min-height: 0;
    align-self: stretch;
    overflow: hidden;
}

.image-card .image-viewer-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.image-card-text {
    text-align: center;
}

.image-card-counter {
    font-size: 0.875rem;
    color: var(--primary-color);
    font-weight: bold;
}

.image-card-nav {
    align-self: center;
    flex-shrink: 0;
    background-color: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-color);
    cursor: pointer;
    padding: 0.375rem 0.625rem;
    border-radius: 0.375rem;
    line-height: 1;
    transition: background-color 0.15s;
}

.image-card-nav:hover {
    background-color: var(--secondary-color);
}

.image-card-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.image-card-nav:disabled:hover {
    background-color: transparent;
}

.div-center {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
