/* ---------- RESET ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", Arial, sans-serif;
}

/* ---------- BACKGROUND ---------- */
body {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.2)),
              url("https://filebrowser.grupoupper.com.br/api/public/dl/4rvP6hII?inline=true") center center no-repeat;
  background-size: cover;
}

/* ---------- CARD ---------- */
.login-wrapper {
  width: 100%;
  padding: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.login-card {
  /*background: rgba(0, 0, 0, 0.4);*/
  border-radius: 1rem;
  box-shadow: 0 6px 30px rgba(0,0,0,0.4);
  border: 1px solid rgba(255, 255, 255, 0.27);
  padding: 2rem;
  width: 90%;
  max-width: 420px;
  text-align: center;
  backdrop-filter: blur(5px);
}

/* ---------- TEXTS ---------- */
.portal-title {
  color: #ffffff;
  font-size: 2rem;
  letter-spacing: 2px;
  margin-bottom: 0.5rem;
}

.subtitle {
  color: #ffffff;
  margin-bottom: 2rem;
  font-size: 1rem;
}

/* ---------- BUTTONS ---------- */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.8rem;
  border-radius: 6px;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s;
  text-decoration: none;
}

.btn img {
  width: 22px;
  height: 22px;
  margin-right: 10px;
}

.btn-microsoft {
  background-color: #ffffff;
  color: #000;
  border: 1px solid #ddd;
  font-weight: 500;
}

.btn-microsoft:hover {
  background-color: #bbb;
}

.btn-secondary {
  background-color: transparent;
  color: #fff;
  border: 1px solid #bbb;
  margin-top: 0.8rem;
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.27);
}

.btn-primary {
  background-color: #1c59d2;
  color: #fff;
  border: none;
  margin-top: 1rem;
}

.btn-primary:hover {
  background-color: #0e42aa;
}

.btn-back {
  background: transparent;
  color: #ffffff;
  border: none;
  margin-top: 1rem;
  font-size: 0.9rem;
  cursor: pointer;
}

.btn-back:hover {
  color: #fff;
}

/* ---------- FORM ---------- */
#loginForm {
  margin-top: 1rem;
  text-align: left;
  transition: all 0.4s ease;
}

#loginForm.hidden {
  display: none;
}

label {
  display: block;
  color: #ffffff;
  margin-top: 0.8rem;
  margin-bottom: 0.3rem;
  font-size: 0.9rem;
}

input[type="text"], input[type="password"] {
  width: 100%;
  padding: 0.7rem;
  border: 1px solid #666;
  border-radius: 6px;
  background: #222;
  color: #fff;
  font-size: 1rem;
}

input:focus {
  border-color: #1c59d2;
  outline: none;
}

/* ---------- CHECKBOX ---------- */
.save-credentials {
  display: flex;
  align-items: center;     /* ✔ alinha verticalmente */
  gap: 0.4rem;
  color: #ffffff;
  font-size: 0.85rem;
  margin-top: 0.5rem;
}

.save-credentials input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 0;                /* ✔ remove deslocamentos */
  display: inline-block;    /* ✔ garante alinhamento */
}

.save-credentials label {
  margin: 0;                /* ✔ evita quebra estranha */
  line-height: 1;           /* ✔ alinha melhor com checkbox */
}

/* ---------- ERROR ---------- */
.error-message {
  color: #ff6b6b;
  font-size: 0.9rem;
  text-align: center;
  margin-bottom: 0.5rem;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 500px) {
  .login-card {
    padding: 1.5rem;
    max-width: 95%;
  }

  .portal-title {
    font-size: 1.6rem;
  }
}
