/* Preserve the Bootstrap 3 horizontal form layout while views migrate to Bootstrap 5 markup. */
.form-horizontal .form-group {
  display: flex;
  flex-wrap: wrap;
  margin-right: -.75rem;
  margin-bottom: 1rem;
  margin-left: -.75rem;
}

.form-horizontal .form-group > [class*="col-"] {
  padding-right: .75rem;
  padding-left: .75rem;
}

.form-horizontal .control-label {
  padding-top: calc(.375rem + 1px);
  margin-bottom: 0;
}

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

.pool-navbar {
  margin: .75rem 0 1.5rem;
  border: 1px solid rgba(13, 110, 253, .12);
  border-radius: 1rem;
  background: linear-gradient(135deg, #fff, #f0f6ff);
  box-shadow: 0 .5rem 1.5rem rgba(20, 53, 94, .08);
}

.pool-brand {
  display: flex;
  align-items: center;
  gap: .65rem;
  color: #0d3b70;
}

.pool-brand:hover {
  color: #0d3b70;
}

.pool-brand > i {
  display: grid;
  width: 2.25rem;
  height: 2.25rem;
  place-items: center;
  border-radius: .7rem;
  background: #0d6efd;
  color: #fff;
  font-size: 1.05rem;
}

.pool-brand > span {
  display: grid;
  line-height: 1;
}

.pool-brand small {
  margin-top: .2rem;
  color: #6c757d;
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.pool-nav {
  gap: .25rem;
}

.pool-nav .nav-link,
.pool-profile,
.pool-logout {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  border-radius: .6rem;
  color: #4b5f78;
  font-weight: 600;
}

.pool-nav .nav-link {
  padding: .55rem .7rem;
}

.pool-nav .nav-link:hover {
  background: rgba(13, 110, 253, .08);
  color: #0d6efd;
}

.pool-nav .nav-link.active {
  background: #0d6efd;
  box-shadow: 0 .25rem .75rem rgba(13, 110, 253, .25);
  color: #fff;
}

.pool-account {
  display: flex;
  align-items: center;
  gap: .35rem;
  margin-top: .75rem;
}

.pool-profile,
.pool-logout {
  padding: .5rem .65rem;
  text-decoration: none;
}

.pool-profile:hover,
.pool-profile.active {
  background: rgba(13, 110, 253, .08);
  color: #0d6efd;
}

.pool-logout {
  color: #b02a37;
}

.pool-logout:hover,
.pool-logout.active {
  background: #f8d7da;
  color: #842029;
}

@media (min-width: 992px) {
  .pool-nav {
    margin-left: 1.5rem;
  }

  .pool-account {
    margin-top: 0;
  }
}

.table-responsive {
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid #e4ebf3;
  border-radius: 1rem;
  background: #fff;
  box-shadow: 0 .5rem 1.5rem rgba(20, 53, 94, .08);
}

.table {
  --bs-table-striped-bg: #f7faff;
  --bs-table-hover-bg: #edf5ff;
  margin-bottom: 0;
  color: #33475b;
}

.table > thead > tr > th {
  padding: .9rem 1rem;
  border-bottom: 1px solid #dfe5eb;
  background: #f3f1ee;
  color: #4b4a48;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  vertical-align: middle;
  white-space: nowrap;
}

.table > tbody > tr > * {
  padding: .75rem 1rem;
  border-color: #edf1f6;
  vertical-align: middle;
}

.table > tbody > tr {
  transition: transform .15s ease, box-shadow .15s ease;
}

.table > tbody > tr:hover {
  position: relative;
  z-index: 1;
  box-shadow: 0 .2rem .8rem rgba(20, 53, 94, .1);
}

.history-table {
  margin-top: .25rem;
  border-color: #d8e4f2;
  border-radius: .75rem;
  box-shadow: none;
}

.history-table .table > thead > tr > th {
  padding: .65rem .75rem;
  background: #edf4fb;
  color: #48627d;
  font-size: .68rem;
}

.history-table .table > tbody > tr > * {
  padding: .55rem .75rem;
}

.history-table a {
  color: #0d6efd;
  font-weight: 500;
  text-decoration: none;
}

.history-table a:hover {
  color: #0a58ca;
  text-decoration: underline;
}

.history-table a:focus-visible {
  outline: 2px solid rgba(13, 110, 253, .45);
  outline-offset: 2px;
}

.dt-container .dt-search input,
.dt-container .dt-length select {
  border: 1px solid #cfd9e5;
  border-radius: .5rem;
  background: #fff;
}

.list-filter {
  margin: 0;
}

.dt-layout-start .list-filter {
  display: inline-flex;
}

.login-page,
.logout-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(159, 206, 255, .35), transparent 28rem),
    #f7f6f3;
}

.login-shell {
  display: grid;
  min-height: calc(100vh - 3rem);
  place-items: center;
  padding: 2rem 1rem;
}

.login-card {
  width: min(100%, 28rem);
  padding: 2.5rem;
  border: 1px solid rgba(91, 103, 116, .14);
  border-radius: 1.25rem;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 1.25rem 3.5rem rgba(44, 58, 72, .12);
}

.login-brand {
  display: grid;
  justify-items: center;
  margin-bottom: 1.75rem;
  color: #30475e;
}

.login-brand-icon {
  display: grid;
  width: 3.5rem;
  height: 3.5rem;
  place-items: center;
  margin-bottom: .75rem;
  border-radius: 1rem;
  background: #dbeafe;
  color: #2563eb;
  font-size: 1.5rem;
}

.login-brand p {
  margin: 0;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -.04em;
}

.login-intro {
  margin-bottom: 1.75rem;
  text-align: center;
}

.login-intro h1 {
  margin-bottom: .5rem;
  color: #333433;
  font-size: 1.5rem;
  font-weight: 700;
}

.login-intro p {
  margin: 0;
  color: #6c6d6b;
}

.login-card .form-label {
  color: #4b4a48;
  font-size: .9rem;
  font-weight: 600;
}

.login-card .input-group-text {
  border-color: #d7dbe0;
  background: #f8f8f6;
  color: #727476;
}

.login-card .form-control {
  border-color: #d7dbe0;
  padding: .7rem .8rem;
}

.login-card .form-control:focus {
  border-color: #86b7fe;
  box-shadow: 0 0 0 .25rem rgba(13, 110, 253, .12);
}

.login-alert {
  display: flex;
  gap: .5rem;
  align-items: flex-start;
}

.login-submit {
  display: inline-flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .7rem 1rem;
  font-weight: 600;
}

.login-reset {
  display: block;
  width: 100%;
  margin-top: .85rem;
  color: #6c6d6b;
  font-size: .9rem;
  text-decoration: none;
}

.login-reset:hover {
  color: #0d6efd;
  text-decoration: underline;
}

body:not(.login-page):not(.logout-page) h1 {
  margin: 1.75rem 0 1.5rem;
  color: #343332;
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  font-weight: 700;
  letter-spacing: -.04em;
}

form.form-horizontal {
  max-width: 76rem;
  margin: 0 auto 2rem;
  padding: 1rem 1.5rem;
  border: 1px solid #e4e7e9;
  border-radius: 1rem;
  background: #fff;
  box-shadow: 0 .5rem 1.5rem rgba(44, 58, 72, .07);
}

.form-horizontal fieldset {
  min-width: 0;
}

.form-horizontal .form-group {
  align-items: center;
  margin-bottom: 0;
  padding: 1rem 0;
  border-bottom: 1px solid #edf0f2;
}

.form-horizontal fieldset > .form-group:first-child {
  padding-top: .5rem;
}

.form-horizontal fieldset > .form-group:last-child {
  border-bottom: 0;
}

.form-horizontal .control-label {
  color: #4b4a48;
  font-size: .88rem;
  font-weight: 600;
}

.form-horizontal .form-control:not(.btn) {
  min-height: 2.7rem;
  border-color: #d7dbe0;
  background: #fcfcfb;
}

.form-horizontal textarea.form-control {
  min-height: auto;
}

.form-horizontal .form-control:not(.btn):focus {
  border-color: #86b7fe;
  background: #fff;
  box-shadow: 0 0 0 .25rem rgba(13, 110, 253, .12);
}

.form-horizontal .form-control[readonly] {
  background: #f4f3f0;
  color: #6c6d6b;
}

.form-horizontal .form-check-input {
  width: 1.15rem;
  height: 1.15rem;
  margin-top: .15rem;
  border-color: #aeb7c0;
}

.form-horizontal .form-check-input:checked {
  border-color: #0d6efd;
  background-color: #0d6efd;
}

.form-horizontal .form-check-inline {
  margin-left: .75rem;
}

.form-horizontal .form-check-inline label {
  white-space: nowrap;
}

.form-horizontal .btn {
  border-radius: .6rem;
  font-weight: 600;
}

.form-horizontal input.btn.form-control {
  min-height: 2.7rem;
}

@media (max-width: 575.98px) {
  .login-card {
    padding: 2rem 1.5rem;
  }

  form.form-horizontal {
    padding: .75rem 1rem;
  }
}

@media (max-width: 767.98px) {
  .pool-navbar {
    margin: .5rem 0 1rem;
    border-radius: .75rem;
  }

  .pool-nav {
    margin-top: .75rem;
  }

  .pool-nav .nav-link {
    width: 100%;
    padding: .7rem;
  }

  .pool-account {
    justify-content: space-between;
    padding-top: .5rem;
    border-top: 1px solid rgba(13, 110, 253, .12);
  }

  body:not(.login-page) h1 {
    margin: 1.25rem 0 1rem;
  }

  form.form-horizontal {
    margin-bottom: 1.5rem;
    border-radius: .75rem;
  }

  .form-horizontal .form-group {
    align-items: flex-start;
    padding: .75rem 0;
  }

  .form-horizontal .form-group > .control-label,
  .form-horizontal .form-group > [class*="col-"] {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .form-horizontal .control-label {
    padding-top: 0;
    margin-bottom: .35rem;
  }

  .form-horizontal .form-group > .form-check {
    width: 100%;
    margin: 0 .75rem .5rem;
  }

  .table-responsive {
    margin-right: -.75rem;
    margin-left: -.75rem;
    border-radius: .75rem;
    overflow-x: visible;
    overflow-y: visible;
  }

  .table-responsive .dt-container,
  .table-responsive .table {
    max-width: 100%;
  }

  .dt-container .dt-layout-row {
    gap: .75rem;
  }

  .dt-container .dt-search {
    width: 100%;
  }

  .dt-container .dt-search input {
    max-width: 100%;
  }
}
