/* M1 Board: exam-paper look for questions (card on the board, bank list, homework) */
.m1q, .m1s { font-weight: 400 !important; line-height: 1.6 !important; letter-spacing: 0 !important; text-align: left !important; }
.m1q *, .m1s * { font-weight: inherit !important; }
.m1q b, .m1q strong, .m1s b, .m1s strong { font-weight: 700 !important; }
.m1q p { margin: 0 0 .55em !important; }
.m1q p:last-child { margin-bottom: 0 !important; }
.m1q-meta { display: inline-flex !important; align-items: center; gap: 6px; margin: 0 0 .7em !important; padding: 3px 11px !important; border-radius: 999px;
  font-size: .72em !important; font-weight: 600 !important; letter-spacing: .02em !important; color: #475569 !important; background: rgba(99,102,241,.08); border: 1px solid rgba(99,102,241,.16); }
/* parts (a), (b): hanging label, marks on the right like a real paper */
.m1q p:has(> b:first-child) { position: relative; padding-left: 2.1em !important; padding-right: 2.6em !important; }
.m1q p:has(> b:first-child) > b:first-child { position: absolute; left: 0; top: 0; font-weight: 700 !important; }
.m1q-mk { position: absolute; right: 0; bottom: 0; font-size: .86em !important; font-weight: 600 !important; color: #64748b !important; white-space: nowrap; }
.m1q p:not(:has(> b:first-child)) { padding-right: 2.6em; position: relative; }
.m1q-note { font-size: .78em !important; color: #94a3b8 !important; margin-top: .7em !important; padding-left: 0 !important; }
.m1q-note i { font-style: normal !important; }
body:not(.light) .m1q-meta, .theme-dark .m1q-meta { color: #cbd5e1 !important; background: rgba(148,163,184,.12); border-color: rgba(148,163,184,.22); }
body:not(.light) .m1q-mk, .theme-dark .m1q-mk { color: #94a3b8 !important; }
/* the board card makes all text bold — undo it for M1 questions */
html body .mb-board-task-card .task-text-body .m1q, html body .mb-board-task-card .task-text-body .m1q p, html body .mb-board-task-card .task-text-body .m1q div,
html body .mb-board-task-card .task-text-body .m1q span, html body.light .mb-board-task-card .task-text-body .m1q p, html body.light .mb-board-task-card .task-text-body .m1q div,
html body .mb-board-task-card .m1s, html body .mb-board-task-card .m1s div, html body .mb-board-task-card .m1s li { font-weight: 400 !important; }
html body .mb-board-task-card .task-text-body .m1q b, html body .mb-board-task-card .task-text-body .m1q p > b, html body .mb-board-task-card .m1s b { font-weight: 700 !important; }
html body .mb-board-task-card .task-text-body .m1q .m1q-meta, html body.light .mb-board-task-card .task-text-body .m1q .m1q-meta { font-size: 11px !important; font-weight: 600 !important; padding: 3px 11px !important; }
html body .mb-board-task-card .task-text-body .m1q .m1q-mk { font-weight: 600 !important; font-size: 13px !important; }
html body .mb-board-task-card .task-text-body .m1q .m1q-note, html body.light .mb-board-task-card .task-text-body .m1q .m1q-note { font-size: 12px !important; font-weight: 400 !important; }

/* ===== Mark scheme: one framed block per part ===== */
html body .m1s { display: block; margin: 0 0 12px !important; padding: 12px 14px 10px !important; border: 1px solid #e2e8f0 !important; border-radius: 14px !important;
  background: #ffffff !important; box-shadow: 0 1px 2px rgba(15,23,42,.04); font-size: 14px !important; line-height: 1.55 !important; color: #1e293b !important; font-weight: 400 !important; }
html body .m1s:last-child { margin-bottom: 0 !important; }
html body .m1s .m1s-head { display: flex !important; align-items: center; justify-content: space-between; margin: 0 0 8px !important; }
html body .m1s .m1s-lbl { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 26px; padding: 0 9px; border-radius: 8px;
  background: #eef2ff !important; color: #4338ca !important; font-weight: 800 !important; font-size: 13px !important; }
html body .m1s .m1s-mk { font-size: 12px !important; font-weight: 600 !important; color: #64748b !important; }
html body .m1s .m1s-ans { margin: 0 0 10px !important; padding: 9px 12px !important; border-radius: 10px; background: #ecfdf5 !important; border: 1px solid #a7f3d0 !important;
  color: #064e3b !important; font-weight: 500 !important; }
html body .m1s .m1s-ak { display: inline-block; margin-right: 6px; font-size: 11px !important; font-weight: 800 !important; text-transform: uppercase; letter-spacing: .06em; color: #059669 !important; }
html body .m1s .m1s-sk { margin: 0 0 6px !important; font-size: 11px !important; font-weight: 800 !important; text-transform: uppercase; letter-spacing: .06em; color: #94a3b8 !important; }
html body .m1s ul { margin: 0 !important; padding: 0 !important; list-style: none !important; }
html body .m1s li { display: flex !important; align-items: flex-start; gap: 10px; margin: 0 !important; padding: 7px 0 !important; border-top: 1px dashed #e2e8f0; }
html body .m1s li:first-child { border-top: 0; padding-top: 2px !important; }
html body .m1s li > span { flex: 1; color: #334155 !important; font-weight: 400 !important; }
html body .m1s .mk { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 22px; padding: 0 7px; border-radius: 6px;
  font-size: 12px !important; font-weight: 800 !important; letter-spacing: .02em; border: 1px solid transparent; }
html body .m1s .mk-M { background: #dbeafe !important; color: #1d4ed8 !important; border-color: #bfdbfe !important; }
html body .m1s .mk-A { background: #dcfce7 !important; color: #15803d !important; border-color: #bbf7d0 !important; }
html body .m1s .mk-B { background: #fef3c7 !important; color: #b45309 !important; border-color: #fde68a !important; }
html body .m1s .mk-E { background: #f3e8ff !important; color: #7e22ce !important; border-color: #e9d5ff !important; }
/* dark board */
html body:not(.light) .m1s, html body .theme-dark .m1s { background: rgba(30,41,59,.85) !important; border-color: rgba(148,163,184,.25) !important; color: #e2e8f0 !important; }
html body:not(.light) .m1s li > span, html body .theme-dark .m1s li > span { color: #cbd5e1 !important; }
html body:not(.light) .m1s li, html body .theme-dark .m1s li { border-top-color: rgba(148,163,184,.2); }
html body:not(.light) .m1s .m1s-ans, html body .theme-dark .m1s .m1s-ans { background: rgba(16,185,129,.12) !important; border-color: rgba(16,185,129,.35) !important; color: #a7f3d0 !important; }
html body:not(.light) .m1s .m1s-lbl, html body .theme-dark .m1s .m1s-lbl { background: rgba(99,102,241,.2) !important; color: #c7d2fe !important; }
/* answer panel on the card: final answer + mark scheme */
html body .m1-sol-wrap { display: block; padding: 12px !important; border-radius: 16px !important; background: #f8fafc !important; border: 1px solid #e2e8f0 !important; }
html body .m1-sol-wrap.hidden { display: none !important; }
html body .m1-final { display: flex !important; align-items: center; gap: 10px; margin: 0 0 10px !important; padding: 10px 14px !important; border-radius: 12px;
  background: linear-gradient(135deg, #4f46e5, #7c3aed) !important; color: #fff !important; box-shadow: 0 6px 18px rgba(79,70,229,.25); }
html body .m1-final .m1-final-k { font-size: 11px !important; font-weight: 800 !important; letter-spacing: .07em; text-transform: uppercase; opacity: .85; color: #fff !important; }
html body .m1-final .m1-final-v, html body .m1-final .m1-final-v * { font-size: 17px !important; font-weight: 800 !important; color: #fff !important; }
html body:not(.light) .m1-sol-wrap, html body .theme-dark .m1-sol-wrap { background: rgba(15,23,42,.6) !important; border-color: rgba(148,163,184,.25) !important; }
/* data tables inside questions (chi-squared, distributions, Spearman) */
.m1q table, .m1q .ib-t { border-collapse: collapse; margin: 8px 0 12px; font-size: .92em; font-weight: 400 !important; }
.m1q table td, .m1q table th { border: 1px solid rgba(100,116,139,.45); padding: 4px 10px; text-align: center; font-weight: 400 !important; }
.m1q table th, .m1q table tr:first-child td:first-child { font-weight: 600 !important; }

/* ===== v2: question layout in the ОбщДоска card style ===== */
html body .m1q2 { font-weight: 400 !important; line-height: 1.55 !important; }
html body .m1q2 .m1q-meta { margin: 0 0 10px !important; }
html body .m1q2 .m1q-stem { margin: 0 0 10px !important; padding: 11px 15px !important; border-radius: 12px; background: #EEF0FF !important; border-left: 3px solid #4B55E8;
  color: #14172B !important; font-weight: 500 !important; }
html body .m1q2 .m1q-stem * { font-weight: 500 !important; }
html body .m1q2 .m1q-parts { border: 1px solid #E5E7F0; border-radius: 12px; overflow: hidden; background: #F8F9FC; }
html body .m1q2 .m1q-part { display: grid !important; grid-template-columns: auto 1fr auto; gap: 10px; align-items: start; padding: 10px 13px !important; border-top: 1px solid #EEF0F5; }
html body .m1q2 .m1q-part:first-child { border-top: 0; }
html body .m1q2 .m1q-lbl { color: #4B55E8 !important; font-weight: 800 !important; min-width: 1.9em; }
html body .m1q2 .m1q-pt, html body .m1q2 .m1q-pt * { color: #1E2235 !important; font-weight: 400 !important; }
html body .m1q2 .m1q-mk { position: static !important; align-self: start; white-space: nowrap; font-size: 11.5px !important; font-weight: 700 !important; color: #3730A3 !important;
  background: #EEF0FF; border: 1px solid #DCE0FA; border-radius: 999px; padding: 2px 9px !important; margin-top: 1px; }
html body .m1q2 .m1q-note { margin: 9px 0 0 !important; font-size: 12px !important; color: #5B6070 !important; font-weight: 500 !important; padding-left: 2px; }
html body .m1q2 .m1q-note::before { content: "✎ "; color: #4B55E8; }
html body .m1q2 table { border-collapse: separate !important; border-spacing: 0; border: 1px solid #E5E7F0; border-radius: 12px; overflow: hidden; margin: 6px 0 4px; }
html body .m1q2 table td, html body .m1q2 table th { border: 0 !important; border-bottom: 1px solid #EEF0F5 !important; border-right: 1px solid #EEF0F5 !important; padding: 6px 11px !important; }
html body .m1q2 table tr:first-child td, html body .m1q2 table th { background: #F3F4FA; font-weight: 700 !important; }
html body .m1q2 table tr:last-child td { border-bottom: 0 !important; } html body .m1q2 table td:last-child { border-right: 0 !important; }
/* dark board */
#board-sheet.theme-dark .m1q2 .m1q-stem, body:not(.light) .m1q2 .m1q-stem { background: rgba(129,140,248,.16) !important; border-left-color: #818CF8; color: #F1F3FF !important; }
#board-sheet.theme-dark .m1q2 .m1q-parts, body:not(.light) .m1q2 .m1q-parts { background: rgba(255,255,255,.03); border-color: rgba(255,255,255,.12); }
#board-sheet.theme-dark .m1q2 .m1q-part, body:not(.light) .m1q2 .m1q-part { border-top-color: rgba(255,255,255,.08); }
#board-sheet.theme-dark .m1q2 .m1q-pt, #board-sheet.theme-dark .m1q2 .m1q-pt *, body:not(.light) .m1q2 .m1q-pt, body:not(.light) .m1q2 .m1q-pt * { color: #E5E8F5 !important; }
#board-sheet.theme-dark .m1q2 .m1q-lbl, body:not(.light) .m1q2 .m1q-lbl { color: #A5B4FC !important; }
#board-sheet.theme-dark .m1q2 .m1q-mk, body:not(.light) .m1q2 .m1q-mk { background: rgba(129,140,248,.18); border-color: rgba(129,140,248,.35); color: #C7D2FE !important; }
html body .mb-board-task-card .task-text-body .m1q2 .m1q-lbl, html body.light .mb-board-task-card .task-text-body .m1q2 .m1q-lbl, html body .drawer-task-item .m1q2 .m1q-lbl, html body .m1q2 span.m1q-lbl { color: #4B55E8 !important; font-weight: 800 !important; }
html body .mb-board-task-card .task-text-body .m1q2 .m1q-mk, html body.light .mb-board-task-card .task-text-body .m1q2 .m1q-mk { color: #3730A3 !important; font-weight: 700 !important; font-size: 11.5px !important; }
html body .mb-board-task-card .task-text-body .m1q2 .m1q-stem, html body.light .mb-board-task-card .task-text-body .m1q2 .m1q-stem, html body .mb-board-task-card .task-text-body .m1q2 .m1q-stem * { font-weight: 500 !important; color: #14172B !important; }
html body .mb-board-task-card .task-text-body .m1q2 .m1q-note, html body.light .mb-board-task-card .task-text-body .m1q2 .m1q-note { font-size: 12px !important; color: #5B6070 !important; font-weight: 500 !important; }
#board-sheet.theme-dark .mb-board-task-card .task-text-body .m1q2 .m1q-lbl { color: #A5B4FC !important; }
#board-sheet.theme-dark .mb-board-task-card .task-text-body .m1q2 .m1q-stem, #board-sheet.theme-dark .mb-board-task-card .task-text-body .m1q2 .m1q-stem * { color: #F1F3FF !important; }
/* «Final answer»: белое число на фиолетовой плашке — перебиваем общие правила карточек */
html body #board-sheet .mb-board-task-card .m1-final .m1-final-v, html body #board-sheet .mb-board-task-card .m1-final .m1-final-v *,
html body.light #board-sheet.theme-dark .mb-board-task-card .m1-final .m1-final-v, html body.light #board-sheet.theme-dark .mb-board-task-card .m1-final .m1-final-v *,
html body.light #board-sheet .mb-board-task-card .m1-final .m1-final-v, html body.light #board-sheet .mb-board-task-card .m1-final .m1-final-v *,
html body #board-sheet .mb-board-task-card .m1-final .m1-final-k, html body.light #board-sheet .mb-board-task-card .m1-final .m1-final-k { color: #fff !important; fill: #fff !important; }
