.person {
  min-width: 0;
  flex: 1;
}
.child-admin strong {
  overflow-wrap: anywhere;
  min-width: 0;
}
* {
  box-sizing: border-box;
}
:root {
  --ink: #18302b;
  --muted: #53655f;
  --green: #176348;
  --line: #d9e1dd;
  --wash: #f3f6f4;
  --red: #9e2525;
}
html {
  color: var(--ink);
  background: var(--wash);
  font:
    16px/1.5 -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  scrollbar-color: #8caaa0 var(--wash);
}
body {
  margin: 0;
}
::selection {
  background: #c8e9db;
  color: var(--ink);
}
a {
  color: var(--green);
  text-underline-offset: 3px;
}
a:hover {
  text-decoration-thickness: 2px;
}
button,
input,
select {
  font: inherit;
}
input,
select {
  caret-color: var(--green);
  accent-color: var(--green);
}
:focus-visible {
  outline: 3px solid #1d7459;
  outline-offset: 4px;
}
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.nav-wrap {
  max-width: 1120px;
  margin: auto;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 22px;
  justify-content: space-between;
}
.brand {
  font-size: 21px;
  font-weight: 750;
  text-decoration: none;
  color: var(--ink);
  line-height: 1.2;
}
.brand span {
  display: block;
  font-size: 12px;
  font-weight: 500;
  margin-top: 5px;
  color: var(--muted);
}
nav {
  display: flex;
  gap: 6px 16px;
  flex-wrap: wrap;
  align-items: center;
}
nav a,
.text-button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  font-size: 14px;
}
nav form {
  margin: 0;
}
main {
  max-width: 1080px;
  margin: 0 auto;
  padding: 30px 20px 60px;
  min-height: 75vh;
}
h1 {
  font-size: clamp(1.65rem, 4vw, 2.4rem);
  letter-spacing: -0.025em;
  line-height: 1.2;
  margin: 0 0 12px;
}
h2 {
  font-size: 1.25rem;
  line-height: 1.3;
  margin: 0 0 12px;
}
p {
  margin: 0 0 18px;
  max-width: 75ch;
}
section + section,
section > section {
  margin-top: 32px;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 20px;
}
.page-heading p {
  margin: 0;
}
.panel {
  padding: 24px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  margin: 20px 0 28px;
}
.panel h2 {
  margin-top: 0;
}
.narrow {
  max-width: 520px;
  margin: 35px auto;
}
.narrow h1 {
  max-width: 18ch;
}
.narrow label {
  display: block;
}
label {
  font-weight: 600;
}
input:not([type="checkbox"]),
select {
  display: block;
  max-width: 100%;
  width: 100%;
  min-height: 48px;
  border: 1px solid #97aaa1;
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  padding: 10px 12px;
  margin: 6px 0 12px;
}
input[type="date"] {
  width: 220px;
}
input[type="checkbox"] {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}
input[type="file"] {
  padding: 10px;
}
button,
.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 17px;
  background: var(--green);
  color: #fff;
  border: 1px solid var(--green);
  border-radius: 7px;
  text-decoration: none;
  font-weight: 650;
  cursor: pointer;
  text-align: center;
  line-height: 1.4;
}
button:hover,
.button:hover {
  background: #104e38;
}
.secondary {
  background: #fff;
  color: var(--green);
  border-color: #9bb4a8;
}
.secondary:hover {
  background: #e7efe9;
}
.danger {
  color: var(--red);
  border-color: #c9a9a9;
}
.text-button {
  padding: 0;
  border: 0;
  background: none;
  color: var(--green);
  font-weight: 400;
}
.text-button:hover {
  background: none;
  text-decoration: underline;
}
button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.actions form {
  margin: 0;
}
.check-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0;
  max-width: 70ch;
}
.helptext,
.muted {
  color: var(--muted);
  font-size: 0.9rem;
}
.helptext ul {
  padding-left: 20px;
}
.errorlist {
  color: var(--red);
}
.notice {
  padding: 16px 20px;
  background: #e0f1e8;
  border: 1px solid #a6cdb7;
  border-radius: 7px;
  margin: 12px 0 22px;
}
.notice p {
  margin-bottom: 12px;
}
.notice.error {
  background: #fff1ef;
  border-color: #d7a5a1;
  color: #7d2222;
}
.error-text {
  color: var(--red);
}
.open-banner {
  padding: 24px;
  border: 1px solid #a5c5b5;
  border-radius: 10px;
  background: #e5f1eb;
  margin: 20px 0 28px;
}
.list {
  border-top: 1px solid var(--line);
  margin-bottom: 18px;
}
.list-link,
.child-admin {
  padding: 18px 4px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.list-link {
  text-decoration: none;
  color: var(--ink);
}
.list-link:hover {
  background: #eaf1ed;
}
.list-link span {
  color: var(--muted);
  font-size: 0.95rem;
}
.empty {
  padding: 24px 0;
  color: var(--muted);
}
.range-form {
  display: flex;
  gap: 16px;
  align-items: flex-end;
  flex-wrap: wrap;
}
.range-form p {
  margin: 0;
}
.range-form input {
  margin-bottom: 0;
}
.range-form .errorlist {
  width: 100%;
}
.summary {
  padding: 16px 0;
  font-size: 1.1rem;
}
.table-scroll {
  max-width: 100%;
  overflow-x: auto;
  margin: 16px 0 28px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 7px;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-variant-numeric: tabular-nums;
}
th,
td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
thead {
  background: #e9efeb;
}
td select {
  min-width: 170px;
}
section > h2 {
  margin-top: 30px;
}
.training-sticky {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--wash);
  padding: 12px 0 14px;
  border-bottom: 1px solid var(--line);
}
.training-sticky .page-heading {
  margin: 0 0 12px;
}
.training-sticky h1 {
  font-size: clamp(1.3rem, 3.3vw, 2rem);
  margin-bottom: 8px;
}
.badge {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 5px;
  background: #e0eae4;
  font-size: 13px;
}
.counts {
  display: flex;
  gap: 8px 22px;
  flex-wrap: wrap;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.counts strong {
  margin-left: 4px;
}
#save-state {
  color: var(--muted);
  font-size: 14px;
  min-height: 42px;
  padding: 10px 0;
}
.search-label {
  display: block;
}
#search {
  max-width: 480px;
}
.attendance-list {
  margin-top: 24px;
  border-top: 1px solid var(--line);
}
.attendance-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  min-height: 100px;
}
.attendance-row h2 {
  font-size: 19px;
  margin: 0 0 5px;
  overflow-wrap: anywhere;
}
.attendance-row h2 span {
  font-weight: 450;
}
.status {
  font-size: 14px;
  color: var(--muted);
}
.status.present {
  color: #126043;
  font-weight: 700;
}
.row-save {
  display: block;
  font-size: 12px;
  color: var(--muted);
}
.switches {
  display: flex;
  gap: 24px;
}
.switch-label {
  position: relative;
  min-width: 98px;
  min-height: 64px;
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  font-size: 13px;
}
.switch-label input {
  position: absolute;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 1;
}
.switch-track {
  width: 52px;
  height: 32px;
  background: #c5cbc7;
  border-radius: 20px;
  display: block;
  position: relative;
  margin: 7px 0;
}
.switch-track:after {
  content: "";
  position: absolute;
  background: #fff;
  width: 26px;
  height: 26px;
  left: 3px;
  top: 3px;
  border-radius: 50%;
  box-shadow: 0 1px 3px #0003;
  transition: transform 0.15s ease-out;
}
.switch-label input:checked + .switch-track {
  background: #218c55;
}
.switch-label input:checked + .switch-track:after {
  transform: translateX(20px);
}
.switch-label input:focus-visible + .switch-track {
  outline: 3px solid #164d3a;
  outline-offset: 4px;
}
.switch-label:has(input:disabled) {
  cursor: not-allowed;
  opacity: 0.55;
}
.training-bottom {
  padding-top: 30px;
}
.training-bottom p {
  margin: 12px 0 24px;
}
.training-bottom .muted {
  margin-top: 28px;
}
.site-footer {
  max-width: 1080px;
  margin: 0 auto;
  border-top: 1px solid var(--line);
  padding: 20px;
  color: var(--muted);
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
}
.skip {
  position: absolute;
  top: -80px;
  left: 10px;
  z-index: 20;
  background: #fff;
  padding: 12px;
}
.skip:focus {
  top: 10px;
}
[hidden] {
  display: none !important;
}
@media (max-width: 760px) {
  .nav-wrap {
    display: block;
    padding: 15px 16px;
  }
  .brand {
    display: block;
    margin-bottom: 10px;
  }
  nav {
    gap: 0 15px;
  }
  main {
    padding: 20px 16px 40px;
  }
  .page-heading {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .child-admin,
  .list-link {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }
  .panel {
    padding: 18px;
  }
  .attendance-row {
    padding: 16px 14px;
  }
  .switches {
    gap: 12px;
  }
  .switch-label {
    min-width: 88px;
  }
  th,
  td {
    padding: 12px;
  }
  .range-form input[type="date"] {
    width: 100%;
  }
  .range-form p {
    flex: 1 1 130px;
  }
  .training-sticky {
    margin-top: -5px;
  }
  .training-sticky .page-heading {
    gap: 8px;
  }
  .training-sticky .page-heading > a {
    font-size: 13px;
    min-height: 40px;
    display: flex;
    align-items: center;
  }
}
@media (max-width: 520px) {
  .attendance-row {
    display: block;
  }
  .switches {
    margin-top: 12px;
    justify-content: space-between;
    max-width: 300px;
  }
  .switch-label {
    min-width: 110px;
    flex-direction: row;
    gap: 12px;
    font-size: 14px;
    min-height: 52px;
  }
  .switch-track {
    flex-shrink: 0;
  }
  .counts {
    gap: 6px 14px;
    font-size: 13px;
  }
  .person h2 {
    font-size: 20px;
  }
  .site-footer {
    flex-direction: column;
  }
  .table-scroll table {
    font-size: 14px;
  }
  .site-header nav a,
  .text-button {
    font-size: 13px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
