/* ── average_ordered_overlap3_5（順序付きの重なり平均から真ん中を求めよう、単元仕様書 v1.2）── */
/* 画面：問題文の下に帯の図と図の説明の文、答えの欄、回答案内、テンキー、こたえるボタン（§5-3・§7 画面表示）。 */
.aoo-main{display:flex;flex-direction:column;align-items:center;margin:4px 0 6px;max-width:100%}
.aoo-fig{--aoo-cell:56px;width:calc(var(--aoo-n) * var(--aoo-cell));max-width:100%;box-sizing:border-box;font-weight:700;font-size:1.05rem}
.aoo-fig-labels{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:flex-end;column-gap:8px;line-height:1.35}
.aoo-fig-lab-left,.aoo-fig-lab-right{white-space:nowrap}
.aoo-fig-lab-right{text-align:right;margin-left:auto}
.aoo-fig-top{height:22px}
.aoo-fig-bottom{height:16px}
.aoo-br{display:block;width:100%;height:100%;overflow:visible}
.aoo-br path{fill:none;stroke:#111827;stroke-width:2.2;vector-effect:non-scaling-stroke;stroke-linejoin:miter}
.aoo-br .aoo-br-right{stroke-dasharray:7 4}
.aoo-br .aoo-br-all{stroke-dasharray:1.5 4;stroke-linecap:round;stroke-width:2.6}
.aoo-fig-cells,.aoo-fig-nums{display:grid;grid-template-columns:repeat(var(--aoo-n),minmax(0,1fr))}
.aoo-fig-cell{box-sizing:border-box;height:40px;border:2px solid #334155;border-left-width:0;background:#fff;display:flex;align-items:center;justify-content:center;font-size:1.35rem;font-weight:800}
.aoo-fig-cell:first-child{border-left-width:2px}
.aoo-fig-mid{background:#fef9c3}
.aoo-fig-nums span{text-align:center;font-size:.95rem;font-weight:700;line-height:1.4}
.aoo-fig-lab-all{text-align:center;line-height:1.35}
.aoo-alt{margin:8px auto 0;max-width:34em;font-size:.95rem;font-weight:400;line-height:1.5;text-align:left;overflow-wrap:anywhere}
.aoo-fields{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:8px;margin:8px auto 2px}
.aoo-input{width:6em;max-width:45vw;min-height:44px;font-size:1.4rem;padding:4px 8px;border:3px solid #1d4ed8;background:#eff6ff;border-radius:10px;text-align:center;font-family:inherit;box-sizing:border-box}
.aoo-input:focus-visible{outline:3px solid #1d4ed8;outline-offset:2px}
.aoo-input:disabled{background:#f8fafc;color:#111827;opacity:1;border-color:#94a3b8}
.aoo-input.aoo-input-ok{border:3px solid #15803d;background:#dcfce7}
.aoo-input.aoo-input-ng{border:3px dashed #b91c1c;background:#fff1f2}
.aoo-guide{margin:6px auto 4px;font-weight:700;text-align:center;max-width:32em}
.aoo-msg{margin:2px auto 0;color:#b91c1c;font-weight:700;font-size:1rem;text-align:center;max-width:32em}
.aoo-msg:empty{display:none}
.feedback.has-text.aoo-feedback{height:auto;min-height:40px;padding:4px 0;text-align:center;line-height:1.45}
.aoo-correct{margin:2px 0 6px;font-weight:700;font-size:1rem}
.aoo-expl-text{margin:4px 0 6px;overflow-wrap:anywhere;font-size:1rem}
#page-quiz.active:has(.aoo-main) #hint-area .kp-card{display:flex;align-items:flex-start;gap:8px}
#page-quiz.active:has(.aoo-main) #hint-area .kp-head{margin-bottom:0;flex:none}
#page-quiz.active:has(.aoo-main) #hint-area .kp-title:empty{display:none}
#page-quiz.active:has(.aoo-main) #hint-area .kp-body{flex:1;min-width:0;padding-left:0;overflow-wrap:anywhere}
/* 360 CSS px幅以下（320をふくむ）：9つの位置を画面の中に収め、かっこの名前を二段に分ける（§7、BC-06）。 */
@media (max-width:360px){
  .aoo-fig{--aoo-cell:30px;font-size:.95rem}
  .aoo-fig-labels{flex-direction:column;align-items:stretch;gap:0}
  .aoo-fig-lab-left{text-align:left}
  .aoo-fig-cell{height:34px;font-size:1.15rem}
  .aoo-fig-nums span{font-size:.85rem}
}

/* 印刷：A4縦・2列・1ページ（§7。用紙の余白10mm、本文190×277mm、列91mm・列の間4mm。各問の領域は高さ42mm：
   番号10mmと帯の図76mm。図は名前と平均の行6mm、左右のかっこ4mm、ます目7mm、番号4mm、全体のかっこ3mm、全体の名前の行6mm、答えの□の行7mm）。 */
.aoo-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}
.aoo-pr-head{display:flex;flex-direction:column;flex:none;box-sizing:border-box;width:190mm}
.aoo-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}
.aoo-pr-instruction{margin:0 0 2mm;font-size:12.6pt;line-height:5mm}
.aoo-pr-problems{display:grid;grid-template-columns:91mm 91mm;column-gap:4mm;flex:none;margin-left:2mm}
.aoo-pr-col{display:grid;grid-template-rows:repeat(5,42mm)}
.aoo-pr-cell{position:relative;box-sizing:border-box;overflow:hidden;display:flex;align-items:flex-start;gap:0;height:42mm;padding:1mm 0 0}
.aoo-pr-cell+.aoo-pr-cell::before{content:'';position:absolute;top:0;left:0;right:0;border-top:0.3mm dotted #888}
.aoo-pr-q{margin:0;width:10mm;flex:none;font-size:12.6pt;line-height:6mm;white-space:nowrap;font-weight:700}
.aoo-pr-body{width:76mm;flex:none;display:flex;flex-direction:column}
.aoo-pr-fig{width:76mm;box-sizing:border-box;font-size:12.6pt;font-weight:700}
.aoo-pr-fig-labels{display:flex;justify-content:space-between;align-items:center;height:6mm;line-height:6mm;white-space:nowrap}
.aoo-pr-fig-top{height:4mm}
.aoo-pr-fig-bottom{height:3mm}
.aoo-pr-fig .aoo-br path{stroke:#000;stroke-width:1.6}
.aoo-pr-fig .aoo-br .aoo-br-right{stroke-dasharray:6 3.5}
.aoo-pr-fig .aoo-br .aoo-br-all{stroke-dasharray:1.4 3;stroke-width:1.9}
.aoo-pr-fig-cells,.aoo-pr-fig-nums{display:grid;grid-template-columns:repeat(var(--aoo-n),minmax(0,1fr))}
.aoo-pr-fig-cell{box-sizing:border-box;height:7mm;border:0.35mm solid #000;border-left-width:0;display:flex;align-items:center;justify-content:center;font-size:12.6pt;font-weight:800;line-height:1}
.aoo-pr-fig-cell:first-child{border-left-width:0.35mm}
.aoo-pr-fig-nums span{text-align:center;font-size:9.2pt;font-weight:400;height:4mm;line-height:4mm}
.aoo-pr-fig-lab-all{text-align:center;height:6mm;line-height:6mm;white-space:nowrap}
.aoo-pr-ansbox{margin:0;height:7mm;display:flex;align-items:center;gap:2mm;font-size:12.6pt;font-weight:700;white-space:nowrap}
.aoo-pr-box{display:inline-block;box-sizing:border-box;width:20mm;height:7mm;border:0.35mm solid #000}
.aoo-pr-answers{flex:none;box-sizing:border-box;margin-top:2mm}
.aoo-pr-dashed{box-sizing:content-box;display:block;height:0;margin:0 0 1mm;padding:0;border:0;border-top:2pt dashed #aaa}
.aoo-pr-answers-title{font-weight:700;font-size:12.6pt;height:6mm;line-height:6mm}
.aoo-pr-answer-grid{display:grid;grid-template-columns:repeat(10,17.5mm);column-gap:1.2mm;margin-left:2mm}
.aoo-pr-ans{margin:0;font-size:10.2pt;line-height:4.5mm;height:4.5mm;white-space:nowrap}
.aoo-app-pdf-page .aoo-pr-page{box-shadow:none;margin:0}

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