.attendance-view[hidden] { display: none; }
.attendance-view { width: min(1560px, 100%); margin: 0 auto; padding: 30px clamp(16px, 4vw, 64px) 56px; }
.attendance-heading { display: flex; justify-content: space-between; align-items: center; gap: 22px; margin-bottom: 24px; }
.attendance-heading h1 { margin: 0 0 18px; font-size: clamp(26px, 3vw, 40px); line-height: 1.15; letter-spacing: -.04em; }
.attendance-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.attendance-actions button { min-height: 44px; padding: 0 22px; border-radius: 999px; font-weight: 650; }
.attendance-actions button:disabled { cursor: wait; opacity: .55; }
.attendance-choose { border: 1px solid var(--line); color: var(--ink); background: rgba(255,255,255,.78); cursor: pointer; }
.attendance-submit { border: 0; color: #fff; background: var(--red); cursor: pointer; }
.attendance-total { flex: 0 0 auto; text-align: right; }
.attendance-total-label { display: block; color: var(--muted); font-size: 13px; }
.attendance-total output { display: block; min-width: 92px; color: var(--red); font-size: clamp(48px, 6vw, 76px); font-weight: 760; letter-spacing: -.06em; line-height: 1.1; }
.attendance-status { min-height: 24px; margin-bottom: 8px; color: var(--muted); font-size: 14px; }
.attendance-status.error { color: var(--red); }
.attendance-actions button[hidden], .attendance-audit-summary[hidden] { display: none; }
.attendance-audit-summary { margin: -2px 0 16px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.attendance-meter { display: block; width: 100%; height: 5px; margin-bottom: 22px; border: 0; overflow: hidden; border-radius: 99px; background: #eadde0; accent-color: var(--red); }
.attendance-meter[hidden] { display: none; }
.attendance-meter::-webkit-progress-bar { background: #eadde0; border-radius: 99px; }
.attendance-meter::-webkit-progress-value { background: var(--red); border-radius: 99px; transition: width 250ms ease; }
.attendance-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 18px; }
.attendance-panel { min-width: 0; margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 20px; background: rgba(255,255,255,.76); }
.attendance-panel figcaption { display: flex; align-items: center; gap: 10px; padding: 13px 18px; border-bottom: 1px solid var(--line); font-size: 14px; font-weight: 650; }
.attendance-step { color: var(--red); font-size: 12px; font-variant-numeric: tabular-nums; }
.attendance-image-button { position: relative; display: grid; width: 100%; aspect-ratio: 16 / 10; place-items: center; padding: 10px; border: 0; color: #948789; background: rgba(247,243,240,.64); cursor: zoom-in; }
.attendance-image-button:disabled { cursor: default; }
.attendance-image-button img { display: block; width: 100%; height: 100%; min-height: 0; object-fit: contain; position: absolute; inset: 0; padding: 8px; }
.attendance-image-button img[hidden] { display: none; }
.attendance-image-button svg { width: 38px; height: 38px; fill: none; stroke: currentColor; stroke-width: 1.2; }
.attendance-image-button:not(:disabled) svg { display: none; }
.attendance-note { margin: 18px 0 0; font-size: 12px; color: var(--muted); line-height: 1.6; }
.attendance-preview { position: fixed; inset: 0; width: 100%; height: 100dvh; max-width: none; max-height: none; padding: 52px 12px 12px; margin: 0; border: 0; background: rgba(23,20,21,.97); color: #fff; }
.attendance-preview::backdrop { background: rgba(23,20,21,.97); }
.attendance-preview img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; margin: auto; object-fit: contain; }
.attendance-preview button { position: absolute; right: 16px; top: 12px; width: 36px; height: 36px; border: 1px solid #fff5; border-radius: 50%; background: #ffffff15; color: #fff; font-size: 24px; cursor: pointer; }
@media(max-width: 720px) {
  .site-nav-links { min-width: 0; max-width: 100%; overflow-x: auto; scrollbar-width: none; justify-content: flex-start; gap: 4px; }
  .site-nav-links::-webkit-scrollbar { display: none; }
  .site-nav-link { flex: 0 0 auto; }
  .attendance-view { padding: 22px 12px 40px; }
  .attendance-heading { gap: 12px; margin-bottom: 18px; align-items: flex-start; }
  .attendance-heading h1 { font-size: 26px; margin-bottom: 16px; }
  .attendance-total-label { font-size: 12px; }
  .attendance-total output { min-width: 64px; font-size: 52px; }
  .attendance-actions { gap: 7px; }
  .attendance-actions button { min-height: 42px; padding: 0 15px; font-size: 13px; }
  .attendance-grid { gap: 10px; }
  .attendance-panel { border-radius: 14px; }
  .attendance-panel figcaption { padding: 11px 10px; gap: 6px; font-size: 13px; }
  .attendance-image-button { aspect-ratio: 1 / 1; }
  .attendance-image-button img { padding: 3px; }
  .attendance-status { font-size: 13px; }
}
