label { display: flex; flex-direction: column; gap: 6px; color: var(--ink-800); font-size: 13px; font-weight: 750; }
input, select, textarea {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid #cedadb;
  border-radius: 10px;
  color: var(--ink-950);
  background: #fff;
  box-shadow: inset 0 1px 2px rgba(20, 60, 62, .03);
  font-weight: 500;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
input:hover, select:hover, textarea:hover { border-color: #aabfc0; }
input:focus, select:focus, textarea:focus { border-color: var(--brand-500); box-shadow: 0 0 0 4px rgba(34, 164, 163, .11); }
textarea { min-height: 110px; resize: vertical; }
input[type="checkbox"], input[type="radio"] { width: 18px; min-height: 18px; accent-color: var(--brand-700); }
input[type="file"] { padding: 7px; }
label small { min-height: 1em; color: var(--danger); font-weight: 500; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; }
.form-grid > .full, .form-grid > button:only-of-type { grid-column: 1 / -1; }
.form-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 10px; }
.check-label, .check-row { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 550; }
.check-label input, .check-row input { margin-top: 3px; flex: 0 0 auto; }
.check-row { padding: 10px 0; border-bottom: 1px solid #edf1f1; }
.check-row:last-child { border-bottom: 0; }
.check-row span, .check-row b, .check-row small { display: block; }
.check-row small { margin-top: 3px; color: var(--ink-600); }
.toolbar { display: flex; align-items: end; gap: 10px; }
.toolbar input, .toolbar select { min-width: 190px; }
.inline-decision { display: flex; min-width: 390px; align-items: center; gap: 7px; }
.inline-decision input { min-height: 36px; }
.permission-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.permission-group { padding: 18px; border: 1px solid var(--line); border-radius: 13px; background: #fbfdfd; }
.permission-group h3 { margin-bottom: 8px; font-size: 16px; text-transform: capitalize; }
[data-scope-field] { display: none; }
[data-scope-field].is-visible { display: flex; }

@media (max-width: 700px) {
  .form-grid, .permission-grid { grid-template-columns: 1fr; }
  .form-grid > * { grid-column: 1 !important; }
  .form-actions { flex-direction: column-reverse; align-items: stretch; }
  .toolbar { align-items: stretch; flex-direction: column; }
  .toolbar > * { width: 100%; }
  .inline-decision { min-width: 310px; }
}
