/* ═══════════════════════════════════════════════════════
   opgave.css — question engine styles
   Inherits CSS variables from ../styles.css
═══════════════════════════════════════════════════════ */

/* ── Page shell ── */
.opgave-page {
  background: var(--cream);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Header ── */
.oq-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  height: 56px;
  background: #fff;
  border-bottom: 1px solid var(--cream-dark);
  flex-shrink: 0;
  position: sticky;
  top: 0;
  z-index: 50;
}
.oq-header__back {
  font-size: .88rem;
  font-weight: 700;
  color: var(--ink-mid);
  transition: color .2s;
}
.oq-header__back:hover { color: var(--teal); }
.oq-header__meta { display: flex; align-items: center; gap: 1rem; }
.oq-header__xp {
  font-size: .82rem; font-weight: 800;
  background: var(--teal-light); color: var(--teal);
  padding: 3px 12px; border-radius: 99px;
  border: 1px solid rgba(29,140,114,.2);
}
.oq-header__streak {
  font-size: .88rem; font-weight: 800; color: var(--amber);
}

/* ── Session progress bar ── */
.oq-session-progress {
  height: 4px;
  background: var(--cream-dark);
  flex-shrink: 0;
}
.oq-session-progress__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--teal), var(--teal-mid));
  transition: width .5s ease;
}

/* ── Main ── */
.oq-main {
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 2.5rem 1rem 4rem;
}

/* ── States ── */
.oq-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  text-align: center;
  padding: 3rem 1rem;
  color: var(--ink-mid);
}
.oq-state--hidden { display: none !important; }
.oq-state__icon { font-size: 3.5rem; line-height: 1; }
.oq-state h2 { font-size: 1.5rem; font-weight: 800; color: var(--ink); }
.oq-state p { font-size: .95rem; color: var(--ink-mid); }

/* ── Spinner ── */
.oq-spinner {
  width: 40px; height: 40px;
  border: 3px solid var(--cream-dark);
  border-top-color: var(--teal);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ═══════════════════════════════════════════════════════
   Question card — split layout
═══════════════════════════════════════════════════════ */
.oq-card {
  display: grid;
  grid-template-columns: 2fr 3fr;
  width: 100%;
  max-width: 900px;
  border-radius: 20px;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  border: 1px solid var(--cream-dark);
  background: #fff;
}

/* Entry animation */
.oq-card.anim-in {
  animation: cardIn .35s cubic-bezier(.22,.68,0,1.2) both;
}
@keyframes cardIn {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Left panel ── */
.oq-card__left {
  padding: 32px 28px;
  background: linear-gradient(145deg, var(--teal) 0%, var(--teal-mid) 100%);
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 280px;
}
.oq-card__left--amber  { background: linear-gradient(145deg, #92400e, var(--amber)); }
.oq-card__left--coral  { background: linear-gradient(145deg, #991b1b, var(--coral)); }
.oq-card__left--blue   { background: linear-gradient(145deg, #1e40af, var(--blue)); }
.oq-card__left--purple { background: linear-gradient(145deg, #4c1d95, var(--purple)); }

.oql-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.oql-badge {
  font-size: .7rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
  background: rgba(255,255,255,.2); padding: 3px 10px; border-radius: 99px;
}
.oql-step { font-size: .75rem; font-weight: 700; opacity: .75; }

.oql-progress {
  height: 5px; background: rgba(255,255,255,.25); border-radius: 99px; overflow: hidden;
}
.oql-progress-fill {
  height: 100%; background: #fff; border-radius: 99px; transition: width .5s ease;
}

.oql-question {
  font-size: 1.05rem; font-weight: 700; line-height: 1.55; flex: 1;
}

.oql-type {
  font-size: .65rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  opacity: .45; margin-top: auto;
}

/* ── Right panel ── */
.oq-card__right {
  padding: 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: #fff;
  overflow: hidden;
}

.oqr-label {
  font-size: .72rem; font-weight: 800; color: var(--ink-light);
  text-transform: uppercase; letter-spacing: .09em;
}

.oqr-area {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.oqr-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 4px;
  border-top: 1px solid var(--cream-dark);
}

/* ── Hint ── */
.hint-btn {
  font-size: .82rem; font-weight: 700; color: var(--amber);
  display: inline-flex; align-items: center; gap: 5px;
  transition: opacity .2s; padding: 0;
  background: none; border: none; cursor: pointer; font-family: inherit;
}
.hint-btn:hover { opacity: .7; }

.hint-box {
  background: var(--amber-light);
  border-left: 3px solid var(--amber);
  border-radius: 0 10px 10px 0;
  padding: 11px 15px;
  font-size: .85rem; font-weight: 600; color: #78350f;
  display: none;
}
.hint-box.open { display: block; }

/* ── Feedback banner ── */
.oqr-feedback {
  border-radius: 10px;
  padding: 10px 15px;
  font-size: .88rem; font-weight: 700;
  display: none;
}
.oqr-feedback.ok  { display: block; background: var(--green-light); color: #14532d; border: 1.5px solid var(--green); }
.oqr-feedback.err { display: block; background: var(--coral-light);  color: #7f1d1d;  border: 1.5px solid var(--coral); }

/* ── Shared input styles ── */
.q-input {
  width: 100%; height: 44px;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  padding: 0 14px;
  font-family: 'Nunito', sans-serif; font-size: 1rem; font-weight: 700;
  color: var(--ink); background: #fff;
  outline: none; transition: border-color .2s;
}
.q-input:focus { border-color: var(--teal); }
.q-input--sm   { width: 80px; text-align: center; }
.q-input--md   { width: 130px; }
.q-input--num  { font-size: 1.1rem; }

.q-textarea {
  width: 100%; min-height: 96px; resize: vertical;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  padding: 10px 14px;
  font-family: 'Nunito', sans-serif; font-size: .95rem; font-weight: 600;
  color: var(--ink); background: #fff;
  outline: none; transition: border-color .2s;
}
.q-textarea:focus { border-color: var(--teal); }

/* ── Markdown table (rendered from | pipe | syntax | in tekst) ── */
.q-table {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0 6px;
  font-size: .9rem;
  font-family: 'Nunito', sans-serif;
  border-radius: 8px;
  overflow: hidden;
}

.q-table th {
  background: var(--teal);
  color: #fff;
  font-weight: 700;
  padding: 7px 12px;
  text-align: left;
  border: 1px solid var(--teal);
}

.q-table td {
  padding: 6px 12px;
  text-align: left;
  border: 1px solid var(--cream-dark);
  color: var(--ink);
}

.q-table tr:nth-child(even) td {
  background: var(--cream);
}

.q-table tr:nth-child(odd) td {
  background: #fff;
}

.q-select {
  height: 44px; padding: 0 12px;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  font-family: 'Nunito', sans-serif; font-size: .92rem; font-weight: 700;
  color: var(--ink); background: #fff; outline: none; cursor: pointer;
  transition: border-color .2s;
}
.q-select:focus { border-color: var(--teal); }

/* ── Row helpers ── */
.q-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.q-row--center { justify-content: center; }

/* ── Fraction ── */
.frac-wrap { display: inline-flex; flex-direction: column; align-items: center; gap: 0; }
.frac-line { width: 64px; height: 2px; background: var(--ink); margin: 3px 0; }

/* ── Options (radio / checkbox / true_false) ── */
.options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.options-grid--1col { grid-template-columns: 1fr; }

.opt-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  cursor: pointer; font-weight: 700; font-size: .9rem;
  transition: border-color .15s, background .15s;
  user-select: none; background: #fff;
}
.opt-item:hover { border-color: var(--teal); background: var(--teal-light); }
.opt-item.is-selected { border-color: var(--teal); background: var(--teal-light); color: var(--teal); }
.opt-item.is-correct  { border-color: var(--green); background: var(--green-light); color: #14532d; pointer-events: none; }
.opt-item.is-wrong    { border-color: var(--coral);  background: var(--coral-light);  color: #7f1d1d;  pointer-events: none; }

.opt-key {
  width: 26px; height: 26px; border-radius: 6px;
  background: var(--cream-dark); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: .75rem; font-weight: 900; transition: background .15s, color .15s;
}
.opt-item.is-selected .opt-key { background: var(--teal); color: #fff; }
.opt-item.is-correct .opt-key  { background: var(--green); color: #fff; }
.opt-item.is-wrong .opt-key    { background: var(--coral);  color: #fff; }

/* True / false */
.tf-row { display: flex; gap: 12px; }
.tf-btn {
  flex: 1; height: 52px; border-radius: 12px;
  border: 2px solid var(--cream-dark); background: #fff;
  font-family: 'Nunito', sans-serif; font-size: 1rem; font-weight: 800;
  cursor: pointer; transition: all .15s;
}
.tf-btn:hover { border-color: var(--teal); color: var(--teal); background: var(--teal-light); }
.tf-btn.is-selected { border-color: var(--teal); background: var(--teal-light); color: var(--teal); }
.tf-btn.is-correct  { border-color: var(--green); background: var(--green-light); color: #14532d; pointer-events: none; }
.tf-btn.is-wrong    { border-color: var(--coral);  background: var(--coral-light);  color: #7f1d1d;  pointer-events: none; }

/* ── Table input ── */
.q-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.q-table th {
  background: var(--cream-mid); font-weight: 800; font-size: .75rem;
  color: var(--ink-mid); text-align: left;
  padding: 8px 10px; border: 1px solid var(--cream-dark);
}
.q-table td { border: 1px solid var(--cream-dark); padding: 4px 6px; }
.q-table input {
  border: none; outline: none; width: 100%; text-align: center;
  font-family: 'Nunito', sans-serif; font-size: .9rem; font-weight: 700;
  color: var(--teal); background: transparent;
}

/* ── Multi-input field rows ── */
.field-row {
  display: flex; align-items: center; gap: 10px;
}
.field-row__label {
  width: 100px; font-size: .85rem; font-weight: 700; color: var(--ink-mid);
  flex-shrink: 0;
}
.field-row__unit { font-size: .82rem; color: var(--ink-light); font-weight: 700; }

/* ── Sort / rank ── */
.sort-list { display: flex; flex-direction: column; gap: 7px; }
.sort-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  background: #fff; font-weight: 700; font-size: .92rem;
  cursor: grab; transition: box-shadow .15s;
}
.sort-item.dragging { opacity: .4; box-shadow: var(--shadow-md); }
.sort-item.drag-over { border-color: var(--teal); background: var(--teal-light); }
.sort-handle { color: var(--cream-dark); font-size: 1.1rem; flex-shrink: 0; }
.sort-num {
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--cream-mid); color: var(--ink-mid);
  font-size: .75rem; font-weight: 900;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: background .2s, color .2s;
}

/* ── Match ── */
.match-grid { display: flex; flex-direction: column; gap: 8px; }
.match-row  { display: grid; grid-template-columns: 1fr 28px 1fr; gap: 8px; align-items: center; }
.match-left {
  padding: 9px 12px; border-radius: 10px; font-weight: 700; font-size: .88rem;
  text-align: center; background: var(--teal-light); color: var(--teal);
  border: 1.5px solid rgba(29,140,114,.25);
}
.match-arrow { text-align: center; color: var(--ink-light); font-size: .9rem; }
.match-select { width: 100%; }

/* ── Steps (fill_steps / step_solution) ── */
.steps-list { display: flex; flex-direction: column; gap: 10px; }
.step-row   { display: grid; grid-template-columns: 28px 1fr; gap: 12px; align-items: start; }
.step-dot {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--cream-mid); color: var(--ink-light);
  font-size: .75rem; font-weight: 900; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  margin-top: 4px;
}
.step-dot--done   { background: var(--green); color: #fff; }
.step-dot--active { background: var(--teal);  color: #fff; }
.step-body { font-size: .9rem; font-weight: 600; color: var(--ink-mid); line-height: 1.6; padding-top: 4px; }
.step-body strong { color: var(--ink); font-weight: 800; }

.step-inline {
  display: inline-flex; align-items: center;
  border-bottom: 2px solid var(--teal);
  vertical-align: bottom;
}
.step-inline input {
  width: 48px; border: none; outline: none;
  font-family: 'Nunito', sans-serif; font-size: .9rem; font-weight: 900;
  color: var(--teal); text-align: center; background: transparent;
}

/* ── Error detection ── */
.error-list { display: flex; flex-direction: column; gap: 7px; }
.error-step {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 13px;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  cursor: pointer; font-size: .88rem; font-weight: 600;
  transition: all .15s; background: #fff;
}
.error-step:hover { border-color: var(--coral); background: var(--coral-light); }
.error-step.is-selected { border-color: var(--coral); background: var(--coral-light); color: #7f1d1d; }
.error-step.is-correct  { border-color: var(--green); background: var(--green-light); color: #14532d; pointer-events: none; }
.error-step-num {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--cream-dark); font-size: .72rem; font-weight: 900;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

/* ── Slider / number line ── */
.slider-wrap { display: flex; flex-direction: column; gap: 6px; }
.slider-val  { font-size: 1.5rem; font-weight: 900; color: var(--teal); text-align: center; }

.q-range {
  -webkit-appearance: none;
  width: 100%; height: 6px; border-radius: 99px;
  background: var(--cream-dark); outline: none; cursor: pointer;
}
.q-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--teal); cursor: pointer;
  box-shadow: 0 2px 8px rgba(29,140,114,.35);
}
.q-range::-moz-range-thumb {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--teal); border: none; cursor: pointer;
}
.range-labels {
  display: flex; justify-content: space-between;
  font-size: .72rem; color: var(--ink-light); font-weight: 700;
}

/* ── Number line ── */
.nl-wrap {
  width: 100%;
  touch-action: none;
  user-select: none;
  padding: 4px 0 8px;
}
.nl-svg {
  width: 100%;
  height: 70px;
  display: block;
  overflow: visible;
}

/* ── Coordinate grid ── */
.coord-wrap {
  position: relative; width: 100%; aspect-ratio: 1;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  overflow: hidden; background: var(--cream); cursor: crosshair;
  max-height: 220px;
}
.coord-info {
  font-size: .78rem; font-weight: 700; color: var(--ink-light);
  text-align: center; margin-top: 4px;
}

/* ── Area mark grid ── */
.area-grid { display: grid; gap: 4px; }
.area-cell {
  aspect-ratio: 1; border-radius: 5px;
  background: var(--cream-mid); border: 1.5px solid var(--cream-dark);
  cursor: pointer; transition: background .12s, border-color .12s;
}
.area-cell.is-marked { background: var(--teal); border-color: var(--teal); }
.area-count { font-size: .8rem; font-weight: 700; color: var(--ink-light); text-align: center; margin-top: 4px; }

/* ── Highlight text ── */
.hl-text { font-size: .92rem; font-weight: 600; color: var(--ink-mid); line-height: 2.1; }
.hl-word { cursor: pointer; border-radius: 4px; padding: 1px 3px; transition: background .12s; }
.hl-word:hover    { background: var(--amber-light); }
.hl-word.is-marked { background: var(--amber); color: #fff; }

/* ── Canvas draw ── */
.draw-canvas {
  width: 100%; aspect-ratio: 16/7;
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  background: var(--cream); cursor: crosshair; touch-action: none;
  display: block;
}
.draw-toolbar { display: flex; gap: 7px; }
.draw-tool-btn {
  height: 34px; padding: 0 14px;
  border: 1.5px solid var(--cream-dark); border-radius: 8px;
  font-family: 'Nunito', sans-serif; font-size: .82rem; font-weight: 700;
  background: #fff; color: var(--ink-mid); cursor: pointer; transition: all .15s;
}
.draw-tool-btn:hover { border-color: var(--teal); color: var(--teal); }

/* ── Formula toolbar ── */
.formula-toolbar { display: flex; gap: 5px; flex-wrap: wrap; }
.fml-key {
  padding: 4px 10px;
  border: 1.5px solid var(--cream-dark); border-radius: 6px;
  font-size: .8rem; font-weight: 800; background: var(--cream); color: var(--ink-mid);
  cursor: pointer; transition: all .15s;
}
.fml-key:hover { border-color: var(--teal); color: var(--teal); background: var(--teal-light); }

/* ── File upload ── */
.upload-zone {
  border: 2px dashed var(--cream-dark); border-radius: 12px;
  padding: 24px; text-align: center; background: var(--cream);
  cursor: pointer; transition: border-color .2s;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.upload-zone:hover { border-color: var(--teal); }
.upload-zone__icon { font-size: 2rem; line-height: 1; }
.upload-zone__text { font-size: .85rem; font-weight: 700; color: var(--ink-light); }
.upload-zone__text strong { color: var(--teal); }
.upload-filename { font-size: .82rem; font-weight: 700; color: var(--teal); }

/* ── Combined (multi-part) ── */
.combined-parts { display: flex; flex-direction: column; gap: 12px; }
.combined-part {
  border: 1.5px solid var(--cream-dark); border-radius: 10px;
  padding: 14px 16px;
}
.combined-part__label {
  font-size: .7rem; font-weight: 800; color: var(--ink-light);
  text-transform: uppercase; letter-spacing: .08em; margin-bottom: 8px;
}

/* ── Unknown type placeholder ── */
.unknown-type {
  padding: 20px; border-radius: 10px;
  background: var(--cream-mid); color: var(--ink-mid);
  font-size: .88rem; font-weight: 700; text-align: center;
}

/* ── Shared btn overrides for page ── */
.btn--primary {
  height: 40px; padding: 0 22px;
  background: var(--teal); color: #fff; border-radius: 99px;
  font-family: 'Nunito', sans-serif; font-size: .9rem; font-weight: 800;
  border: none; cursor: pointer; transition: background .2s, opacity .2s;
  white-space: nowrap;
}
.btn--primary:hover { background: #16705b; }
.btn--primary:disabled { opacity: .5; cursor: not-allowed; }

/* ── Responsive ── */
@media (max-width: 660px) {
  .oq-card { grid-template-columns: 1fr; }
  .oq-card__left { min-height: unset; padding: 20px; }
  .oq-card__right { padding: 20px; }
  .options-grid { grid-template-columns: 1fr; }
  .oq-main { padding: 1rem .5rem 3rem; }
}

/* ── Pattern next (figurmønster) ── */
.pn-sequence {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: center;
  padding: 12px 10px;
  background: var(--cream);
  border: 1.5px solid var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 12px;
}

.pn-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--cream-dark);
  flex-shrink: 0;
}

.pn-cell--question {
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--teal);
  background: var(--teal-light);
  border: 2px dashed var(--teal);
}

.pn-prompt {
  font-size: .78rem;
  font-weight: 700;
  color: var(--ink-light);
  margin-bottom: 8px;
  text-align: center;
}

.pn-opt {
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  padding: 10px 6px 10px;
  min-height: 88px;
}

/* ── Figure question (figuropgave) ── */
.fq-figure {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 12px;
  background: var(--cream);
  border: 1.5px solid var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 14px;
}

.fq-figure svg {
  max-width: 100%;
  height: auto;
}

.fq-unit {
  font-size: .95rem;
  font-weight: 700;
  color: var(--ink-mid);
}

/* ── Chart read (diagramopgave) ── */
.cr-chart-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 14px 10px 10px;
  background: var(--cream);
  border: 1.5px solid var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 14px;
}

.cr-chart-wrap svg { max-width: 100%; height: auto; }

.cr-title {
  font-size: .8rem;
  font-weight: 700;
  color: var(--ink-mid);
  margin-bottom: 6px;
  text-align: center;
}

.cr-opt {
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 4px;
  padding: 6px 4px;
  min-height: 118px;
  overflow: hidden;
}

.cr-opt svg { max-width: 100%; height: auto; }

.cr-grid {
  grid-template-columns: 1fr 1fr;
}

/* ── Clock time (ur-opgave) ── */
.ct-clock-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: var(--cream);
  border: 1.5px solid var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 12px;
}

.ct-digital-display {
  font-family: 'Nunito', sans-serif;
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--ink);
  text-align: center;
  padding: 14px 24px;
  background: var(--cream);
  border: 1.5px solid var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 12px;
  letter-spacing: .06em;
}

.ct-prompt {
  font-size: .78rem;
  font-weight: 700;
  color: var(--ink-light);
  margin-bottom: 10px;
  text-align: center;
}

.ct-input {
  text-align: center;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: .08em;
  width: 96px;
}

.ct-opt {
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 4px;
  padding: 8px 4px;
  min-height: 108px;
}

/* ── Figure sequence (figurfølge) ── */
.fs-sequence {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: center;
  padding: 14px 12px;
  background: var(--cream);
  border: 1.5px solid var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 12px;
}

.fs-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  padding: 14px 12px;
  background: var(--cream);
  border: 1.5px solid var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 12px;
}

.fs-grid-row {
  display: flex;
  gap: 8px;
}

.fs-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 66px;
  height: 66px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--cream-dark);
  flex-shrink: 0;
  overflow: hidden;
}

.fs-cell--question {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--teal);
  background: var(--teal-light);
  border: 2px dashed var(--teal);
}

.fs-prompt {
  font-size: .78rem;
  font-weight: 700;
  color: var(--ink-light);
  margin-bottom: 8px;
  text-align: center;
}

.fs-opt {
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  padding: 10px 6px 10px;
  min-height: 92px;
}

.fs-opt__fig {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── GROUP 16 — probability_visual ── */
.pv-visual {
  display: flex;
  justify-content: center;
  margin-bottom: 14px;
}

.pv-prompt {
  font-size: .85rem;
  font-weight: 700;
  color: var(--ink-mid);
  margin-bottom: 10px;
  text-align: center;
}

.pv-frac {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin: 0 auto;
  width: fit-content;
}

.pv-fracline {
  width: 80px;
  height: 2px;
  background: var(--ink-dark);
  border-radius: 1px;
}

/* ── GROUP 17 — fraction_visual ── */
.fv-visual {
  display: flex;
  justify-content: center;
  margin-bottom: 14px;
}

.fv-prompt {
  font-size: .85rem;
  font-weight: 700;
  color: var(--ink-mid);
  margin-bottom: 10px;
  text-align: center;
}

.fv-opt {
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  padding: 10px 6px 10px;
  min-height: 110px;
}

.fv-opt__fig {
  display: flex;
  align-items: center;
  justify-content: center;
}
