:root {
  color-scheme: light dark;
  --bg: #f5f6f8;
  --surface: #ffffff;
  --text: #17202b;
  --muted: #5b6573;
  --border: #d9dee5;
  --primary: #1f4e8c;
  --primary-text: #ffffff;
  --danger: #a4262c;
  --notice: #eef4fb;
  --alert: #fdf0f0;
  --focus: #2f6fd1;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #11151b;
    --surface: #1a2029;
    --text: #e7ebf0;
    --muted: #a3adba;
    --border: #2f3846;
    --primary: #5d93d9;
    --primary-text: #0d1117;
    --danger: #f08b8f;
    --notice: #1d2a3b;
    --alert: #3a1f22;
    --focus: #8fb6ec;
  }
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font:
    15px/1.5 system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    "Helvetica Neue",
    Arial,
    sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a {
  color: var(--primary);
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.skip {
  position: absolute;
  left: -999px;
}
.skip:focus {
  left: 16px;
  top: 8px;
  background: var(--surface);
  padding: 8px;
}
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-wrap: wrap;
}
.brand {
  font-weight: 650;
  letter-spacing: 0.01em;
  color: var(--text);
  text-decoration: none;
}
nav {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}
nav form {
  margin: 0;
}
main {
  flex: 1;
  width: 100%;
  margin: 32px auto;
  padding: 0 16px;
}
main.narrow {
  max-width: 30rem;
}
main.wide {
  max-width: 72rem;
}
.foot {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  padding: 16px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 16px;
}
h1 {
  font-size: 22px;
  margin: 0 0 8px;
}
h2 {
  font-size: 17px;
  margin: 16px 0 8px;
}
.card > h2:first-child {
  margin-top: 0;
}
.lead,
.hint,
.meta,
.small {
  color: var(--muted);
}
.meta {
  display: block;
  font-size: 13px;
}
.small {
  font-size: 13px;
  margin-top: 20px;
}
label {
  display: block;
  font-weight: 550;
  margin: 12px 0 4px;
}
input,
select {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
}
.mono,
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
}
.button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 42px;
  padding: 8px 16px;
  border-radius: 6px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  margin-top: 12px;
}
.stack .button,
.card > .button,
[data-enroll-ready] .button,
form[data-recovery-form] .button {
  width: 100%;
}
.button.small {
  min-height: 32px;
  padding: 4px 10px;
  font-size: 13px;
  margin-top: 6px;
}
.button.primary {
  background: var(--primary);
  color: var(--primary-text);
}
.button.secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}
.button.danger {
  background: var(--surface);
  color: var(--danger);
  border-color: var(--danger);
}
.button[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}
button.link {
  background: none;
  border: 0;
  color: var(--primary);
  font: inherit;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}
.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  margin: 20px 0 4px;
}
.divider::before,
.divider::after {
  content: "";
  flex: 1;
  border-top: 1px solid var(--border);
}
.alert,
.notice {
  border-radius: 6px;
  padding: 10px 12px;
}
.alert {
  background: var(--alert);
  color: var(--danger);
}
.notice {
  background: var(--notice);
}
.status:empty {
  display: none;
}
.codes {
  columns: 2;
  padding-left: 24px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.facts {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 4px 16px;
  margin: 12px 0 0;
}
.facts dt {
  color: var(--muted);
}
.facts dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}
.list.compact li {
  padding: 4px 0;
}
.list form {
  margin: 0;
}
.roles {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 10px;
  margin: 8px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
}
.roles label {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  font-weight: 400;
  margin: 0;
}
.roles input {
  width: auto;
}
.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 16px;
}
.grid .roles,
.grid .button {
  grid-column: 1 / -1;
  justify-self: start;
}
.inline {
  display: flex;
  gap: 8px;
  align-items: end;
  flex-wrap: wrap;
}
.inline label {
  margin: 0;
  align-self: center;
}
.inline input,
.inline select {
  width: auto;
  flex: 1;
  min-width: 12rem;
}
.inline .button {
  margin: 0;
}
.table-wrap {
  overflow-x: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
}
th,
td {
  text-align: left;
  vertical-align: top;
  padding: 10px 8px;
  border-bottom: 1px solid var(--border);
}
thead th {
  font-size: 13px;
  color: var(--muted);
}
td.actions form {
  margin: 0;
}
.badge {
  display: inline-block;
  font-size: 12px;
  border-radius: 999px;
  padding: 1px 8px;
  border: 1px solid var(--border);
}
.badge.revoked {
  color: var(--danger);
  border-color: var(--danger);
}
.nowrap {
  white-space: nowrap;
}
.details {
  overflow-wrap: anywhere;
  min-width: 14rem;
}
@media (max-width: 760px) {
  table.stacked,
  table.stacked tbody,
  table.stacked tr,
  table.stacked th,
  table.stacked td {
    display: block;
  }
  table.stacked thead {
    position: absolute;
    left: -9999px;
  }
  table.stacked tr {
    border-bottom: 1px solid var(--border);
    padding: 8px 0;
  }
  table.stacked th,
  table.stacked td {
    border: 0;
    padding: 4px 0;
  }
  table.stacked td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: 12px;
    color: var(--muted);
  }
}
@media (max-width: 640px) {
  main {
    margin: 16px auto;
  }
  .card {
    padding: 16px;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .codes {
    columns: 1;
  }
}
