.modal {
  position: fixed;
  display: flex;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  height: 100dvh;
  width: 100%;
  background-color: rgba(0, 0, 0, 0.098);
  pointer-events: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 0px 16px;
  z-index: 10;
  opacity: 0;
}
body.darkmode .modal{
  background-color: rgba(0, 0, 0, 0.32);
}
.modal iframe{
  width: 100%;
}
#notificationContainer_1,
#notificationContent_1,
#notification_window_1,
#notificationContainer_2,
#notificationContent_2,
#notification_window_2{
  height: 512px;
  border-radius: 6px;
}
#modal_script_message .modal-content .modal-content-container p.center{
  line-break:loose;
  overflow: hidden;
}
.modal .notificationContent{
  position: relative;
}
.modal .loadingVeil{
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background-color: #fff;
  pointer-events: none;
  opacity: 0;
}
.modal .scrollableArea{
  padding-right: 0px !important;
}
#modal_module_selection .modal-window{
  background-image: url('../../assets/backgrounds/credit-pattern.png');
  background-blend-mode: darken;
  background-size: 230%;
  background-position: -55px;
}
body.darkmode #modal_module_selection .modal-window{
  background-image: url('../../assets/backgrounds/credit-pattern-dm.png');
  background-blend-mode: overlay;
}
#modal_module_selection .modal-window::after{
  position: absolute;
  content: '';
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: rgb(255,255,255);
  background: linear-gradient(0deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.8773634453781513) 32%, rgba(255,255,255,1) 70%);
  z-index: -1;
}
body.darkmode #modal_module_selection .modal-window::after{
  background: rgb(36,49,69);
  background: linear-gradient(0deg, rgba(36,49,69,0) 0%, rgba(36,49,69,0.8773634453781513) 32%, rgba(36,49,69,1) 70%);
}

body.darkmode .modal .loadingVeil{
  background-color: var(--box-bg);
}
.modal .loadingVeil::after{
  position: absolute;
  content: '';
  height: 44px;
  width: 44px;
  background-image: url('../../assets/icons/progress_activity.svg');
  background-size: 44px;
  -webkit-animation:spin 1.5s linear infinite;
  -moz-animation:spin 1.5s linear infinite;
  animation:spin 1.5s linear infinite;
  opacity: 0.5;
}
body.darkmode .modal .loadingVeil::after{
  filter: invert(1);
}
#cookiesAlert{
  justify-content: flex-end;
  align-items: center;
  background-color: transparent !important;
}
.modal::-webkit-scrollbar {
  display: none;
}
.modal-window .gridRow {
  display: grid !important;
}
.modal-window {
  position: relative;
  display: none;
  max-height: calc(100dvh - 32px);
  width: 100%;
  background-color: rgba(255, 255, 255, 0.98);
  border-radius: 6px;
  padding: 0 24px 24px 24px;
  border: 1px solid var(--box-border-light);
  margin: 16px 0px;
  display: flex;
  flex-direction: column;
  transition: scale 50ms;
  align-items: flex-start;
  -webkit-box-shadow: 0px 16px 5px 0px rgba(0,0,0,0.16);
  -moz-box-shadow: 0px 16px 5px 0px rgba(0,0,0,0.16);
  box-shadow: 0px 16px 5px 0px rgba(0,0,0,0.16);
  scale: 0.95;
  gap: 16px;
}
.modal.open .modal-window{
  scale: 1;
  transition: scale 50ms;
  z-index: 10;
}
body.darkmode .modal-window{
  background-color: var(--box-bg);
  border: 1px solid var(--box-border);
}
.modal-window .modal-content{
  height: calc(100% - 54px - 16px) !important;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 24px;
  opacity: 1;
}
.modal-window .modal-content-container{
  height: fit-content;
  padding-top: 6px;
}
#logout .modal-window .modal-content{
  min-height: 50px !important;
  height: 100% !important;
}
.modal-window .codeDisplay{
  display: flex;
  align-self: center;
  border-radius: 6px;
  padding: 12px 16px;
  font-size: 20px;
  font-weight: 600;
  -webkit-user-select: none;
  -ms-user-select: none;
  user-select: none;
  pointer-events: none;
  border: 1px solid var(--box-border-light);
  padding: 16px;
  color: #444444;
  background-color: #FFF;
  box-shadow: 0px 6px 6px 0px rgba(0, 0, 0, 0.04);
}
body.darkmode .modal-window .codeDisplay{
  background-color: var(--box-input-bg);
  border: 1px solid var(--box-input-border);
  color: #fff;
}
.modal-window .codeError{
  display: none;
  color: #c52929;
  align-self: center;
  text-align: center;
  margin-top: -16px;
}
.modal-window .title {
  position: relative;
  display: grid;
  grid-template-columns: auto 32px;
  align-items: start;
  font-size: 14px;
  min-height: 52px;
  width: 100%;
  padding: 12px 0px;
  border-bottom: 1px solid var(--box-border-light);
  gap: 24px;
  margin: 0 !important;
}
body.darkmode .modal-window .title{
  border-bottom: 1px solid var(--box-border);
  color: #fff;
}
.modal-window .title.center {
  display: flex;
  align-items: center !important;
  justify-content: center !important;
}
.modal-window .closeWindow {
  border-radius: 6px;
  cursor: pointer;
}
.modal-window .closeWindow .icon{
  height: 32px;
  width: 32px;
  background: url("../../assets/icons/close.svg") no-repeat;
  background-position: center;
  pointer-events: none;
  filter: invert(58%) sepia(19%) saturate(4177%) hue-rotate(319deg) brightness(110%) contrast(100%);
}
.modal-window .closeWindow:hover {
  background-color: #C65959;
}
.modal-window .closeWindow:hover .icon{
  filter: invert(1);
}
.modal-window .title img{
  position: absolute;
  content: '';
  left: 0;
  top: 16px;
}
.modal-window .filePreview{
  display: flex;
  width: 100%;
  aspect-ratio: 1 / 1;
  grid-column: 1 / span 2;
  background-repeat: no-repeat;
  background-position: center;
  border-radius: 6px;
}
.modal-window .filePreview > div{
  height: 100%;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 6px;
  background-color: rgba(255, 255, 255, 0.64);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  overflow: hidden;
}
.modal p {
  line-height: 20px;
  font-size: 14px;
}
.modal p a{
  text-decoration: underline;
}
body.darkmode .modal p{
  color: #ffffff;
}
.modal p.center {
  text-align: center;
  margin-bottom: 24px;
}
.modal h5 {
  display: flex;
  height: 100%;
  font-weight: 600;
  font-size: 14px;
  align-items: center;
}
.modal .center h5 {
  text-align: center;
}
.modal h6 {
  text-align: center;
}
.close {
  position: absolute;
  top: 0;
  right: 0;
  color: rgba(0, 0, 0, 0.3);
  height: 30px;
  width: 30px;
  font-size: 30px;
  line-height: 30px;
  text-align: center;
}
.modal.open{
  backdrop-filter: blur(1px);
}
.modal.open,
.modal.open > div{
  pointer-events: all;
  opacity: 1;
}
.modal form,
.modal .details {
  max-width: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.modal options {
  display: flex;
  flex-direction: row;
  align-items: flex-end;
  justify-content: center;
  flex-wrap: wrap;
  grid-column: 1 / span 2;
  height: auto;
  width: 100%;
  gap: 16px;
}
.modal options button,
.modal options a,
.modal options form {
  flex-grow: 1;
  width: calc(50% - 8px);
  justify-content: center;
  box-sizing: border-box;
  text-align: center;
}
.modal options a button{
  width: 100%;
}
.modal .radio-toolbar{
  justify-content: center;
}
body.darkmode .modal .form-input label,
body.darkmode .modal .form-select label,
body.darkmode .modal .form-textarea label{
  background-color: var(--box-input-bg) !important;
  margin-left: 2px;
}
body.darkmode .modal .form-item:read-only + label,
body.darkmode .modal .form-item:read-only ~ i ~ label{
  background-color: #403838 !important;
}
.modal .filePreview{
  display: flex;
}
.modal .fileInfo{
  width: 100%;
  color: #444444;
  font-size: 14px;
  font-weight: 600;
}
.modal grid2Col{
  display: grid !important;
  padding-right: 0px !important;
  grid-template-columns: calc(50% - 8px) calc(50% - 8px) !important;
  gap: 16px;
}
.modal videoContainer{
  border-radius: 6px;
  width: 100%;
  overflow: hidden;
}
.modal videoContainer video{
  width: inherit;
}
.endOfNotifications{
  padding: 24px;
  font-size: 14px;
}
.modal .petInfo{
  position: relative;
  text-align: right;
  padding-left: calc(32px + 8px);
}
.modal .petInfo p{
  display: flex;
  align-items: center;
  min-height: 32px;
  text-align: left;
}
.modal .petInfo::after{
  position: absolute;
  content: '';
  width: 32px;
  height: 32px;
  left: 0;
  top: 0;
  background-image: url('../../assets/icons/pet_FILL.svg');
  background-size: cover;
  filter: invert(87%) sepia(40%) saturate(3473%) hue-rotate(320deg) brightness(103%) contrast(103%);
}
.modal .thermal_preview{
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100%;
  background-color: #FFF6EE;
}
body.darkmode .modal .thermal_preview{
  background-color: #cdcdcd;
}
.modal .thermal_detail_top,
.modal .thermal_detail_bottom{
  height: 10px;
  width: 100%;
  filter: invert(96%) sepia(42%) saturate(441%) hue-rotate(296deg) brightness(105%) contrast(101%);
  background-image: url('../../assets/images/thermal_detail.svg');
  background-repeat: repeat-x;  
}
.modal .thermal_detail_bottom{
  transform: rotate(180deg);
}
body.darkmode .thermal_detail_top,
body.darkmode .thermal_detail_bottom{
  filter: invert(85%) sepia(0%) saturate(19%) hue-rotate(161deg) brightness(100%) contrast(88%);
}
.modal.petPic .modal-window:first-of-type{
  background-color: transparent !important;
  border: none !important;
  box-shadow: none !important;
}
.modal.petPic .modal-window{
  overflow-x: unset;
}
.modal.petPic .modal-window .modal-content{
  height: 100% !important;
  gap: 16px;
}
.modal.petPic .modal-window .modal-content-container{
  padding-top: 0px !important;
}
.modal.petPic .title{
  display: none;
}
.modal.petPic .modal-window .filePreview {
  display: flex;
  width: 100%;
  aspect-ratio: 1 / 1;
}
.modal.petPic form{
  position: absolute;
  display: flex;
  z-index: 2;
  width: calc(100% - 70px);
  bottom: -56px;
  left: 37px;
}
.modal.petPic .modal-window .filePreview::after{
  position: absolute;
  content: '';
  left: 2px;
  top: -43px;
  height: 551px;
  width: 466px;
  background-image: url('../../assets/images/polaroid.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  border-radius: 4px;
  border-bottom: 2px solid rgba(0, 0, 0, 0.024);
  border-right: 2px solid rgba(0, 0, 0, 0.024);
  box-shadow: 16px 16px 6px rgba(0, 0, 0, 0.024);
  pointer-events: none;
  z-index: 1;
}
body.darkmode .modal.petPic .modal-window .filePreview::after{
  background-image: url('../../assets/images/polaroid.darkmode.png');
}
.modal.petPic .modal-window options{
  z-index: 3;
}
.modal .calendar-grid{
  gap: 0px;
}
#welcome_home img{
  max-width: 320px;
}
#welcome_home grid2Col{
  margin-bottom: 24px;
}
#welcome_home grid2Col .span{
  display: flex;
  align-items: center;
}

@media only all and (max-width: 1024px) {
  .modal{
    backdrop-filter: none;
  }
  body.darkmode .modal{
    background-color: rgba(0, 0, 0, 0.44);
  }
}
@media only all and (max-width: 620px) {
  .modal{
    justify-content: flex-end;
    padding: 16px;
  }
  .modal .modal-window{
    max-height: 96vh;
    margin: 0px;
    max-width: 100% !important;
    padding: 0 16px 16px;
  }
}
@media only all and (max-width: 420px) {
  
  .modal .options {
    flex-direction: column;
  }
  .modal .options button,
  .modal .options a {
    width: 100%;
  }
}

@media only all and (max-width: 530px) {
  .modal grid2Col{
    display: flex !important;
    flex-direction: column;
    gap: 16px;
  }
}