/* --------------------------- VARIABLES CSS --------------------------- */
:root {
  --bg-color: #121212;
  --card-bg: #1e1e1e;
  --text-color: #f1f1f1;
  --accent-color: #00bfff;
  --border: #333;
  --green: #4caf50;
}


/* --------------------------- RESET & BASE --------------------------- */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}


/* --------------------------- HEADER --------------------------- */
header {
  background: linear-gradient(to right, #1b1b1b, #1d1d2f);
  padding: 1rem 2rem;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

header h1 {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0;
}

header h1 span {
  color: var(--accent-color);
}

header p {
  margin: 0.3rem 0 0;
  font-size: 0.85rem;
  color: #aaa;
}


/* --------------------------- MAIN --------------------------- */
main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2rem 1rem;
}


/* --------------------------- CONTAINER --------------------------- */
.container {
  background: var(--card-bg);
  padding: 2rem;
  border-radius: 16px;
  width: 100%;
  max-width: 500px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.4);
  margin: auto;
  animation: slideIn 0.5s ease-out;
}


/* --------------------------- ANIMATION --------------------------- */
@keyframes slideIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}


/* --------------------------- TITRE FORMULAIRE --------------------------- */
h2 {
  text-align: center;
  margin-bottom: 2rem;
  font-size: 1.4rem;
  color: var(--accent-color);
}


/* --------------------------- FORMULAIRES --------------------------- */
label {
  display: block;
  margin-top: 1rem;
  margin-bottom: 0.3rem;
  font-weight: 600;
}

input,
select {
  width: 100%;
  padding: 0.75rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background-color: #2a2a2a;
  color: var(--text-color);
  font-size: 1rem;
  transition: border 0.3s ease;
}

input:focus,
select:focus {
  border-color: var(--accent-color);
  outline: none;
}


/* --------------------------- LOGIN GÉNÉRÉ --------------------------- */
.result {
  margin-top: 1.5rem;
  font-weight: bold;
  font-size: 1.2rem;
  text-align: center;
  transition: all 0.3s ease;
}


/* --------------------------- BOUTON --------------------------- */
button {
  margin-top: 1.5rem;
  width: 100%;
  padding: 0.75rem;
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg, #00bfff, #1e90ff);
  color: white;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 191, 255, 0.3);
}


/* --------------------------- MESSAGE DE COPIE --------------------------- */
#copie-msg {
  text-align: center;
  color: var(--green);
  margin-top: 0.5rem;
  font-size: 0.95rem;
  opacity: 0;
  transition: opacity 0.4s ease;
}

#copie-msg.visible {
  opacity: 1;
}


/* --------------------------- FOOTER --------------------------- */
footer {
  background-color: #1b1b1b;
  text-align: center;
  padding: 1rem;
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
}

footer a {
  color: var(--accent-color);
  text-decoration: none;
}


/* --------------------------- RESPONSIVE --------------------------- */
@media (max-width: 480px) {
  h2 {
    font-size: 1.2rem;
  }

  input,
  select,
  button {
    font-size: 0.95rem;
  }

  .result {
    font-size: 1rem;
  }
}
