/*----------------------------------------------------*/
/* RESTRICT FORM                                       */
/* Originalmente src/app/restrict-form/restrict-form.component.css.
   O Angular escopava estas regras ao componente; aqui elas são
   escopadas manualmente em .restrict-form para não vazarem
   para o resto do site. */
/*----------------------------------------------------*/

.restrict-form {
  position: relative;
}

/*----------------------------------------------------*/
/* PORTAO ISOLADO (#kb-gate)                           */
/* Na home o formulario fica sobre o card roxo, que da */
/* altura e contraste. Nas paginas cifradas ele e       */
/* injetado numa pagina vazia e branca: sem estas       */
/* regras o container colapsa para altura zero e o      */
/* texto branco some no fundo branco.                   */
/*----------------------------------------------------*/

#kb-gate {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 70vh;
  padding: 40px 20px;
}

#kb-gate form {
  position: static;
  width: 100%;
  max-width: 420px;
}

#kb-gate legend {
  color: #555;
  font-size: 20px;
  margin-bottom: 40px;
}

#kb-gate input {
  color: #555;
  border-bottom: 1px solid #cfcfcf;
}

#kb-gate input:focus {
  border-bottom: 2px solid #F84E61;
}

#kb-gate ::placeholder {
  color: #aaa;
}

#kb-gate button {
  border: 1px solid #555;
  color: #555;
}

#kb-gate button:hover {
  background: #F84E61;
  border-color: #F84E61;
  color: #ffffff;
}

#kb-gate .form-error {
  color: #F84E61;
}

.restrict-form legend {
  color: #ffffff;
  margin-bottom: 70px;
  text-align: center;
}

.restrict-form form {
  position: absolute;
  display: flex;
  align-items: center;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  justify-content: center;
}

.restrict-form input {
  width: 100%;
  height: 40px;
  display: block;
  color: #ffffff;
  font-size: 24px;
  background-color: #b11d1d00;
  border: none;
  border-bottom: 1px solid #ffffff;
  text-align: center;
}

.restrict-form input:focus {
  border: none;
  border-bottom: 2px solid #ffffff;
}

/* sem o anel de foco neste campo: o traco branco embaixo ja indica
   que ele esta selecionado */
.restrict-form input:focus-visible {
  outline: none;
}

.restrict-form ::placeholder {
  color: #ffffff38;
  font-weight: 300;
  font-size: 18px;
}

.restrict-form button {
  padding: 8px 80px;
  border: 1px solid #ffffff;
  border-radius: 50px;
  background-color: rgba(0, 0, 255, 0);
  font-size: 18px;
  font-weight: 400;
  color: #ffffff;
  margin-top: 20px;
  margin-bottom: 30px;
  cursor: pointer;
}

.restrict-form button:hover {
  border: 1px solid #ffffff;
  background: #ffffff;
  color: #630948;
}

.restrict-form fieldset {
  border: 0;
  text-align: center;
}

/* mensagem de senha inválida — antes o erro só ia para o console */
.restrict-form .form-error {
  color: #ffffff;
  font-size: 14px;
  min-height: 20px;
  margin-top: 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.restrict-form .form-error.is-visible {
  opacity: 1;
}

@media only screen and (min-width: 1024px) and (max-width: 1200px) {
  .restrict-form legend {
    margin-bottom: 30px;
    font-size: 16px;
  }

  .restrict-form button {
    margin-top: 20px;
    margin-bottom: 30px;
  }
}

@media only screen and (min-width: 768px) and (max-width: 1023px) {
  .restrict-form legend {
    margin-bottom: 80px;
  }

  .restrict-form button {
    margin-top: 20px;
    margin-bottom: 30px;
  }
}

@media only screen and (min-width: 375px) and (max-width: 480px) {
  .restrict-form legend {
    margin-bottom: 40px;
    margin-top: 50px;
    font-size: 16px;
  }

  .restrict-form button {
    margin-top: 20px;
    margin-bottom: 20px;
  }
}

@media only screen and (min-width: 320px) and (max-width: 374px) {
  .restrict-form legend {
    margin-bottom: 30px;
    margin-top: 20px;
    font-size: 14px;
  }

  .restrict-form button {
    margin-top: 20px;
    margin-bottom: 20px;
  }
}
