@import url('https://fonts.googleapis.com/css?family=Montserrat:400,800');

* { box-sizing: border-box; }

html, body{
  height: 100%;
  margin: 0;
  padding: 0;
}

/* ✅ agora o body NÃO é mais flex em linha com vários filhos */
body{
  font-family: 'Montserrat', sans-serif;
  background-image: url('background.png');
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;

  min-height: 100dvh;
  position: relative;

  /* evita scroll horizontal */
  overflow-x: hidden;
}

/* Overlay (usa sua variável) */
body::before{
  content: '';
  position: fixed;
  inset: 0;
  background-color: var(--opace-login-bk);
  pointer-events: none;
  z-index: 1;
}

/* ✅ Wrapper que centraliza o card */
.login-stage{
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  position: relative;
  z-index: 2;
}

/* =========================
   SISTEMA FECHADO (UI)
   ========================= */
.sign-up-container,
.overlay-container{
  display: none !important;
}

/* =========================
   CARD CENTRAL NOVO
   ========================= */
.container{
  background: var(--container-color);
  border-radius: 16px;
  box-shadow: 0 18px 55px rgba(0,0,0,0.20);
  width: min(460px, 100%);
  overflow: hidden;
}

/* login ocupa 100% */
.form-container{
  position: relative !important;
  top: auto !important;
  height: auto !important;
  transition: none !important;
}

.sign-in-container{
  left: 0 !important;
  width: 100% !important;
  z-index: 2;
  transform: none !important;
}

/* FORM */
form{
  background: transparent !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 34px 30px 28px;
  text-align: center;
}

.logo{
  width: 150px;
  margin: 0 0 14px 0;
}

h1{
  font-weight: 800;
  margin: 0 0 6px 0;
  font-size: 24px;
  color: var(--text-color);
}

.login-sub{
  font-size: 13px;
  color: var(--text-color);
  opacity: .75;
  margin-bottom: 14px;
}

/* links */
a{
  color: var(--text-color);
  font-size: 13px;
  text-decoration: none;
  margin-top: 10px;
  opacity: .85;
}
a:hover{ opacity: 1; text-decoration: underline; }

/* inputs */
input{
  width: 100%;
  display: block;
  background: var(--secondary-container-color);
  border: 1px solid var(--border-color);
  padding: 12px 44px 12px 16px;
  margin: 10px 0;
  border-radius: 999px;
  color: var(--text-color);
  outline: none;
  transition: .15s ease;
}

input:focus{
  border-color: #00ff8f;
  box-shadow: 0 0 0 4px rgba(0,255,143,.15);
}

/* senha + olho */
.pwd-wrap{
  width: 100%;
  position: relative;
}

#togglePassword{
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: var(--text-color);
  opacity: .7;
}
#togglePassword:hover{ opacity: 1; }

/* botão */
button{
  width: 100%;
  border-radius: 999px;
  border: 1px solid #00ff8f;
  background-color: #00ff8f;
  color: #06210f;
  font-size: 13px;
  font-weight: 800;
  padding: 13px 18px;
  letter-spacing: .7px;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 80ms ease-in, filter .15s ease;
  margin-top: 10px;
}
button:active{ transform: scale(0.99); }
button:hover{ filter: brightness(.98); }

.helper{
  margin-top: 14px;
  font-size: 13px;
  color: var(--text-color);
  opacity: .85;
}
.helper strong{
  opacity: 1;
  font-weight: 800;
}

/* DARK MODE TOGGLE (seu) */
.dark-mode-toggle {
  position: fixed;
  top: 18px;
  left: 18px;
  width: 50px;
  height: 20px;
  background-color: #fff;
  border-radius: 25px;
  display: flex;
  align-items: center;
  padding: 2px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: background-color 0.3s ease;
  z-index: 50;
}

.dark-mode-toggle .toggle-circle {
  width: 21px;
  height: 21px;
  background-color: #fff;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  position: absolute;
  left: 2px;
  z-index: 5;
}

.dark-mode-toggle::before {
  content: "\f0eb";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  left: 35px;
  font-size: 14px;
  color: #333;
  z-index: 4;
  transition: opacity 0.3s ease;
  opacity: 1;
}

.dark-mode-toggle::after {
  content: "\f186";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  right: 35px;
  font-size: 14px;
  color: #fff;
  z-index: 4;
  transition: opacity 0.3s ease;
  opacity: 0;
}

body.dark-mode .dark-mode-toggle { background-color: #333; }
body.dark-mode .dark-mode-toggle .toggle-circle { transform: translateX(25px); }
body.dark-mode .dark-mode-toggle::before { opacity: 0; }
body.dark-mode .dark-mode-toggle::after { opacity: 1; }

/* FOOTER em baixo (sem quebrar o centro) */
.main-footer{
  position: fixed;
  left: 0;
  bottom: 0;
  width: 100%;
  text-align: center;
  padding: 10px 0;
  font-size: 13px;
  color: var(--text-color);
  background-color: transparent;
  z-index: 3;
}

.main-footer a{
  color: var(--text-color);
  text-decoration: none;
  margin: 0 5px;
  opacity: .9;
}
.main-footer a:hover{ text-decoration: underline; opacity: 1; }

.main-footer a.brand-link{
  color: #00ff8f;
  text-decoration: none;
  margin-left: 12px;
}

/* ✅ evita o footer “subir” por cima do card em telas baixas */
.login-stage{
  padding-bottom: 60px;
}

@media (max-height: 620px){
  .login-stage{
    align-items: flex-start;
  }
}
