/* RESET BÁSICO */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Arial", sans-serif;
}

/* FONDO PREMIUM */
body,
html {
  height: 100%;
  background: #2e2e2e;
  position: relative;
}

/* FORMULARIO CENTRAL SIN FLEX */
.login-container {
  background: linear-gradient(145deg, #2e2e2e, #1f1f1f);
  padding: 22px 25px;
  border-radius: 20px;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.7);
  width: 100%;
  max-width: 380px;
  border: 2px solid #d4af37;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #fff;
}

/* CABECERA DEL FORM */
.login-header {
  text-align: center;
  margin-bottom: 30px;
}

.login-header .logo img {
  width: 50%;
  margin-bottom: 10px;
  filter: none;
}

.login-header h1 {
  font-size: 26px;
  color: #d4af37;
  text-shadow: 1px 1px 2px #000;
  letter-spacing: 1px;
}

/* INPUTS */
.login-container input[type="text"],
.login-container input[type="email"],
.login-container input[type="password"] {
  width: 100%;
  padding: 12px 15px;
  margin: 10px 0;
  border: 1px solid #555;
  border-radius: 10px;
  background-color: #1a1a1a;
  color: #fff;
  font-size: 15px;
  transition: all 0.3s ease;
}

.login-container input:focus {
  border-color: #d4af37;
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.7);
  outline: none;
}

/* CONTENEDOR DE CONTRASEÑA */
.password-container {
  position: relative;
  width: 100%;
}

/* INPUT PASSWORD CON ESPACIO PARA EL EMOJI */
.password-container input[type="password"] {
  padding-right: 40px; /* espacio para el emoji al lado */
}

/* EMOJI AL LADO DEL INPUT */
.password-container button {
  position: absolute;
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  color: #d4af37;
  padding: 0;
  line-height: 1;
}

.password-container button:hover {
  color: #ff0000;
}

/* BOTONES */
.btn-primary {
  width: 100%;
  padding: 12px;
  margin-top: 18px;
  margin-bottom: 18px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #d4af37, #ffcc00);
  color: #1a1a1a;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.6);
  transition: all ease 0.2s;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #ff0000, #d4af37);
  color: #fff;
  box-shadow: 0 6px 16px rgba(255, 0, 0, 0.6);
}

/* BOTONES LINK */
.link-btn {
  background: none;
  border: none;
  color: #d4af37;
  cursor: pointer;
  font-size: 13px;
  text-decoration: underline;
  transition: color 0.3s ease;
}

.link-btn:hover {
  color: #ff0000;
}

/* FLASH MESSAGES - notificaciones en la esquina inferior derecha */
.flash-messages {
  position: fixed;
  bottom: 20px;
  right: 20px; /* derecha */
  list-style: none;
  padding: 0;
  margin: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column-reverse; /* nuevos mensajes van abajo */
  gap: 10px;
}

.flash-messages li {
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: bold;
  text-align: left;
  min-width: 200px;
  max-width: 350px;
  opacity: 0;
  transform: translateY(20px);
  animation: slideIn 0.4s forwards, fadeOut 0.4s 4s forwards;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.flash-messages li.success,
li.info {
  background-color: #d4af37;
  color: #1a1a1a;
}

.flash-messages li.error {
  background-color: #ff0000;
  color: #fff;
}

.flash-messages li.warning {
  background-color: #555;
  color: #d4af37;
}

/* Animaciones */
@keyframes slideIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeOut {
  to {
    opacity: 0;
    transform: translateY(20px);
  }
}

/* FOOTER PEGADO ABAJO */
footer {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  text-align: center;
  color: #d4af37;
  text-shadow: 1px 1px 1px #000;
  position: fixed;
  bottom: 0;
  left: 0;
  padding: 10px 0;
  background: transparent;
}

footer img {
  width: 4%;
  filter: none;
  margin: 0px 4px;
}

footer p {
  font-size: 13px;
}

/* validacion contraseña */
.password-help {
  font-size: 0.8rem;
  color: #999;
  margin-top: 5px;
}

input:invalid {
  border: 2px solid #c0392b;
}

input:valid {
  border: 2px solid #27ae60;
}

.password-requirements-inline {
  list-style: none;
  padding-left: 0;
  margin-top: 5px;
  display: flex;
  justify-content: center;
  gap: 10px; /* espacio entre requisitos */
  font-size: 10px;
  color: #ccc;
}

.password-requirements-inline li {
  padding: 2px 6px;
  border-radius: 4px;
  background: #2b2b2b;
  transition: color 0.2s, background 0.2s;
}
.password-requirements-inline li:empty {
  display: none;
}
/* MEDIA QUERIES */
@media (max-width: 450px) {
  .login-container {
    padding: 30px 20px;
  }

  .password-container input[type="password"] {
    padding-right: 35px; /* ajustar en pantallas pequeñas */
  }

  .password-container button {
    font-size: 16px;
  }
  footer img {
    width: 18%;
  }
}
