
:root{
  --bg:#f4f7f6; --card:#fff; --text:#1e2b28; --muted:#66736f;
  --primary:#1f6f5f; --primary2:#165448; --border:#d9e3df;
}
*{box-sizing:border-box}
body{margin:0;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Noto Sans JP",sans-serif;background:var(--bg);color:var(--text)}
header{position:sticky;top:0;z-index:5;background:var(--primary);color:#fff;padding:14px 16px;display:flex;justify-content:space-between;align-items:center;box-shadow:0 2px 8px #0002}
header h1{font-size:1.25rem;margin:0}
header p{font-size:.78rem;margin:.2rem 0 0;opacity:.9}
main{max-width:760px;margin:auto;padding:14px}
.card,.notice{background:var(--card);border:1px solid var(--border);border-radius:14px;padding:16px;margin-bottom:14px;box-shadow:0 2px 7px #0000000c}
.notice{background:#fff8d8;border-color:#ead57e;font-size:.9rem}
h2{font-size:1.05rem;margin:0 0 12px}
button,.camera-button{border:0;border-radius:10px;padding:12px 14px;font-weight:700;font-size:1rem;cursor:pointer}
button{background:#e7efec;color:var(--text)}
button.primary,.camera-button{display:block;width:100%;background:var(--primary);color:#fff;text-align:center}
button.primary:hover{background:var(--primary2)}
button:disabled{opacity:.45;cursor:not-allowed}
.camera-button input{display:none}
.icon-btn{width:auto;background:transparent;color:inherit;font-size:1.25rem;padding:7px}
textarea,input{width:100%;border:1px solid var(--border);border-radius:10px;padding:12px;font-size:1rem;margin:7px 0 12px;background:#fff}
.preview{width:100%;max-height:340px;object-fit:contain;border-radius:10px;margin:12px 0;background:#eef3f1}
.hidden{display:none}
.status{padding-top:10px;color:var(--muted);font-size:.9rem}
.legend{display:flex;gap:7px;flex-wrap:wrap;margin-bottom:12px}
.legend span,.badge{padding:4px 9px;border-radius:999px;font-size:.8rem;font-weight:700}
.green{background:#d9f4df;color:#176629}
.yellow{background:#fff0b5;color:#7a5700}
.red{background:#ffd8d5;color:#9e1f17}
.gray{background:#e7e9e8;color:#535a58}
.result-item{border:1px solid var(--border);border-radius:12px;padding:12px;margin-bottom:9px}
.result-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}
.result-title{font-weight:800}
.reason{font-size:.88rem;color:var(--muted);margin-top:7px;line-height:1.5}
.staff-message{white-space:pre-wrap;background:#f1f6f4;border-radius:10px;padding:12px;margin-bottom:9px;line-height:1.6}
.log-item{border-top:1px solid var(--border);padding:10px 0;font-size:.9rem}
.small{font-size:.83rem;color:var(--muted);line-height:1.55}
dialog{width:min(92vw,560px);border:0;border-radius:16px;padding:0}
dialog::backdrop{background:#0007}
.dialog-form{padding:18px}
.dialog-title{display:flex;justify-content:space-between;align-items:center}
.setting-row{display:grid;grid-template-columns:1fr 120px;align-items:center;gap:8px;border-bottom:1px solid var(--border);padding:9px 0}
.setting-row select{padding:8px;border-radius:8px;border:1px solid var(--border);background:#fff}
footer{max-width:760px;margin:auto;padding:15px 18px 30px;color:#8b271f;font-size:.85rem;font-weight:700}
@media(min-width:700px){header{padding-left:calc((100% - 730px)/2);padding-right:calc((100% - 730px)/2)}}
