:root { color-scheme: light dark; font-family: system-ui, sans-serif; }
body { margin: 0; line-height: 1.5; }
header, main { max-width: 70rem; margin: auto; padding: 1rem; }
header { display: flex; justify-content: space-between; border-bottom: 1px solid #8885; }
form { display: grid; gap: .75rem; width: 100%; max-width: 32rem; }
input, select, button, .button { box-sizing: border-box; font: inherit; padding: .6rem; }
input, select { min-width: 0; width: 100%; }
input[type="checkbox"] { width: auto; }
button, .button { cursor: pointer; width: fit-content; }
.actions { display: flex; flex-wrap: wrap; gap: 1rem; }
.check { display: flex; gap: .5rem; align-items: start; }
.check input { margin-top: .35rem; }
.error { color: #b00020; }
.success { color: #176b2c; }
table { border-collapse: collapse; width: 100%; }
th, td { border: 1px solid #8888; padding: .5rem; text-align: left; vertical-align: top; }
.inline { display: inline; }
.delete { border-top: 1px solid #8888; margin-top: .75rem; padding-top: .75rem; }
section { margin-bottom: 1.5rem; }
.notice { border: 2px solid #7778; border-radius: .35rem; padding: 1rem; }
.metadata, .optional { color: #666; font-size: .9rem; }
.field { display: grid; gap: .25rem; margin-bottom: .75rem; }
.repeat-rows { display: grid; gap: .75rem; margin-bottom: .75rem; }
.repeat-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .75rem; align-items: end; }
.repeat-row-removable { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; }
.repeat-row > * { min-width: 0; }
.repeat-row label { display: grid; gap: .25rem; }
.secondary { padding: .45rem .65rem; }
.existing-domain { border-bottom: 1px solid #8885; padding-bottom: .75rem; }
.domain-autocomplete { position: relative; }
.domain-results {
  position: absolute;
  z-index: 10;
  top: 100%;
  right: 0;
  left: 0;
  max-height: 18rem;
  overflow-y: auto;
  border: 1px solid #777;
  border-radius: .25rem;
  background: Canvas;
  color: CanvasText;
  box-shadow: 0 .35rem .8rem #0003;
}
.domain-result {
  display: grid;
  width: 100%;
  padding: .5rem .65rem;
  border: 0;
  border-bottom: 1px solid #8885;
  border-radius: 0;
  background: transparent;
  color: inherit;
  text-align: left;
}
.domain-result:last-child { border-bottom: 0; }
.domain-result:hover, .domain-result.active { background: Highlight; color: HighlightText; }
.domain-result-detail { font-size: .8rem; opacity: .75; }
@media (max-width: 45rem) {
  table, thead, tbody, tr, th, td { display: block; }
  thead { position: absolute; left: -10000px; }
  tr { margin-bottom: 1rem; }
  .repeat-row, .repeat-row-removable { grid-template-columns: 1fr; }
}
