/* ===== Reset básico ===== */
* {
  box-sizing: border-box;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  margin: 0;
  padding: 20px;
  background-color: #f8fafc;
  color: #111827;
}

/* ===== Contenedor general ===== */
.questionnaire {
  max-width: 900px;
  margin: 0 auto;
}

/* ===== Pregunta ===== */
.question {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 20px;
}

/* ===== Encabezado ===== */
.question-header {
  margin-bottom: 14px;
}

.question-meta {
  display: flex;
  gap: 12px;
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 6px;
}

.question-id {
  font-weight: bold;
}

.question-name {
  font-style: italic;
}

.question-title {
  font-size: 17px;
  font-weight: 700;
  margin: 0;
}

/* ===== Opciones ===== */
.question-options ul {
  list-style: none;
  padding: 0;
  margin: 12px 0;
}

.question-options .option {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 8px;
  background-color: #f9fafb;
}

/* Respuesta correcta (solo visible cuando se muestre) */
.question-options .option.correct {
  border-color: #16a34a;
  background-color: #ecfdf5;
  font-weight: bold;
}

/* ===== Respuesta ===== */
.question-answer {
  margin-top: 12px;
  padding: 10px 12px;
  border-left: 4px solid #2563eb;
  background-color: #eff6ff;
}

/* ===== Explicación ===== */
.question-explanation {
  margin-top: 10px;
  padding: 12px;
  background-color: #f9fafb;
  border: 1px dashed #d1d5db;
  border-radius: 8px;
  line-height: 1.5;
}

/* ===== Tablas ===== */
.question table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.question table td,
.question table th {
  border: 1px solid #e5e7eb;
  padding: 8px;
  vertical-align: top;
}

.question table th {
  background-color: #f3f4f6;
  font-weight: bold;
}

/* ===== Listas internas ===== */
.question ul,
.question ol {
  margin-left: 20px;
}

/* ===== Modo examen (opcional) ===== */
/* Oculta respuestas y explicación */
.exam-mode .question-answer,
.exam-mode .question-explanation {
  display: none;
}

/* ===== Modo revisión (opcional) ===== */
.review-mode .question-answer,
.review-mode .question-explanation {
  display: block;
}

/* ===== Menú ===== */
.menu {
  gap: 15px;
}
.menu {
  display: flex;
  width: 100%;
  justify-content: space-between;
  margin: 25px 0;
}

.menu a {
  flex: 1;
  text-align: center;
  text-decoration: none;
  padding: 8px 0;
  background: #e5e7eb;
  color: #111827;
  border-radius: 6px;
  font-size: 14px;
}

.menu a:hover {
  background: #c7d2fe;
}
