:root{font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#17253b;background:#f4f7fb}*{box-sizing:border-box}body{margin:0}header{background:#152f50;color:white;padding:28px 0 32px}.wrap{max-width:1100px;margin:auto;padding:0 22px}.header{display:flex;justify-content:space-between;align-items:center;gap:20px}.eyebrow{font-size:11px;letter-spacing:2px;color:#9ec5ef;font-weight:800}h1{font-size:29px;margin:8px 0}header p{color:#bfd0e4;margin:0}label{font-size:13px;font-weight:650}.datebox{display:grid;gap:8px}.datebox input{background:white}.tabs{display:flex;gap:7px;border-bottom:1px solid #dce3ee;margin:22px 0}.tab{background:transparent;color:#59677a;border:0;border-bottom:3px solid transparent;border-radius:0;padding:14px 17px;font-weight:700}.tab.active{color:#1b62b4;border-color:#2677d6}.panel{display:none}.panel.active{display:block}.stats{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px;margin:24px 0}.stat{background:white;border:1px solid #e1e8f1;border-radius:12px;padding:17px;box-shadow:0 2px 6px #1c375508}.stat span{display:block;color:#64758b;font-size:12px;margin-bottom:7px}.stat strong{font-size:30px}.toolbar{display:flex;justify-content:space-between;align-items:center;gap:14px;margin:25px 0 16px}.toolbar h2{margin:0 0 6px;font-size:21px}.toolbar p{margin:0;color:#718096;font-size:13px}button{cursor:pointer;background:#226ac0;color:white;border:1px solid #226ac0;border-radius:8px;padding:11px 15px;font-weight:650}button:hover{filter:brightness(.95)}button:disabled{opacity:.45;cursor:wait}.secondary{background:white;color:#255f9f;border-color:#c8d7e9}input,select{padding:11px 12px;border:1px solid #ccd6e3;border-radius:8px;font:inherit;background:white;color:#25374b;min-width:0}.filters{display:flex;gap:12px;margin-bottom:15px}.filters input{flex:1}.rows{background:white;border:1px solid #e1e8f1;border-radius:12px;overflow:hidden;margin-bottom:30px}.personrow{display:flex;justify-content:space-between;align-items:center;gap:14px;padding:15px 18px;border-bottom:1px solid #edf1f5}.personrow:last-child{border-bottom:0}.personname{font-weight:750}.meta{color:#7c8999;font-size:12px;margin-top:4px}.statuses{display:flex;flex-wrap:wrap;gap:6px}.status{background:#f4f7fb;border:1px solid #d9e2ed;color:#53657b;padding:8px 11px;font-size:12px}.status.selected.checked-in{background:#dff6e8;color:#11643a;border-color:#a7e4bf}.status.selected.absent{background:#ffe8e8;color:#9b2727;border-color:#f2b6b6}.status.selected.early{background:#fff0cf;color:#8d5b0b;border-color:#f3d491}.status.selected.excused{background:#e6edff;color:#3a58a0;border-color:#bac9f3}.rowactions{display:flex;gap:8px;align-items:center}.addform{display:flex;gap:12px;align-items:end;background:white;padding:18px;border:1px solid #e1e8f1;border-radius:12px;margin-bottom:16px}.addform label{flex:1;display:grid;gap:7px}.toggle{display:flex;align-items:center;gap:8px;margin-bottom:14px}.toggle input{width:17px;height:17px}.empty{padding:28px;text-align:center;color:#77869a}.inactive{opacity:.55}#message{min-height:0;color:#a72e2e;font-weight:650}#message:not(:empty){padding:12px 0}footer{text-align:center;color:#8997a7;padding:25px;font-size:12px}@media(max-width:800px){.stats{grid-template-columns:repeat(3,1fr)}.personrow{align-items:flex-start;flex-direction:column}.header{align-items:flex-start;flex-direction:column}.addform{flex-wrap:wrap}.addform label{flex-basis:40%}}@media(max-width:480px){.stats{grid-template-columns:repeat(2,1fr)}.filters{flex-direction:column}.addform{flex-direction:column;align-items:stretch}.addform label{width:100%}.tab{font-size:12px;padding:12px 9px}.stat{padding:13px}}

[hidden]{display:none!important}.login-screen{min-height:100vh;display:grid;place-items:center;background:#f0f4f8;padding:20px}.login-card{background:white;padding:32px;border-radius:16px;box-shadow:0 10px 35px #0002;width:min(100%,420px);display:grid;gap:14px}.login-card label{display:grid;gap:6px}.login-card input{width:100%;padding:12px}.login-card button{padding:12px}.datebox #logout{margin:8px 0}.datebox #userLabel{display:block;font-weight:600}#historyDetails{margin-top:24px}#loginError{color:#b42318}

/* Member list: callsign and name share the prominent first line. */
.personname{font-size:18px;line-height:1.35;overflow-wrap:anywhere}
.personrow .meta{font-size:12px;line-height:1.5}

.callsign-lookup{background:white;border:1px solid #e1e8f1;border-radius:12px;padding:18px;margin:20px 0}.callsign-lookup h3{margin:0 0 12px;font-size:18px}.lookup-form{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.lookup-form input{flex:1;min-width:150px;text-transform:uppercase}.lookup-result{margin-top:14px;border:1px solid #dce3ee;background:#f7f9fc;border-radius:8px;padding:14px;overflow-wrap:anywhere}.lookup-result pre{white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;max-height:420px;overflow-y:auto;margin-bottom:0}@media(max-width:480px){.lookup-form input{flex-basis:100%}}

.member-note{width:20ch;max-width:100%;font-size:12px;padding:8px 9px}.statuses{align-items:center}

.visitors-panel{background:white;border:1px solid #e1e8f1;border-radius:12px;padding:16px 18px;margin:0 0 16px}.visitors-panel label{display:block;margin-bottom:8px}.visitors-entry{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.visitors-entry input{width:min(100%,520px);flex:1;text-transform:uppercase}.visitors-entry span{font-size:12px;color:#64758b}

.verified-label{display:inline-block;font-size:11px;color:#11643a;background:#dff6e8;border:1px solid #a7e4bf;border-radius:5px;padding:3px 7px;vertical-align:middle}

/* Independent roster checkboxes on attendance and maintenance tabs. */
.roster-filters{display:flex;align-items:center;flex-wrap:wrap;gap:10px 22px;margin:0 0 14px;padding:12px 16px;background:#fff;border:1px solid #e1e8f1;border-radius:10px}
.roster-filters legend{font-weight:700;font-size:13px;padding:0 5px}
.roster-filters label{display:inline-flex;align-items:center;gap:7px;cursor:pointer}
.roster-filters input[type=checkbox]{width:17px;height:17px;accent-color:#226ac0}

/* History detail section is a layout container, not a member-row list. */
#historyDetails.history-details{margin:24px 0 30px;padding:20px 18px;background:#fff;border:1px solid #e1e8f1;border-radius:12px;box-shadow:0 2px 6px #1c375508;min-width:0}
#historyDetails.history-details:empty{display:none}
#historyDetails .toolbar{margin:0 0 16px;align-items:flex-start}
#historyDetails .toolbar h3{font-size:20px;line-height:1.4;margin:0 0 6px}
#historyDetails .toolbar .meta{margin:0}
#historyDetails .filters{margin:0 0 16px;width:100%}
#historyDetails .filters input{width:100%;min-width:0;flex:1}
#historyDetails #historyResultRows{margin:0;box-shadow:none}
@media(max-width:480px){#historyDetails.history-details{padding:16px 14px}#historyDetails .toolbar h3{font-size:18px}}

/* Read-only visitors for the selected history date, above the search control. */
#historyDetails .history-visitors{margin:0 0 16px;padding:12px 14px;background:#f6f9fd;border:1px solid #e1e8f1;border-radius:8px;overflow-wrap:anywhere}
#historyDetails .history-visitors-label{display:block;font-weight:600;margin-bottom:6px}
#historyDetails .history-visitors-value{font-size:14px;color:#34465c;white-space:pre-wrap}

/* Four-field member editing dialog */
.member-edit-dialog{width:min(94vw,480px);max-height:90vh;overflow-y:auto;border:1px solid #cbd5e1;border-radius:14px;padding:24px;box-shadow:0 20px 65px #0004;color:inherit;background:var(--panel,#fff)}
.member-edit-dialog::backdrop{background:rgba(15,23,42,.55)}
.member-edit-dialog h3{margin:0 0 18px}
.member-edit-fields{display:grid;grid-template-columns:1fr;gap:14px}
.member-edit-fields label{display:flex;flex-direction:column;gap:5px;font-weight:600}
.member-edit-fields input,.member-edit-fields select{width:100%;box-sizing:border-box;min-height:42px}
.member-edit-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:22px}
.member-edit-error{color:#b91c1c;margin-top:12px;font-size:.9rem}

.member-edit-lookup{margin-top:16px}.member-edit-lookup .meta{margin:8px 0 0}

.statistics-form{display:flex;align-items:end;flex-wrap:wrap;gap:14px;padding:18px;background:#fff;border:1px solid #e1e8f1;border-radius:12px}.statistics-form label{display:grid;gap:7px;flex:1;min-width:170px}.statistics-results[hidden]{display:none}.statistics-results{margin-top:18px}@media(max-width:520px){.statistics-form{flex-direction:column;align-items:stretch}}
