
.checkbox-composite {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: horizontal;
  -webkit-box-direction: normal;
  -ms-flex-direction: row;
  flex-direction: row;
  align-items: center;
  margin-bottom: 1rem;
}
.checkbox-composite.no-margin {
  margin: 0;
}
.checkbox-composite.label-left input {
  margin-left: 0.5rem;
  order: 1;
}
.checkbox-composite label {
  -webkit-box-flex: 1;
  -ms-flex: 1;
  flex: 1;
  height: unset;
  width: unset;
  margin-left: 1rem;
  color: var(--c-font-label);
}
.checkbox-composite .label-container {
  flex: 1;
}

.checkbox-label-composite {
  flex-flow: row-reverse;
}
.checkbox-label-composite pragma-checkbox:focus {
  border-radius: 0.25rem;
}
.checkbox-label-composite pragma-checkbox[aria-checked=true] svg {
  fill: var(--c-accent);
}
.checkbox-label-composite pragma-checkbox[disabled] svg {
  fill: var(--c-sc-disabled);
}
.checkbox-label-composite pragma-checkbox[readonly] svg {
  fill: var(--c-sc-disabled);
}

input[type=checkbox] {
  width: 1.5rem;
  height: 1.5rem;
  background-color: transparent;
  position: relative;
  outline: none;
  border: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

input[type=checkbox]:before {
  display: block;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' style='fill: rgb(2, 118, 194)' width='32' height='32' viewBox='0 0 24 24'><path d='M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z'/></svg>");
  background-position: center;
  background-size: contain;
  width: 1.5rem;
  height: 1.5rem;
  line-height: 1.5rem;
  content: "";
  position: absolute;
  box-sizing: border-box;
  border-radius: 0.25rem;
}

input[type=checkbox][disabled=true]:checked:before {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' style='fill: rgb(222, 220, 223)' width='32' height='32' viewBox='0 0 24 24'><path d='M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z'/></svg>");
}

input[type=checkbox][disabled=true]:before {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' style='fill: rgb(216, 216, 216)' width='32' height='32' viewBox='0 0 24 24'><path d='M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z'/></svg>");
}

input[type=checkbox]:checked:before {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' style='fill: rgb(2, 118, 194)' width='32' height='32' viewBox='0 0 24 24'><path d='M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z'/></svg>");
}

input[type=checkbox]:focus:before {
  box-shadow: inset 0 0 0 0.2rem var(--c-focus);
}

input[type=checkbox]:hover:before {
  box-shadow: inset 0 0 0 0.2rem var(--c-hover);
}

input[type=checkbox]:focus,
input[type=checkbox]:hover {
  box-shadow: none;
}
