/* Klero — reading a scanned jury list (review screen) */

/* ---------- reading a scanned jury list ---------- */
.scan { position: fixed; inset: 0; z-index: 90; background: var(--bg); display: flex; flex-direction: column;
  padding: calc(env(safe-area-inset-top, 0px) + 10px) 16px 10px; gap: 8px; }
.scan-progress { margin: auto; max-width: 440px; width: 100%; background: var(--surface); border: 1px solid var(--line);
  border-radius: 12px; padding: 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 10px; }
/* progress card text and bar */
.scan-progress h2 { margin: 0; font-size: 18px; }
.scan-progress .btn { align-self: flex-start; }
.scan-status { margin: 0; color: var(--ink-2); overflow-wrap: anywhere; }
.scan-bar { height: 8px; border-radius: 4px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; }
.scan-bar i { display: block; height: 100%; width: 3%; background: var(--accent); transition: width .4s; }
/* review screen: header, table of what was read, and the scan beside it */
.scan-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.scan-title h2 { margin: 0; font-size: 18px; }
.scan-sum { color: var(--ink-2); font-size: 13px; }
.scan-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.scan-note { margin: 0; font-size: 12.5px; color: var(--ink-2); }
.scan-body { flex: 1; min-height: 0; display: flex; gap: 12px; }
.scan-tablewrap { flex: 1.25; min-width: 0; min-height: 0; overflow: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 0 0 10px; -webkit-overflow-scrolling: touch; }
.scan-tablewrap .row-btns { padding: 8px 10px 0; }
.scan-table { border-collapse: collapse; width: 100%; min-width: 900px; font-size: 13px; table-layout: fixed; }
.scan-table th { position: sticky; top: 0; background: var(--surface-2); text-align: left; font-weight: 600; font-size: 12px;
  color: var(--ink-2); padding: 6px 4px; border-bottom: 1px solid var(--line); z-index: 1; }
.scan-table td { padding: 1px 2px; border-bottom: 1px solid var(--line); }
.scan-table tr.cur td { background: color-mix(in srgb, var(--accent) 12%, transparent); }
.scan-table input { width: 100%; border: 1px solid transparent; background: transparent; color: var(--ink); font: inherit;
  padding: 5px 5px; border-radius: 5px; min-height: 30px; }
.scan-table input:focus { outline: none; border-color: var(--accent); background: var(--surface); }
.scan-table input.flag { background: color-mix(in srgb, var(--warn) 30%, var(--surface)); border-color: var(--warn); color: var(--ink); }
.scan-table input.dup { border-color: var(--danger); box-shadow: inset 0 0 0 1px var(--danger); }
.scan-table .c-num { width: 64px; } .scan-table .c-sex { width: 52px; } .scan-table .c-name { width: 200px; }
.scan-table .c-addr { width: 320px; } .scan-table .c-occ { width: 210px; } .scan-table .c-x { width: 80px; }
.scan-table .c-del { width: 36px; text-align: center; }
.scan-table .c-del .x { width: 28px; height: 28px; }
.scan-view { flex: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; gap: 6px; }
.scan-tabs { display: flex; flex-wrap: wrap; gap: 4px; }
.scan-tabs:empty { display: none; }
.scan-tabs .on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.scan-scroll { flex: 1; min-height: 0; overflow: auto; border: 1px solid var(--line); border-radius: 10px; background: #fff; -webkit-overflow-scrolling: touch; }
.scan-imgwrap { position: relative; }
.scan-imgwrap img { display: block; width: 100%; height: auto; }
.scan-band { position: absolute; left: 0; right: 0; background: rgba(255, 214, 0, .28); outline: 2px solid rgba(230, 160, 0, .9); pointer-events: none; }
@media (max-width: 900px) {
  .scan-body { flex-direction: column-reverse; }
  .scan-view { flex: 0 0 34vh; }
  .scan-tablewrap { flex: 1; }
}
/* page tabs above the scan */
.scan-tabs .btn { padding: 3px 10px; font-size: 12px; min-height: 0; }

/* ---------- checking unclear juror numbers (js/scan/claude-read.js) ---------- */
.num-check { overflow-y: auto; -webkit-overflow-scrolling: touch; }
.nc-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 10px; }
.nc-head h2 { margin: 0 0 2px; font-size: 20px; }
.nc-head .btn { min-height: 44px; }
.nc-total { margin: 0; font-size: 13px; color: var(--ink-2); }
.nc-msg { margin: 0; color: var(--danger); font-weight: 600; }
.nc-msg:empty { display: none; }
.nc-list { display: flex; flex-direction: column; gap: 12px; padding-bottom: 20px; }
.nc-card { display: flex; flex-wrap: wrap; gap: 14px; align-items: flex-start; background: var(--surface); border: 1px solid var(--line);
  border-radius: 12px; padding: 12px; }
.nc-card.dropped { opacity: .45; }
.nc-img { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.nc-img canvas { display: block; max-width: 100%; height: auto; border: 1px solid var(--line); border-radius: 6px; background: #fff; }
.nc-img .cr-num { max-height: 160px; width: auto; align-self: flex-start; }
.nc-side { flex: 0 1 230px; display: flex; flex-direction: column; gap: 8px; }
.nc-label span { display: block; font-size: 12px; font-weight: 600; color: var(--ink-2); margin-bottom: 4px; }
.nc-label input { width: 100%; font-size: 28px; font-weight: 650; letter-spacing: .04em; padding: 8px 12px; min-height: 56px;
  border: 2px solid var(--warn); border-radius: 10px; background: var(--surface); color: var(--ink); font-variant-numeric: tabular-nums; }
.nc-label input:focus { outline: none; border-color: var(--accent); }
.nc-who { font-weight: 600; overflow-wrap: anywhere; }
.nc-why { font-size: 12.5px; color: var(--ink-2); }
.nc-side .btn { align-self: flex-start; min-height: 40px; }

/* the start page: one button that does it all */
.photo-new { display: grid; gap: 8px; }
.photo-btn { min-height: 52px; font-size: 16px; display: flex; align-items: center; justify-content: center; gap: 8px; }
.photo-btn .ico svg { width: 22px; height: 22px; display: block; }
.or-line { display: flex; align-items: center; gap: 10px; color: var(--ink-3); font-size: 12px; margin-top: 4px; }
.or-line::before, .or-line::after { content: ''; flex: 1; border-top: 1px solid var(--line); }

/* which reader reads a list: Automatic / Claude only / This device only (js/scan/read-list.js), on the start
 * page and in Settings; touch-sized buttons, the line under them says what the choice means */
.reader-row { display: grid; gap: 4px; justify-items: start; }
.reader-row .seg { margin: 0; flex-wrap: wrap; }
.reader-row .seg button { min-height: 40px; padding: 6px 14px; font-size: 13px; }
.reader-pick { display: grid; gap: 4px; }
.reader-pick-label { font-size: 12px; font-weight: 600; color: var(--ink-2); }
