/* 班分けくん */
.hw-quick { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 12px; border: 2px solid var(--line); border-radius: 16px; background: color-mix(in srgb, var(--mint) 12%, var(--card)); margin-bottom: 14px; }
.hw-q-l { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.hw-sizes { font-weight: 800; font-size: 14px; }
.hw-go { min-width: 180px; }
@media (max-width: 520px) { .hw-go { width: 100%; } }
.hw-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
@media (max-width: 1000px) { .hw-layout { grid-template-columns: 1fr; } }
.hw-main { min-width: 0; display: grid; gap: 10px; }
.hw-side { display: grid; gap: 10px; min-width: 0; }
.hw-h { font-size: 16px; margin: 0; }
.hw-empty { border: 2px dashed var(--line-soft); border-radius: 16px; padding: 30px 14px; text-align: center; color: var(--ink2); }
.hw-status { display: grid; gap: 4px; padding: 10px 12px; border: 2px solid var(--line); border-radius: 14px; background: var(--card2); }
.hw-st { display: flex; gap: 8px; align-items: baseline; font-size: 14px; line-height: 1.5; }
.hw-mark { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; display: inline-grid; place-items: center; font-weight: 900; font-size: 13px; color: #fff; background: var(--ok); transform: translateY(3px); }
.hw-st.ng .hw-mark { background: var(--warn); }
.hw-st.ng { font-weight: 700; }
.hw-selbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 12px; border: 2px solid var(--line); border-radius: 12px; background: var(--yellow); color: #1d2433; position: sticky; top: calc(var(--header-h) + 6px); z-index: 5; font-size: 14px; }
.hw-acts { gap: 8px; }
.hw-show { display: grid; gap: 10px; }
.hw-show-title { display: none; }
.hw-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr)); gap: 12px; }
.hw-card { border: 2px solid var(--line); border-radius: 16px; background: var(--card); box-shadow: var(--sh-sm); overflow: hidden; min-width: 0; }
.hw-ch { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; padding: 8px 12px; background: var(--gc); color: #fff; border-bottom: 2px solid var(--line); text-shadow: 0 1px 0 rgba(0, 0, 0, .35); }
.hw-ch b { font-size: 17px; font-family: var(--head); }
.hw-cs { font-size: 12px; font-weight: 700; opacity: .95; }
.hw-here { margin-left: auto; border: 2px solid var(--line); border-radius: 9px; background: var(--yellow); color: #1d2433; font-weight: 800; font-size: 12px; padding: 2px 8px; text-shadow: none; }
.hw-mem { list-style: none; margin: 0; padding: 4px; }
.hw-m { display: flex; align-items: center; gap: 6px; padding: 6px 8px; border-radius: 10px; cursor: grab; min-height: 40px; border: 2px solid transparent; user-select: none; }
.hw-m:hover { background: var(--bg2); }
.hw-m.sel { border-color: var(--line); background: var(--yellow); color: #1d2433; }
.hw-m.bad { border-color: var(--bad); border-style: dashed; }
.hw-m::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--line-soft); flex-shrink: 0; }
.hw-m.m::before { background: var(--chu); }
.hw-m.f::before { background: var(--coral); }
.hw-nm { font-weight: 800; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hw-role { font-size: 11.5px; font-weight: 800; border: 1.5px solid var(--line); border-radius: 99px; padding: 0 7px; background: var(--yellow); color: #1d2433; flex-shrink: 0; }
.hw-star { color: #e0a100; font-size: 15px; }
.hw-sc { font-size: 12px; color: var(--ink2); font-variant-numeric: tabular-nums; }
.hw-grid.anim .hw-m { animation: hw-pop .45s cubic-bezier(.2, 1.4, .4, 1) both; animation-delay: var(--d); }
@keyframes hw-pop { from { opacity: 0; transform: translateY(-14px) scale(.85); } }
@media (prefers-reduced-motion: reduce) { .hw-grid.anim .hw-m { animation: none; } }
.hw-det summary { cursor: pointer; list-style: none; display: flex; align-items: baseline; flex-wrap: wrap; }
.hw-det summary::before { content: '▸'; margin-right: 6px; transition: transform .15s; }
.hw-det[open] > summary::before { transform: rotate(90deg); }
.hw-det > p { margin: 8px 0; }
.hw-sub { margin-top: 8px; }
.hw-sub summary { cursor: pointer; font-weight: 700; }
.hw-memtable { max-height: 340px; }
.hw-memtable .table { font-size: 13.5px; }
.hw-memtable td { padding: 3px 6px; white-space: nowrap; }
.hw-score { width: 72px; min-height: 32px !important; text-align: center; }
.hw-tg { width: 34px; height: 32px; border: 1.5px solid var(--line-soft); border-radius: 8px; background: var(--card); color: var(--ink3); font-weight: 900; }
.hw-tg.on { background: var(--yellow); border-color: var(--line); color: #b37400; }
.hw-tg.x.on { background: var(--ink); color: var(--bg); }
.hw-absent td { opacity: .5; text-decoration: line-through; }
.hw-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--line-soft); margin-right: 6px; vertical-align: 1px; }
.hw-dot.m { background: var(--chu); } .hw-dot.f { background: var(--coral); }
.hw-pair { cursor: default; font-size: 12.5px; }
.hw-pair.avoid { border-color: var(--coral); }
.hw-pair.together { border-color: var(--mint); }
.hw-pair button { border: 0; background: none; font-weight: 900; padding: 0 2px; }
.hw-chk { display: flex; gap: 8px; align-items: flex-start; font-weight: 700; font-size: 14px; }
.hw-chk input { width: 18px; height: 18px; margin-top: 4px; accent-color: var(--ink); }
.hw-hist { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 4px; }
.hw-hist li { display: flex; align-items: center; gap: 6px; font-size: 13.5px; }
.hw-hist li span { flex: 1; }
/* 全画面の発表 */
.hw-show:fullscreen { background: var(--bg); padding: 2.5vw; overflow: auto; align-content: start; }
.hw-show:fullscreen .hw-show-title { display: flex; justify-content: space-between; align-items: baseline; font-family: var(--head); font-weight: 900; font-size: 3.2vw; }
.hw-show:fullscreen .hw-show-title small { font-size: 1.6vw; color: var(--ink2); }
.hw-show:fullscreen .hw-grid { grid-template-columns: repeat(auto-fit, minmax(22vw, 1fr)); gap: 1.4vw; }
.hw-show:fullscreen .hw-ch b { font-size: 2.2vw; }
.hw-show:fullscreen .hw-cs { font-size: 1.1vw; }
.hw-show:fullscreen .hw-m { font-size: 1.9vw; min-height: 3.4vw; }
.hw-show:fullscreen .hw-sc { display: none; }
