label {
  margin-bottom: 6px;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group.required .control-label::after,
.form-group.required .label-heading::after {
  content: '*';
  color: red;
  margin-left: 1px;
}

.custom-file-label {
  padding: 10px 28px 10px 15px;
  border-color: #e8e8e8;
  border-radius: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0;
}

.custom-file-label.selected {
  padding-left: 112px;
}

.custom-file-label::after {
  display: block;
  position: absolute;
  top: 5px;
  right: auto;
  left: 6px;
  bottom: auto;
  height: 34px;
  padding: 5px 12px;
  color: #495057;
  font-size: 14px;
  line-height: 1.5;
  background-color: #f6f7fa;
  border: 1px solid #e8e8e8 !important;
  border-radius: 3px;
  border-left: inherit;
  cursor: pointer;
  transition: 0.3s;
  z-index: 3;
}

.custom-file-input:lang(en) ~ .custom-file-label::after {
  content: "Choose File";
}

.custom-file-input,
.custom-file-label {
  height: 46px;
}

.custom-file .image-preview {
  position: relative;
  display: flex;
  align-self: start;
  flex-grow: 0;
}

.custom-file .image-preview img,
.image-preview-outside img {
  display: block;
  width: auto !important;
  height: auto !important;
  max-width: 300px;
  max-height: 0;
}

p.small.text-muted.mt-1.mb-2 {
  margin-bottom: 0 !important;
}

.custom-file.custom-file__with-preview {
  display: flex;
  flex-direction: column;
  height: auto;
}

.custom-file__with-preview .image-preview:has(img[src]:not([src=""])) {
  margin-top: 16px;
}

.custom-file__with-preview .image-preview img[src]:not([src=""]) {
  padding: 12px 14px;
  border-radius: 9px;
  border: 1px dashed #dcdcdc;
  max-height: 150px;
  transition: max-height 0.5s;
}

.image-preview-outside img[src]:not([src=""]) {
  max-height: 150px;
  transition: max-height 0.5s;
}

.upload_file_with_preview__reset_input_btn,
.upload_file_with_preview__delete_upload_btn {
  display: none;
  position: absolute;
  z-index: 2;
  transition: 0.3s;
}

.upload_file_with_preview__reset_input_btn:focus,
.upload_file_with_preview__delete_upload_btn:focus {
  outline: none;
}

.upload_file_with_preview__reset_input_btn svg,
.upload_file_with_preview__delete_upload_btn svg {
  transition: 0.3s;
}

.upload_file_with_preview__reset_input_btn {
  background: #ffffff;
  border: none;
  border-radius: 0;
  color: #8d959d;
  opacity: 0.65;
  padding-top: 5px;
  padding-bottom: 5px;
  top: 5px;
  right: 5px;
}

.upload_file_with_preview__delete_upload_btn svg {
  opacity: 0.4;
  width: 18px;
  height: auto;
}

.upload_file_with_preview__delete_upload_btn:hover {
  background-color: #D6DCE3;
  border-color: #D6DCE3;
}

.upload_file_with_preview__delete_upload_btn:hover svg {
  opacity: 1;
}

.upload_file_with_preview__delete_upload_btn {
  align-items: center;
  justify-content: center;
  background: #F6F7FA;
  border: 1px solid #E8E8E8;
  border-radius: 50px;
  padding: 4px;
  width: 24px;
  height: 24px;
  top: -10px;
  right: -8px;
}

.upload_file_with_preview__delete_upload_btn svg {
  width: 14px;
  height: auto;
}

.upload_file_with_preview__reset_input_btn:hover {
  opacity: 1;
}

.upload_file_with_preview__reset_input_btn:hover svg {
  color: #212529;
}

.custom-file__with-preview .image-preview:has(img[src]:not([src=""])) .upload_file_with_preview__delete_upload_btn {
  display: flex;
}