/* === Global box-sizing et styles de base === */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 1rem;
  font-family: Arial, Tahoma, Verdana, sans-serif;
  background-color: #e6f0fa;
  font-size: 1rem;
  overflow-x: hidden;
}

/* === Titres et paragraphes === */
h1 {
  text-align: center;
  font-size: 1.25rem;
  margin-bottom: 0.625rem;
}

p {
  text-align: center;
  font-size: 1rem;
  margin-bottom: 1.25rem;
}

/* === Form container === */
.form-container {
  max-width: 450px;   /* limite la largeur sur grand écran */
  width: 100%;        /* s'adapte automatiquement à l'écran */
  margin: 1rem auto;
  padding: 1.5rem;
  background: #fff;
  border-radius: 0.5rem;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  text-align: center;
}

/* === Formulaire === */
form {
  width: 100%;
  margin: 0 auto;
  padding: 1.25rem;
  background: #fff;
  border-radius: 0.5rem;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* === Fieldset et legend === */
fieldset {
  border: 1px solid #ccc;
  border-radius: 0.3rem;
  padding: 0.9rem;
  margin-bottom: 1.25rem;
}

legend {
  padding: 0 0.5rem;
  font-weight: bold;
}

/* === Labels et inputs === */
label {
  display: block;
  margin-top: 0.5rem;
  font-weight: bold;
}

input[type="text"],
input[type="password"] {
  width: 100%;
  padding: 0.5rem;
  font-size: 1rem;
  height: 2.5rem;
  margin-top: 0.3rem;
}

/* === Password toggle === */
.password-container {
  position: relative;
  display: flex;
  align-items: center;
  margin-top: 0.3rem;
}

#password {
  flex: 1;
  padding-right: 2.5rem;
}

.password-toggle {
  position: absolute;
  right: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.password-toggle svg {
  width: 1.5rem;
  height: 1.5rem;
  color: #555;
}

/* === Bouton submit === */
button[type="submit"] {
  width: 100%;
  background-color: #007BFF;
  color: #fff;
  border: none;
  padding: 0.625rem;
  font-size: 1rem;
  border-radius: 0.3rem;
  cursor: pointer;
  margin-top: 0.625rem;
}

button[type="submit"]:hover {
  background-color: #0056b3;
}

/* === Messages d'erreur === */
.error-message {
  color: red;
  text-align: center;
  margin-top: 0.9375rem;
}

/* === Tooltip === */
.no-info {
  position: relative;
  display: inline-block;
  cursor: help;
  color: #444;
  font-style: italic;
}

.no-info::after {
  content: "Pour obtenir l'identifiant et le mot de passe, rendez-vous sur l'ENT enseignant de la Faculté des Lettres, rubrique...";
  position: absolute;
  left: 50%;
  bottom: 120%;
  transform: translateX(-50%);
  background: #333;
  color: #fff;
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 0.85rem;
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease-in-out;
  max-width: 90vw;
  white-space: normal;
  word-break: break-word;
}

.no-info::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 110%;
  transform: translateX(-50%);
  border-width: 6px;
  border-style: solid;
  border-color: transparent transparent #333 transparent;
  opacity: 0;
  transition: opacity 0.2s ease-in-out;
}

.no-info:hover::after,
.no-info:hover::before {
  opacity: 1;
}
