@layer base {
  form {
    font-family: "Mulish", sans-serif;
  }
  .btn {
    padding: 0.5rem 1rem;
    cursor: pointer;
    outline: none;
    border-radius: 0.125rem;
    --tw-ring-offset-shadow: none;
    --tw-ring-shadow: none;
    box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow);
    /*&:focus {*/
    /*  box-shadow: 0 0 0 2px var(--tw-ring-color);*/
    /*  outline-offset: 1px;*/
    /*}*/

    &.btn-primary {
      background-color: #0ab39c;
      color: white !important;
      &:hover {
        background-color: #099885;
      }
      &:focus {
        --tw-ring-color: #3b82f6;
      }
    }

    &.btn-primary-outline {
      border: 1px solid #3b82f6;
      color: #1d4ed8;
      &:hover {
        background-color: #1d4ed8;
        color: white;
      }
      &:focus {
        --tw-ring-color: #1d4ed8;
      }
    }
    &.btn-secondary {
      background-color: #F4F4F6;
      border-color: transparent;
    }
    &.btn-danger {
      background-color: #dc2626;
      color: white !important;
      &:hover {
        background-color: #b91c1c;
      }
      &:focus {
        --tw-ring-color: #ef4444;
      }
    }
  }

  .checkbox-group {
    label {
      margin-left: 0.5rem;
      display: block;
      font-weight: 500;
      color: #4b5563;
      cursor: pointer;
    }

    input {
      height: 1rem;
      width: 1rem;
      border-radius: 0.125rem;
      background-color: white;
      color: #475281;
      border: 1px solid #e5e7eb;
      font-size: 1.125rem;

      &:focus {
        --tw-ring-color: #93c5fd;
        border-color: #93c5fd;
        box-shadow: 0 0 0 2px var(--tw-ring-color);
      }
    }
  }

  .form-group {
    margin: 10px 0;
    width: 100%;
    label {
      display: block;
      /*font-weight: 500;*/
      /*color: #4b5563;*/
      cursor: pointer;
      margin-bottom: 0.2rem;
      font-size: 14px;
      font-weight: bold;

      &.is-invalid {
        color: #ef4444;
      }
    }

    input,
    select, textarea {
      -webkit-appearance: none;
      -moz-appearance: none;
      appearance: none;
      width: 100%;
      /*max-width: 40rem;*/
      background-color: white;
      color: #878a99;
      border: 1px solid #ced4da;
      border-radius: 0.25rem;
      padding: .4rem .7rem;
      outline: thick #878a99;

      &:focus {
        color: #495057;
        border-color: #878a99;
      }

      &.is-invalid {
        border-color: #ef4444;
        --tw-ring-color: #dc2626;
        &:focus {
          box-shadow: 0 0 0 2px var(--tw-ring-color);
        }
      }
    }

    input::placeholder {
      font-size: 14px;
      color: #878a99;
    }

    input[type="file"]::-webkit-file-upload-button {
      padding: 0.5rem 2rem;
      background-color: white;
      border: 1px solid #3b82f6;
      color: #1d4ed8;
      font-size: 0.875rem;
      box-shadow: unset;
      outline: none;

      &:hover {
        background-color: #1d4ed8;
        color: white;
      }

      &:focus {
        --tw-ring-color: #1d4ed8;
        box-shadow: 0 0 0 2px var(--tw-ring-color);
      }
    }
  }
  .card {
    --color-bg: white;
    background-color: white;
    padding: 15px;
    .card-header {
      color: #4B5057;
      padding: 10px;
    }
  }
  .list-items turbo-frame:not(:last-child) > :first-child {
    border-bottom: 1px solid oklch(0.871 0.006 286.286) !important;
  }
  .t-header {
    background-color: #F4F6F9;
    padding: 10px;
    color: #878a99;
    font-size: 15px;
  }

  .dropdown-content {
    top: calc(100% - 0.25rem);
    left: 50%;
    transform: rotateX(-90deg) translateX(-50%);
    transform-origin: top;
    opacity: 0.1;
    transition: 280ms all ease-out;
    z-index: 20;
  }
  .dropdown-content.open {
    opacity: 1;
    transform: rotateX(0) translateX(-50%);
    visibility: visible;
  }
}

.filter-form {
  display: flex;
  color: #212529;
  font-size: 15px;
  input, select {
    display: block;
    width: 100%;
    padding: .5rem .9rem;
    line-height: 1.5;
    outline: none;
    border: 0;
    background-color: #f3f6f9;
  }
  @media (width < 40rem) {
    display: block;
    width: 100%;
    input, select {
      margin: 5px 0;
      padding: .3rem .5rem;
    }
  }
}
