/* assets/css/quiz.css */

.quiz-wrapper {
  border: 1px solid #e9ecef;
  border-radius: 8px;
  overflow: hidden;
}
.quiz-wrapper-header {
  background: #f8f9fa;
  border-bottom: 1px solid #e9ecef;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}
.quiz-container { padding: 20px; }

/* ── Question layout ── */
.quiz-question {
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid #e9ecef;
}
.quiz-question:last-of-type { border-bottom: none; margin-bottom: 0; }

.quiz-q-header {
  display: flex; align-items: center;
  margin-bottom: 10px;
}
.quiz-q-num {
  font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: #6c757d;
}
.quiz-q-type { font-size: 0.68rem; }

.quiz-q-text {
  font-size: 1rem; line-height: 1.6;
  margin-bottom: 16px;
  color: #212529;
}

/* ── Multichoice ── */
.quiz-choice-label {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 10px 14px;
  border: 1px solid #dee2e6;
  border-radius: 6px; margin-bottom: 8px;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s;
  background: #fff;
}
.quiz-choice-label:hover {
  border-color: var(--accent);
  background: var(--accent-light);
}
.quiz-choice-input { margin-top: 3px; flex-shrink: 0; }
.quiz-choice-text { flex: 1; line-height: 1.5; }

/* ── Answer states ── */
.quiz-correct {
  border-color: #28a745 !important;
  background: rgba(40,167,69,0.08) !important;
}
.quiz-wrong {
  border-color: #dc3545 !important;
  background: rgba(220,53,69,0.08) !important;
}
.quiz-neutral { opacity: 0.55; }
.quiz-answer-feedback {
  color: #495057; font-size: 0.82rem;
  margin-top: 6px; font-style: italic;
}

/* ── Text / numerical inputs ── */
.quiz-text-input, .quiz-num-input {
  max-width: 400px;
}
.quiz-input-correct { border-color: #28a745 !important; }
.quiz-input-wrong   { border-color: #dc3545 !important; }

/* ── Matching table ── */
.quiz-match-table { margin-bottom: 12px; }
.quiz-match-term {
  font-weight: 600;
  vertical-align: middle;
  padding-right: 16px;
  color: #212529;
}

/* ── Submit row ── */
.quiz-submit-row {
  display: flex; align-items: center;
  padding-top: 16px;
  border-top: 1px solid #e9ecef;
}

/* ── Loading spinner ── */
.quiz-loading { padding: 40px 20px; }
