.modal-mask {
  position: fixed;
  z-index: 900;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0!important;
  background-color: rgba(0, 0, 0, .5);
  transition: opacity .3s ease;
}

.modal-container {
  position: relative;
  top: 10%;
  display: flex;
  width: 90%;
  max-height: 80%;
  margin: 0 auto;
  background-color: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .33);
  font-family: Helvetica, Arial, sans-serif;
  overflow: hidden;
}

.modal-container > .modal-buttons {
  position: absolute;
  top: 5px;
  right: 5px;
  display: flex;
  z-index: 100;
}

.modal-container > .modal-buttons > .btn {
  display: flex;
  padding: 6px;
  font-size: 20px;
}

.modal-container .dynamic-loading {
  background-color: rgba(0, 0, 0, .1);
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  z-index: 200;
}

.modal-container .dynamic-loading .spinner-holder {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.modal-contents {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-height: 100%;
  overflow: visible;
}

.modal-header h3 {
  margin: 0;
  color: #42b983;
}

.modal-body {
  flex-grow: 1;
  overflow: auto;
  margin: 0;
}

.modal-body h5 {
  margin: 0;
}

.modal-body > .form-horizontal {
  margin-bottom: -15px;
}

.modal-body > .form-horizontal .form-group {
  margin-top: -5px;
  padding-top: 5px;
}

.modal-body > .form-horizontal .form-group.focus {
  position: relative;
}

.modal-body > .form-horizontal .form-group.focus::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  animation-name: form-group-focus;
  animation-duration:2s;
  background-image: linear-gradient(rgba(243, 187, 69, 0.2), rgba(243, 187, 69, 0.2));
  background-size: calc(100% - 20px) calc(100% + 5px);
  background-repeat: no-repeat;
  background-position: top 0 left 10px;
}

@keyframes form-group-focus {
  0%, 80% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

.modal-body .table-responsive {
  max-height: calc(80vh - 165px);
}

.modal-container .form-control,
.modal-container .form-select {
  display: block;
  width: 100%;
}

.modal-container.click-mask .modal-header,
.modal-container.use-fullscreen .modal-header {
  padding-right: 46px;
}

.modal-container.click-mask:not(:has(.modal-header)),
.modal-container.use-fullscreen:not(:has(.modal-header)) {
  padding-top: 46px;
}

.modal-container.click-mask.use-fullscreen .modal-header {
  padding-right: 87px;
}

@media (min-width: 768px) {
  .modal-container {
    min-width: 600px;
    max-width: 700px;
  }

  .modal-container.large {
    max-width: 1080px;
  }
}

.modal-container.full {
  width: 95%;
  max-width: none;
}

.modal-container.fullscreen {
  top: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  border-radius: 0;
}

.modal-footer .btn+.btn {
  margin: 0;
}

/*
 * The following styles are auto-applied to elements with
 * transition="modal" when their visibility is toggled
 * by Vue.js.
 *
 * You can easily play with the modal transition by editing
 * these styles.
 */

.modal-enter {
  opacity: 0;
}

.modal-leave-active {
  opacity: 0;
}

/*-------------------
 FIX: Safari bug
---------------------*/
@media (min-width: 992px) {
  .modal-open .main-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding-left: 200px;
    background: linear-gradient(90deg, transparent 0%, transparent 200px, #f4f3ef 200px, #f4f3ef 100%);
    transition: none;
  }

  .sidebar-mini .modal-open .main-panel {
    width: 100%;
    padding-left: 60px;
    background: linear-gradient(90deg, transparent 0%, transparent 60px, #f4f3ef 60px, #f4f3ef 100%);
  }
}

/*-------------------
 Draggable Modal
---------------------*/
.draggable-modal.modal-container {
  position: fixed;
  max-width: 100%;
  max-height: 100%;
  min-width: 150px;
  min-height: 60px;
  margin: 0;
  border-radius: 5px;
  transition: opacity .3s ease;
  overflow: visible;
}

.draggable-modal.modal-container.is-hide {
  height: 30px !important;
  min-height: 30px;
}

.draggable-modal .modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 30px;
  padding: 3px 3px 3px 7px;
  background-color: #F3F2EE;
}

.draggable-modal .modal-header:before,
.draggable-modal .modal-header:after {
  content: none;
}

.draggable-modal .modal-header .title  {
  flex: 1;
  font-size: 16px;
  font-weight: bold;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  cursor: grab;
}

.draggable-modal .modal-header .title.is-dragging {
  cursor: grabbing;
}

.draggable-modal .modal-header .buttons {
  display: flex;
  align-items: center;
  cursor: default;
}

.draggable-modal .modal-header .buttons .btn {
  padding: 0 3px;
  border: none !important;
}

.draggable-modal .modal-body {
  padding: 7px;
}

.draggable-modal .resize {
  position: absolute;
}

.draggable-modal .resize.horizontal {
  right: 0;
  left: 0;
  height: 6px;
}

.draggable-modal .resize.top {
  top: -3px;
  cursor: ns-resize;
}

.draggable-modal .resize.bottom {
  bottom: -3px;
  cursor: ns-resize;
}

.draggable-modal .resize.vertical {
  top: 0;
  bottom: 0;
  width: 6px;
}

.draggable-modal .resize.left {
  left: -2px;
  cursor: ew-resize;
}

.draggable-modal .resize.right {
  right: -2px;
  cursor: ew-resize;
}

.draggable-modal .resize.corner {
  width: 10px;
  height: 10px;
  z-index: 1;
}

.draggable-modal .resize.tleft {
  top: -3px;
  left: -3px;
  cursor: nwse-resize;
}

.draggable-modal .resize.tright {
  top: -3px;
  right: -3px;
  cursor: nesw-resize;
}

.draggable-modal .resize.bleft {
  bottom: -3px;
  left: -3px;
  cursor: nesw-resize;
}

.draggable-modal .resize.bright {
  right: -3px;
  bottom: -3px;
  cursor: nwse-resize;
  width: 15px;
  height: 15px;
}

.draggable-modal .resize.bright .handle {
  position: relative;
  width: 10px;
  height: 10px;
  overflow: hidden;
}

.draggable-modal .resize.bright .handle i {
  position: absolute;
  top: 0;
  left: 0;
  transform: rotate(45deg);
  color: #66615B;
}
