/* ==========================================================
   毒劇しらべ 過去問 のページだけの見た目
   ==========================================================
   site.css と /assets/dokugeki/theme.css の後に読む。色はアプリと同じ（theme.css の変数）。
   スマホで選択肢を押し間違えないよう、ボタンは大きさをそろえ、間をあける。
   広告を置くときも、選択肢と「答え合わせ」の近くには置かない（設計書 5章）。
   ========================================================== */

.kakomon { padding-top: var(--s6); padding-bottom: var(--s8); max-width: 44rem; }
.kakomon h1 { font-size: clamp(24px, 3.4vw, 30px); margin: var(--s2) 0 var(--s4); }
.kakomon h1 .sub { display: block; font-size: 14px; font-weight: 400; color: var(--ink-soft); margin-top: var(--s1); }
.kakomon p { margin: 0 0 var(--s3); line-height: 1.9; }
.crumbs { color: var(--ink-soft); margin-bottom: var(--s3); }
.crumbs a { color: inherit; }

/* 回の前提は全ページで問題文の上に出す（設計書 4章）。毎回読むものではないので、文字と余白を小さくして問題文を押し下げすぎない */
.preamble { background: var(--surface); border-radius: var(--radius); padding: var(--s2) var(--s3); margin-bottom: var(--s4); font-size: 12.5px; }
.preamble p { margin: 0 0 var(--s1); line-height: 1.6; }
.preamble ul { margin: 0; padding-inline-start: 1.1em; }
.preamble li { margin: 1px 0; line-height: 1.6; }

.group { border-inline-start: 3px solid var(--rule); padding-inline-start: var(--s3); margin-bottom: var(--s4); }
.target { background: var(--primary-soft); color: var(--ink); border-radius: var(--radius); padding: var(--s2) var(--s3); }
.stem { margin-bottom: var(--s3); }

.items { list-style: none; padding: 0; margin: 0 0 var(--s4); }
.items li { display: flex; gap: var(--s3); padding: var(--s2) 0; border-bottom: 1px solid var(--rule); line-height: 1.8; }
.items .label { flex: none; font-weight: 700; min-width: 1.4em; }
.items-table { border-collapse: collapse; width: 100%; margin: 0 0 var(--s4); font-size: 15px; }
.items-table th, .items-table td { border: 1px solid var(--rule); padding: var(--s2); text-align: start; vertical-align: top; line-height: 1.7; }

.blank { display: inline-block; min-width: 3em; padding: 0 .4em; margin: 0 .15em; border: 1px solid var(--ink-soft); border-radius: 3px; text-align: center; line-height: 1.6; }

.choice-heads { margin: 0 0 var(--s2); }
.choices { display: flex; flex-direction: column; gap: var(--s3); margin-bottom: var(--s4); }
.choice {
  display: flex; gap: var(--s3); align-items: flex-start; width: 100%; min-height: 48px;
  padding: var(--s3) var(--s4); text-align: start; font: inherit; line-height: 1.7; color: var(--ink);
  background: var(--card); border: 1.5px solid var(--rule); border-radius: var(--radius); cursor: pointer;
}
.choice .no { flex: none; font-weight: 700; min-width: 1.2em; }
.choice[aria-pressed="true"] { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary-soft); }
.choice.is-correct { border-color: var(--correct); box-shadow: 0 0 0 2px color-mix(in srgb, var(--correct) 30%, transparent); }
.choice.is-wrong { border-color: var(--wrong); }
.choice:focus-visible, .check:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

.actions { margin: var(--s4) 0; }
.check { font: inherit; font-weight: 700; padding: var(--s3) var(--s6); min-height: 48px; border: 0; border-radius: 999px; background: var(--primary); color: var(--on-primary); cursor: pointer; }
.check:disabled { opacity: .45; cursor: default; }
.result { font-weight: 700; padding: var(--s3) var(--s4); border-radius: var(--radius); background: var(--surface); }
.result.is-correct { color: var(--correct); }
.result.is-wrong { color: var(--wrong); }

details.answer, details.answers { margin: var(--s5) 0; border-top: 1px solid var(--rule); padding-top: var(--s3); }
details summary { cursor: pointer; color: var(--primary); font-weight: 700; padding: var(--s2) 0; }
.explanation { margin-top: var(--s3); }

.notes { padding-inline-start: 1.2em; margin: 0 0 var(--s4); }
.pager { display: flex; justify-content: space-between; gap: var(--s3); margin: var(--s6) 0 var(--s4); }
.pager a { color: var(--primary); }

.qlist { list-style: none; padding: 0; margin: var(--s4) 0; border-top: 1px solid var(--rule); }
.qlist a { display: flex; gap: var(--s3); align-items: baseline; padding: var(--s3) var(--s2); border-bottom: 1px solid var(--rule); color: var(--ink); text-decoration: none; }
.qlist a:hover { background: var(--surface); }
.qlist .no { flex: none; font-weight: 700; min-width: 3.4em; }
.qlist .lead { flex: 1; color: var(--ink-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qlist .mark { flex: none; width: 1.4em; text-align: center; font-weight: 700; }
.qlist .is-correct .mark::after { content: "○"; color: var(--correct); }
.qlist .is-wrong .mark::after { content: "×"; color: var(--wrong); }
.qlist .is-done .mark::after { content: "－"; color: var(--ink-soft); }

.exam-list { list-style: none; padding: 0; margin: var(--s5) 0; border-top: 1px solid var(--rule); }
.exam-list a { display: flex; justify-content: space-between; gap: var(--s3); padding: var(--s4) var(--s2); border-bottom: 1px solid var(--rule); color: var(--ink); text-decoration: none; }
.exam-list a:hover { background: var(--surface); }
.answer-list { columns: 2; padding-inline-start: 1.2em; }

.source { margin-top: var(--s6); padding-top: var(--s4); border-top: 1px solid var(--rule); }
.source p { line-height: 1.8; margin-bottom: var(--s2); overflow-wrap: anywhere; }  /* 出典の長い URL を画面の幅で折り返す */
.app-promo { margin-top: var(--s5); background: var(--surface); border-radius: var(--radius); padding: var(--s3) var(--s4); }
.app-promo p { margin: 0; }

ruby rt { font-size: .55em; }
