/* ── Get Started Landing ── */
.qs-landing {
  padding: 20px;
  animation: fadeUp 0.6s var(--ease-out) both;
}
.qs-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: var(--wh);
  letter-spacing: -0.02em;
  margin: 0 0 16px 0;
}

/* Resume card */
.qs-resume {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--r);
  background: var(--card-gradient), var(--sf);
  border: 1px solid var(--glass-border);
  border-left: 3px solid var(--acc);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  margin-bottom: 16px;
  transition: all 0.15s ease;
}
.qs-resume:hover {
  box-shadow: var(--shadow-card);
  border-color: var(--glass-border-strong);
  border-left-color: var(--acc);
}
.qs-resume:active { transform: scale(0.99); }
.qs-resume-icon {
  flex-shrink: 0;
  color: var(--acc);
  opacity: 0.8;
}
.qs-resume-info { flex: 1; min-width: 0; }
.qs-resume-title {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  color: var(--wh);
  margin-bottom: 2px;
}
.qs-resume-meta {
  font-size: 11px;
  color: var(--dim);
}
.qs-resume > svg:last-child {
  flex-shrink: 0;
  color: var(--dim);
}

/* Card grid */
.qs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}
.qs-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 18px 12px;
  border-radius: var(--r);
  background: var(--card-gradient), var(--sf);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
  text-align: center;
  animation: fadeUp var(--anim-slow) var(--ease-out) both;
}
.qs-card:nth-child(1) { animation-delay: 60ms; }
.qs-card:nth-child(2) { animation-delay: 120ms; }
.qs-card:nth-child(3) { animation-delay: 180ms; }
.qs-card:nth-child(4) { animation-delay: 240ms; }
.qs-card:nth-child(5) { animation-delay: 300ms; }
.qs-card:nth-child(6) { animation-delay: 360ms; }
.qs-card:hover {
  border-color: var(--glass-border-strong);
  box-shadow: var(--shadow-card);
  transform: translateY(-1px);
}
.qs-card:active { transform: scale(var(--press-scale)); }
.qs-card-icon { opacity: 0.9; }
.qs-card-title {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--wh);
  line-height: 1.3;
}
.qs-card-count {
  font-family: "SF Mono", "JetBrains Mono", monospace;
  font-size: 11px;
  color: var(--dim);
  font-variant-numeric: tabular-nums;
}

/* Section labels */
.qs-section-label {
  font-family: "SF Mono", "JetBrains Mono", monospace;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--dim);
  margin-bottom: 12px;
}

/* Filter chip row on landing */
.qs-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

/* Quick filter list on landing */
.qs-filter-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 16px;
}
.qs-filter-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--card-gradient), var(--sf);
  border-radius: var(--r);
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
}
.qs-filter-row:first-child { border-radius: var(--r) var(--r) 4px 4px; }
.qs-filter-row:last-child { border-radius: 4px 4px var(--r) var(--r); }
.qs-filter-row:only-child { border-radius: var(--r); }
.qs-filter-row:hover { background: var(--cd2); }
.qs-filter-row:active { transform: scale(0.99); }
.qs-filter-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  flex-shrink: 0;
}
.qs-filter-label {
  flex: 1;
  font-size: 14px;
  font-weight: 600;
  color: var(--wh);
}
.qs-filter-count {
  font-size: 13px;
  font-weight: 500;
  color: var(--dim);
  min-width: 28px;
  text-align: right;
}
.qs-filter-row > svg:last-child {
  color: var(--dim);
  opacity: 0.4;
  flex-shrink: 0;
}

/* ── Quiz Header ── */
.quiz-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border);
}
.quiz-mode-label {
  font-family: "SF Mono", "JetBrains Mono", monospace;
  font-size: 11px;
  font-weight: 600;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Auto-study micro-progress bar (under mode label) */
.as-micro-progress { height: 3px; background: var(--sf); border-radius: 2px; overflow: hidden; margin-top: 4px; }
.as-micro-progress-fill { height: 100%; background: var(--acc); border-radius: 2px; transition: width 0.4s var(--ease-out); }

/* ── Stats Bar ── */
.stats {
  display: flex;
  gap: 8px;
  padding: 10px 12px;
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.stats::-webkit-scrollbar { display: none; }
.st {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: 20px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  white-space: nowrap;
  flex-shrink: 0;
}
.st .n {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.st .l {
  font-family: "SF Mono", "JetBrains Mono", monospace;
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--dim);
}
.st svg { width: 12px; height: 12px; flex-shrink: 0; }

/* ── Flat Stats Bar (replaces pill-per-stat) ── */
.quiz-stats-flat {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  font-size: 12px;
  color: var(--dim);
  border-bottom: 1px solid var(--flat-divider);
  background: transparent;
}
.qs-stat { display: inline-flex; align-items: center; gap: 4px; font-weight: 500; }
.qs-stat b { font-weight: 800; font-size: 13px; font-variant-numeric: tabular-nums; }
.qs-stat-sep { width: 1px; height: 14px; background: var(--flat-divider); }

/* ── Question card entrance transition ── */
.qcard-enter {
  animation: slideInRight var(--anim-base) var(--ease-out) both;
}

/* ── Adaptive Engine Badge ── */
.adaptive-engine-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 700;
  color: #D4A843;
  background: rgba(212,168,67,0.12);
  border: 1px solid rgba(212,168,67,0.25);
  padding: 2px 8px;
  border-radius: 6px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* ── Choice selection micro-animation ── */
.choice.sel {
  animation: choicePop 200ms var(--ease-spring) both;
}
@keyframes choicePop {
  0% { transform: scale(1); }
  50% { transform: scale(1.02); }
  100% { transform: scale(1); }
}

/* ── Filters ── */
.flt {
  display: flex;
  gap: 5px;
  padding: 8px 12px;
  overflow-x: auto;
  background: var(--bg);
  border-bottom: 1px solid var(--bdr);
  -webkit-overflow-scrolling: touch;
}
.flt::-webkit-scrollbar { display: none; }

/* ── Question Card ── */
.qcard {
  margin: 12px;
  border-radius: var(--r);
  background: var(--card-gradient), var(--sf);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  overflow: hidden;
  animation: fadeUp var(--anim-base) var(--ease-out) both;
  transition: border-color 0.4s ease;
}
.qcard.feedback-correct {
  animation: feedbackPulse 0.6s ease both;
  --pulse-color: var(--grn);
}
.qcard.feedback-wrong {
  animation: feedbackPulse 0.6s ease both;
  --pulse-color: var(--red);
}
.qhdr {
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--glass-border);
  background: var(--glass-bg);
}
.qnum { font-family: "SF Mono", "JetBrains Mono", monospace; font-size: 12px; font-weight: 700; color: var(--acc); letter-spacing: 0.04em; }
.qtype {
  font-family: "SF Mono", "JetBrains Mono", monospace;
  font-size: 10px;
  padding: 3px 10px;
  border-radius: 9999px;
  font-weight: 600;
  border: 1px solid var(--bdr);
  letter-spacing: 0.03em;
}
.qtype.mcq { color: var(--acc); border-color: rgba(10,132,255,0.3); }
.qtype.yesno { color: var(--pur); border-color: rgba(10,132,255,0.3); }
.qtype.text { color: var(--cyn); border-color: var(--cyn-border); }
.qtype.study { color: var(--amb); border-color: var(--amb-border); }
.qtype.dropdown { color: var(--cyn); border-color: var(--cyn-border); }
.qtype.dragdrop { color: var(--amb); border-color: var(--amb-border); }
.qtype.multiselect { color: var(--pur); border-color: var(--pur-border); }
.qtype.ordering { color: var(--cyn); border-color: var(--cyn-border); }
.qtype.explain { color: var(--dim); border-color: rgba(255,255,255,0.15); }

.qbody { padding: 18px; overflow-x: auto; }
.qbody p { font-family: var(--font-body); font-size: 15px; line-height: 1.7; margin-bottom: 8px; color: var(--tx); overflow-wrap: break-word; word-break: break-word; }
.qbody .cfg { font-size: 12px; color: var(--dim); padding-left: 12px; margin-bottom: 3px; }
.qbody .scenario { margin-bottom: 12px; }

/* ── Tables ── */
.qt, .qt-tbl {
  width: 100%;
  border-collapse: collapse;
  margin: 10px 0;
  font-size: 12px;
  border: 1px solid var(--bdr);
}
.qt th, .qt-tbl th {
  background: var(--sf);
  color: var(--acc);
  font-weight: 700;
  text-align: left;
  padding: 7px 10px;
  border: 1px solid var(--bdr);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.qt td, .qt-tbl td {
  padding: 6px 10px;
  border: 1px solid var(--bdr);
  color: var(--tx);
}
.qt .ent, .qt-tbl .ent, .qt td:first-child, .qt-tbl td:first-child {
  font-weight: 700;
  color: var(--wh);
}
.qt tr:nth-child(even), .qt-tbl tr:nth-child(even) { background: var(--zebra-bg); }
.qt tr:hover, .qt-tbl tr:hover { background: var(--acc-5); }

/* ── MCQ Choices ── */
.choices {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}
.choice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px;
  border-radius: var(--r2);
  border: 1px solid var(--glass-border);
  background: var(--glass-bg);
  cursor: pointer;
  transition: all 0.15s ease;
}
.choice:hover { border-color: var(--glass-border-strong); background: var(--glass-bg-strong); }
.choice.sel { border-color: var(--acc); border-left: 3px solid var(--acc); background: var(--acc-8); }
.choice.correct { border-color: var(--grn); border-left: 3px solid var(--grn); background: var(--grn-soft); }
.choice.wrong { border-color: var(--red); border-left: 3px solid var(--red); background: var(--red-soft); }
.choice .lt {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid var(--bdr2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--dim);
  flex-shrink: 0;
  transition: all 0.15s ease;
}
.choice.sel .lt { border-color: var(--acc); color: var(--acc); background: var(--acc-15); }
.choice.correct .lt { border-color: var(--grn); color: var(--grn); background: var(--grn-soft-2); }
.choice.wrong .lt { border-color: var(--red); color: var(--red); background: var(--red-soft-2); }
.choice .ct { font-family: var(--font-body); font-size: 14px; line-height: 1.5; flex: 1; }

/* ── Yes/No Items ── */
.yn-list { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.yn-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: var(--r2);
  border: 1px solid var(--glass-border);
  background: var(--glass-bg);
}
.yn-label { flex: 1; font-size: 12px; font-weight: 600; color: var(--wh); }
.yn-btns { display: flex; gap: 4px; }
.yn-btn {
  padding: 4px 14px;
  border-radius: 14px;
  border: 1px solid var(--bdr);
  background: transparent;
  color: var(--dim);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}
.yn-btn:hover { border-color: var(--bdr2); }
.yn-btn.sel-y { border-color: var(--grn); color: var(--grn); background: var(--grn-soft); }
.yn-btn.sel-n { border-color: var(--red); color: var(--red); background: var(--red-soft); }
.yn-btn.cor { border-color: var(--grn); color: var(--grn); background: var(--grn-soft-2); }
.yn-btn.wrg { border-color: var(--red); color: var(--red); background: var(--red-soft-2); }
.yn-item.checked-ok { background: var(--grn-soft); border-color: var(--grn-border); }
.yn-item.checked-bad { background: var(--red-soft); border-color: var(--red-border); }
.yn-item.yn-incomplete { border-color: var(--amb); background: var(--amb-soft); }

/* ── Text Input ── */
.txt-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--r2);
  border: 1px solid var(--bdr);
  background: var(--sf);
  color: var(--wh);
  font-size: 13px;
  font-family: inherit;
  margin-top: 10px;
  resize: vertical;
  min-height: 44px;
}
.txt-input:focus { outline: none; border-color: var(--acc); }
.txt-input::placeholder { color: var(--dim); }

/* ── Actions ── */
.actions { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }

/* ── Feedback ── */
.feedback {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: var(--r2);
  font-size: 12px;
  line-height: 1.6;
  animation: slideDown var(--anim-base) var(--ease-out) both;
}
.feedback.ok { background: var(--grn-soft); border: 1px solid var(--grn-border); color: var(--grn); }
.feedback.bad { background: var(--red-soft); border: 1px solid var(--red-border); color: var(--red); }
.feedback-sub { font-size: 12px; font-weight: 400; color: var(--dim); margin-top: 6px; line-height: 1.4; }
.feedback .ans-val { font-weight: 700; color: var(--wh); }
.feedback-why { margin-top: 10px; padding: 10px 12px; background: rgba(255,255,255,0.04); border-radius: 8px; font-size: 13px; font-weight: 400; color: var(--tx); line-height: 1.5; }
.feedback-why strong { color: var(--wh); font-family: "SF Mono", "JetBrains Mono", monospace; font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; }
.feedback-why em { color: var(--dim); font-style: normal; }
.feedback-illumi-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  padding: 8px 16px;
  background: #1a1a2e;
  color: #ffd54f;
  border: 1px solid rgba(255,213,79,0.3);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  box-shadow: 0 0 8px rgba(255,213,79,0.15);
  transition: box-shadow 0.2s ease;
}
.feedback-illumi-btn:hover {
  box-shadow: 0 0 16px rgba(255,213,79,0.3);
}

/* ── Misconception Hint ── */
.misconception-hint {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--acc-5);
  border: 1px solid rgba(10,132,255,0.15);
  border-radius: 10px;
  animation: slideDown var(--anim-base) var(--ease-out) 0.3s both;
}
.misconception-hint-icon {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: var(--acc-12);
  color: var(--acc);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}
.misconception-hint-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--acc);
  margin-bottom: 2px;
}
.misconception-hint-text {
  font-size: 12px;
  color: var(--dim);
  line-height: 1.4;
}
.misconception-hint-text strong {
  color: var(--wh);
  font-weight: 600;
}

/* ── Floating Nav Arrows ── */
.nav-bar {
  display: none;
}
.quiz-nav-arrows {
  position: fixed;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  z-index: 50;
  padding: 0 4px;
}
.quiz-nav-arrow {
  pointer-events: auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--glass-border);
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: var(--dim);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--anim-base) var(--ease-out);
}
.quiz-nav-arrow:hover {
  background: var(--acc);
  border-color: var(--acc);
  color: var(--text-on-accent);
  box-shadow: var(--elev-2);
}
.quiz-nav-arrow:active {
  transform: scale(0.95);
}
.quiz-nav-arrow:disabled {
  opacity: 0;
  pointer-events: none;
}
.quiz-nav-pos {
  pointer-events: auto;
  font-size: 11px;
  font-weight: 700;
  color: var(--dim);
  background: var(--overlay-bg);
  border: 1px solid var(--bdr);
  border-radius: 20px;
  padding: 4px 12px;
  font-variant-numeric: tabular-nums;
}

/* ── Jump ── */
.jump { display: flex; gap: 6px; padding: 8px 12px; align-items: center; }
.jump input {
  width: 60px;
  padding: 6px 8px;
  border-radius: var(--r2);
  border: 1px solid var(--bdr);
  background: var(--sf);
  color: var(--wh);
  font-size: 12px;
  text-align: center;
}
.jump input:focus { outline: none; border-color: var(--acc); }

/* ── Domain tag ── */
.domain-tag {
  font-size: 9px;
  padding: 2px 6px;
  border-radius: 8px;
  font-weight: 600;
  background: var(--tint-bg);
  color: var(--dim);
}

/* ═══════════════════════════════
   DROPDOWN SELECT
   ═══════════════════════════════ */
.dd-list { margin-top: 12px; }
.dd-item {
  padding: 12px;
  margin-bottom: 8px;
  border-radius: var(--r2);
  background: var(--sf);
  border: 1px solid var(--bdr);
  line-height: 1.8;
}
.dd-select {
  padding: 4px 8px;
  margin: 0 4px;
  border-radius: 4px;
  border: 2px solid var(--acc);
  background: var(--bg);
  color: var(--wh);
  font-size: 13px;
  cursor: pointer;
}
.dd-select:disabled { opacity: 0.6; cursor: default; }
.dd-text { font-size: 13px; color: var(--wh); }
.dd-correct { border-color: var(--grn); background: var(--grn-soft); }
.dd-wrong { border-color: var(--red); background: var(--red-soft); }
.dd-correction {
  display: inline-block;
  margin-left: 8px;
  font-size: 12px;
  color: var(--grn);
  font-weight: 600;
}

/* ═══════════════════════════════
   DRAG & DROP
   ═══════════════════════════════ */
.dnd-container { margin-top: 12px; }
.dnd-section { margin-bottom: 16px; }
.dnd-heading { font-size: 11px; text-transform: uppercase; color: var(--dim); margin-bottom: 8px; letter-spacing: .5px; }
.dnd-items { display: flex; flex-wrap: wrap; gap: 6px; }
.dnd-chip {
  padding: 8px 14px;
  border-radius: var(--r2);
  background: var(--acc);
  color: var(--text-on-color);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: .2s;
  border: 2px solid transparent;
}
.dnd-chip.active { border-color: var(--text-on-accent); box-shadow: 0 0 12px rgba(10,132,255,.5); transform: scale(1.05); }
.dnd-chip.assigned { opacity: 0.4; }
.dnd-chip.dnd-correct { background: var(--grn); opacity: 1; }
.dnd-chip.dnd-wrong { background: var(--red); opacity: 1; }
.dnd-targets { display: flex; flex-direction: column; gap: 8px; }
.dnd-target {
  padding: 12px;
  border-radius: var(--r2);
  background: var(--sf);
  border: 1px dashed var(--bdr);
}
.dnd-target.dnd-correct { border-color: var(--grn); border-style: solid; background: var(--grn-soft); }
.dnd-target.dnd-wrong { border-color: var(--red); border-style: solid; background: var(--red-soft); }
.dnd-target-label { font-size: 13px; color: var(--wh); margin-bottom: 6px; }
.dnd-slot {
  padding: 8px 12px;
  border-radius: 4px;
  background: var(--bg);
  min-height: 32px;
  font-size: 12px;
  color: var(--acc);
  font-weight: 600;
}
.dnd-placeholder { color: var(--dim); font-weight: 400; font-style: italic; }
.dnd-correction { font-size: 11px; color: var(--grn); margin-top: 4px; font-weight: 600; }

/* ═══════════════════════════════
   MULTI-SELECT
   ═══════════════════════════════ */
.ms-choices .ms-choice { cursor: pointer; }
.ms-check { font-size: 16px; min-width: 24px; }
.ms-counter {
  text-align: center;
  font-size: 12px;
  color: var(--dim);
  margin-top: 8px;
  padding: 6px;
  border-radius: var(--r2);
  background: var(--sf);
}

/* ═══════════════════════════════
   ORDERING
   ═══════════════════════════════ */
.ord-list { margin-top: 12px; }
.ord-hint { font-size: 11px; color: var(--dim); margin-bottom: 8px; font-style: italic; }
.ord-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  margin-bottom: 6px;
  border-radius: var(--r2);
  background: var(--sf);
  border: 1px solid var(--bdr);
  cursor: pointer;
  transition: .2s;
}
.ord-item:hover { border-color: var(--acc); }
.ord-item.ord-active { border-color: var(--acc); background: rgba(10,132,255,.12); box-shadow: 0 0 8px rgba(10,132,255,.3); }
.ord-item.ord-correct { border-color: var(--grn); background: var(--grn-soft); }
.ord-item.ord-wrong { border-color: var(--red); background: var(--red-soft); }
.ord-num {
  min-width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--acc);
  color: var(--text-on-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}
.ord-label { font-size: 13px; color: var(--wh); flex: 1; }
.ord-correction { font-size: 11px; color: var(--amb); font-weight: 600; white-space: nowrap; }

/* ═══════════════════════════════
   QUESTION FEEDBACK
   ═══════════════════════════════ */
.q-feedback-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}
.btn-feedback {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 14px;
  border: 1px solid var(--bdr);
  background: transparent;
  color: var(--dim);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.btn-feedback:hover {
  border-color: var(--acc);
  color: var(--acc);
  background: var(--acc-8);
}

/* ── Feedback Modal ── */
.feedback-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 16px;
}
.feedback-modal {
  background: var(--card-gradient), var(--sf);
  border: 1px solid var(--glass-border);
  border-radius: var(--r);
  box-shadow: var(--shadow-hero);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  padding: 20px;
  max-width: 360px;
  width: 100%;
  animation: fadeUp 0.2s ease both;
}
.feedback-modal-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--wh);
  margin-bottom: 2px;
}
.feedback-modal-subtitle {
  font-size: 12px;
  color: var(--dim);
  margin-bottom: 16px;
}
.feedback-modal-options {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}
.feedback-modal-opt {
  padding: 10px 14px;
  border-radius: var(--r2);
  border: 1px solid var(--bdr);
  background: var(--sf);
  color: var(--tx);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
}
.feedback-modal-opt:hover {
  border-color: var(--bdr2);
  background: var(--cd2);
}
.feedback-modal-opt.selected {
  border-color: var(--acc);
  background: var(--acc-10);
  color: var(--acc);
  font-weight: 600;
}
.feedback-modal-comment {
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--r2);
  border: 1px solid var(--bdr);
  background: var(--sf);
  color: var(--wh);
  font-size: 12px;
  font-family: inherit;
  resize: vertical;
  min-height: 60px;
  margin-bottom: 12px;
  box-sizing: border-box;
}
.feedback-modal-comment:focus {
  outline: none;
  border-color: var(--acc);
}
.feedback-modal-comment::placeholder { color: var(--dim); }
.feedback-modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

/* ── Exam Report Question Rows ── */
.report-questions {
  margin-top: 16px;
}
.report-q-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid var(--bdr);
}
.report-q-row:last-child { border-bottom: none; }
.report-q-id {
  font-size: 12px;
  font-weight: 600;
  color: var(--wh);
  min-width: 50px;
}

/* ═══════════════════════════════
   CLI LAB TERMINAL
   ═══════════════════════════════ */
.qtype.cli { color: #27c93f; border-color: rgba(39,201,63,0.3); }
.cli-terminal { background:#0c0c0c; border-radius:var(--r); overflow:hidden; border:1px solid #333; margin:16px 0; }
.cli-titlebar { display:flex; align-items:center; gap:6px; padding:8px 12px; background:#1a1a1a; border-bottom:1px solid #333; }
.cli-dot { width:10px; height:10px; border-radius:50%; }
.cli-dot-r { background:#ff5f56; }
.cli-dot-y { background:#ffbd2e; }
.cli-dot-g { background:#27c93f; }
.cli-title { font-size:11px; color:#888; margin-left:8px; font-family:monospace; }
.cli-body { padding:12px 14px; min-height:80px; font-family:'Cascadia Code','Consolas','Courier New',monospace; font-size:13px; line-height:1.6; }
.cli-line { display:flex; align-items:center; gap:0; flex-wrap:wrap; }
.cli-prompt { color:#27c93f; white-space:nowrap; margin-right:6px; }
.cli-text { color:#e0e0e0; word-break:break-all; }
.cli-input { background:transparent; border:none; outline:none; color:#e0e0e0; font-family:inherit; font-size:inherit; flex:1; min-width:200px; caret-color:#27c93f; }
.cli-input::placeholder { color:#555; }
.cli-output { margin-top:8px; padding:4px 0; }
.cli-success { color:#27c93f; }
.cli-error { color:#ff5f56; }

/* Micro-feedback overlay */
.micro-feedback-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease-out;
  cursor: pointer;
}
.micro-feedback-overlay.micro-feedback-fade {
  opacity: 0;
  transition: opacity 0.3s ease-out;
}
.micro-feedback-content {
  text-align: center;
  padding: 32px 24px;
  max-width: 280px;
}
.micro-feedback-done {
  font-size: 18px;
  font-weight: 700;
  color: var(--wh);
  margin-bottom: 12px;
}
.micro-feedback-bar {
  width: 100%;
  height: 6px;
  background: rgba(255,255,255,0.1);
  border-radius: 3px;
  margin-bottom: 16px;
  overflow: hidden;
}
.micro-feedback-bar-fill {
  height: 100%;
  background: var(--acc);
  border-radius: 3px;
  transition: width 0.5s ease-out;
}
.micro-feedback-score {
  font-size: 15px;
  font-weight: 600;
  color: var(--dim);
  margin-bottom: 8px;
}
.micro-feedback-msg {
  font-size: 16px;
  font-weight: 700;
  color: var(--acc);
}

/* ═══════════════════════════════
   QUICK SESSION RESULTS
   ═══════════════════════════════ */
.quick-results {
  max-width: 420px;
  margin: 32px auto;
  padding: 24px 16px;
  text-align: center;
  animation: fadeUp 0.4s var(--ease-out);
}
.quick-results-icon {
  color: var(--acc);
  margin-bottom: 12px;
}
.quick-results-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--tx);
  margin-bottom: 4px;
}
.quick-results-score {
  font-size: 14px;
  color: var(--dim);
  margin-bottom: 20px;
}
.quick-results-ring {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}
.quick-results-missed {
  background: var(--card-gradient), var(--sf);
  border: 1px solid var(--glass-border);
  border-radius: var(--r);
  box-shadow: var(--shadow-soft);
  padding: 12px 16px;
  margin-bottom: 20px;
  text-align: left;
}
.quick-results-missed-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--tx);
  margin-bottom: 8px;
}
.quick-results-missed-item {
  font-size: 12px;
  color: var(--dim);
  padding: 4px 0;
  display: flex;
  align-items: flex-start;
  gap: 6px;
  line-height: 1.4;
}
.quick-results-missed-item .icon-wrap {
  color: var(--red);
  flex-shrink: 0;
  margin-top: 1px;
}
.quick-results-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.quick-results-actions .btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  font-size: 14px;
  border-radius: var(--r);
  font-weight: 600;
}
.quick-results-actions .btn-acc {
  background: var(--acc);
  color: var(--text-on-accent);
  border: none;
}
.quick-results-actions .btn-sec {
  background: var(--sf);
  color: var(--dim);
  border: 1px solid var(--bdr);
}

/* ── Cross-Reference Panel ── */
.xref-panel {
  margin-top: 12px;
  padding: 10px 12px;
  background: var(--sf);
  border: 1px solid var(--bdr);
  border-radius: 10px;
}
.xref-panel-fc {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--bdr);
  background: none;
  border: none;
  border-radius: 0;
}
.xref-header {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--dim);
  margin-bottom: 8px;
}
.xref-cards {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.xref-card {
  padding: 8px 10px;
  background: var(--bg);
  border: 1px solid var(--bdr);
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 0.15s;
}
.xref-card:active {
  border-color: var(--pri);
}
.xref-card-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--wh);
}
.xref-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.xref-tag {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--sf);
  color: var(--dim);
  border: 1px solid var(--bdr);
}
.xref-tag-more {
  color: var(--pri);
  border-color: var(--pri);
}

/* ── Cross-Ref Flashcard Overlay ── */
.xref-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.15s ease-out;
}
.xref-viewer {
  width: 100%;
  max-width: 400px;
  max-height: 80vh;
  overflow-y: auto;
  padding: 16px;
  border-radius: 14px;
  background: var(--card);
  border: 1px solid var(--bdr);
  animation: fadeUp 0.2s ease-out;
}
.xref-viewer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}
.xref-close {
  background: none;
  border: none;
  color: var(--dim);
  cursor: pointer;
  padding: 4px;
}
.xref-viewer-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--wh);
  margin-bottom: 10px;
}
.xref-viewer-body {
  font-size: 13px;
  color: var(--tx);
  line-height: 1.6;
}
