.col-sm-2-grid {
    flex: 0 0 16.66667%;
    max-width: 16.66667%;
    position: relative;
    width: 100%;
    padding-right: 40px;
    padding-left: 40px;
}

.col-sm-2-grid-text {
    flex: 0 0 16.66667%;
    max-width: 16.66667%;
    position: relative;
    width: 100%;
    padding-right: 14px;
    padding-left: 14px;
}

.col-sm-3-grid {
    flex: 0 0 22%;
    max-width: 22%;
    position: relative;
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
  }

.col-sm-3-text {
    flex: 0 0 22%;
    max-width: 22%;
    position: relative;
    width: 100%;
    padding-right: 0px;
    padding-left: 10px;
  }

  .col-sm-4-grid {
    flex: 0 0 28%;
    max-width: 28%;
    position: relative;
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
  }

.col-sm-4-text {
    flex: 0 0 28%;
    max-width: 28%;
    position: relative;
    width: 100%;
    padding-right: 0px;
    padding-left: 10px;
  }

  /* Faguer's score section: shown when Faguer or Comparison is picked (js/shows.js) */
  .box {
    display: none;
    flex-grow: 0;
    flex-shrink: 0;
    flex-basis: 100%;
    max-width: 100%;
  }

  .box.hidden {
    display: none;
  }

  .box.hide {
    display: block;
    animation: fadeOut .25s ease-out;
  }

  .box.show {
    display: block;
    animation: fadeIn .25s ease-out;
  }

  @keyframes fadeIn {
    from { opacity: 0; }
    to {opacity: 1; }
  }

  @keyframes fadeOut {
    from { opacity: 1; }
    to {opacity: 0; }
  }

  /* Tooltips styling */
  .tooltip {
    position: relative;
    display: inline-block;
    border-bottom: none;
  }

  .tooltip .tooltiptext {
    visibility: hidden;
    width: 120px;
    background-color: #4747A1;
    text-align: center;
    padding: 5px 0;
    border-radius: 6px;

    position: absolute;
  }

  .tooltip:hover .tooltiptext {
    visibility: visible;
  }

 .tooltip.show {
    opacity: 1;
  }

/* Tooltip body and arrow in the same purple (BS4 and BS5) */
.tooltip .tooltip-inner { background: #4747A1 !important; color: #fff !important; }
.bs-tooltip-right .arrow::before,
.bs-tooltip-auto[x-placement^=right] .arrow::before,
[data-popper-placement^=right] .tooltip-arrow::before { border-right-color: #4747A1 !important; }
.bs-tooltip-left .arrow::before,
.bs-tooltip-auto[x-placement^=left] .arrow::before,
[data-popper-placement^=left] .tooltip-arrow::before { border-left-color: #4747A1 !important; }
.bs-tooltip-top .arrow::before,
.bs-tooltip-auto[x-placement^=top] .arrow::before,
[data-popper-placement^=top] .tooltip-arrow::before { border-top-color: #4747A1 !important; }
.bs-tooltip-bottom .arrow::before,
.bs-tooltip-auto[x-placement^=bottom] .arrow::before,
[data-popper-placement^=bottom] .tooltip-arrow::before { border-bottom-color: #4747A1 !important; }


/* footer classes*/
.footer {
  display: flex;
  flex-flow: row wrap;
  padding: 30px 30px 20px 30px;
  color: #2f2f2f;
  background-color: #fff;
  border-top: 1px solid #e5e5e5;
  background: #F5F7FF;
  transition: all 0.25s ease;
  -moz-transition: all 0.25s ease;
  -webkit-transition: all 0.25s ease;
  -ms-transition: all 0.25s ease;
}

.footer > * {
  flex:  1 100%;
}

.footer__addr {
  margin-right: 1.25em;
  margin-bottom: 0.2em;
}

.footer__logo {
  font-family: 'Pacifico', cursive;
  font-weight: 400;
  text-transform: lowercase;
  font-size: 1.5rem;
}

.footer__addr h2 {
  margin-top: 1.3em;
  font-size: 15px;
  font-weight: 400;
}

.nav__title {
  font-weight: 400;
  font-size: 15px;
}

.footer address {
  font-style: normal;
  color: #5B6275;
}

.footer__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  max-width: max-content;
  background-color: #4B49AC;
  border-radius: 100px;
  color: #ffffff;
  line-height: 0;
  margin: 0.6em 0;
  font-size: 1rem;
  padding: 0 1.3em;
  transition: background-color .15s ease-out;
}

.footer .footer__btn { color: #ffffff; }  /* beats the template's .footer a */

.footer .footer__btn:hover,
.footer .footer__btn:focus-visible {
  background-color: #3c3a8f;
  color: #ffffff;
  text-decoration: none;
}

.footer ul {
  list-style: none;
  padding-left: 0;
}

.footer li {
  line-height: 2em;
}

.footer__nav {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.nav__ul a {
  color: #5B6275;
}

.nav__ul--extra {
  column-count: 2;
  column-gap: 1.25em;
}

.legal {
  display: flex;
  flex-wrap: wrap;
  color: #5B6275;
}

.legal__links {
  display: flex;
  align-items: center;
}

.heart {
  color: #2f2f2f;
}

@media screen and (min-width: 24.375em) {
  .legal .legal__links {
    margin-left: auto;
  }
}

@media screen and (min-width: 40.375em) {
  .nav__item--extra {
    flex-grow: 2;
  }

  .footer__addr {
    flex: 1 0px;
  }

  .footer__nav {
    flex: 2 0px;
  }
}

@media (min-width: 768px) {
  .footer__nav { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 767.98px) {
  .footer { padding: 16px; }
  .footer__addr { margin-bottom: 16px; }
}

/* Articles*/

.article-container {
  overflow: hidden;
}

.article-container img {
  object-fit: contain;
  height:100%;
  width: 100%;
  transform-origin: center center;
  transition: transform .2s, opacity .2s;
}

.article-container img:hover {
  transform: scale(1.1);
  opacity: 0.55;
}

.art-text {
  color: #000000;
  transition: transform .2s, opacity .2s;
}

.article-container img:hover + .art-text {
  transform: scale(1.1);
  opacity: 0.55;
}

/* custom cards */

/* Disclaimer under the calculator */
.card.card-grey {
  background: #ECEEF6;
  color: #33354A;
  box-shadow: none;
}

.disclaimer,
.disclaimer li {
  font-size: 0.8125rem;
  line-height: 1.55;
}

.disclaimer li {
  margin-bottom: 0.4rem;
}

.disclaimer .art-link {
  color: #4B49AC;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* art link */
.art-link {
  text-decoration: none;
}

.vertical-center {
  margin: 0;
  position: absolute;
  top: 50%;
  -ms-transform: translateY(-50%);
  transform: translateY(-50%);
}

/* bios container */
.bio-container img {
  object-fit: contain;
  height:100%;
  width: 100%;
  transition: transform .4s, opacity .4s;
}

.bio-container img:hover {
  transform: scale(1.03);
  opacity: 0.8;
}

.bio-text {
  text-align: left;
  margin-top: 1.5rem;
}

.bio-desc {
  text-align: center;
  font-size: 1.05rem;
  line-height: 1.5rem;
}

/* email / ORCID / ResearchGate icons next to each name */
.bio-socials{
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding-top: 1.5rem;
}

.bio-socials a {
  display: inline-flex;
  margin: 0 !important;
}

.social-icon{
  color:#4747A1;
  font-size: 22px;
  transition: opacity .4s;
  -moz-transition: opacity .4s; /* Firefox 4 */
  -webkit-transition:opacity .4s; /* Safari and Chrome */
  -o-transition: opacity .4s;
}

.social-icon:hover {
  opacity: 0.55;
}

/* Privacy policy and terms: keep lines at a readable length */
.legal-page > * {
  max-width: 920px;
}

.legal-page a {
  overflow-wrap: anywhere;
}


/* =========================
   Layout and template overrides
   ========================= */

/* Hide sideways overflow without turning <body> into its own scroll box */
body { overflow-x: clip; }
img, video { max-width: 100%; height: auto; }

/* The floating "settings" bubble from the admin template */
.theme-setting-wrapper { display: none; }

/* Navbar logo */
.navbar-brand img { max-height: 40px; height: auto !important; }
@media (min-width: 576px) {
  .navbar-brand img { max-height: 48px; }
}
@media (max-width: 575.98px) {
  .navbar { padding-left: 8px; padding-right: 8px; }
  .navbar .navbar-brand-wrapper { width: 70px !important; height: 60px; }
  .navbar .brand-logo { display: none !important; }
  .navbar .brand-logo-mini { display: inline-block !important; }
  .navbar-menu-wrapper { padding-right: 8px; }
}

/* Below 992px the sidebar is an off-canvas menu, opened by the navbar button */
@media (max-width: 991.98px) {
  #sidebar.sidebar-offcanvas {
    position: fixed;
    top: 0;
    bottom: 0;
    left: -280px;
    right: auto;
    width: 260px;
    height: 100vh;
    z-index: 1040;
    overflow-y: auto;
    padding-top: 1rem;
    transition: left .25s ease-out;
    box-shadow: 0 0 20px rgba(0, 0, 0, .15);
  }
  #sidebar.sidebar-offcanvas.active { left: 0; }
  .page-body-wrapper { margin: 0 !important; }

  /* the template styles the sidebar only on desktop: same look here */
  #sidebar.sidebar-offcanvas { background: #fff; padding-left: .75rem; padding-right: .75rem; }
  #sidebar .nav { flex-direction: column; flex-wrap: nowrap; }
  #sidebar .nav .nav-item { width: 100%; margin-top: .2rem; }
  #sidebar .nav .nav-item > .nav-link {
    display: flex;
    align-items: center;
    padding: 13px 16px;
    border-radius: 8px;
    color: #6C7383;
    white-space: nowrap;
  }
  #sidebar .nav .nav-item .menu-icon { margin-right: 1rem; font-size: 16px; color: inherit; }
  #sidebar .nav .nav-item .menu-title { font-size: 14px; font-weight: 500; color: inherit; }
  #sidebar .nav .nav-item.active > .nav-link { background: #4B49AC; color: #fff; }
}

.nav .nav-item > .nav-link { line-height: 1.2; padding: 10px 12px; }

/* Phones: a little less padding around the content */
@media (max-width: 767.98px) {
  .grid-margin { margin: 0 0 12px 0 !important; }
}
@media (max-width: 575.98px) {
  .content-wrapper { padding: 16px 12px !important; }
  .card .card-body { padding: 1rem !important; }
  h3.font-weight-bold { font-size: 1.25rem; }
  h4.card-title { font-size: 1.1rem; }
}

/* Wide tables scroll sideways on phones */
@media (max-width: 767.98px) {
  table, .table { width: 100% !important; }
  .table, table.dataTable {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }
  .dataTables_wrapper .row { margin-left: 0; margin-right: 0; }
}

/* Coloured cards keep their background; text on them stays readable */
.card.card-dark-blue    { background: #4747A1 !important; color: #fff !important; }
.card.card-light-blue   { background: #7978E9 !important; color: #fff !important; }
.card.card-light-danger { background: #F3797E !important; color: #fff !important; }
.card.card-dark-blue .card-description,
.card.card-light-blue .card-description,
.card.card-light-danger .card-description { color: #fff !important; }

/* Ticked / starred / arrow lists at every width (the template only styles them from 768px);
   wrapped lines line up with the first line */
.list-ticked,
.list-arrow,
.list-star { list-style: none; padding: 0; }
.list-ticked li,
.list-arrow li,
.list-star li { position: relative; padding-left: 1.5rem; }
.list-ticked li:before,
.list-arrow li:before,
.list-star li:before {
  font-family: "themify";
  font-size: .6rem;
  position: absolute;
  left: 0;
  top: 0.45em;
  margin: 0;
}
.list-ticked li:before { content: '\e64c'; color: #ffffff; }
.list-arrow li:before { content: '\e649'; color: #000000; }
.list-star li:before { content: '\e60a'; color: #ffffff; }


/* =========================
   Calculator form
   ========================= */

/* One radio style everywhere: the template's purple ring with a filled dot */
.form-check { display: flex; align-items: center; margin: 0; min-height: 0; }
.form-check .form-check-label {
  position: static;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
  padding-left: 0;
  white-space: normal;
}
.form-check .form-check-label::before,
.form-check .form-check-label::after,
.form-check .input-helper { display: none !important; }
.form-check .form-check-label input[type="radio"] {
  position: static;
  flex: none;
  width: 20px;
  height: 20px;
  margin: 0;
  opacity: 1;
  -webkit-appearance: none;
     -moz-appearance: none;
          appearance: none;
  border: 2px solid #4B49AC;
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
  transition: box-shadow .15s ease-out, background-color .15s ease-out;
}
.form-check .form-check-label input[type="radio"]:checked {
  background: #4B49AC;
  box-shadow: inset 0 0 0 3px #fff;
}
.form-check .form-check-label input[type="radio"]:focus { outline: none; }
.form-check .form-check-label input[type="radio"]:focus-visible {
  outline: 2px solid #4B49AC;
  outline-offset: 2px;
}
.form-check .form-check-label input[type="radio"]:hover:not(:checked) {
  box-shadow: 0 0 0 4px rgba(75, 73, 172, .12);
}

.form-group > .form-check + .form-check { margin-top: 0.75rem; }

/* Answer grids (Yes / No, Left / Right / Both / None): radios centred under their heading */
.col-sm-2-grid, .col-sm-2-grid-text,
.col-sm-3-grid, .col-sm-3-text,
.col-sm-4-grid, .col-sm-4-text {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 4px;
  padding-right: 4px;
}
.col-sm-2-grid-text .form-check-label,
.col-sm-3-text .form-check-label,
.col-sm-4-text .form-check-label { margin-left: 0 !important; font-weight: 600; }

.form-group.row {
  align-items: center;
  margin-bottom: 0 !important;
  padding: 0.55rem 0;
  border-top: 1px solid #EEF0F6;
}
.form-group.row > label.col-form-label { padding-top: 0; padding-bottom: 0; }
.form-group.row > label.col-form-label h5,
.row > label.col-form-label h5 { margin: 0 !important; line-height: 1.35; }

/* Labels with an explanation on hover or focus */
h5[data-toggle="tooltip"] {
  border-bottom: 0 !important;
  text-decoration: underline dotted;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  cursor: help;
}
h5[data-toggle="tooltip"]:focus { outline: none; }
h5[data-toggle="tooltip"]:focus-visible { outline: 2px solid #4B49AC; outline-offset: 3px; border-radius: 2px; }
h5[data-toggle="tooltip"] .ti-info-alt { font-size: 0.85rem; }

@media (max-width: 767.98px) {
  /* Label and its radios stay on one row, radios under the column headings */
  .row:has(> .col-sm-4-grid, > .col-sm-4-text, > .col-sm-3-grid, > .col-sm-3-text,
           > .col-sm-2-grid, > .col-sm-2-grid-text) { flex-wrap: nowrap; }
  .row > label.col-form-label {
    flex: 1 1 0 !important;
    max-width: none !important;
    min-width: 0;
    padding-right: 8px;
  }
  .col-sm-4-grid, .col-sm-4-text { flex: 0 0 3.75rem !important; max-width: 3.75rem !important; padding: 0 !important; }
  .col-sm-3-grid, .col-sm-3-text { flex: 0 0 3.25rem !important; max-width: 3.25rem !important; padding: 0 !important; }
  .col-sm-2-grid, .col-sm-2-grid-text { flex: 0 0 3rem !important; max-width: 3rem !important; padding: 0 !important; }
  .row > label.col-form-label h5 { font-size: 0.9rem; }
}

/* sK field: label, value, unit on one line */
.input-group { flex-wrap: nowrap; }
.input-group-text { display: flex; align-items: center; height: 44px; }
.floatNumberField { height: 44px; min-width: 0; }
.input-group .input-group-text:not(.bg-primary) { background-color: #fff !important; color: inherit !important; border-color: #ced4da !important; }
.input-group-text.bg-primary { background: #4747A1 !important; color: #fff !important; }
.input-group-text.bg-primary h5 {
  margin: 0 !important;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration-color: rgba(255, 255, 255, .7);
}
.input-group-text .ti-info-alt { color: #fff; opacity: .9; font-size: .95rem; }
.form-control:not(:disabled):not([readonly]) { background-color: #fff !important; }

/* Submit / Cancel */
.calc-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}
.calc-actions .btn { margin: 0 !important; }
.calc-actions .btn-primary { flex: 1 1 60%; }
.calc-actions .btn-light { flex: 0 0 25%; }
@media (max-width: 575.98px) {
  .calc-actions .btn { flex: 1 1 100%; }
}

/* Shown when Faguer's score is picked without any finding */
.calc-alert {
  flex: 1 1 100%;
  margin: 0;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  background: #FDECEC;
  color: #8A1F24;
  font-size: 0.875rem;
  line-height: 1.45;
}
.calc-alert[hidden] { display: none; }
