.modal-card .form-grid > .check-label {
  display: inline-flex;
  width: max-content;
  max-width: 100%;
  align-items: center;
  justify-content: flex-start;
  align-self: start;
  gap: 7px;
  margin-top: 18px;
  white-space: nowrap;
}

.modal-card .form-grid > .check-label input[type="checkbox"] {
  display: inline-block;
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  margin: 0;
  padding: 0;
  accent-color: var(--green);
}

#configForm.skill-editor {
  width: min(920px, 100%);
  max-height: none;
  overflow: visible;
}

#configForm.skill-editor .modal-actions {
  margin-top: -20px;
}

#configForm.rule-editor {
  width: min(920px, 100%);
}

#configForm.mcp-editor {
  width: min(920px, 100%);
}

.mcp-form {
  display: grid;
  gap: 16px;
}

.mcp-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
}

.mcp-grid > label,
.mcp-auth > label {
  margin-top: 0;
}

.mcp-auth {
  display: grid;
  width: calc(50% - 12px);
  gap: 16px;
}

.mcp-auth .check-label {
  display: inline-flex !important;
  width: max-content;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 14px;
  white-space: nowrap;
}

.mcp-auth .check-label input[type="checkbox"] {
  display: inline-block !important;
  flex: 0 0 17px;
  width: 17px !important;
  height: 17px !important;
  margin: 0;
  padding: 0;
  accent-color: var(--green);
}

.rule-form {
  display: grid;
  gap: 18px;
}

.rule-top,
.rule-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  align-items: end;
}

.rule-top > label,
.rule-details > label,
.rule-form > label {
  margin-top: 0;
}

.rule-top .check-label {
  display: inline-flex !important;
  width: max-content;
  align-items: center;
  justify-self: start;
  gap: 5px;
  margin-bottom: 10px;
  font-size: 14px;
  white-space: nowrap;
}

.rule-top .check-label input[type="checkbox"] {
  display: inline-block !important;
  flex: 0 0 17px;
  width: 17px !important;
  height: 17px !important;
  margin: 0;
  padding: 0;
  accent-color: var(--green);
}

.rule-skill-binding {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.rule-skill-binding legend {
  padding: 0;
  color: #4e5b53;
  font-size: 12px;
}

.skill-checkboxes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 12px;
  margin-top: 8px;
}

.skill-checkbox {
  display: flex !important;
  align-items: center;
  gap: 8px;
  min-width: 0;
  margin: 0 !important;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink) !important;
  font-size: 13px !important;
}

.skill-checkbox input[type="checkbox"] {
  display: block !important;
  flex: 0 0 16px;
  width: 16px !important;
  height: 16px !important;
  margin: 0 !important;
  padding: 0 !important;
  accent-color: var(--green);
}

.skill-checkbox span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rule-skill-binding small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
}

.rule-form > label:not(.rule-skill-binding) {
  font-size: 15px;
  font-weight: 400;
}

.rule-form > label:not(.rule-skill-binding) textarea {
  min-height: 260px;
  max-height: 52vh;
  resize: vertical;
  line-height: 1.65;
}

@media (max-width: 650px) {
  .skill-checkboxes {
    grid-template-columns: 1fr;
  }
}

.skill-form {
  display: grid;
  gap: 18px;
}

.skill-basics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
}

.skill-basics > label,
.skill-form > label {
  margin-top: 0;
}

.skill-basics > label {
  font-size: 13px;
}

.skill-basics > label input {
  font-size: 12px;
}

.skill-basics textarea {
  min-height: 74px;
}

.skill-options {
  display: flex !important;
  flex-wrap: nowrap;
  align-items: center;
  gap: 22px;
  overflow-x: auto;
}

.skill-options .check-label {
  display: inline-flex !important;
  width: max-content;
  flex: 0 0 auto;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 13px;
  white-space: nowrap;
}

.skill-options .check-label input[type="checkbox"] {
  display: inline-block !important;
  flex: 0 0 17px;
  width: 17px !important;
  height: 17px !important;
  margin: 0;
  padding: 0;
  accent-color: var(--green);
}

.skill-form > label:last-child {
  font-size: 15px;
  font-weight: 400;
}

.skill-form > label:last-child textarea {
  min-height: 356px;
  max-height: 62vh;
  resize: none;
  line-height: 1.65;
}

@media (max-width: 650px) {
  .skill-basics {
    grid-template-columns: 1fr;
  }

  .rule-top,
  .rule-details {
    grid-template-columns: 1fr;
  }

  .mcp-grid {
    grid-template-columns: 1fr;
  }

  .mcp-auth {
    width: 100%;
  }

  .skill-form > label:last-child textarea {
    min-height: 300px;
  }
}

.watchlist-table-wrap {
  overflow-x: auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 3px 13px rgba(23, 37, 29, .025);
}

.watchlist-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  text-align: left;
}

.watchlist-table th,
.watchlist-table td {
  padding: 14px 17px;
  border-bottom: 1px solid #edf0ed;
}

.watchlist-table th {
  background: #f8faf8;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.watchlist-table tr:last-child td { border-bottom: 0; }
.watchlist-table th:first-child, .watchlist-table td:first-child { width: 90px; }
.watchlist-table th:last-child, .watchlist-table td:last-child { width: 150px; }
.watchlist-table .actions { justify-content: flex-end; }
