/* Shared, scoped data-entry layout; compact navigation actions stay unchanged. */
.sg-form{max-width:72rem;min-width:0;margin:1.5rem 0}
.sg-form p{margin:0 0 1.4rem;min-width:0}
.sg-form label{display:block;font-size:1rem;font-weight:650;line-height:1.5;margin:0 0 .45rem;color:var(--ink)}
.sg-form :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]),select,textarea){display:block;width:100%;max-width:100%;min-width:0;box-sizing:border-box;font:inherit;padding:.7rem .8rem;border:1px solid var(--line);border-radius:4px;background:#fff;color:var(--ink)}
.sg-form textarea{min-height:10rem;resize:vertical}
.sg-form :is(input[type=checkbox],input[type=radio]){width:1.25rem;height:1.25rem;flex:none;accent-color:var(--green)}
.sg-form p:has(>input[type=checkbox]),.sg-form p:has(>input[type=radio]){display:flex;align-items:center;gap:.7rem}
.sg-form p:has(>input[type=checkbox])>input,.sg-form p:has(>input[type=radio])>input{order:-1}
.sg-form p:has(>input[type=checkbox])>label,.sg-form p:has(>input[type=radio])>label{margin:0}
:is(.sg-form,.editor-form) label:has(>input[type=checkbox]),:is(.sg-form,.editor-form) label:has(>input[type=radio]){display:flex;align-items:center;gap:.7rem;margin:.6rem 0}
.editor-form input[type=radio]{width:1.25rem;height:1.25rem}
.editor-form .field:has(>input[type=checkbox]){flex-direction:row;align-items:center;gap:.7rem}
.editor-form .field:has(>input[type=checkbox])>input{order:-1;flex:none}
.sg-form .helptext{display:block;font-size:.9rem;line-height:1.6;margin-top:.45rem;color:var(--muted)}
:is(.sg-form,.editor-form) .errorlist{line-height:1.5;margin:.6rem 0 1rem;padding-left:1.3rem}
:is(.sg-form,.editor-form) fieldset{min-width:0;margin:1.5rem 0;padding:1.3rem;border:1px solid var(--line)}
:is(.sg-form,.editor-form) legend{font-weight:650;padding:0 .4rem}
.sg-form :is(input,select,textarea,button):focus-visible{outline:3px solid var(--green);outline-offset:3px}
:is(.sg-form,.editor-form) .actions{display:flex;flex-wrap:wrap;align-items:center;gap:1rem}
.editor-form .table-scroll td{min-width:8rem}
.editor-form .table-scroll td:has(input[type=checkbox]){min-width:4rem}
.form-errors{border-left:4px solid #9d3131;padding:1rem 1.3rem;margin-bottom:1.5rem}
@media(max-width:640px){.sg-form{margin:1rem 0}.sg-form label{overflow-wrap:anywhere}:is(.sg-form,.editor-form) fieldset{padding:1rem}.sg-form .button{max-width:100%;white-space:normal;text-align:center}}
