/* Général */
main.container {
  background-color: #ffffff;
  border-radius: 16px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.05);
  padding: 2rem;
  animation: fadeIn 0.5s ease-in-out;
}

/* Titres et paragraphes */
h2, h4, h5 {
  color: #0d6efd;
  font-weight: 600;
}

p.lead, ul {
  font-size: 1.1rem;
}

ul li {
  margin-bottom: 0.5rem;
}

hr {
  border-top: 2px solid #eee;
  margin-top: 2rem;
  margin-bottom: 2rem;
}

/* Pre & code */
pre {
  background-color: #f9f9f9;
  border-left: 4px solid #0d6efd;
  padding: 1rem;
  overflow-x: auto;
  border-radius: 8px;
  transition: background-color 0.3s;
}

pre:hover {
  background-color: #f1f1f1;
}

code {
  font-family: 'Courier New', monospace;
  color: #333;
}

/* Sélecteur de langage + bouton */
#langSelect {
  transition: all 0.3s ease;
  max-width: 300px;
}

#langSelect:hover {
  transform: scale(1.03);
  box-shadow: 0 0 5px rgba(13, 110, 253, 0.5);
}

button.btn-primary {
  transition: background-color 0.3s, transform 0.3s;
}

button.btn-primary:hover {
  background-color: #0b5ed7;
  transform: scale(1.02);
}

/* Code affiché dynamiquement */
#codeResultat {
  background-color: #f5f5f5;
  color: #222;
  font-size: 0.95rem;
  max-height: 500px;
  overflow-y: auto;
  white-space: pre-wrap;
  line-height: 1.5;
}

/* Responsive */
@media screen and (max-width: 768px) {
  main.container {
    padding: 1.2rem;
  }

  #langSelect {
    width: 100% !important;
  }

  button.btn-primary {
    width: 100%;
    margin-top: 0.5rem;
  }

  pre {
    font-size: 0.9rem;
  }
}

/* Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
