:root {
  color-scheme: light;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: #17211e;
  background: #eef3f1;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

.shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 40px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 24px;
}

h2 {
  font-size: 17px;
  margin-bottom: 14px;
}

p,
.muted {
  color: #60706a;
  font-size: 13px;
}

.panel {
  border: 1px solid #d4dfdc;
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.loginGrid {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(160px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

label {
  display: grid;
  gap: 6px;
  color: #34413d;
  font-size: 12px;
  font-weight: 700;
}

input,
select {
  height: 38px;
  border: 1px solid #c8d4d0;
  border-radius: 6px;
  padding: 8px 10px;
  color: #17211e;
  background: #fff;
  font: inherit;
  outline: none;
}

input:focus,
select:focus {
  border-color: #0b8a6a;
  box-shadow: 0 0 0 3px rgba(11, 138, 106, 0.12);
}

button {
  min-height: 38px;
  border: 1px solid #c6d1cd;
  border-radius: 6px;
  padding: 8px 12px;
  color: #1c2824;
  background: #fff;
  font-weight: 800;
  cursor: pointer;
}

button:hover {
  border-color: #0b8a6a;
}

.primary {
  border-color: #0b8a6a;
  color: #fff;
  background: #0b8a6a;
}

.primary:hover {
  background: #087457;
}

.hidden {
  display: none;
}

.dashboard {
  display: grid;
  gap: 14px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.stats article {
  border: 1px solid #d4dfdc;
  border-radius: 8px;
  background: #fff;
  padding: 14px;
}

.stats span {
  display: block;
  font-size: 26px;
  font-weight: 900;
}

.stats small {
  color: #60706a;
}

.toolbar {
  display: flex;
  align-items: end;
  gap: 12px;
}

.events {
  display: grid;
  gap: 10px;
}

.event {
  display: grid;
  grid-template-columns: 180px 1fr auto;
  gap: 12px;
  align-items: start;
  border: 1px solid #dce5e2;
  border-radius: 8px;
  padding: 12px;
  background: #fbfcfc;
}

.event strong {
  display: block;
  margin-bottom: 4px;
}

.event code {
  display: block;
  overflow-wrap: anywhere;
  color: #54635e;
  font-size: 12px;
}

.status {
  display: inline-flex;
  width: fit-content;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 12px;
  font-weight: 800;
}

.status.info {
  color: #34586d;
  background: #eaf3f8;
}

.status.success {
  color: #0a6b54;
  background: #e8f7f2;
}

.status.error {
  color: #973022;
  background: #faeae7;
}

pre {
  max-height: 140px;
  overflow: auto;
  margin: 8px 0 0;
  border-radius: 6px;
  background: #f3f6f5;
  padding: 8px;
  white-space: pre-wrap;
  font-size: 12px;
}

dialog {
  width: min(1000px, calc(100% - 24px));
  border: 0;
  border-radius: 10px;
  padding: 0;
}

.dialogHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid #dce5e2;
  padding: 12px;
}

#screenshotImage {
  display: block;
  width: 100%;
  max-height: 78vh;
  object-fit: contain;
  background: #f5f7f6;
}

@media (max-width: 760px) {
  .loginGrid,
  .stats,
  .event {
    grid-template-columns: 1fr;
  }

  .toolbar,
  .topbar {
    align-items: stretch;
    flex-direction: column;
  }
}
