#modal, #loading {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 1000;
}
#modal .flex, #loading .flex {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
  width: 100%;
}
#modal .frame {
  background: white;
  box-shadow: 0px 5px 20px rgba(0,0,0,0.3);
  border-radius: 10px;
  padding: 30px;
  margin: 20px;
  min-width: 300px;
  max-width: 450px;
}
#modal .frame h3 {
  font-size: 22px;
}
#modal .frame button {
  width: 100%;
  background-color: #4C463E;
  border-radius: 5px;
  padding: 10px 20px;
  color: white;
}
#modal .frame .msg {
  margin: 15px 0 30px;
  line-height: 24px;
}

/* Restored Loader Styles (lds-ring) */
.lds-ring {
  display: inline-block;
  position: relative;
  width: 80px;
  height: 80px;
}
.lds-ring div {
  box-sizing: border-box;
  display: block;
  position: absolute;
  width: 64px;
  height: 64px;
  margin: 8px;
  border: 8px solid #fff;
  border-radius: 50%;
  animation: lds-ring 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  border-color: #fff transparent transparent transparent;
}
.lds-ring div:nth-child(1) {
  animation-delay: -0.45s;
}
.lds-ring div:nth-child(2) {
  animation-delay: -0.3s;
}
.lds-ring div:nth-child(3) {
  animation-delay: -0.15s;
}
@keyframes lds-ring {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@media(max-width: 414px){
  #modal, #loading {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}
