/* ------------------------------------------------------------------------- */
/* Base */

.preInit {
  visibility: hidden;
  opacity: 0;
}

.live {
  visibility: visible !important;
  opacity: 1 !important;
  transition: opacity 1s;
}

@media (prefers-color-scheme: light) {
  :root {
    background-color: #F5F5F5;
    color: black;
    border-color: #C5C5C5;
    font-size: 12pt;
  }

  select,
  input[type="text"],
  input[type="password"] {
    border: solid #C5C5C5 1px;
    background-color: #F5F5F5;
  }

  option {
    background-color: white;
    color: black;
  }

  a {
    color: blue;
  }

  .tool:focus,
  .submenu-item:focus,
  .command-item:focus {
    background-color: #F0F0F0 !important;
    border-radius: 4px;
    outline: none !important;
  }

  input:focus {
    background-color: white !important;
    border: solid #C5C5C5 1px;
  }

  select:read-only,
  input:read-only
  textarea:read-only {
    background-color: transparent;
    color: gray;
    cursor: default !important;
  }

  text-area {
    border: solid #C5C5C5 1px;
  }

  *:disabled {
    color: gainsboro !important;
    background-color: transparent !important;
    border-color: gainsboro !important;
    cursor: default !important;
  }

  *::placeholder {
    color: lightgray;
  }

  *:disabled::placeholder {
    visibility: hidden;
  }

  textarea:focus {
    background-color: white;
    color: black;
  }

  input[type='button'],
  button {
    background-color: #DDDDDD;
    color: black;
  }

  dialog {
    background-color: #F5F6F7;
    color: black;
    border-color: #C5C5C5 !important;
    box-shadow: 5px 5px 5px rgba(200, 200, 200, 0.5);
  }

  .formSheet {
    background-color: #F5F5F5;
    color: black;
  }

  .border {
    border-color: #C5C5C5;
  }

  .divider {
    border-color: #C5C5C5;
  }

  #alert {
    border-color: #F5F5F5 !important;
  }

  .menu {
    background-color: white;
    color: black;
    border-color: #C5C5C5;
    box-shadow: 4px 4px 4px rgba(200, 200, 200, 0.5);
  }

  .menuActive {
    background-color: white;
    color: black;
    border-color:gray !important;
    box-shadow: 2px 0 2px rgba(200, 200, 200, 0.5);
  }

  .ribbon {
    background-color: #FFFFFF;
    border-left-width: 1px !important;
    border-right-width: 1px !important;
    box-shadow: 0 2px #d9d9d9 !important;
  }

  .ribbon .expansion {
    background-color: #FFFFFF;
    box-shadow: 0 2px #d9d9d9 !important;
  }

  .ribbon .showAll {
    filter: invert(0.6);
  }

  .ribbon.file {
    /* background-image: url(../../images/Knurling.light.png); */
  }

  .sidePanel {
    background-color: #EFEFEF;
  }

  .subPanel:not(:last-child) {
    border-bottom: solid 1px #C5C5C5 !important;
  }

  .ui-splitbar {
    background-color: transparent !important;
    border-color: transparent !important;
    background-image: none !important;
  }

  .canvas {
    background-color: #FFFFFF;
  }

  .view {

  }

  .appLogo {
    filter: invert(0.6) !important;
  }

  #importDialog-workflow {
    background-color: #EAEAEA;
  }

  img.icon {
    /* filter: grayscale(100%); */
  }

  img.info {
    background-color: #ECECEC;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    background-color: #141414;
    color: #D5D5D5;
  }

  select,
  input[type="text"],
  input[type="password"],
  textarea {
    border: solid gray 1px;
    background-color: white;
    color: black;
  }

  .tool:focus,
  .submenu-item:focus,
  .command-item:focus {
    background-color: #383838 !important;
    border-radius: 5px;
    outline: none !important;
  }

  input:focus {
    background-color: white !important;
  }

  select:read-only,
  input:read-only,
  textarea:read-only {
    background-color: transparent !important;
    color: gray;
    cursor: default !important;
  }

  *:disabled {
    color: #505050 !important;
    background-color: transparent !important;
    border-color: #505050 !important;
    cursor: default !important;
  }

  *::placeholder {
    color: silver;
  }

  *:disabled::placeholder {
    visibility: hidden;
  }

  option {
    background-color: #292929;
    color: white;
  }

  a {
    color: steelblue;
  }

  input[type='button'],
  button {
    background-color: #444444 ;
    color: white;
  }

  dialog {
    background-color: #292929;
    color: white;
    border-color:gray !important;
    box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.7);
  }

  .formSheet {
    background-color: #141414;
    color: white;
  }

  .border {
    border-color: #656565;
  }

  .divider {
    border-color: #656565;
  }

  #alert {
    border-color: #141414 !important;
  }

  .menu {
    background-color: #292929;
    color: white;
    border-color:#454545;
    box-shadow: 4px 4px 4px rgba(0, 0, 0, 0.7);
  }

  .menuActive {
    background-color: #292929;
    color: white;
    border-color:#454545 !important;
    box-shadow: 2px 0 2px rgba(0, 0, 0, 0.7);
  }

  .ribbon {
    background-color: #292929;
  }

  .ribbon .expansion {
    background-color: #292929;
  }

  .ribbon.file {
    /* background-image: url(../../images/Knurling.dark.png); */
  }

  .sidePanel {
    background-color: #1A1A1A;
  }

  .subPanel:not(:last-child) {
    border-bottom: solid 1px #656565 !important;
  }

  .ui-splitbar {
    background-color: transparent !important;
    border-color: transparent !important;
    background-image: none !important;
  }

  .canvas {
    background-color: #1E1E1E;
  }

  .view {

  }

  .appLogo {
    filter: invert(0.3) !important;
  }

  #importDialog-workflow {
    background-color: #444444;
  }

  img.info {
    background-color: #333333;
  }
}

@media (forced-colors: active) {
  .tabs > .tab {
    margin-bottom: 4pt !important;
    border-bottom: 0 !important;
  }

  .tabs > .tab.active {
    margin-bottom: 4px !important;
    border-bottom: solid 3px !important;
  }

  .docBar .mode {
    border: solid lightgrey 1px !important;
  }

  .ribbon {
    border: solid lightgrey 1px !important;
  }

  .ribbon .expansion {
    border: solid lightgrey 1px !important;
    background-color: unset !important;
  }

  .ribbon .tool {
    margin: 4px !important;
    border-width: 0 !important;
  }

  .ribbon .tool:focus,
  .menu .command-item:focus {
    outline: solid #D6B4FD 1px !important;
  }

  img.icon {
    border-width: 0 !important;
    margin-top: 1px !important;
    margin-bottom: 1px !important;
  }

  .disabled {
    opacity: 0.2 !important;
  }

  .selected {
    border: dotted 1px !important;
    border-radius: 5px !important;
    padding-left: 1px !important;
  }
}

/* ------------------------------------------------------------------------- */

.lds-dual-ring {
  display: inline-block;
  width: 80px;
  height: 80px;
}

.lds-dual-ring:after {
  content: " ";
  display: block;
  width: 32px;
  height: 32px;
  margin: 10px;
  border-radius: 50%;
  border-width: 5px;
  border-style: solid;
  border-color: gray transparent gray transparent;
  animation: lds-dual-ring 1.2s linear infinite;
}

@keyframes lds-dual-ring {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* ------------------------------------------------------------------------- */
