/* ── average_table_missing2_5（平均と合計から表の欠けた人数を求めよう、単元仕様書 v1.2）── */
/* 画面：問題文の下に表の題名と表、答えの欄、回答案内、テンキー、こたえるボタン（§5-3・§7 画面表示）。 */
.avt-main{display:flex;flex-direction:column;align-items:center;margin:4px 0 6px;max-width:100%}
.avt-fig-title{margin:0 0 4px;font-weight:700;font-size:1rem;text-align:center}
/* 360 CSS px幅では表の部分だけを横にスクロールできるようにし、ページ全体は横にスクロールしない（§5-5・§7）。 */
.avt-table-wrap{max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
.avt-table{border-collapse:collapse;background:#fff;color:#0f172a;font-variant-numeric:tabular-nums;margin:0 auto}
.avt-table th,.avt-table td{border:2px solid #334155;padding:5px 9px;font-size:1.05rem;text-align:center;white-space:nowrap}
.avt-table th{background:#e2e8f0;font-weight:700}
.avt-table td{font-weight:700;min-width:2.6em}
.avt-table td.avt-corner{background:#f1f5f9}
.avt-table td.avt-blank{position:relative;min-width:3.2em;height:2.2em;background:#fff;border:2px solid #334155}
.avt-box-label{position:absolute;left:3px;top:1px;font-size:.8rem;font-weight:700;line-height:1;color:#1e293b}
.avt-table td.avt-rate{font-weight:700}
.avt-frac{display:inline-flex;align-items:center;gap:.12em;vertical-align:middle;line-height:1}
.avt-frac-stack{display:inline-flex;flex-direction:column;align-items:center;font-size:.85em;line-height:1.05}
.avt-frac-num{border-bottom:.08em solid currentColor;padding:0 .12em}
.avt-frac-den{padding:0 .12em}
.avt-fields{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:8px;margin:6px auto 2px}
.avt-field-label{font-weight:700;font-size:1.1rem}
.avt-input{width:5em;max-width:40vw;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}
.avt-input:focus-visible{outline:3px solid #1d4ed8;outline-offset:2px}
.avt-input:disabled{background:#f8fafc;color:#111827;opacity:1;border-color:#94a3b8}
.avt-input.avt-input-ok{border:3px solid #15803d;background:#dcfce7}
.avt-input.avt-input-ng{border:3px dashed #b91c1c;background:#fff1f2}
.avt-guide{margin:6px auto 4px;font-weight:700;text-align:center;max-width:32em}
.avt-msg{margin:2px auto 0;color:#b91c1c;font-weight:700;font-size:1rem;text-align:center;max-width:32em}
.avt-msg:empty{display:none}
.feedback.has-text.avt-feedback{height:auto;min-height:40px;padding:4px 0;text-align:center;line-height:1.45}
.avt-correct{margin:2px 0 6px;font-weight:700;font-size:1rem}
.avt-expl-text{margin:4px 0 6px;overflow-wrap:anywhere;font-size:1rem;line-height:1.7}
.avt-lesson-q{font-weight:700}
#page-quiz.active:has(.avt-main) #hint-area .kp-card{display:flex;align-items:flex-start;gap:8px}
#page-quiz.active:has(.avt-main) #hint-area .kp-head{margin-bottom:0;flex:none}
#page-quiz.active:has(.avt-main) #hint-area .kp-title:empty{display:none}
#page-quiz.active:has(.avt-main) #hint-area .kp-body{flex:1;min-width:0;padding-left:0;overflow-wrap:anywhere}
/* 320〜420 CSS px幅でも、8列の表（B群）を表の部分のスクロールなしで見られるようにする。 */
@media (max-width:420px){
  .avt-table th,.avt-table td{padding:3px 2px;font-size:.88rem}
  .avt-table td{min-width:1.9em}
  .avt-table td.avt-blank{min-width:2.4em}
}
/* 320 CSS px幅では、英語の見出し（Japanese・Science・Student 1）がある表も収まるよう、見出しの文字を少し小さくする。 */
@media (max-width:340px){
  .avt-table th{font-size:.76rem;padding:3px 1px}
  .avt-table td{font-size:.85rem;min-width:1.7em}
}

/* 印刷：A4縦・2列×5段・1ページ（§7。用紙の余白10mm、本文190×277mm、上部21mm、列91mm・列の間4mm、各問の領域44.5mm・段の間1mm）。 */
.avt-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}
.avt-pr-head{display:flex;flex-direction:column;flex:none;box-sizing:border-box;width:190mm;height:21mm}
.avt-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}
.avt-pr-problems{display:grid;grid-template-columns:91mm 91mm;column-gap:4mm;flex:none;height:226.5mm;margin-top:2mm}
.avt-pr-col{display:flex;flex-direction:column;gap:1mm}
.avt-pr-cell{box-sizing:border-box;height:44.5mm;overflow:hidden;display:flex;flex-direction:column}
.avt-pr-q{margin:0 0 1mm;font-size:12.6pt;line-height:5.5mm;max-height:16mm;overflow:hidden;width:88mm}
.avt-pr-num{font-weight:700}
.avt-pr-q .avt-frac{line-height:1;vertical-align:-1.6mm}
.avt-pr-q .avt-frac-stack{font-size:10.5pt}
.avt-pr-fig-title{margin:0;font-size:9.2pt;line-height:4mm;height:4mm;font-weight:700}
.avt-pr-table-wrap{overflow:visible}
.avt-pr-table{border-collapse:collapse;font-size:12.6pt;font-variant-numeric:tabular-nums;table-layout:fixed}
.avt-pr-table th,.avt-pr-table td{border:0.3mm solid #333;padding:0 0.6mm;white-space:nowrap;text-align:center;font-weight:400;line-height:4.4mm;box-sizing:border-box}
.avt-pr-table th{font-size:9.2pt;font-weight:700}
.avt-pr-table-a{width:80mm}
.avt-pr-table-a th:first-child,.avt-pr-table-a td:first-child{width:18mm}
.avt-pr-table-a thead th{height:5mm}
.avt-pr-table-a tbody tr{height:6.5mm}
.avt-pr-table-a tbody tr.avt-pr-sum-row{height:5.5mm}
.avt-pr-table-a thead th:nth-child(n+2):nth-child(-n+4){width:16mm}
.avt-pr-table-a thead th:last-child{width:14mm}
.avt-pr-table-b{width:80mm}
.avt-pr-table-b th:first-child{width:14mm}
.avt-pr-table-b tr:first-child th:last-child{width:12mm}
.avt-pr-table-c{width:78mm}
.avt-pr-table-c th:first-child{width:14mm}
.avt-pr-table-c tr:first-child th:nth-child(2),.avt-pr-table-c tr:first-child th:nth-child(3){width:12mm}
.avt-pr-table-c tr:first-child th:nth-child(4){width:28mm}
.avt-pr-table-c tr:first-child th:last-child{width:12mm}
.avt-pr-table-b tr:first-child,.avt-pr-table-c tr:first-child{height:5mm}
.avt-pr-table-b tr:last-child,.avt-pr-table-c tr:last-child{height:6.5mm}
.avt-pr-table td.avt-pr-blank{position:relative}
.avt-pr-box-label{position:absolute;left:0.5mm;top:0.2mm;font-size:9.2pt;font-weight:700;line-height:1}
.avt-pr-table td.avt-pr-corner{background:#fff}
.avt-pr-answers{flex:none;box-sizing:border-box;margin-top:2mm;height:20mm}
.avt-pr-dashed{box-sizing:content-box;display:block;height:0;margin:0 0 0.5mm;padding:0;border:0;border-top:2pt dashed #aaa}
.avt-pr-answers-title{font-weight:700;font-size:12.6pt;height:6mm;line-height:6mm}
.avt-pr-answer-grid{display:grid;grid-template-columns:repeat(5,35mm);column-gap:2mm;font-size:10.2pt;line-height:4.5mm}
.avt-pr-ans{white-space:nowrap}
.avt-app-pdf-page .avt-pr-page{box-shadow:none;margin:0}

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