
:root {
  font-family: system-ui, sans-serif;
  background: #0f1720;
  color: #e8eef5;
}
body { margin: 0; }
header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 1.2rem 2rem; background: #162231; border-bottom: 1px solid #2a3a4c;
}
header h1 { margin: 0; font-size: 1.45rem; }
header p { margin: .25rem 0 0; color: #9fb0c3; }
main { max-width: 1100px; margin: 2rem auto; padding: 0 1rem; }
.cards { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 1rem; }
.card, .panel {
  background: #172433; border: 1px solid #2a3a4c; border-radius: 12px;
  padding: 1.2rem; margin-bottom: 1.2rem;
}
.card span { display: block; color: #9fb0c3; }
.card strong { display: block; font-size: 1.8rem; margin-top: .4rem; }
.good { color: #68d391; }
.bad { color: #fc8181; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: .75rem; text-align: left; border-bottom: 1px solid #2a3a4c; }
a { color: #79b8ff; }
button {
  background: #2f81f7; color: white; border: 0; border-radius: 8px;
  padding: .7rem 1rem; font-weight: 700; cursor: pointer;
}
button.secondary { background: #314052; }
input {
  width: 100%; box-sizing: border-box; margin: .4rem 0 1rem;
  padding: .75rem; border-radius: 8px; border: 1px solid #405269;
}
.narrow { max-width: 420px; margin: 5rem auto; }
.alert { background: #5b2020; padding: .75rem; border-radius: 8px; margin-bottom: 1rem; }
dl { display: grid; grid-template-columns: 150px 1fr; gap: .5rem; }
dt { color: #9fb0c3; }
dd { margin: 0; overflow-wrap: anywhere; }
.center { text-align: center; }
.qr { width: min(320px, 90%); background: white; padding: 10px; border-radius: 10px; }
.mono { font-family: ui-monospace, monospace; overflow-wrap: anywhere; }

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.button-link {
  display: inline-block;
  background: #2f81f7;
  color: white;
  padding: .7rem 1rem;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
}

.narrow-form {
  max-width: 620px;
}

/* User deletion and action controls */
.muted {
  color: #9fb0c3;
  margin: .35rem 0 0;
}

.danger-panel {
  border-color: #7f3038;
  background: #251b24;
}

.danger-label {
  display: inline-block;
  color: #fc8181;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.danger-panel h2 {
  margin: .35rem 0;
}

.danger-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.warning-text {
  color: #f6c3c7;
  padding: .8rem;
  border-left: 4px solid #fc8181;
  background: #321d23;
  border-radius: 6px;
}

.danger-button,
.danger-link {
  background: #c93c4b;
  color: white;
}

.danger-button:hover,
.danger-link:hover {
  background: #e04b5a;
}

.secondary-link {
  background: #314052;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: .75rem;
  margin-top: .5rem;
}

.table-actions {
  display: flex;
  align-items: center;
  gap: .8rem;
  white-space: nowrap;
}

.small-link {
  font-weight: 700;
  text-decoration: none;
}

.danger-text {
  color: #fc8181;
}

@media (max-width: 760px) {
  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .form-actions {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .form-actions a,
  .form-actions button {
    text-align: center;
    width: 100%;
    box-sizing: border-box;
  }

  table {
    display: block;
    overflow-x: auto;
  }
}
