.st-x { position: absolute; top: 2px; right: 2px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 1rem; line-height: 1; cursor: pointer; }
.st-x:hover { background: #fde0dc; color: #c0392b; }
.st-mk { flex: none; display: grid; place-items: center; min-width: 1.5em; height: 1.5em; border-radius: .35em; background: color-mix(in srgb, var(--tint, #151935) 55%, #151935); color: #fff; font-family: var(--display); font-weight: 800; font-size: .85em; }
.mt-list { display: flex; flex-direction: column; gap: 6px; max-height: 70vh; overflow-y: auto; padding-right: 4px; }
.mt-w { display: flex; gap: 10px; align-items: flex-start; padding: 8px 12px; border-radius: 10px; border: 2px solid var(--line); background: var(--bg); cursor: pointer; }
.mt-w:hover { border-color: var(--muted); }
.mt-w.on { border-color: var(--ink); }
.mt-w input { margin-top: 4px; flex: none; width: 18px; height: 18px; accent-color: var(--ink); }
.mt-w small { font-size: .78rem; color: var(--muted); font-weight: 700; margin-left: 4px; }
.mt-w .note, .mt-picked .note { display: block; font-size: .88rem; }
.mt-picked { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.mt-picked li { position: relative; display: flex; gap: 8px; align-items: flex-start; padding: 6px 28px 6px 8px; border-radius: 10px; background: var(--bg); border: 1.5px solid var(--line); font-size: .95rem; line-height: 1.3; }
.mt-picked li > span:nth-child(2) { min-width: 0; }
.mt-picked .st-mk { font-size: .8rem; margin-top: 1px; }
.mt-picked .mt-none { color: var(--muted); padding: 10px; border-style: dashed; }
/* Handouts on the teacher page (8 Nov 2026): choosing the words (#/handouts) and the preview of the two A4 sides.
   Uses the Starters page's layout (starters.css: .st-build, .st-side, .st-stick, .mt-…) and the site's colours. */
.ho-list { max-height: 62vh; }
.ho-pw { overflow: hidden; }
.mt-w:has(input:disabled) { opacity: .5; cursor: default; }
.ho-meter { position: relative; height: 26px; border-radius: 99px; background: var(--bg); border: 1.5px solid var(--line); overflow: hidden; }
.ho-meter i { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--web-soft); transition: width .25s; }
.ho-meter.full i { background: var(--hi); }
.ho-meter span { position: relative; display: block; text-align: center; font-size: .85rem; font-weight: 700; line-height: 23px; }
.ho-acts { display: flex; flex-direction: column; gap: 6px; }
.ho-act { display: flex; gap: 8px; align-items: flex-start; padding: 7px 10px; border-radius: 10px; border: 2px solid var(--line); background: var(--bg); cursor: pointer; font-size: .95rem; line-height: 1.3; }
.ho-act input { margin-top: 3px; flex: none; width: 17px; height: 17px; accent-color: var(--ink); }
.ho-act.on { border-color: var(--ink); }
.ho-act.off { opacity: .5; cursor: default; }
.ho-act .note { display: block; font-size: .84rem; }

/* The preview: each side is an A4 page (210 × 297 mm), scaled down to fit (fitPreview in handouts.js) */
.ho-prev-card { margin-top: 16px; }
.ho-pages { display: flex; gap: 16px; align-items: flex-start; }
.ho-pw { position: relative; flex: none; }
.ho-page { position: absolute; top: 0; left: 0; transform-origin: 0 0; width: 210mm; height: 297mm; padding: 18mm; box-sizing: border-box; overflow: hidden;
  background: #fff; color: #111; font-family: var(--body); font-size: 10.5pt; line-height: 1.2;
  box-shadow: 0 2px 10px rgba(0,0,0,.18); border-radius: 2px; }
.ho-page table { border-collapse: collapse; }
.hp-title { font-size: 18pt; font-weight: 700; }
.hp-sub { color: #555; margin: 2pt 0 8pt; }
.hp-name { font-size: 10pt; margin-bottom: 10pt; }
.hp-words { width: 100%; table-layout: fixed; }
.hp-words th, .hp-words td { border: 1px solid #999; padding: 3pt 4pt; text-align: left; vertical-align: middle; height: 1cm; box-sizing: border-box; }
.hp-words th { background: #e8eaf2; font-size: 10pt; height: 0.7cm; }
.hp-words th:nth-child(1), .hp-words td:nth-child(1) { width: 0.8cm; text-align: center; color: #555; }
.hp-words th:nth-child(2) { width: 3cm; } .hp-words th:nth-child(3) { width: 5.3cm; }
.hp-words td:nth-child(2) b { font-size: 11pt; }
.hp-pos { font-size: 8.5pt; color: #555; }
.hp-def { font-size: var(--msz, 10pt); }
.hp-title2 { font-size: 14pt; font-weight: 700; margin-bottom: 2pt; }
.hp-h { margin-top: 10pt; break-after: avoid; }
.hp-h b { font-size: 12pt; }
.hp-how { font-size: 9.5pt; color: #555; margin: 1pt 0 4pt; }
.hp-two { display: grid; grid-template-columns: 1fr; }
.hp-line { display: flex; align-items: flex-end; gap: 4pt; min-height: .82cm; }
.hp-line span { flex: none; width: 72%; padding: 2pt; font-size: 11pt; }
.hp-line i { flex: 1; border-bottom: 1px solid #888; height: 1px; margin-bottom: 3pt; }
.hp-mix { font-family: var(--body); letter-spacing: 1pt; }
.hp-lcwc { width: 100%; table-layout: fixed; }
.hp-lcwc th, .hp-lcwc td { border: 1px solid #999; height: 0.72cm; padding: 0 4pt; font-size: 11pt; }
.hp-lcwc th { background: #e8eaf2; font-size: 9.5pt; height: 0.62cm; text-align: left; }
.hp-lcwc th:nth-child(3), .hp-lcwc th:nth-child(5) { width: 1.15cm; text-align: center; }
.hp-lcwc th:nth-child(1) { width: 4.6cm; }
.hp-lcwc td:nth-child(1) { font-weight: 700; }
.hp-ws table { flex: none; }
.hp-ws { display: flex; gap: 6mm; align-items: flex-start; }
.hp-grid td { width: 0.6cm; height: 0.6cm; border: 1px solid #bbb; text-align: center; font-weight: 700; font-size: 11pt; padding: 0; }
.hp-clues div { font-size: 11pt; margin-bottom: 4pt; }
/* Crossword (9 Nov 2026): squares only where there are letters, the number small in the corner */
.ho-page .hp-xw { width: auto; }
.ho-page .hp-xw td { width: 0.6cm; min-width: 0.6cm; height: 0.6cm; padding: 0; border: 0; box-sizing: border-box; position: relative; vertical-align: top; }
.ho-page .hp-xw td.on { border: 1px solid #333; }
.hp-xn { position: absolute; left: 1pt; top: 0; font-size: 5.5pt; line-height: 1; color: #333; }
.ho-page .hp-xw tr:last-child td { border-bottom: 0; }
.ho-page .hp-xw tr:last-child td.on { border-bottom: 1px solid #333; }
.hp-clues .hp-xh { font-weight: 700; font-size: 10.5pt; margin: 2pt 0 3pt; }
.hp-clues .hp-xh ~ .hp-xh { margin-top: 6pt; }
.hp-gap { font-size: 10.5pt; margin-bottom: 5pt; line-height: 1.35; }
.hp-blank { display: inline-block; width: 3.2cm; border-bottom: 1px solid #333; }
.hp-bank { border: 1px solid #999; padding: 4pt 6pt; text-align: center; margin-top: 4pt; }
.hp-sent { font-size: 10.5pt; margin-top: 4pt; }
.hp-sent i { display: block; height: 0.85cm; border-bottom: 1px solid #888; }
/* The teacher page's own table styles (no wrapping, capital headings) are not for the preview */
.ho-page th, .ho-page td { white-space: normal; text-transform: none; letter-spacing: normal; color: inherit; font-size: inherit; }
.ho-page tr:last-child td { border-bottom: 1px solid #999; }
.ho-page .hp-grid tr:last-child td { border-bottom: 1px solid #bbb; }
.ho-page .hp-words td:nth-child(1) { color: #555; }
.ho-page .hp-words th { font-size: 10pt; }
.ho-page .hp-words td.hp-def { font-size: var(--msz, 10pt); }
.ho-page .hp-lcwc th { font-size: 9.5pt; }
.ho-page .hp-lcwc td, .ho-page .hp-grid td { font-size: 11pt; }
#ho-picked li { padding-top: 4px; padding-bottom: 4px; }
.ho-page table.hp-grid { width: auto; }

.hp-title, .hp-title2 { font-family: var(--head); font-weight: var(--hw); }
.ho-page { letter-spacing: normal; word-spacing: normal; }
.ho-pages { min-width: 0; overflow: clip; }
@container (max-width: 640px) { .ho-pages { flex-direction: column; } }
[data-page="dark"] .ho-meter.full span { color: #151935; }
