body { --accent: var(--actg); --soft: var(--actg-soft); }
.accounting-meta { display:flex; align-items:center; justify-content:space-between; gap:12px; position:sticky; top:56px; z-index:30; padding:12px 16px; }
#notice:not(:empty), #login-error:not(:empty) { padding:12px; background:var(--soft); border-left:4px solid var(--accent); }
#notice { position:sticky; top:56px; z-index:35; }
.mode-choices, .accounting-days { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.mode-choices .btn { font-size:20px; padding:24px 14px; }
.accounting-top { display:flex; gap:12px; align-items:center; flex-wrap:wrap; margin:24px 0; }
.accounting-top h1 { margin:0; flex:1; }
.accounting-row { display:flex; gap:12px; align-items:center; justify-content:space-between; padding:14px 0; border-bottom:1px solid var(--line); }
.accounting-row a:first-child { flex:1; }
.accounting-row .small { color:var(--muted); }
.accounting-row:last-child { border-bottom:0; }
.jump-label, .written-label { display:block; font-weight:600; margin:14px 0 8px; }
select, textarea, #tutor-code { width:100%; padding:12px; border:1px solid var(--line); border-radius:8px; background:var(--paper); color:var(--ink); font:inherit; max-width:100%; }
select { min-height:48px; }
textarea { resize:vertical; line-height:1.5; }
#tutor-code { margin:8px 0 16px; }
.question-controls { justify-content:space-between; }
.review-item { margin-top:16px; }
.written-response { white-space:pre-wrap; overflow-wrap:anywhere; }
.qprompt table { width:100%; border-collapse:collapse; font-size:clamp(13px,2vw,16px); margin:12px 0; }
.qprompt td, .qprompt th { padding:8px 5px; text-align:left; border-bottom:1px solid var(--line); }
.qprompt caption { text-align:left; font-weight:600; }
.accounting2 .btn, .accounting2 .nopt { min-height:44px; }
.accounting2 :focus-visible { outline:3px solid var(--accent); outline-offset:3px; }
.accounting2 .slot.is-ghost { pointer-events:none; }
.accounting2 .qprompt, .accounting2 .nopts, .accounting2 .qcard { min-width:0; overflow-wrap:anywhere; }
@media(max-width:600px) {
  .accounting-meta { top:0; flex-wrap:wrap; }
  #notice { top:0; }
  .accounting2 .topbar-in { flex-wrap:wrap; padding:10px 14px; }
  .accounting2 .keylegend { display:none; }
  .accounting-row { align-items:flex-start; }
  .accounting-days { grid-template-columns:1fr; }
  .question-controls { gap:8px; }
  .accounting2 .wrap { padding-left:14px; padding-right:14px; }
  .accounting2 .qcard { padding:18px 14px; }
}

.accounting-confirm { border:1px solid var(--line); border-radius:12px; padding:24px; max-width:min(500px,calc(100vw - 28px)); color:var(--ink); background:var(--paper); }
.accounting-confirm::backdrop { background:rgba(20,30,40,.35); }
