/* SCUZO RC6722 — typed text, caret, placeholders and autofill stay readable.
 * Applies only when the matching background color has been measured by the JS
 * contrast guard. Leave checkboxes, native color/file controls and buttons alone.
 * Never turn light-background inputs white-on-white. */
:where(input,textarea,select).scuzo-rc6722-dark-control,
#appView :is(input,textarea,select).scuzo-rc6722-dark-control {
  color: #f7fbff !important;
  -webkit-text-fill-color: #f7fbff !important;
  caret-color: #f7fbff !important;
  color-scheme: dark;
}
:where(input,textarea).scuzo-rc6722-dark-control::placeholder,
#appView :is(input,textarea).scuzo-rc6722-dark-control::placeholder {
  color: #b9cad9 !important;
  -webkit-text-fill-color: #b9cad9 !important;
  opacity: 1 !important;
}
:where(input,textarea,select).scuzo-rc6722-dark-control:disabled,
#appView :is(input,textarea,select).scuzo-rc6722-dark-control:disabled {
  color: #d2dde6 !important;
  -webkit-text-fill-color: #d2dde6 !important;
}
:where(select).scuzo-rc6722-dark-control option,
#appView select.scuzo-rc6722-dark-control option {
  color: #f7fbff !important;
  -webkit-text-fill-color: #f7fbff !important;
  background-color: #20262c !important;
}
:where(input,textarea,select).scuzo-rc6722-light-control,
#appView :is(input,textarea,select).scuzo-rc6722-light-control {
  color: #162434 !important;
  -webkit-text-fill-color: #162434 !important;
  caret-color: #162434 !important;
  color-scheme: light;
}
:where(input,textarea).scuzo-rc6722-light-control::placeholder,
#appView :is(input,textarea).scuzo-rc6722-light-control::placeholder {
  color: #506579 !important;
  -webkit-text-fill-color: #506579 !important;
  opacity: 1 !important;
}
:where(select).scuzo-rc6722-light-control option,
#appView select.scuzo-rc6722-light-control option {
  color: #162434 !important;
  -webkit-text-fill-color: #162434 !important;
  background-color: #fff !important;
}
/* WebKit autofill previously retained a yellow/light surface with inherited
 * dark fill in places, or a dark background with black autofill text. */
input.scuzo-rc6722-dark-control:-webkit-autofill,
input.scuzo-rc6722-dark-control:-webkit-autofill:focus {
  -webkit-text-fill-color: #f7fbff !important;
  -webkit-box-shadow: 0 0 0 1000px #21272d inset !important;
  caret-color: #f7fbff !important;
  transition: background-color 5000s ease-in-out 0s;
}
input.scuzo-rc6722-light-control:-webkit-autofill,
input.scuzo-rc6722-light-control:-webkit-autofill:focus {
  -webkit-text-fill-color: #162434 !important;
  caret-color: #162434 !important;
}
/* RC6734: Removed obsolete always-white Manager/Cashier fallback.
 * Those fields can have LIGHT backgrounds. The RC6722 computed contrast classes
 * determine text fill; never force light text independent of the background.
 */
/* The visible Store wizard is sometimes mounted inside parent panels; avoid
 * inherited -webkit-text-fill-color overriding its dark editable fields. */
#appView #storeForm :is(input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=color]),select,textarea):not(.scuzo-rc6722-light-control) {
  -webkit-text-fill-color: #f7fbff !important;
  caret-color:#f7fbff !important;
}
