/* Feuille de style commune à tous les quiz réseau */
body {
  font-family: Arial, Helvetica, sans-serif;
  background: #f4f8ff;
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

h1 {
  text-align: center;
  color: #004080;
  margin-bottom: 30px;
}

.question {
  margin: 20px 0;
  padding: 15px;
  background: #fff;
  border-left: 5px solid #004080;
  border-radius: 0 4px 4px 0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.answers {
  margin-top: 10px;
}

.answers label {
  display: block;
  padding: 8px;
  margin: 5px 0;
  cursor: pointer;
  border-radius: 4px;
  transition: background-color 0.2s;
}

.answers label:hover {
  background: #f5f5f5;
}

.answers input {
  margin-right: 10px;
}

.correct-answer {
  background: #d4edda;
  border-left: 4px solid #28a745;
  padding: 5px;
  margin-left: -15px;
  margin-right: -15px;
  padding-left: 20px;
}

.wrong-answer {
  background: #f8d7da;
  border-left: 4px solid #dc3545;
  padding: 5px;
  margin-left: -15px;
  margin-right: -15px;
  padding-left: 20px;
}

.explanation {
  font-size: .9em;
  color: #555;
  margin-top: 10px;
  padding: 10px;
  background: #f8f9fa;
  border-left: 3px solid #007bff;
  border-radius: 0 4px 4px 0;
}

#result {
  text-align: center;
  font-weight: bold;
  margin-top: 25px;
  font-size: 1.2em;
}

#timer {
  text-align: center;
  color: #666;
  margin-top: 10px;
}

#progress {
  width: 100%;
  height: 20px;
  background: #ccc;
  margin-top: 20px;
  border-radius: 10px;
  overflow: hidden;
}

#bar {
  height: 100%;
  background: #28a745;
  width: 0;
  transition: width 0.5s ease-in-out;
}

button {
  background: #004080;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1em;
  transition: background 0.3s;
  margin: 10px 5px;
}

button:hover {
  background: #003366;
}

#resetBtn {
  background: #6c757d;
}

#reviewBtn {
  background: #ffc107;
  color: #000;
}

#exportBtn {
  background: #17a2b8;
}

#quiz-form-buttons {
  text-align: center;
  margin-top: 30px;
}

/* Styles améliorés pour le bouton "Retour à l'accueil" */
a.back {
  display: inline-block;
  margin-top: 40px;
  padding: 12px 25px;
  background: linear-gradient(135deg, #004080, #0056b3);
  color: white;
  text-decoration: none;
  border-radius: 25px;
  font-weight: bold;
  font-size: 1.1em;
  transition: all 0.3s ease;
  box-shadow: 0 2px 5px rgba(0,64,128,0.3);
  position: relative;
  overflow: hidden;
}

a.back:before {
  content: '←';
  margin-right: 10px;
  font-size: 1.3em;
  transition: transform 0.3s ease;
  display: inline-block;
}

a.back:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0,64,128,0.5);
  background: linear-gradient(135deg, #0056b3, #004080);
}

a.back:hover:before {
  transform: translateX(-5px);
}

a.back:active {
  transform: translateY(0);
  box-shadow: 0 2px 3px rgba(0,64,128,0.3);
}

.back-container {
  text-align: center;
  margin: 40px 0;
}

/* Styles pour la page d'accueil */
.quiz-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
  padding: 30px 0;
}

.quiz {
  position: relative;
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 20px;
  width: 280px;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  transition: transform 0.2s, box-shadow 0.2s;
}

.quiz:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

.quiz img, .quiz svg {
  width: 64px;
  height: 64px;
  margin-bottom: 15px;
}

.quiz h2 {
  color: #004080;
  margin-bottom: 15px;
}

.quiz a {
  display: inline-block;
  background: #004080;
  color: white;
  padding: 8px 20px;
  border-radius: 4px;
  text-decoration: none;
  transition: background 0.3s;
}

.quiz a:hover {
  background: #003366;
}

.badge {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 10px;
  border-radius: 20px;
  font-weight: bold;
  font-size: 0.9em;
}

.badge.success {
  background-color: #d4edda;
  color: #155724;
}

.badge.fail {
  background-color: #f8d7da;
  color: #721c24;
}

.stats-summary {
  text-align: center;
  margin: 30px 0;
  padding: 20px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.stats-summary h3 {
  color: #004080;
  margin-bottom: 15px;
}

@media (max-width: 768px) {
  .quiz-list {
    flex-direction: column;
    align-items: center;
  }
  
  .quiz {
    width: 90%;
    max-width: 300px;
  }
}