:root {
  font-family:
    system-ui,
    -apple-system,
    sans-serif;
  color: #16332e;
  background: #f3f5f1;
  font-size: 16px;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
header {
  background: #142b27;
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 5%;
  gap: 16px;
}
.brand {
  font-size: 28px;
  font-weight: 900;
  letter-spacing: 2px;
}
.brand span {
  font-size: 12px;
  display: block;
  letter-spacing: 3px;
}
small {
  font-size: 11px;
  color: #abbcb3;
}
main {
  max-width: 1160px;
  margin: 32px auto;
  padding: 0 24px;
}
h1 {
  font-size: 32px;
  margin-bottom: 8px;
}
h2 {
  font-size: 21px;
}
p {
  line-height: 1.6;
}
.muted {
  color: #60766c;
}
.card {
  background: white;
  border: 1px solid #dde5dc;
  border-radius: 16px;
  padding: 24px;
  margin: 18px 0;
  break-inside: avoid;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.stat {
  font-size: 36px;
  font-weight: 750;
}
.stat small {
  display: block;
  font-size: 14px;
  color: #60766c;
  font-weight: 400;
}
nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 26px 0;
}
button,
.button {
  border: 0;
  border-radius: 8px;
  background: #1f5948;
  color: white;
  padding: 12px 18px;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  min-height: 44px;
}
button.secondary,
nav button {
  background: #e2eade;
  color: #16332e;
}
nav button.active {
  background: #1f5948;
  color: white;
}
button.danger {
  background: #933b35;
}
label {
  display: block;
  margin: 15px 0 6px;
  font-weight: 600;
  font-size: 14px;
}
input,
select,
textarea {
  display: block;
  width: 100%;
  padding: 12px;
  border: 1px solid #b8c8bc;
  border-radius: 8px;
  font: inherit;
  background: #fff;
  color: #16332e;
}
textarea {
  min-height: 100px;
}
form {
  max-width: 700px;
}
form button {
  margin-top: 18px;
}
#message:not(:empty) {
  padding: 15px 5%;
  background: #fff0cb;
  color: #653b00;
}
.badge {
  display: inline-block;
  padding: 5px 10px;
  background: #edf1e9;
  border-radius: 20px;
  font-size: 12px;
}
.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.photo {
  width: 150px;
  height: 110px;
  object-fit: cover;
  border-radius: 8px;
  margin: 6px;
}
canvas {
  border: 1px solid #b8c8bc;
  border-radius: 8px;
  width: 100%;
  max-width: 500px;
  touch-action: none;
  background: white;
}
pre {
  white-space: pre-wrap;
  font-family: inherit;
}
.login {
  max-width: 440px;
  margin: 70px auto;
}
.print-only {
  display: none;
}
#identity {
  font-size: 13px;
}
#identity button {
  margin-left: 12px;
  padding: 8px;
  font-size: 12px;
}
@media (max-width: 600px) {
  main {
    padding: 0 16px;
  }
  header {
    padding: 18px 16px;
    align-items: flex-start;
  }
  .card {
    padding: 18px;
  }
  h1 {
    font-size: 27px;
  }
  #identity {
    max-width: 160px;
  }
  .grid {
    gap: 0;
  }
}
@media print {
  header,
  nav,
  #message,
  .actions,
  form,
  .no-print,
  button {
    display: none !important;
  }
  body {
    background: white;
  }
  main {
    margin: 0;
    max-width: none;
  }
  .card {
    border: 1px solid #aaa;
  }
  .print-only {
    display: block;
  }
  .photo {
    width: 180px;
    height: auto;
  }
  h1 {
    font-size: 24px;
  }
}
.button {
  display: inline-block;
  text-decoration: none;
}
.digest {
  overflow-wrap: anywhere;
  font-size: 12px;
}
.check {
  display: flex;
  align-items: center;
  gap: 12px;
}
.check input {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}
details {
  margin: 10px 0;
}
pre {
  overflow-wrap: anywhere;
}
canvas {
  display: block;
}
input[type="file"] {
  max-width: 100%;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
@supports (padding: max(0px)) {
  body {
    padding-bottom: env(safe-area-inset-bottom);
  }
}
p,
h2 {
  overflow-wrap: anywhere;
}
.grid > * {
  min-width: 0;
}
@media (max-width: 480px) {
  nav button {
    flex: 1 1 140px;
  }
  .actions {
    align-items: stretch;
  }
  .actions button,
  .actions .button {
    max-width: 100%;
  }
  .check {
    min-height: 44px;
  }
  input,
  select,
  textarea {
    font-size: 16px;
  }
}
nav button:focus-visible,
button:focus-visible,
a:focus-visible {
  outline: 3px solid #b88718;
  outline-offset: 3px;
}
