.elegso-cutoff-field,
.elegso-cutoff-field *,
.elegso-cutoff-field *::before,
.elegso-cutoff-field *::after {
  box-sizing: border-box;
}

.elegso-cutoff-field {
  position: relative;
  display: grid;
  align-content: start;
  gap: 6px;
  width: min(100%, 300px);
  margin: 0;
  color: #252d2b;
  font-family: Ubuntu, system-ui, -apple-system, "Segoe UI", sans-serif;
}

.elegso-cutoff-label {
  display: flex;
  align-items: center;
  min-height: 18px;
  gap: 7px;
  color: #4f5e5b;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.25;
}

.elegso-cutoff-badge {
  display: inline-flex;
  align-items: center;
  min-height: 18px;
  padding: 2px 7px;
  border: 1px solid rgba(53, 90, 86, 0.22);
  border-radius: 999px;
  background: #eef3f1;
  color: #355a56;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.025em;
  line-height: 1;
  white-space: nowrap;
}

.elegso-cutoff-date-wrap {
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
}

#elegso-saldo-ab .elegso-cutoff-input,
#elegso-saldo-print .elegso-cutoff-input {
  width: 100%;
  min-width: 0;
  height: 40px;
  margin: 0;
  padding: 8px 11px;
  border: 1px solid #d7dfdd;
  border-radius: 10px;
  outline: none;
  background: #fff;
  color: #252d2b;
  font: 400 14px/1.25 Ubuntu, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-variant-numeric: tabular-nums;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

#elegso-saldo-ab .elegso-cutoff-input::placeholder,
#elegso-saldo-print .elegso-cutoff-input::placeholder {
  color: #89918f;
  opacity: 1;
}

#elegso-saldo-ab .elegso-cutoff-input:focus,
#elegso-saldo-print .elegso-cutoff-input:focus {
  border-color: #355a56;
  box-shadow: 0 0 0 3px rgba(53, 90, 86, 0.14);
}

#elegso-saldo-ab .elegso-cutoff-input[aria-invalid="true"],
#elegso-saldo-print .elegso-cutoff-input[aria-invalid="true"] {
  border-color: #b33838;
  box-shadow: 0 0 0 3px rgba(179, 56, 56, 0.1);
}

#elegso-saldo-ab .elegso-cutoff-input:disabled,
#elegso-saldo-print .elegso-cutoff-input:disabled {
  cursor: wait;
  background: #f4f6f5;
  color: #707976;
}

#elegso-saldo-ab .elegso-cutoff-icon-button,
#elegso-saldo-print .elegso-cutoff-icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  min-width: 40px;
  margin: 0;
  padding: 0;
  border: 1px solid #d7dfdd;
  border-radius: 10px;
  background: #fff;
  color: #355a56;
  cursor: pointer;
  transition: color 160ms ease, background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

#elegso-saldo-ab .elegso-cutoff-icon-button:hover,
#elegso-saldo-print .elegso-cutoff-icon-button:hover {
  border-color: #355a56;
  background: #eef3f1;
}

#elegso-saldo-ab .elegso-cutoff-icon-button:focus-visible,
#elegso-saldo-print .elegso-cutoff-icon-button:focus-visible {
  outline: 3px solid rgba(53, 90, 86, 0.18);
  outline-offset: 2px;
}

#elegso-saldo-ab .elegso-cutoff-icon-button:active,
#elegso-saldo-print .elegso-cutoff-icon-button:active {
  transform: translateY(1px);
}

#elegso-saldo-ab .elegso-cutoff-icon-button:disabled,
#elegso-saldo-print .elegso-cutoff-icon-button:disabled {
  cursor: wait;
  opacity: 0.55;
}

.elegso-cutoff-icon-button svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

#elegso-saldo-ab .elegso-cutoff-clear,
#elegso-saldo-print .elegso-cutoff-clear {
  color: #7c4747;
}

#elegso-saldo-ab .elegso-cutoff-clear:hover,
#elegso-saldo-print .elegso-cutoff-clear:hover {
  border-color: #b56b6b;
  background: #fff4f3;
}

.elegso-cutoff-native-date {
  position: absolute;
  right: 46px;
  bottom: 0;
  width: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

.elegso-cutoff-help,
.elegso-cutoff-error,
.elegso-cutoff-status {
  position: absolute;
  top: calc(100% + 5px);
  left: 0;
  z-index: 2;
  display: block;
  max-width: 300px;
  font-size: 11px;
  line-height: 1.35;
}

#elegso-saldo-ab .hdr,
#elegso-saldo-print > .row {
  margin-bottom: 44px;
}

#elegso-saldo-ab .ctrls {
  flex: 1 1 700px;
  justify-content: flex-end;
}

.elegso-cutoff-help {
  color: #68726f;
}

.elegso-cutoff-error {
  color: #a72f2f;
  font-weight: 600;
}

.elegso-cutoff-status {
  min-height: 0;
  color: #68726f;
}

.elegso-cutoff-status:empty {
  display: none;
}

.elegso-cutoff-status[data-kind="success"] {
  color: #2d6b4d;
}

.elegso-cutoff-status[data-kind="error"] {
  color: #a72f2f;
  font-weight: 600;
}

.elegso-cutoff-status[data-kind="pending"] {
  color: #5d6a67;
}

.elegso-cutoff-field [hidden] {
  display: none !important;
}

@media (max-width: 640px) {
  #elegso-saldo-ab .hdr,
  #elegso-saldo-print > .row {
    margin-bottom: 0;
  }

  #elegso-saldo-ab .ctrls,
  #elegso-saldo-print > .row {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    width: 100%;
    gap: 14px;
  }

  #elegso-saldo-ab .ctrls {
    justify-content: stretch;
  }

  #elegso-saldo-ab .ctrls > *,
  #elegso-saldo-print > .row > *,
  .elegso-cutoff-field {
    width: 100%;
    max-width: none;
  }

  #elegso-saldo-ab .elegso-cutoff-input,
  #elegso-saldo-print .elegso-cutoff-input {
    height: 46px;
    font-size: 16px;
  }

  #elegso-saldo-ab .elegso-cutoff-icon-button,
  #elegso-saldo-print .elegso-cutoff-icon-button {
    width: 46px;
    height: 46px;
    min-width: 46px;
  }

  .elegso-cutoff-date-wrap {
    display: flex;
  }

  .elegso-cutoff-help,
  .elegso-cutoff-error,
  .elegso-cutoff-status {
    position: static;
    max-width: none;
    font-size: 12px;
  }

  #elegso-saldo-ab #btnBuild,
  #elegso-saldo-print #btnPrint {
    justify-content: center;
    width: 100%;
    min-height: 46px;
  }
}
