/* ── decimal_multi_addsub_conversion2_3（たんいをそろえて小数をつづけて計算しよう、単元仕様書 v1.3）── */
/* 画面：問題文の下に、式、たんいの表（B群・C群）、答えの欄とたんい、回答案内、数字のボタン、「こたえる！」（§5-3・§7 画面表示）。 */
.dmc-main{display:flex;flex-direction:column;align-items:center;gap:6px;margin:4px 0 8px;max-width:100%}
/* 式：記号は直後の数と同じかたまりにして、記号が行頭にひとりで残らないように折り返す（§7）。 */
.dmc-expr{display:flex;flex-wrap:wrap;justify-content:center;align-items:baseline;column-gap:.25em;row-gap:2px;max-width:100%;font-size:clamp(17px,5vw,1.55rem);font-weight:700;color:#0f172a;line-height:1.5}
.dmc-chunk{white-space:nowrap}
.dmc-op{padding:0 .08em}
.dmc-table{display:flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:4px 10px;border:2px solid #94a3b8;border-radius:8px;padding:4px 12px;background:#f8fafc;font-weight:700;max-width:100%;box-sizing:border-box}
.dmc-table-title{font-size:.85rem;color:#334155}
.dmc-table-row{font-size:1.05rem;color:#0f172a;white-space:nowrap}
.dmc-answer-row{display:flex;align-items:center;justify-content:center;gap:6px;font-size:1.3rem;font-weight:700}
.dmc-input{width:5em;min-height:44px;font-size:1.35rem;padding:2px 6px;border:3px solid #1d4ed8;background:#eff6ff;border-radius:10px;text-align:center;font-family:inherit;font-weight:700;box-sizing:border-box;flex:none}
.dmc-input:focus-visible{outline:3px solid #1d4ed8;outline-offset:2px}
.dmc-input:disabled{background:#f8fafc;color:#111827;opacity:1;border-color:#94a3b8}
.dmc-input.dmc-input-ok{border:3px solid #15803d;background:#dcfce7}
.dmc-input.dmc-input-ng{border:3px dashed #b91c1c;background:#fff1f2}
.dmc-unit{min-width:1.5em}
/* とちゅうの計算（回答後だけ）：そろえた式と、左から1つずつの計算を1行ずつ。 */
.dmc-steps{border:2px solid #94a3b8;border-radius:8px;padding:4px 12px;background:#f8fafc;max-width:100%;box-sizing:border-box}
.dmc-steps-title{margin:0 0 2px;font-size:.85rem;font-weight:700;color:#334155;text-align:center}
.dmc-steps-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;align-items:center;gap:2px}
.dmc-steps-list li{font-size:clamp(14px,4vw,1.15rem);font-weight:700;line-height:1.45;color:#1e293b;overflow-wrap:anywhere;text-align:center}
.dmc-guide{margin:6px auto 4px;font-weight:700;text-align:center;max-width:32em}
.dmc-msg{margin:2px auto 0;color:#b91c1c;font-weight:700;font-size:1rem;text-align:center;max-width:32em}
.dmc-msg:empty{display:none}
.feedback.has-text.dmc-feedback{height:auto;min-height:40px;padding:4px 0;text-align:center;line-height:1.45}
.dmc-correct{margin:2px 0 6px;font-weight:700;font-size:1rem}
.dmc-expl-text{margin:4px 0 6px;overflow-wrap:anywhere;font-size:1rem}
#page-quiz.active:has(.dmc-main) #hint-area .kp-card{display:flex;align-items:flex-start;gap:8px}
#page-quiz.active:has(.dmc-main) #hint-area .kp-head{margin-bottom:0;flex:none}
#page-quiz.active:has(.dmc-main) #hint-area .kp-title:empty{display:none}
#page-quiz.active:has(.dmc-main) #hint-area .kp-body{flex:1;min-width:0;padding-left:0;overflow-wrap:anywhere}

/* 印刷：A4縦・2列・1ページ（§7。用紙の余白10mm、本文190×277mm、各列92mm・列の間6mm、各問の領域は幅92mm・高さ33mm）。 */
.dmc-pr-page{width:190mm;height:277mm;box-sizing:border-box;display:flex;flex-direction:column;padding:0;margin:0 auto 8mm;overflow:hidden;background:#fff;color:#000;font-family:'Atkinson Hyperlegible','BIZ UDPGothic','Yu Gothic','Meiryo',sans-serif}
.dmc-pr-head{display:flex;flex-direction:column;flex:none;box-sizing:border-box;width:190mm}
.dmc-pr-title{box-sizing:border-box;margin:0;height:9mm;font-size:14.3pt;font-weight:700;line-height:7.8mm;text-align:center;white-space:nowrap;padding:0;border:1.5pt solid #666;background:#ffffcc;print-color-adjust:exact;-webkit-print-color-adjust:exact}
.dmc-pr-head hr.pp-fields-solid{margin:1mm 0!important}
.dmc-pr-inst{margin:0;font-size:12.6pt;line-height:5.4mm;max-height:10.8mm;overflow:hidden}
/* 英語の表は行の間を2つの空白で区切るため、空白をつめずに表示する。 */
.dmc-pr-table{margin:1mm 0 0;font-size:12.6pt;line-height:6mm;height:6mm;white-space:pre;font-weight:700}
.dmc-pr-problems{display:grid;grid-template-columns:92mm 92mm;column-gap:6mm;flex:none;margin-top:2mm}
.dmc-pr-col{display:grid;grid-template-rows:repeat(5,33mm)}
.dmc-pr-cell{box-sizing:border-box;height:33mm;overflow:hidden;display:flex;flex-direction:column;padding-right:3mm}
.dmc-pr-num{flex:none;height:5.5mm;line-height:5.5mm;font-size:12.6pt;font-weight:700}
.dmc-pr-q{flex:none;font-size:12.6pt;line-height:7mm;max-height:14mm;overflow:hidden;font-weight:700}
.dmc-pr-paren{white-space:nowrap}
.dmc-pr-box{display:inline-block;width:22mm;height:6mm;vertical-align:-1.2mm}
.dmc-pr-work{flex:1;min-height:8mm;margin:1mm 0 2.5mm;border:0.3mm solid #666;border-radius:1mm;padding:0.5mm 1mm;box-sizing:border-box}
.dmc-pr-work-label{font-size:9pt;color:#333}
.dmc-pr-answers{flex:none;box-sizing:border-box;margin-top:1mm}
.dmc-pr-dashed{box-sizing:content-box;display:block;height:0;margin:0 0 0.5mm;padding:0;border:0;border-top:2pt dashed #aaa}
.dmc-pr-answers-title{font-weight:700;font-size:12.6pt;height:6mm;line-height:6mm}
.dmc-pr-ans-grid{display:grid;grid-template-columns:92mm 92mm;column-gap:6mm}
.dmc-pr-ans-col{display:grid;grid-template-rows:repeat(5,9.6mm)}
.dmc-pr-ans{margin:0;font-size:10.2pt;line-height:4.6mm;max-height:9.2mm;overflow:hidden}
.dmc-app-pdf-page .dmc-pr-page{box-shadow:none;margin:0}

#pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"]{width:190mm;max-width:none;padding:0;margin:calc(12px + 10mm) auto;background:transparent;box-shadow:none}
#pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"]>:not(#pr-problems){display:none!important}
#pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"]>#pr-problems{display:block}
/* 画面のプレビューでは、用紙の余白10mmを白い縁で見せる（印刷の寸法は変えない）。 */
#pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"] .dmc-pr-page{box-shadow:0 0 0 10mm #fff,0 0 4px 10mm rgba(0,0,0,.12);margin-bottom:calc(8mm + 10mm)}
@media print{
  #page-print #pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"]{width:auto!important;max-width:none!important;margin:0!important;padding:0!important;transform:none!important;box-shadow:none!important}
  #page-print #pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"]>:not(#pr-problems){display:none!important}
  #page-print #pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"]>#pr-problems{display:block!important}
  #page-print #pr-sheet[data-unit="decimal_multi_addsub_conversion2_3"] .dmc-pr-page{display:flex!important;margin:0!important;box-shadow:none!important;break-after:auto;page-break-after:auto}
}
