* {
  box-sizing: border-box;
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 80vh;
  margin: 0;
  padding: var(--gap);
  background: url("../images/158699.jpg") center / cover no-repeat fixed;
  color: var(--text-color);
}

h1 {
  margin-bottom: 1em;
  font-weight: 600;
  font-size: 2rem;
  text-align: center;
  color: var(--text-color);
  text-shadow: 0 0 0.25rem rgba(0, 0, 0, 0.5);
}

form {
  background: var(--frosted-bg);
  border: 1px solid var(--frosted-border);
  border-radius: var(--radius);
  box-shadow: 0 0 1.2rem var(--frosted-shadow);
  backdrop-filter: blur(1.4rem);
  -webkit-backdrop-filter: blur(1.4rem);
  padding: 2rem;
  width: 100%;
  max-width: 480px;
  transition: all var(--transition);
}

form input[type="text"],
form input[type="time"],
form input[type="number"],
form input[type="tel"],
form input[type="password"] {
  width: 100%;
  padding: 0.9rem 1rem;
  margin-bottom: var(--gap);
  border: 1px solid var(--frosted-border);
  border-radius: var(--radius);
  background-color: var(--frosted-bg);
  color: var(--text-color);
  font-size: 1rem;
  backdrop-filter: blur(1.4rem);
  transition: all var(--transition);
  box-shadow: 0 0 0.5rem rgba(255, 255, 255, 0.1), 0 0 0.8rem rgba(0, 0, 0, 0.5);
}

form input:focus {
  outline: none;
  background-color: var(--frosted-bg);
  box-shadow: 0 0 1.2rem var(--frosted-glow);
}

form input::placeholder {
  color: rgba(255, 255, 255, 0.6);
  font-style: italic;
}

form input[type="checkbox"] {
  appearance: none;
  background-color: var(--frosted-bg);
  border: 1px solid var(--frosted-border);
  border-radius: var(--radius);
  width: 1em;
  height: 1em;
  margin-right: 0.5em;
  cursor: pointer;
  display: inline-block;
  position: relative;
  vertical-align: middle;
}

form input[type="checkbox"]:checked {
  background-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 0.6rem rgba(255, 255, 255, 0.6);
  border-color: #fff;
}

form input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  top: 0.2em;
  left: 0.25em;
  width: 0.4em;
  height: 0.4em;
  background-color: #fff;
  border-radius: var(--radius);
}

form button[type="submit"] {
  width: 100%;
  padding: 0.85rem;
  background-color: var(--frosted-bg);
  border: 1px solid var(--frosted-border);
  border-radius: var(--radius);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: 0 0 1.2rem var(--frosted-shadow);
  backdrop-filter: blur(1.4rem);
}

form button[type="submit"]:hover {
  background-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 1.2rem var(--frosted-glow);
  transform: translateY(-2px);
}

button .spinner {
  width: 0.8rem;
  height: 0.8rem;
  border: 2px solid #fff;
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  vertical-align: middle;
  margin-left: 0.5rem;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

#remember,
#forgot {
  font-size: 0.75em;
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
  color: rgba(255, 255, 255, 0.7);
}

#forgot a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: all var(--transition);
}
#forgot a:hover {
  color: #fff;
}

p#responseMsg {
  margin-top: 1rem;
  font-size: 0.95rem;
  min-height: 1.3em;
  color: rgba(255, 255, 255, 0.8);
  text-align: center;
}

/* Responsive layout tweaks */
@media screen and (max-width: 460px) {
  form {
    margin-top: 4rem;
    padding: 1.5rem;
    width: 90%;
  }

  #registerBtn {
    font-size: 1rem;
    padding: 0.4em 0.75em;
  }

  h2 {
    font-size: 1.3rem;
  }
}
