:root { --gap: 12px; --brand:#0ea5e9; }
* { box-sizing: border-box; }
body { font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, 'Helvetica Neue', Arial; margin:0; background:#f8fafc; color:#0f172a; }
header { display:flex; align-items:center; justify-content:space-between; padding:12px 16px; background:#fff; border-bottom:1px solid #e2e8f0; position:sticky; top:0; z-index:10; }
header.debug {background: violet;}
nav a { margin-right:12px; text-decoration:none; color:#0f172a; }
nav a.active { color: var(--brand); font-weight:600; }
.container { max-width: 1100px; margin: 24px auto; padding: 0 16px; }
.card { background:#fff; border:1px solid #e2e8f0; border-radius:12px; padding:16px; margin-bottom:16px; }
.btn { background: var(--brand); color:#fff; border:none; padding:8px 12px; border-radius:8px; cursor:pointer; }
.btn.icon { padding: 4px 10px; border-radius: 6px; }
.btn.secondary { background:#334155; }
.btn.link { background:transparent; color:var(--brand); padding:0; }
input, select, textarea { width:100%; padding:8px; border:1px solid #e2e8f0; border-radius:8px; background:#fff; }
.halflength{width: 50%;}
table { width:100%; border-collapse: collapse; }
th, td { padding:8px; border-bottom:1px solid #e2e8f0; text-align:left; }
.badge { padding:2px 8px; border-radius:999px; font-size:12px; background:#e2e8f0; }
.badge.emergency { background:#fecaca; }
label { display:block; margin-bottom:6px; font-size:14px; }
form .row { display:grid; grid-template-columns: 1fr 1fr; gap:var(--gap); }
@media (max-width: 700px) { form .row { grid-template-columns: 1fr; } }
.alert { padding:10px 12px; border-radius:8px; background:#fef3c7; border:1px solid #fde68a; }
.success { background:#dcfce7; border-color:#86efac; }
.error { background:#fee2e2; border-color:#fecaca; }

/* Modal */
#adjust-modal { position: fixed; inset:0; display:none; }
#adjust-modal.open { display:block; }
#adjust-modal .modal-backdrop { position:absolute; inset:0; background:rgba(0,0,0,.35); }
#adjust-modal .modal-card {
  position:absolute; left:50%; top:50%; transform:translate(-50%,-50%);
  width: min(560px, 92vw);
  background:#fff; border:1px solid #e2e8f0; border-radius:12px; padding:16px;
  box-shadow: 0 10px 30px rgba(0,0,0,.15);
}
.radio-list { display:flex; flex-direction:column; gap:8px; margin:8px 0; }
.radio-row { display:flex; gap:8px; align-items:center; padding:6px 8px; border:1px solid #e2e8f0; border-radius:8px; }
