* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Arial, sans-serif;
  background: url("/assets/login-bg.png") center/cover no-repeat fixed;
  color: #fff;
}

.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
}

.login-card {
  position: relative;
  z-index: 1;
  width: 380px;
  max-width: calc(100% - 40px);
  margin-left: auto;
  margin-right: 37%;
  top: 50vh;
  transform: translateY(-50%);
  padding: 32px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(12px);
  box-shadow: 0 20px 50px rgba(0,0,0,.35);
}

.login-card h1 {
  margin: 0 0 8px;
  font-size: 26px;
}

.login-card p {
  margin: 0 0 26px;
  opacity: .85;
}

label {
  display: block;
  margin: 14px 0 6px;
  font-weight: bold;
}

input {
  width: 100%;
  padding: 13px;
  border-radius: 10px;
  border: none;
  outline: none;
}

button {
  width: 100%;
  margin-top: 22px;
  padding: 14px;
  border: none;
  border-radius: 10px;
  background: #0b4f8c;
  color: white;
  font-weight: bold;
  cursor: pointer;
}

button:hover {
  background: #126bbd;
}

#msg {
  margin-top: 14px;
  color: #ffd2d2;
}

footer {
  position: fixed;
  left: 20px;
  bottom: 16px;
  z-index: 1;
  font-size: 13px;
  opacity: .85;
}

.password-requirements {
  margin-top: 10px;
  margin-bottom: 16px;
  padding: 12px 14px;

  border: 1px solid #d9dee8;
  border-radius: 8px;

  background: #f8fafc;

  font-size: 13px;
  line-height: 1.5;
}

.password-requirements p {
  margin: 0 0 8px;
  font-weight: 600;
  color: #344054;
}

.password-rule {
  margin: 4px 0;
  color: #667085;

  transition:
    color 0.2s ease,
    font-weight 0.2s ease;
}

.password-rule.valid {
  color: #16803a;
  font-weight: 600;
}

.password-rule.invalid {
  color: #667085;
}

.login-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}

.login-title-row h1 {
  margin: 0;
}

.login-language-selector {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
}

.login-language-btn {
  width: 38px;
  height: 30px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  margin: 0;
  padding: 3px;

  border: 1px solid transparent;
  border-radius: 7px;

  background: transparent;

  cursor: pointer;

  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.login-language-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}

.login-language-btn.active {
  border-color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.18);
}

.login-flag-image {
  display: block;
  width: 27px;
  height: 18px;
  object-fit: cover;
  border-radius: 2px;
}

.login-language-separator {
  color: rgba(255, 255, 255, 0.55);
  font-size: 16px;
}

@media (max-width: 480px) {
  .login-title-row {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* =====================================================
   LOGIN - MOSTRAR / OCULTAR SENHA
===================================================== */

.password-input-wrapper {
  position: relative;
  width: 100%;
}

.password-input-wrapper input {
  padding-right: 48px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);

  width: 38px;
  height: 38px;
  margin: 0;
  padding: 0;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border: none;
  border-radius: 8px;
  background: transparent;
  color: #344054;

  font-size: 18px;
  line-height: 1;

  cursor: pointer;
}

.password-toggle:hover,
.password-toggle:focus {
  background: rgba(11, 79, 140, 0.10);
  outline: none;
}


/* Recuperação de senha */
.recovery-link {
  display: block;
  margin-top: 18px;
  color: #fff;
  text-align: center;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.recovery-link:hover { color: #deedff; }
.recovery-note { font-size: 14px; line-height: 1.5; }
.recovery-note a { color: #fff; }
.recovery-message { min-height: 22px; margin-top: 16px; font-size: 14px; }
