/* Styling for UI components. Generally anything composed of multiple elements and multiple classes like navbars and modals. */

.material-symbols-outlined {
  font-variation-settings: "FILL" 0, "wght" 300, "GRAD" 0, "opsz" 24;
  display: flex;

  --icon-size: 24px;
  width: var(--icon-size);
  height: var(--icon-size);
  font-size: var(--icon-size);
}
.icon-lg {
  --icon-size: 32px;
}

.dropdown-menu {
  --bs-dropdown-link-active-color: var(--bs-body-bg);
  --bs-dropdown-link-active-bg: var(--bs-body-color);
  --bs-dropdown-link-hover-color: var(--bs-body-color);
  --bs-dropdown-link-hover-bg: var(--bg-light);
}
.dropdown-item {
  transition: background-color 0.2s ease-in-out;
  cursor: pointer;
}

.card-header {
  background: transparent;
  padding: var(--bs-card-spacer-y) var(--bs-card-spacer-x);
}

.nav-tabs .nav-link {
  color: var(--bs-body-color);
  --bs-nav-tabs-link-active-bg: transparent;
  transition: none;
  border: none;
  --bs-nav-link-padding-x: 2rem;
  --bs-nav-link-padding-y: 0.5rem;
}
.nav-tabs .nav-link.active {
  border-bottom: 4px solid var(--color-highlight) !important;
  margin-bottom: 0;
}

.stoplight {
  width: 3em;
  height: 3em;
  aspect-ratio: 1;
  border-radius: 100%;
  border: 1px solid var(--color-border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
}
.stoplight-md {
  width: 2em;
  height: 2em;
}
.stoplight-sm {
  width: 1.5em;
  height: 1.5em;
}
.stoplight-xs {
  width: 1em;
  height: 1em;
}
.stoplight-red {
  background-color: var(--color-stoplight-red);
}
.stoplight-green {
  background-color: var(--color-stoplight-green);
}
.stoplight-yellow {
  background-color: var(--color-stoplight-yellow);
}
.stoplight-na,
.stoplight-does-not-apply {
  background-color: var(--color-stoplight-does-not-apply);
}
.stoplight-skipped {
  background-color: var(--color-stoplight-skipped);
}
/* Indicator question without an answer */
.stoplight-unanswered {
  border: none;
}
.stoplight-unanswered:after {
  content: "-";
}
/* Indicator answer with undefined state (useful for error feedback)  */
.stoplight-error:after {
  content: "?";
}

details .summary-expand-icon {
  display: inline-flex;
  transition: transform 0.2s ease-in-out;
  user-select: none;
  margin-left: -0.2em;
  transform: rotate(0deg) translateX(-0.1em) translateY(-0.05em);
}
details[open] .summary-expand-icon {
  transform: rotate(90deg) translateY(0.1em);
}
